mirror of
https://github.com/didi/KnowStreaming.git
synced 2026-01-05 13:08:48 +08:00
Merge pull request #239 from Liu-XinYuan/i238
fix create topic failed when not specify peak_byte_in
This commit is contained in:
@@ -40,6 +40,9 @@ public class TopicCreationDTO extends ClusterTopicDTO {
|
|||||||
@ApiModelProperty(value = "Topic属性列表")
|
@ApiModelProperty(value = "Topic属性列表")
|
||||||
private Properties properties;
|
private Properties properties;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "最大写入字节数")
|
||||||
|
private Long peakBytesIn;
|
||||||
|
|
||||||
public String getAppId() {
|
public String getAppId() {
|
||||||
return appId;
|
return appId;
|
||||||
}
|
}
|
||||||
@@ -104,6 +107,14 @@ public class TopicCreationDTO extends ClusterTopicDTO {
|
|||||||
this.properties = properties;
|
this.properties = properties;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Long getPeakBytesIn() {
|
||||||
|
return peakBytesIn;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPeakBytesIn(Long peakBytesIn) {
|
||||||
|
this.peakBytesIn = peakBytesIn;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "TopicCreationDTO{" +
|
return "TopicCreationDTO{" +
|
||||||
@@ -135,4 +146,4 @@ public class TopicCreationDTO extends ClusterTopicDTO {
|
|||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.xiaojukeji.kafka.manager.common.entity.pojo;
|
package com.xiaojukeji.kafka.manager.common.entity.pojo;
|
||||||
|
|
||||||
import com.xiaojukeji.kafka.manager.common.entity.dto.op.topic.TopicCreationDTO;
|
import com.xiaojukeji.kafka.manager.common.entity.dto.op.topic.TopicCreationDTO;
|
||||||
|
import com.xiaojukeji.kafka.manager.common.utils.ValidateUtils;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
||||||
@@ -95,6 +96,7 @@ public class TopicDO {
|
|||||||
topicDO.setClusterId(dto.getClusterId());
|
topicDO.setClusterId(dto.getClusterId());
|
||||||
topicDO.setTopicName(dto.getTopicName());
|
topicDO.setTopicName(dto.getTopicName());
|
||||||
topicDO.setDescription(dto.getDescription());
|
topicDO.setDescription(dto.getDescription());
|
||||||
|
topicDO.setPeakBytesIn(ValidateUtils.isNull(dto.getPeakBytesIn()) ? -1L : dto.getPeakBytesIn());
|
||||||
return topicDO;
|
return topicDO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user