“mitao”
2026-02-25 bfe14c42d806ef369993940573245b954fddfc8e
Merge remote-tracking branch 'origin/master'
24个文件已修改
362 ■■■■■ 已修改文件
xp-robotaxi-account-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-api/src/main/java/com/xiaopeng/api/factory/order/XpCruiseOrderClientFallbackFactory.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-api/src/main/java/com/xiaopeng/api/feignClient/order/XpCruiseOrderClient.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-api/src/main/java/com/xiaopeng/api/model/operation/XpPoint.java 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-automatic-pilot-boot/src/main/java/com/xiaopeng/automaticPilot/service/KafkaConsumerService.java 100 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-automatic-pilot-boot/src/main/resources/seata.conf 4 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-itinerary-boot/src/main/java/com/xiaopeng/itinerary/service/impl/XpPricingServiceImpl.java 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-itinerary-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-maintenance-boot/src/main/java/com/xiaopeng/maintenance/controller/XpVehicleOperationsController.java 48 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-maintenance-boot/src/main/java/com/xiaopeng/maintenance/dto/VehicleDispatchDepartureDTO.java 1 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-maintenance-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-map-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-operation-boot/src/main/java/com/xiaopeng/operation/controller/XpPointManagementController.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-operation-boot/src/main/resources/bootstrap.yml 92 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-operation-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/controller/XpCruiseOrderController.java 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/service/IXpCruiseOrderService.java 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/service/impl/XpCruiseOrderServiceImpl.java 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/service/impl/XpOrderServiceImpl.java 39 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-order-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-payment-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-push-message-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-remote-driving-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-vehicle-convoy-boot/src/main/resources/seata.conf 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
xp-robotaxi-account-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-account-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-api/src/main/java/com/xiaopeng/api/factory/order/XpCruiseOrderClientFallbackFactory.java
@@ -42,6 +42,12 @@
            }
            @Override
            public R<String> closeCruiseOrder(String vin) {
                log.error("订单服务调用失败: {}", cause.getMessage());
                return null;
            }
            @Override
            public R<XpCruiseOrder> getCruiseOrder(String orderId) {
                log.error("订单服务调用失败: {}", cause.getMessage());
                return null;
xp-robotaxi-api/src/main/java/com/xiaopeng/api/feignClient/order/XpCruiseOrderClient.java
@@ -46,6 +46,12 @@
    /**
     * 关闭
     */
    @PostMapping("/inner/cruiseOrder/closeCruiseOrder")
    R<String> closeCruiseOrder(@RequestParam String vin);
    /**
     * 查询订单信息
     *
     * @param orderId 订单信息id
xp-robotaxi-api/src/main/java/com/xiaopeng/api/model/operation/XpPoint.java
@@ -89,7 +89,11 @@
    @TableField(exist = false)
    private BigDecimal distance;
    @ApiModelProperty(value = "0正常点位  1充电点位  2收车点位")
    @TableField(exist = false)
    private Integer type;
    @ApiModelProperty(value = "0否 1是充电点位")
    @TableField("charge_point")
    private Integer chargePoint;
    @ApiModelProperty(value = "0否 1是收车点位")
    @TableField("parking_point")
    private Integer parkingPoint;
}
xp-robotaxi-automatic-pilot-boot/src/main/java/com/xiaopeng/automaticPilot/service/KafkaConsumerService.java
@@ -51,6 +51,7 @@
import com.xiaopeng.common.core.utils.SnowFlake;
import com.xiaopeng.common.core.utils.StringUtils;
import com.xiaopeng.common.core.utils.uuid.UUID;
import com.xiaopeng.common.redis.service.RedisService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.mongodb.core.MongoTemplate;
@@ -103,6 +104,8 @@
    @Resource
    private Snowflake snowflake;
    @Autowired
    private RedisService redisService;
    /**
@@ -476,17 +479,37 @@
        //订单类型  1:乘客订单,2=巡游订单
        LonLatDto destination = new LonLatDto();
        LonLatDto origin = new LonLatDto();
        //导航id
        String routeID = "";
        Long vehicleId = null;
        if (orderId.contains("XU")) {
            // todo 下发巡游单的导航数据
            //巡游单
            if (orderPhase.equals(OrderPhase.ROUTE_TO_CRUISE)) {
                origin.setLongitude(116.40528);
                origin.setLatitude(39.90498);
                destination.setLongitude(116.40528);
                destination.setLatitude(39.90498);
                //先响应消息
                responseMessage(sequence, "");
                /* 构建导航数据给到车端 */
                R<XpCruiseOrder> cruiseOrder = xpCruiseOrderClient.getCruiseOrder(orderId);
                XpCruiseOrder xpCruiseOrder = cruiseOrder.getData();
                origin.setLongitude(xpCruiseOrder.getStartLon());
                origin.setLatitude(xpCruiseOrder.getStartLat());
                destination.setLongitude(xpCruiseOrder.getEndLon());
                destination.setLatitude(xpCruiseOrder.getEndLat());
                OrderRouteAndFareDto dto = new OrderRouteAndFareDto();
                dto.setOrderId(Long.parseLong(orderId));
                dto.setOrigin(origin);
                dto.setDestination(destination);
                R<RouteVo> routeVoR = xpMapClient.getOrderDistanceAndDuration(dto);
                if (200 != routeVoR.getCode()) {
                    throw new RuntimeException("获取订单线路和运费失败");
                }
                RouteVo routeVo = routeVoR.getData();
                routeID = routeVo.getRouteID();
//                vehicleId = xpOrder.getVehicleId();
            }
        } else {
            //正常单
@@ -510,31 +533,57 @@
                origin.setLatitude(vehiclePosition.getPoint().getY());
                destination.setLongitude(xpOrder.getStartLon());
                destination.setLatitude(xpOrder.getStartLat());
                OrderRouteAndFareDto dto = new OrderRouteAndFareDto();
                dto.setOrderId(Long.parseLong(orderId));
                dto.setOrigin(origin);
                dto.setDestination(destination);
                R<RouteVo> routeVoR = xpMapClient.getOrderDistanceAndDuration(dto);
                if (200 != routeVoR.getCode()) {
                    throw new RuntimeException("获取订单线路和运费失败");
                }
                RouteVo routeVo = routeVoR.getData();
                routeID = routeVo.getRouteID();
            }
            //驶往下车点的行程
            if (orderPhase.equals(OrderPhase.ROUTE_TO_DESTINATION)) {
                //查询起点到终点的线路
                origin.setLongitude(xpOrder.getStartLon());
                origin.setLatitude(xpOrder.getStartLat());
                destination.setLongitude(xpOrder.getEndLon());
                destination.setLatitude(xpOrder.getEndLat());
                //直接取缓存中的导航数据推送给车端和乘客
                Object cacheObject = redisService.getCacheObject("ORDER_NAVIGATION_DATA:" + xpOrder.getAppUserId());
                if(null == cacheObject){
                    //没有缓存数据,重新规划线路
                    //查询起点到终点的线路
                    origin.setLongitude(xpOrder.getStartLon());
                    origin.setLatitude(xpOrder.getStartLat());
                    destination.setLongitude(xpOrder.getEndLon());
                    destination.setLatitude(xpOrder.getEndLat());
                    OrderRouteAndFareDto dto = new OrderRouteAndFareDto();
                    dto.setOrderId(Long.parseLong(orderId));
                    dto.setOrigin(origin);
                    dto.setDestination(destination);
                    R<RouteVo> routeVoR = xpMapClient.getOrderDistanceAndDuration(dto);
                    if (200 != routeVoR.getCode()) {
                        throw new RuntimeException("获取订单线路和运费失败");
                    }
                    RouteVo routeVo = routeVoR.getData();
                    routeID = routeVo.getRouteID();
                    //缓存导航数据,用于后面的逻辑中给乘客端推送导航数据
                    redisService.setCacheObject("ORDER_NAVIGATION_DATA:" + xpOrder.getAppUserId(), com.alibaba.fastjson.JSON.toJSONString(routeVo), 24L, TimeUnit.HOURS);
                }else{
                    RouteVo routeVo = JSON.parseObject(cacheObject.toString(), RouteVo.class);
                    routeID = routeVo.getRouteID();
                }
            }
            OrderRouteAndFareDto dto = new OrderRouteAndFareDto();
            dto.setOrderId(Long.parseLong(orderId));
            dto.setOrigin(origin);
            dto.setDestination(destination);
            R<RouteVo> routeVoR = xpMapClient.getOrderDistanceAndDuration(dto);
            if (200 != routeVoR.getCode()) {
                throw new RuntimeException("获取订单线路和运费失败");
            }
            XpVehicle xpVehicle = xpVehicleClient.queryById(xpOrder.getVehicleId()).getData();
            RouteVo routeVo = routeVoR.getData();
            R<String> stringR = xpMapClient.queryRouted(routeVo.getRouteID());
            vehicleId = xpOrder.getVehicleId();
        }
        if(StringUtils.isNotEmpty(routeID)){
            XpVehicle xpVehicle = xpVehicleClient.queryById(vehicleId).getData();
            R<String> stringR = xpMapClient.queryRouted(routeID);
            if (200 != stringR.getCode()) {
                throw new RuntimeException("根据导航ID获取车端需要的导航数据失败");
            }
            //构建导航下发请求对象
            cloudPushNavigationInfo(requestId, routeVo.getRouteID(), stringR.getData(), orderId, xpVehicle.getVehicleVin(), xpVehicle.getXpuId());
            cloudPushNavigationInfo(requestId, routeID, stringR.getData(), orderId, xpVehicle.getVehicleVin(), xpVehicle.getXpuId());
        }
    }
