Skip to content

Commit

Permalink
refactor: extract out the RandomBackendSelector
Browse files Browse the repository at this point in the history
� Conflicts:
�	carapace-server/src/main/java/org/carapaceproxy/server/mapper/StandardEndpointMapper.java

� Conflicts:
�	carapace-server/src/main/java/org/carapaceproxy/core/ProxyRequestsManager.java
�	carapace-server/src/main/java/org/carapaceproxy/server/mapper/EndpointMapper.java
�	carapace-server/src/main/java/org/carapaceproxy/server/mapper/StandardEndpointMapper.java
  • Loading branch information
NiccoMlt committed Nov 29, 2024
1 parent a8cbb5c commit 9c24ad6
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -346,14 +346,17 @@ public void configure(ConfigurationStore properties) throws ConfigurationNotVali

this.defaultServiceUnavailable = properties.getString("default.action.serviceunavailable", DEFAULT_SERVICE_UNAVAILABLE_ACTION);
LOG.info("configured default.action.serviceunavailable={}", defaultServiceUnavailable);

this.forceDirectorParameter = properties.getString("mapper.forcedirector.parameter", forceDirectorParameter);
LOG.info("configured mapper.forcedirector.parameter={}", forceDirectorParameter);

this.forceBackendParameter = properties.getString("mapper.forcebackend.parameter", forceBackendParameter);
LOG.info("configured mapper.forcebackend.parameter={}", forceBackendParameter);

// To add custom debugging header for request chosen mapping-path
this.debuggingHeaderEnabled = properties.getBoolean("mapper.debug", false);
LOG.info("configured mapper.debug={}", debuggingHeaderEnabled);

this.debuggingHeaderName = properties.getString("mapper.debug.name", DEBUGGING_HEADER_DEFAULT_NAME);
LOG.info("configured mapper.debug.name={}", debuggingHeaderName);

Expand Down Expand Up @@ -426,7 +429,8 @@ public void configure(ConfigurationStore properties) throws ConfigurationNotVali
}

addAction(action);
LOG.info("configured action {} type={} enabled:{} headers:{} redirect location:{} redirect proto:{} redirect host:{} redirect port:{} redirect path:{}", id, actionType, enabled, headersIds, redirectLocation, action.getRedirectProto(), action.getRedirectHost(), action.getRedirectPort(), action.getRedirectPath());
LOG.info("configured action {} type={} enabled:{} headers:{} redirect location:{} redirect proto:{} redirect host:{} redirect port:{} redirect path:{}",
id, actionType, enabled, headersIds, redirectLocation, action.getRedirectProto(), action.getRedirectHost(), action.getRedirectPort(), action.getRedirectPath());
}
}

Expand Down

0 comments on commit 9c24ad6

Please sign in to comment.