소스 검색

use HttpSchemes constants

tags/v0.5.0
Jonathan Cobb 4 년 전
부모
커밋
dcf64600d9
2개의 변경된 파일4개의 추가작업 그리고 2개의 파일을 삭제
  1. +2
    -1
      bubble-server/src/main/java/bubble/client/BubbleNodeClient.java
  2. +2
    -1
      bubble-server/src/main/java/bubble/model/cloud/BubbleNetwork.java

+ 2
- 1
bubble-server/src/main/java/bubble/client/BubbleNodeClient.java 파일 보기

@@ -24,6 +24,7 @@ import static bubble.server.BubbleServer.getRestoreKey;
import static bubble.server.BubbleServer.isRestoreMode;
import static org.cobbzilla.util.daemon.ZillaRuntime.die;
import static org.cobbzilla.util.daemon.ZillaRuntime.notSupported;
import static org.cobbzilla.util.http.HttpSchemes.SCHEME_HTTPS;
import static org.cobbzilla.util.json.JsonUtil.COMPACT_MAPPER;
import static org.cobbzilla.util.json.JsonUtil.json;

@@ -67,7 +68,7 @@ public class BubbleNodeClient extends BubbleApiClient {

private static String baseUri(BubbleNode node, BubbleConfiguration configuration) {
final HttpConfiguration http = configuration.getHttp();
return "https://" + node.getFqdn() + ":" + node.getSslPort() + http.getBaseUri();
return SCHEME_HTTPS + node.getFqdn() + ":" + node.getSslPort() + http.getBaseUri();
}

@Override protected <T> void setRequestEntity(HttpEntityEnclosingRequest entityRequest, T data, ContentType contentType) {


+ 2
- 1
bubble-server/src/main/java/bubble/model/cloud/BubbleNetwork.java 파일 보기

@@ -36,6 +36,7 @@ import static bubble.model.cloud.BubbleNetworkState.created;
import static bubble.server.BubbleConfiguration.getDEFAULT_LOCALE;
import static org.cobbzilla.util.daemon.ZillaRuntime.die;
import static org.cobbzilla.util.daemon.ZillaRuntime.empty;
import static org.cobbzilla.util.http.HttpSchemes.SCHEME_HTTPS;
import static org.cobbzilla.util.reflect.ReflectionUtil.copy;
import static org.cobbzilla.util.string.ValidationRegexes.HOST_PART_PATTERN;
import static org.cobbzilla.util.string.ValidationRegexes.validateRegexMatches;
@@ -103,7 +104,7 @@ public class BubbleNetwork extends IdentifiableBase implements HasNetwork, HasBu
@Getter @Setter private Integer sslPort;

@Transient @JsonIgnore public String getPublicUri() {
return "https://" + getNetworkDomain() + (getSslPort() == 443 ? "" : ":"+getSslPort());
return SCHEME_HTTPS + getNetworkDomain() + (getSslPort() == 443 ? "" : ":"+getSslPort());
}

public String getPublicUri(BubbleConfiguration configuration) {


불러오는 중...
취소
저장