后端:增加商品修改时,发送 MQ 消息
后端:增加搜索服务,监听 MQ 消息,建立商品索引
This commit is contained in:
@@ -22,4 +22,11 @@ dubbo:
|
||||
port: -1
|
||||
name: dubbo
|
||||
scan:
|
||||
base-packages: cn.iocoder.mall.product.service
|
||||
base-packages: cn.iocoder.mall.product.service
|
||||
|
||||
|
||||
# rocketmq
|
||||
rocketmq:
|
||||
name-server: 127.0.0.1:9876
|
||||
producer:
|
||||
group: product-producer-group
|
||||
|
||||
@@ -32,6 +32,17 @@
|
||||
AND deleted = 0
|
||||
</select>
|
||||
|
||||
<select id="selectByIds" resultType="ProductCategoryDO">
|
||||
SELECT
|
||||
<include refid="FIELDS" />
|
||||
FROM product_category
|
||||
WHERE id IN
|
||||
<foreach collection="ids" item="id" separator="," open="(" close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
AND deleted = 0
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="ProductCategoryDO" useGeneratedKeys="true" keyColumn="id" keyProperty="id">
|
||||
INSERT INTO product_category (
|
||||
pid, name, description, pic_url, sort,
|
||||
@@ -70,4 +81,4 @@
|
||||
WHERE id = #{id}
|
||||
</update>
|
||||
|
||||
</mapper>
|
||||
</mapper>
|
||||
|
||||
Reference in New Issue
Block a user