根据时间戳重围消费位点,采用东8区时间

This commit is contained in:
许晓东
2021-11-29 19:40:46 +08:00
parent e881c58a8f
commit 39e50a6589
5 changed files with 17 additions and 3 deletions

View File

@@ -142,7 +142,7 @@ public class ConsumerServiceImpl implements ConsumerService {
@Override public ResponseData resetOffsetByDate(String groupId, String topic, String dateStr) {
long timestamp = -1L;
try {
StringBuilder sb = new StringBuilder(dateStr.replace(" ", "T")).append(".000");
StringBuilder sb = new StringBuilder(dateStr.replace(" ", "T")).append(".000+08:00");//固定为utc+08:00东8区来计算
timestamp = Utils.getDateTime(sb.toString());
} catch (ParseException e) {
throw new IllegalArgumentException(e);

View File

@@ -70,6 +70,11 @@
</a-button>
</div>
</a-table>
<p>
<strong style="color: red"
>注意重置位点时要求当前没有正在运行的消费端否则重置的时候会报错返回失败信息</strong
>
</p>
</div>
<a-modal

View File

@@ -32,6 +32,10 @@
/>
</a-form-item>
</a-form>
<hr />
<p>
*注意该时间为北京时间这里固定为东8区的计算时间如果所在地区不是采用北京时间中国大部分地区都是采用的北京时间请自行对照为当地时间重置
</p>
</a-spin>
</div>
</a-modal>

View File

@@ -30,7 +30,9 @@
<span>将集群中所有分区leader副本设置为首选副本</span>
</p>
<p>
<a-button type="primary"> 副本变更详情 </a-button>
<a-button type="primary" @click="openReplicaReassignmentDetailDialog">
副本变更详情
</a-button>
<label>说明</label>
<span>查看正在进行副本变更/重分配的任务或者将其取消</span>
</p>
@@ -183,6 +185,9 @@ export default {
closeRemoveThrottleDialog() {
this.brokerManager.showRemoveThrottleDialog = false;
},
openReplicaReassignmentDetailDialog() {
this.$message.info("此功能尚不支持,下个版本支持");
},
},
};
</script>

View File

@@ -295,7 +295,7 @@ export default {
this.showUpdateReplicaDialog = false;
},
openMessageStatsDialog() {
this.$message.info("此功能尚不支持");
this.$message.info("此功能尚不支持,下个版本支持");
},
openThrottleDialog(topic) {
this.showThrottleDialog = true;