@@ -181,7 +181,7 @@ protected void configure() {
181
181
.map ("healthy" ::equals )
182
182
.orElse (false );
183
183
} catch (IOException e ) {
184
- logger ().error ("Unable to parse response {}" , response , e );
184
+ logger ().error ("Unable to parse response {}" , response );
185
185
return false ;
186
186
}
187
187
})
@@ -350,10 +350,10 @@ private void configureIndexer() {
350
350
* Based on the user-configured bucket definitions, creating buckets and corresponding indexes if needed.
351
351
*/
352
352
private void createBuckets () {
353
- logger ().debug ("Creating {} buckets (and corresponding indexes)." , buckets . size () );
353
+ logger ().debug ("Creating " + buckets . size () + " buckets (and corresponding indexes)." );
354
354
355
355
for (BucketDefinition bucket : buckets ) {
356
- logger ().debug ("Creating bucket \" {} \" " , bucket .getName ());
356
+ logger ().debug ("Creating bucket \" " + bucket .getName () + " \" " );
357
357
358
358
@ Cleanup Response response = doHttpRequest (MGMT_PORT , "/pools/default/buckets" , "POST" , new FormBody .Builder ()
359
359
.add ("name" , bucket .getName ())
@@ -395,7 +395,7 @@ private void createBuckets() {
395
395
396
396
checkSuccessfulResponse (queryResponse , "Could not create primary index for bucket " + bucket .getName ());
397
397
} else {
398
- logger ().info ("Primary index creation for bucket {} ignored, since QUERY service is not present." , bucket . getName () );
398
+ logger ().info ("Primary index creation for bucket " + bucket . getName () + " ignored, since QUERY service is not present." );
399
399
}
400
400
}
401
401
}
@@ -419,16 +419,7 @@ private String getInternalIpAddress() {
419
419
*/
420
420
private void checkSuccessfulResponse (final Response response , final String message ) {
421
421
if (!response .isSuccessful ()) {
422
- String body = null ;
423
- if (response .body () != null ) {
424
- try {
425
- body = response .body ().string ();
426
- } catch (IOException e ) {
427
- logger ().debug ("Unable to read body of response: {}" , response , e );
428
- }
429
- }
430
-
431
- throw new IllegalStateException (message + ": " + response .toString () + ", body=" + (body == null ? "<null>" : body ));
422
+ throw new IllegalStateException (message + ": " + response .toString ());
432
423
}
433
424
}
434
425
0 commit comments