javeme commented on code in PR #132:
URL:
https://github.com/apache/incubator-hugegraph-commons/pull/132#discussion_r1261149583
##########
hugegraph-common/src/main/java/org/apache/hugegraph/event/EventHub.java:
##########
@@ -49,21 +49,27 @@ public class EventHub {
// Event executor
private static ExecutorService executor = null;
- private String name;
- private Map<String, List<EventListener>> listeners;
+ private final String name;
+ private final Map<String, List<EventListener>> listeners;
public EventHub() {
this("hub");
}
public EventHub(String name) {
LOG.debug("Create new EventHub: {}", name);
-
this.name = name;
this.listeners = new ConcurrentHashMap<>();
EventHub.init(1);
}
+ public EventHub(String name, int threadSize) {
Review Comment:
just let `EventHub(String name)` call `EventHub(name, 1)`
##########
hugegraph-common/src/main/java/org/apache/hugegraph/rest/RestResult.java:
##########
@@ -43,6 +43,12 @@ public RestResult(Response response) {
this.content = response.readEntity(String.class);
}
+ public RestResult(int status, String content, MultivaluedMap<String,
Object> headers) {
Review Comment:
ditto
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]