@@ -64,9 +64,7 @@ public void testFailuresFromRemote() throws IOException {
6464 // Closed shards will result to index error because shards must be in readable state
6565 FieldCapabilitiesIT .closeShards (cluster ("remote_cluster" ), remoteErrorIndex );
6666
67- response = client ().prepareFieldCaps ("*" , "remote_cluster:*" )
68- .setFields ("*" )
69- .get ();
67+ response = client ().prepareFieldCaps ("*" , "remote_cluster:*" ).setFields ("*" ).get ();
7068 assertThat (response .getIndices ()[0 ], equalTo (localIndex ));
7169 assertThat (response .getFailedIndicesCount (), equalTo (1 ));
7270 FieldCapabilitiesFailure failure = response .getFailures ()
@@ -78,23 +76,21 @@ public void testFailuresFromRemote() throws IOException {
7876 assertEquals (RemoteTransportException .class , ex .getClass ());
7977 Throwable cause = ExceptionsHelper .unwrapCause (ex );
8078 assertEquals (IllegalIndexShardStateException .class , cause .getClass ());
81- assertEquals ("CurrentState[CLOSED] operations only allowed when shard state is one of [POST_RECOVERY, STARTED]" , cause .getMessage ());
79+ assertEquals (
80+ "CurrentState[CLOSED] operations only allowed when shard state is one of [POST_RECOVERY, STARTED]" ,
81+ cause .getMessage ()
82+ );
8283
8384 // if we only query the remote we should get back an exception only
84- ex = expectThrows (
85- IllegalIndexShardStateException .class ,
86- client ().prepareFieldCaps ("remote_cluster:*" ).setFields ("*" )
87- );
85+ ex = expectThrows (IllegalIndexShardStateException .class , client ().prepareFieldCaps ("remote_cluster:*" ).setFields ("*" ));
8886 assertEquals ("CurrentState[CLOSED] operations only allowed when shard state is one of [POST_RECOVERY, STARTED]" , ex .getMessage ());
8987
9088 // add an index that doesn't fail to the remote
9189 assertAcked (remoteClient .admin ().indices ().prepareCreate ("okay_remote_index" ));
9290 remoteClient .prepareIndex ("okay_remote_index" ).setId ("2" ).setSource ("foo" , "bar" ).get ();
9391 remoteClient .admin ().indices ().prepareRefresh ("okay_remote_index" ).get ();
9492
95- response = client ().prepareFieldCaps ("*" , "remote_cluster:*" )
96- .setFields ("*" )
97- .get ();
93+ response = client ().prepareFieldCaps ("*" , "remote_cluster:*" ).setFields ("*" ).get ();
9894 assertThat (Arrays .asList (response .getIndices ()), containsInAnyOrder (localIndex , "remote_cluster:okay_remote_index" ));
9995 assertThat (response .getFailedIndicesCount (), equalTo (1 ));
10096 failure = response .getFailures ()
0 commit comments