任务描述
自动刊登队列、凤凰刊登队列所有平台历史数据归档
| 所属迭代 | 技术研发中心 11月运维事项(2022年) |
|---|---|
| 所属模块 | / |
| 相关需求 | 暂无 |
| 指派给 | Closed 于 2022-11-28 14:59:02 |
| 任务类型 | 运维 |
| 任务标签 | 初始 |
| 开发组 | 有品开发组 |
| 任务状态 | 已关闭 |
| 进度 | 100% |
| 优先级 | P2 |
| 关键词 | |
| 抄送给 |
| 由谁创建 | 韦思成 于 2022-11-03 16:00:30 |
|---|---|
| 由谁完成 | 韦思成 于 2022-11-05 15:15:08 |
| 由谁取消 | 暂无 |
| 由谁关闭 | zhengqiao 于 2022-11-28 14:59:02 |
| 关闭原因 | 已完成 |
| 最后编辑 | zhengqiao 于 2022-11-28 14:59:02 |
| 团队 | 最初预计 | 总计消耗 | 预计剩余 |
|---|
| 最初预计 | 8工时 |
|---|---|
| 总计消耗 | 4工时 |
| 预计剩余 | 0工时 |
| 预计开始 | 2022-11-03 |
| 实际开始 | 2022-11-05 |
| 截止日期 | 2022-11-04 |
已处理。
-- 一、自动刊登队列近一个月以前的所有刊登失败数据 (最后执行时间:11-05)
-- 1.aliexpressDELETE a,b from ap_autopublish_aliexpress_queue a left join ap_autopublish_aliexpress_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
-- 2.mercadolibre
DELETE a,b from ap_autopublish_mercadolibre_queue a left join ap_autopublish_mercadolibre_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
-- 3.allegro
DELETE a,b from ap_autopublish_allegro_queue a left join ap_autopublish_allegro_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
-- 4.shopeev2
DELETE a,b from ap_autopublish_shopeev2_queue a left join ap_autopublish_shopeev2_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
-- 5.lazada
DELETE a,b from ap_autopublish_lazada_queue a left join ap_autopublish_lazada_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
-- 6.kogan
DELETE a,b from ap_autopublish_kogan_queue a left join ap_autopublish_kogan_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
-- 7.wish
DELETE a,b from ap_autopublish_wish_queue a left join ap_autopublish_wish_allsku b
on a.CustomerId=b.CustomerId and a.MarketId=b.MarketId and a.StrategyId=b.StrategyId and a.OrderSourceId=b.OrderSourceId and a.Sku=b.Sku
where a.CustomerId=1 and a.`Status`='failure' and a.Time < date_sub(curdate(),interval 1 month);
--二、凤凰队列近一个月以前的所有队列失败数据(最后清理时间:2022.11.03)
delete from pp_phoenixplan_wish_queue where CustomerId = 1 and MarketId=23 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_cdiscount_queue where CustomerId = 1 and MarketId=35 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_mercadolibre_queue where CustomerId = 1 and MarketId=70 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_allegro_queue where CustomerId = 1 and MarketId=67 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_kogan_queue where CustomerId = 1 and MarketId=81 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_lazada_queue where CustomerId = 1 and MarketId=58 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_aliexpress_queue where CustomerId = 1 and MarketId=57 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_shopeev2_queue where CustomerId = 1 and MarketId=97 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);
delete from pp_phoenixplan_walmart_queue where CustomerId = 1 and MarketId=45 and `Status` = 'failure' and Time < date_sub(curdate(),interval 1 month);