重现步骤

严重级别:严重
所属项目:OZON
问题原因:mongodb集合t_ozon_listing_rating是由于sourceId分片键,而执行操作却全部在分片1上并发增删改查操作,把分片1节点CPU打满,执行SQL之一为("op" : "update",
"ns" : "zhcxkj_comprehensive_pilot.t_ozon_listing_rating",
"command" : {
"$truncated" : "{ q: { $and: [ { sourceId: 25848 }, { uniqueId: "25848_2236276743_100.0" } ] }, u: { $setOnInsert: { uniqueId: "25848_2236276743_100.0", _id: 32703989, createTime: new Date(1750816317730) }, $set: { rating: 100.0, pfSku: 2236276743, syncTime: "2025-06-25 09:51:57", status: 1, listingCreateTime: new Date(1749085809000), listingStatus: 3, updateTime: new Date(1750816317730), isDeleted: 0, sourceId: 25848, pfListingId: 1901054047, groups: [ { key: "important_attributes", name: "Важные атрибуты", rating: 100, weight: 30, conditions: [ { key: "important_2", description: "Заполнено 2 атрибута и более", fulfilled: true, cost: 50 }, { key: "important_50_percent", description: "Заполнено более 50% атрибутов", fulfilled: true, cost: 25 }, { key: "important_70_percent", description: "Заполнено более 70% атрибутов", fulfilled: true, cost: 25 } ], improveAttributes: [], improveAtLeast: 0, _class: "com.zhcxkj.commo..."
})
解决方案:请评估当前分片键是否适合?如果不适合,则调整分片键,如果适合请根据业务场景调整解决方式
历史记录  
  1. 2025-06-25 10:12:27, 由 万昌楠 创建。
  2. 2025-06-25 10:47:29, 由 任芳涛 解决,方案为 性能问题 。
    修改了 解决方案,旧值为 "",新值为 "performance"。
    修改了 解决版本,旧值为 "",新值为 "trunk"。
    修改了 解决日期,旧值为 "",新值为 "2025-06-25 10:46:16"。
    修改了 指派给 ,旧值为 "renfangtao",新值为 "wanchangnan"。
    修改了 Bug状态 ,旧值为 "active",新值为 "resolved"。
    修改了 是否确认,旧值为 "0",新值为 "1"。
    修改了 解决者 ,旧值为 "",新值为 "renfangtao"。

    代码已调整分片创建完成

  3. 2025-06-25 14:04:01, 由 万昌楠 编辑。
    修改了 所属模块 ,旧值为 "0",新值为 "1953"。
    修改了 业务部门 ,旧值为 "0",新值为 "2"。
    修改了 开发责任人,旧值为 "",新值为 "renfangtao"。
    修改了 测试责任人,旧值为 "",新值为 "renfangtao"。
    修改了 解决时效 ,旧值为 "0",新值为 "0.56"。
    修改了 重现步骤 ,区别为:
    001-
    001+ 严重级别:严重 所属项目:OZON 问题原因:mongodb集合t_ozon_listing_rating是由于sourceId分片键,而执行操作却全部在分片1上并发增删改查操作,把分片1节点CPU打满,执行SQL之一为("op" : "update", "ns" : "zhcxkj_comprehensive_pilot.t_ozon_listing_rating", "command" : { "$truncated" : "{ q: { $and: [ { sourceId: 25848 }, { uniqueId: "25848_2236276743_100.0" } ] }, u: { $setOnInsert: { uniqueId: "25848_2236276743_100.0", _id: 32703989, createTime: new Date(1750816317730) }, $set: { rating: 100.0, pfSku: 2236276743, syncTime: "2025-06-25 09:51:57", status: 1, listingCreateTime: new Date(1749085809000), listingStatus: 3, updateTime: new Date(1750816317730), isDeleted: 0, sourceId: 25848, pfListingId: 1901054047, groups: [ { key: "important_attributes", name: "Важные атрибуты", rating: 100, weight: 30, conditions: [ { key: "important_2", description: "Заполнено 2 атрибута и более", fulfilled: true, cost: 50 }, { key: "important_50_percent", description: "Заполнено более 50% атрибутов", fulfilled: true, cost: 25 }, { key: "important_70_percent", description: "Заполнено более 70% атрибутов", fulfilled: true, cost: 25 } ], improveAttributes: [], improveAtLeast: 0, _class: "com.zhcxkj.commo..." }) 解决方案:请评估当前分片键是否适合?如果不适合,则调整分片键,如果适合请根据业务场景调整解决方式
    002- 严重级别:严重
    003- 所属项目:OZON
    004- 问题原因:mongodb集合t_ozon_listing_rating是由于sourceId分片键,而执行操作却全部在分片1上并发增删改查操作,把分片1节点CPU打满,执行SQL之一为("op" : "update",
    005- "ns" : "zhcxkj_comprehensive_pilot.t_ozon_listing_rating",
    006- "command" : {
    007- "$truncated" : "{ q: { $and: [ { sourceId: 25848 }, { uniqueId: "25848_2236276743_100.0" } ] }, u: { $setOnInsert: { uniqueId: "25848_2236276743_100.0", _id: 32703989, createTime: new Date(1750816317730) }, $set: { rating: 100.0, pfSku: 2236276743, syncTime: "2025-06-25 09:51:57", status: 1, listingCreateTime: new Date(1749085809000), listingStatus: 3, updateTime: new Date(1750816317730), isDeleted: 0, sourceId: 25848, pfListingId: 1901054047, groups: [ { key: "important_attributes", name: "Важные атрибуты", rating: 100, weight: 30, conditions: [ { key: "important_2", description: "Заполнено 2 атрибута и более", fulfilled: true, cost: 50 }, { key: "important_50_percent", description: "Заполнено более 50% атрибутов", fulfilled: true, cost: 25 }, { key: "important_70_percent", description: "Заполнено более 70% атрибутов", fulfilled: true, cost: 25 } ], improveAttributes: [], improveAtLeast: 0, _class: "com.zhcxkj.commo..."
    008- })
    009- 解决方案:请评估当前分片键是否适合?如果不适合,则调整分片键,如果适合请根据业务场景调整解决方式
    001- <br />
    001+ <br /> 严重级别:严重<br /> 所属项目:OZON<br /> 问题原因:mongodb集合t_ozon_listing_rating是由于sourceId分片键,而执行操作却全部在分片1上并发增删改查操作,把分片1节点CPU打满,执行SQL之一为("op" : "update",<br /> "ns" : "zhcxkj_comprehensive_pilot.t_ozon_listing_rating",<br /> "command" : {<br /> "$truncated" : "{ q: { $and: [ { sourceId: 25848 }, { uniqueId: "25848_2236276743_100.0" } ] }, u: { $setOnInsert: { uniqueId: "25848_2236276743_100.0", _id: 32703989, createTime: new Date(1750816317730) }, $set: { rating: 100.0, pfSku: 2236276743, syncTime: "2025-06-25 09:51:57", status: 1, listingCreateTime: new Date(1749085809000), listingStatus: 3, updateTime: new Date(1750816317730), isDeleted: 0, sourceId: 25848, pfListingId: 1901054047, groups: [ { key: "important_attributes", name: "Важные атрибуты", rating: 100, weight: 30, conditions: [ { key: "important_2", description: "Заполнено 2 атрибута и более", fulfilled: true, cost: 50 }, { key: "important_50_percent", description: "Заполнено более 50% атрибутов", fulfilled: true, cost: 25 }, { key: "important_70_percent", description: "Заполнено более 70% атрибутов", fulfilled: true, cost: 25 } ], improveAttributes: [], improveAtLeast: 0, _class: "com.zhcxkj.commo..."<br /> })<br /> 解决方案:请评估当前分片键是否适合?如果不适合,则调整分片键,如果适合请根据业务场景调整解决方式
    002- 严重级别:严重<br />
    003- 所属项目:OZON<br />
    004- 问题原因:mongodb集合t_ozon_listing_rating是由于sourceId分片键,而执行操作却全部在分片1上并发增删改查操作,把分片1节点CPU打满,执行SQL之一为("op" : "update",<br />
    005- "ns" : "zhcxkj_comprehensive_pilot.t_ozon_listing_rating",<br />
    006- "command" : {<br />
    007- "$truncated" : "{ q: { $and: [ { sourceId: 25848 }, { uniqueId: "25848_2236276743_100.0" } ] }, u: { $setOnInsert: { uniqueId: "25848_2236276743_100.0", _id: 32703989, createTime: new Date(1750816317730) }, $set: { rating: 100.0, pfSku: 2236276743, syncTime: "2025-06-25 09:51:57", status: 1, listingCreateTime: new Date(1749085809000), listingStatus: 3, updateTime: new Date(1750816317730), isDeleted: 0, sourceId: 25848, pfListingId: 1901054047, groups: [ { key: "important_attributes", name: "Важные атрибуты", rating: 100, weight: 30, conditions: [ { key: "important_2", description: "Заполнено 2 атрибута и более", fulfilled: true, cost: 50 }, { key: "important_50_percent", description: "Заполнено более 50% атрибутов", fulfilled: true, cost: 25 }, { key: "important_70_percent", description: "Заполнено более 70% атрибутов", fulfilled: true, cost: 25 } ], improveAttributes: [], improveAtLeast: 0, _class: "com.zhcxkj.commo..."<br />
    008- })<br />
    009- 解决方案:请评估当前分片键是否适合?如果不适合,则调整分片键,如果适合请根据业务场景调整解决方式
  4. 2025-06-25 14:04:04, 由 万昌楠 关闭。
    修改了 Bug状态 ,旧值为 "resolved",新值为 "closed"。
    修改了 指派给 ,旧值为 "wanchangnan",新值为 "closed"。
    修改了 由谁关闭,旧值为 "",新值为 "wanchangnan"。
    修改了 关闭日期,旧值为 "",新值为 "2025-06-25 14:04:04"。
所属项目 技术中心-需求池
所属模块 多平台   OZON
所属计划
所属迭代
Bug类型
严重程度 一般
优先级 P2
Bug状态 已关闭
业务部门 总经办
影响功能
开发责任人 任芳涛
测试责任人 任芳涛
解决时效 0.56
激活次数 0
激活日期
是否确认 是
当前指派 Closed 于 2025-06-25 14:04:04
截止日期 0000-00-00
上线时间 2025-06-25 10:47:29
上线时效 0.58
操作系统
浏览器
关键词
抄送给
所属迭代
相关需求
相关任务
由谁创建 万昌楠 于 2025-06-25 10:12:27
影响环境 生产环境-业务反馈
由谁解决 任芳涛 于 2025-06-25 10:46:16
解决版本 主干
解决方案 性能问题
由谁关闭 万昌楠 于 2025-06-25 14:04:04
最后修改 万昌楠 于 2025-06-25 14:04:04
相关Bug