@@ -58,7 +58,7 @@ public Debug withNameSpace(final String nameSpace) {
5858 * </blockquote>
5959 */
6060 public HealthResponse health () throws VaultException {
61- return health (null , null , null , null );
61+ return health (null , null , null , null , null );
6262 }
6363
6464 /**
@@ -81,14 +81,17 @@ public HealthResponse health() throws VaultException {
8181 * node instead of the default of 429
8282 * @param sealedCode (optional) Indicates the status code that should be returned for a sealed
8383 * node instead of the default of 500
84+ * @param performanceStandbyCode (optional) Indicates the status code that should be
85+ * returned for a performanceStandbyCode node instead of the default of 473
8486 * @return The response information returned from Vault
8587 * @throws VaultException If an error occurs or unexpected response received from Vault
8688 */
8789 public HealthResponse health (
8890 final Boolean standbyOk ,
8991 final Integer activeCode ,
9092 final Integer standbyCode ,
91- final Integer sealedCode
93+ final Integer sealedCode ,
94+ final Integer performanceStandbyCode
9295 ) throws VaultException {
9396 final String path = "sys/health" ;
9497
@@ -116,6 +119,8 @@ public HealthResponse health(
116119 if (sealedCode != null ) {
117120 rest .parameter ("sealedcode" , sealedCode .toString ());
118121 }
122+ if (performanceStandbyCode != null ) rest .parameter ("performancestandbycode" ,
123+ performanceStandbyCode .toString ());
119124 // Execute request
120125 final RestResponse restResponse = rest .get ();
121126
@@ -124,6 +129,7 @@ public HealthResponse health(
124129 validCodes .add (200 );
125130 validCodes .add (429 );
126131 validCodes .add (500 );
132+ validCodes .add (473 );
127133 if (activeCode != null ) {
128134 validCodes .add (activeCode );
129135 }
@@ -133,6 +139,9 @@ public HealthResponse health(
133139 if (sealedCode != null ) {
134140 validCodes .add (sealedCode );
135141 }
142+ if (performanceStandbyCode != null ) {
143+ validCodes .add (performanceStandbyCode );
144+ }
136145
137146 if (!validCodes .contains (restResponse .getStatus ())) {
138147 throw new VaultException (
0 commit comments