@@ -707,15 +756,15 @@
            //到达目的地
            if(OrderStatusEnum.COMPLETED.equals(status)){
                    // 返程找到目前的订单 -》之前的订单 查询生成一个   正常巡游 找到下一个点位   若到达最后点位  则反向找点位  每次判断是否收车状态 是则不进行处理了
                // 返程找到目前的订单 -》之前的订单 查询生成一个   正常巡游 找到下一个点位   若到达最后点位  则反向找点位  每次判断是否收车状态 是则不进行处理了
                // 找到这个订单
                R<XpCruiseOrder> cruiseOrder = xpCruiseOrderClient.getCruiseOrder(orderId);
                if(cruiseOrder!=null){
                    XpCruiseOrder xpCruiseOrder = cruiseOrder.getData();
                    Long vehicleId = xpCruiseOrder.getVehicleId();
                    // 关闭当前巡游单子
                    xpCruiseOrderClient.updateCruiseOrder(xpCruiseOrder.getVehicleVin());
                    // 关闭当前巡游单子 已完成
                    xpCruiseOrderClient.closeCruiseOrder(xpCruiseOrder.getVehicleVin());
                    R<XpVehicle> xpVehicleR = xpVehicleClient.queryById(vehicleId);
                    XpVehicle xpVehicle = xpVehicleR.getData();
                    // 运营中 继续执行
@@ -727,6 +776,7 @@
                            // 修改一下id 加一个一样的巡游单子
                            lastXpCruiseOrder.setId("XU"+ IdUtil.fastUUID());
                            lastXpCruiseOrder.setStatus(1);
                            xpCruiseOrderClient.addCruiseOrder(lastXpCruiseOrder);
xp-robotaxi-automatic-pilot-boot/src/main/resources/seata.conf
@@ -1,5 +1,7 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-automaticPilot"  # 与spring.application.name一致
    application.id = "xp-robotaxi-automatic-pilot-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
}
xp-robotaxi-itinerary-boot/src/main/java/com/xiaopeng/itinerary/service/impl/XpPricingServiceImpl.java
@@ -351,7 +351,8 @@
        String voJsonStr = JSONObject.toJSONString(routeAndFareVo);
        // 进行缓存
        redisService.setCacheObject(key, voJsonStr, 5l, TimeUnit.MINUTES);
        //缓存导航数据,用于下单后推送导航给车端和乘客端
        redisService.setCacheObject("ORDER_NAVIGATION_DATA:" + userId, JSON.toJSONString(routeVo), 24L, TimeUnit.HOURS);
        return routeAndFareVo;
    }
