diff --git a/src/main/java/io/opensergo/OpenSergoClient.java b/src/main/java/io/opensergo/OpenSergoClient.java index 1bf3b29..2197097 100644 --- a/src/main/java/io/opensergo/OpenSergoClient.java +++ b/src/main/java/io/opensergo/OpenSergoClient.java @@ -53,7 +53,7 @@ public class OpenSergoClient implements AutoCloseable { public static class Builder { private String host; - private int port; + private int port = 10246; private OpenSergoClientConfig openSergoConfig; public OpenSergoClient.Builder endpoint(String host, int port) { @@ -68,6 +68,7 @@ public OpenSergoClient.Builder openSergoConfig(OpenSergoClientConfig openSergoCo } public OpenSergoClient build() { + AssertUtils.notEmpty(this.host, "host cannot be empty, maybe need to invoke endpoint(host, port)"); if (this.openSergoConfig == null) { this.openSergoConfig = new OpenSergoClientConfig(); }