-
Notifications
You must be signed in to change notification settings - Fork 207
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into cherry_pick_1_11
- Loading branch information
Showing
6 changed files
with
320 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
55 changes: 55 additions & 0 deletions
55
sdk/src/main/java/io/dapr/client/domain/AppConnectionPropertiesHealthMetadata.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
/* | ||
* Copyright 2024 The Dapr Authors | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
limitations under the License. | ||
*/ | ||
|
||
package io.dapr.client.domain; | ||
|
||
public final class AppConnectionPropertiesHealthMetadata { | ||
|
||
private final String healthCheckPath; | ||
private final String healthProbeInterval; | ||
private final String healthProbeTimeout; | ||
private final int healthThreshold; | ||
|
||
/** | ||
* Constructor for a AppConnectionPropertiesHealthMetadata. | ||
* | ||
* @param healthCheckPath of the application | ||
* @param healthProbeInterval time interval between health probes | ||
* @param healthProbeTimeout timeout for each health probe | ||
* @param healthThreshold max number of failed health probes | ||
*/ | ||
public AppConnectionPropertiesHealthMetadata(String healthCheckPath, String healthProbeInterval, | ||
String healthProbeTimeout, int healthThreshold) { | ||
this.healthCheckPath = healthCheckPath; | ||
this.healthProbeInterval = healthProbeInterval; | ||
this.healthProbeTimeout = healthProbeTimeout; | ||
this.healthThreshold = healthThreshold; | ||
} | ||
|
||
public String getHealthCheckPath() { | ||
return healthCheckPath; | ||
} | ||
|
||
public String getHealthProbeInterval() { | ||
return healthProbeInterval; | ||
} | ||
|
||
public String getHealthProbeTimeout() { | ||
return healthProbeTimeout; | ||
} | ||
|
||
public int getHealthThreshold() { | ||
return healthThreshold; | ||
} | ||
|
||
} |
62 changes: 62 additions & 0 deletions
62
sdk/src/main/java/io/dapr/client/domain/AppConnectionPropertiesMetadata.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
/* | ||
* Copyright 2024 The Dapr Authors | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
limitations under the License. | ||
*/ | ||
|
||
package io.dapr.client.domain; | ||
|
||
public final class AppConnectionPropertiesMetadata { | ||
|
||
private final int port; | ||
private final String protocol; | ||
private final String channelAddress; | ||
private final int maxConcurrency; | ||
private final AppConnectionPropertiesHealthMetadata health; | ||
|
||
/** | ||
* Constructor for a AppConnectionPropertiesMetadata. | ||
* | ||
* @param port of the application | ||
* @param protocol of the application | ||
* @param channelAddress host address of the application | ||
* @param maxConcurrency number of concurrent requests the app can handle | ||
* @param health health check details of the application | ||
*/ | ||
public AppConnectionPropertiesMetadata(int port, String protocol, String channelAddress, int maxConcurrency, | ||
AppConnectionPropertiesHealthMetadata health) { | ||
this.port = port; | ||
this.protocol = protocol; | ||
this.channelAddress = channelAddress; | ||
this.maxConcurrency = maxConcurrency; | ||
this.health = health; | ||
} | ||
|
||
public int getPort() { | ||
return port; | ||
} | ||
|
||
public String getProtocol() { | ||
return protocol; | ||
} | ||
|
||
public String getChannelAddress() { | ||
return channelAddress; | ||
} | ||
|
||
public int getMaxConcurrency() { | ||
return maxConcurrency; | ||
} | ||
|
||
public AppConnectionPropertiesHealthMetadata getHealth() { | ||
return health; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
sdk/src/main/java/io/dapr/client/domain/HttpEndpointMetadata.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
* Copyright 2024 The Dapr Authors | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
limitations under the License. | ||
*/ | ||
|
||
package io.dapr.client.domain; | ||
|
||
public final class HttpEndpointMetadata { | ||
|
||
private final String name; | ||
|
||
/** | ||
* Constructor for a HttpEndpointMetadata. | ||
* | ||
* @param name of the HTTP endpoint | ||
*/ | ||
public HttpEndpointMetadata(String name) { | ||
this.name = name; | ||
} | ||
|
||
public String getName() { | ||
return name; | ||
} | ||
|
||
} |
Oops, something went wrong.