xp-robotaxi-itinerary-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-itinerary-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-maintenance-boot/src/main/java/com/xiaopeng/maintenance/controller/XpVehicleOperationsController.java
@@ -1,9 +1,17 @@
package com.xiaopeng.maintenance.controller;
import cn.hutool.core.util.IdUtil;
import com.sun.xml.internal.bind.v2.TODO;
import com.xiaopeng.api.dto.automaticPilot.PushOrderDto;
import com.xiaopeng.api.feignClient.automaticPilot.OrderMissionClient;
import com.xiaopeng.api.feignClient.order.XpCruiseOrderClient;
import com.xiaopeng.api.feignClient.vehicleConvoy.XpVehicleClient;
import com.xiaopeng.api.model.order.XpCruiseOrder;
import com.xiaopeng.api.model.vehicleConvoy.XpVehicle;
import com.xiaopeng.api.vo.automaticPilot.VehiclePosition;
import com.xiaopeng.common.core.domain.R;
import com.xiaopeng.common.core.web.page.PageInfo;
import com.xiaopeng.common.redis.service.RedisService;
import com.xiaopeng.maintenance.dto.VehicleDispatchAcceptDTO;
import com.xiaopeng.maintenance.dto.VehicleDispatchDepartureDTO;
import com.xiaopeng.maintenance.model.query.OperationRecordsQuery;
@@ -13,10 +21,17 @@
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.mongodb.core.MongoTemplate;
import org.springframework.data.mongodb.core.geo.GeoJsonPoint;
import org.springframework.data.mongodb.core.query.Criteria;
import org.springframework.data.mongodb.core.query.Query;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
 * <p>
