|
@@ -16,17 +16,17 @@ func CollectMap() {
|
|
command = append(command, "record")
|
|
command = append(command, "record")
|
|
command = append(command, "-O "+config.CloudConfig.MapBagPath)
|
|
command = append(command, "-O "+config.CloudConfig.MapBagPath)
|
|
command = append(command, "-l 1")
|
|
command = append(command, "-l 1")
|
|
- _, err := util.ExecuteWithEnvAndDirAsync(config.RosbagEnvs, config.CloudConfig.BagDataDir, config.RosbagPath, command...)
|
|
|
|
|
|
+ _, s, err := util.ExecuteWithEnvAndDir(config.RosbagEnvs, config.CloudConfig.BagDataDir, config.RosbagPath, command...)
|
|
if err != nil {
|
|
if err != nil {
|
|
- c_log.GlobalLogger.Error("程序异常退出。采集地图", command, "出错:", err)
|
|
|
|
|
|
+ c_log.GlobalLogger.Error("程序异常退出。采集地图", command, "出错:", s, "----", err)
|
|
os.Exit(-1)
|
|
os.Exit(-1)
|
|
}
|
|
}
|
|
config.OssMutex.Lock()
|
|
config.OssMutex.Lock()
|
|
err = config.OssBucket.PutObjectFromFile(ossMapBagObjectKey, config.CloudConfig.MapBagPath)
|
|
err = config.OssBucket.PutObjectFromFile(ossMapBagObjectKey, config.CloudConfig.MapBagPath)
|
|
config.OssMutex.Unlock()
|
|
config.OssMutex.Unlock()
|
|
if err != nil {
|
|
if err != nil {
|
|
- c_log.GlobalLogger.Error("程序异常退出。上传地图包", ossMapBagObjectKey, "->", ossMapBagObjectKey, "出错:", err)
|
|
|
|
|
|
+ c_log.GlobalLogger.Error("程序异常退出。上传地图包", config.CloudConfig.MapBagPath, "->", ossMapBagObjectKey, "出错:", err)
|
|
os.Exit(-1)
|
|
os.Exit(-1)
|
|
}
|
|
}
|
|
- c_log.GlobalLogger.Error("上传地图包", ossMapBagObjectKey, "->", ossMapBagObjectKey, "成功。")
|
|
|
|
|
|
+ c_log.GlobalLogger.Error("上传地图包", config.CloudConfig.MapBagPath, "------", ossMapBagObjectKey, "成功。")
|
|
}
|
|
}
|