@@ -35,6 +50,12 @@
    private IXpVehiclePreparationService xpVehiclePreparationService;
    @Autowired
    private XpVehicleClient xpVehicleClient;
    @Autowired
    private XpCruiseOrderClient xpCruiseOrderClient;
    @Autowired
    private MongoTemplate mongoTemplate;
    @Autowired
    private OrderMissionClient orderMissionClient;
    /**
     * 车辆详情-车辆调度-发车 收车
@@ -56,7 +77,32 @@
        if(dto.getDepartureStatus()==1){
            // 找车辆的任务  生成巡游单子 下发命令 TODO
        }else if(dto.getDepartureStatus()==3){
            // 收车 关闭当前巡游单子 生成新的返程单子  找到收车站点 TODO
            // 收车 关闭当前巡游单子 生成新的返程单子  找到收车站点
            R<String> r = xpCruiseOrderClient.updateCruiseOrder(xpVehicle.getVehicleVin());
            // redis 获取当前最新经纬度位置
            VehiclePosition vehiclePosition = mongoTemplate.findOne(new Query(Criteria.where("vin").is(xpVehicle.getVehicleVin())), VehiclePosition.class);
            double x = vehiclePosition.getPoint().getX();
            double y = vehiclePosition.getPoint().getY();
            XpCruiseOrder xpCruiseOrder = new XpCruiseOrder();
            xpCruiseOrder.setId("XU"+ IdUtil.fastUUID());
            xpCruiseOrder.setVehicleId(xpVehicle.getId());
            xpCruiseOrder.setOrderType(2);
            xpCruiseOrder.setStartLon(x);
            xpCruiseOrder.setStartLat(y);
            // TODO 找到收车站点
            xpCruiseOrder.setStatus(1);
            // 下发命令
            orderMissionClient.pushOrder(new PushOrderDto( xpCruiseOrder.getVehicleVin(),xpCruiseOrder.getId(),null));
        }
        return R.ok();
xp-robotaxi-maintenance-boot/src/main/java/com/xiaopeng/maintenance/dto/VehicleDispatchDepartureDTO.java
@@ -16,4 +16,5 @@
    @ApiModelProperty(value = "发车状态 1=发车 3=收车")
    private Integer departureStatus;
}
xp-robotaxi-maintenance-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-maintenance-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-map-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-map-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-operation-boot/src/main/java/com/xiaopeng/operation/controller/XpPointManagementController.java
@@ -120,9 +120,9 @@
    @PostMapping("/setSpecialPoint")
    @ApiOperation(value = "设置特殊点位")
    public R setSpecialPoint(@RequestBody XpPointSpecialDto dto) {
        xpPointService.update(new LambdaUpdateWrapper<XpPoint>().set(XpPoint::getType, 0));
        xpPointService.update(new LambdaUpdateWrapper<XpPoint>().in(XpPoint::getId,dto.getChargePoints()).set(XpPoint::getType,1));
        xpPointService.update(new LambdaUpdateWrapper<XpPoint>().in(XpPoint::getId,dto.getParkingPoints()).set(XpPoint::getType,2));
        xpPointService.update(new LambdaUpdateWrapper<XpPoint>().set(XpPoint::getChargePoint, 0).set(XpPoint::getParkingPoint,0));
        xpPointService.update(new LambdaUpdateWrapper<XpPoint>().in(XpPoint::getId,dto.getChargePoints()).set(XpPoint::getChargePoint,1));
        xpPointService.update(new LambdaUpdateWrapper<XpPoint>().in(XpPoint::getId,dto.getParkingPoints()).set(XpPoint::getParkingPoint,2));
        return R.ok();
    }
}
xp-robotaxi-operation-boot/src/main/resources/bootstrap.yml
@@ -160,95 +160,3 @@
          - application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
---
#---
#spring:
#  shardingsphere:
#    props:
#      sql-show: true
#      sql-simple: true
#    datasource:
#      names: xp0
#      xp0:
#        type: com.alibaba.druid.pool.DruidDataSource
#        driver-class-name: com.mysql.cj.jdbc.Driver
#        url: jdbc:mysql://192.168.110.34:3306/xprt_operation?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
#        username: root
#        password: 123456
#    rules:
#      sharding:
#        tables:
#          sys_oper_log:
#            actual-data-nodes: xp0.sys_oper_log
#            database-strategy:
#              standard:
#                sharding-column: userId
#                sharding-algorithm-name: sys-oper-log-inline
#            key-generate-strategy:
#              column: oper_id
#              key-generator-name: snowflake
#          xp_agreement_app_user:
#            actual-data-nodes: xp0.xp_agreement_app_user
#            database-strategy:
#              standard:
#                sharding-column: app_user_id
#                sharding-algorithm-name: xp-agreement-app-user-inline
#            key-generate-strategy:
#              column: id
#              key-generator-name: snowflake
#          xp_point:
#            actual-data-nodes: xp0.xp_point
#            database-strategy:
#              standard:
#                sharding-column: id
#                sharding-algorithm-name: xp-point-inline
#            key-generate-strategy:
#              column: id
#              key-generator-name: snowflake
#        sharding-algorithms:
#          sys-oper-log-inline:
#            type: INLINE
#            props:
#              algorithm-expression: sys_oper_log
#          xp-agreement-app-user-inline:
#            type: INLINE
#            props:
#              algorithm-expression: xp_agreement_app_user
#          xp-point-inline:
#            type: INLINE
#            props:
#              algorithm-expression: xp_point
#        key-generators:
#          snowflake:
#            type: SNOWFLAKE
#    single-table:
#      tables:
#        - xp0.sys_config
#        - xp0.sys_dict_data
#        - xp0.sys_dict_type
#        - xp0.sys_logininfor
#        - xp0.sys_menu
#        - xp0.xp_acticity
#        - xp0.xp_acticity_coupon
#        - xp0.xp_agreement
#        - xp0.xp_banner
#        - xp0.xp_coupon
#        - xp0.xp_electronic_fence
#        - xp0.xp_electronic_fence_area
#        - xp0.xp_feedback_type
#        - xp0.xp_frequently_asked_questions
#        - xp0.xp_invitation_code
#        - xp0.xp_notification
#        - xp0.xp_open_city
#        - xp0.xp_pricing
#        - xp0.xp_pricing_item
#        - xp0.xp_region
#        - xp0.xp_ride_guide
#        - xp0.xp_route_plan
#        - xp0.xp_system_setting
#        - xp0.xp_trading_strategy
#        - xp0.xp_trading_strategy_city
#        - xp0.xp_user_feedback
#        - xp0.xp_whitelist
#        - xp0.xp_whitelist_operlog
xp-robotaxi-operation-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-operation-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/controller/XpCruiseOrderController.java
@@ -32,7 +32,7 @@
    /**
     * 查询并关闭订单信息  返回id信息
     * 查询并终止订单信息  返回id信息
     *
     * @param
     */
@@ -41,6 +41,16 @@
        String id = xpCruiseOrderService.updateCruiseOrder(vin);
        return R.ok(id);
    }
    /**
     * 查询并完成订单信息  返回id信息
     *
     * @param
     */
    @PostMapping("/inner/cruiseOrder/closeCruiseOrder")
    public R<String> closeCruiseOrder(@RequestParam String vin) {
        String id = xpCruiseOrderService.closeCruiseOrder(vin);
        return R.ok(id);
    }
    /**
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/service/IXpCruiseOrderService.java
@@ -39,4 +39,7 @@
    String updateCruiseOrder(String vin);
    String closeCruiseOrder(String vin);
}
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/service/impl/XpCruiseOrderServiceImpl.java
@@ -130,4 +130,16 @@
        }
        return null;
    }
    @Override
    public String closeCruiseOrder(String vin) {
        LambdaQueryWrapper<XpCruiseOrder> wrapper = new LambdaQueryWrapper<XpCruiseOrder>().eq(XpCruiseOrder::getVehicleVin, vin).eq(XpCruiseOrder::getStatus, 1);
        XpCruiseOrder xpCruiseOrder = this.getOne(wrapper);
        if (xpCruiseOrder != null) {
            xpCruiseOrder.setStatus(3);
            this.update(xpCruiseOrder, wrapper);
            return xpCruiseOrder.getId();
        }
        return null;
    }
}
xp-robotaxi-order-boot/src/main/java/com/xiaopeng/order/service/impl/XpOrderServiceImpl.java
@@ -1666,25 +1666,28 @@
        // TODO appid
        addTaxiPassengerVo.setAppId("");
        // Redis弹出这个队列元素
        // value 订单Id_经纬度_状态_用户id_订单编号_距离_时间
        String popFirstElement = redisService.popFirstElement(order.getQueueName());
        XpGeoQueryEntity xpGeoQueryEntity = new XpGeoQueryEntity();
        String[] split = popFirstElement.split("_");
        xpGeoQueryEntity.setOrderId(split[0]);
        // 存mongo数据
        xpPricingClient.updateXpGeoQueryEntity(split[0]);
        this.updateById(order);
        // 修改车辆信息
        vehicle.setState(1);
        xpVehicleClient.updateVehicleById(vehicle);
        // 推送点位轨迹信息
        // 绑定关系
        BaseVehicleUserDto baseVehicleUserDto = userVehicleClient.addTaxiPassenger(addTaxiPassengerVo);
        if (baseVehicleUserDto.getCode() == 200) {
            // Redis弹出这个队列元素
            // value 订单Id_经纬度_状态_用户id_订单编号_距离_时间
            String popFirstElement = redisService.popFirstElement(order.getQueueName());
            XpGeoQueryEntity xpGeoQueryEntity = new XpGeoQueryEntity();
            String[] split = popFirstElement.split("_");
            xpGeoQueryEntity.setOrderId(split[0]);
            // 存mongo数据
            xpPricingClient.updateXpGeoQueryEntity(split[0]);
            this.updateById(order);
            // 修改车辆信息
            vehicle.setState(1);
            xpVehicleClient.updateVehicleById(vehicle);
        }
    }
xp-robotaxi-order-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-order-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-payment-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-payment-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-push-message-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-push-message-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-remote-driving-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-remote-driving-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"
xp-robotaxi-vehicle-convoy-boot/src/main/resources/seata.conf
@@ -1,4 +1,6 @@
# seata.conf
shardingsphere.transaction.seata.at.enable = true
shardingsphere.transaction.seata.tx.timeout = 60
client {
    application.id = "xp-robotaxi-vehicle-convoy-boot"  # 与spring.application.name一致
    transaction.service.group = "seata_tx_group"