File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -218,14 +218,14 @@ private static Optional<ConfiguredChannelCredentials> channelCredsFromProto(Any
218218 XdsChannelCredentials .create (fallbackCreds .get ().channelCredentials ()),
219219 new ProtoChannelCredsConfig (typeUrl , cred )));
220220 case LOCAL_CREDENTIALS_TYPE_URL :
221- throw new UnsupportedOperationException (
221+ throw new GrpcServiceParseException (
222222 "LocalCredentials are not supported in grpc-java. "
223223 + "See https://github.com/grpc/grpc-java/issues/8928" );
224224 case TLS_CREDENTIALS_TYPE_URL :
225225 // For this PR, we establish this structural skeleton,
226- // but throw an UnsupportedOperationException until the exact stream conversions are
226+ // but throw an GrpcServiceParseException until the exact stream conversions are
227227 // merged.
228- throw new UnsupportedOperationException (
228+ throw new GrpcServiceParseException (
229229 "TlsCredentials input stream construction pending." );
230230 default :
231231 return Optional .empty ();
Original file line number Diff line number Diff line change @@ -241,7 +241,7 @@ public void parse_localCredentials() throws GrpcServiceParseException {
241241 .addChannelCredentialsPlugin (localCreds ).addCallCredentialsPlugin (accessTokenCreds ).build ();
242242 GrpcService grpcService = GrpcService .newBuilder ().setGoogleGrpc (googleGrpc ).build ();
243243
244- UnsupportedOperationException exception = assertThrows (UnsupportedOperationException .class ,
244+ GrpcServiceParseException exception = assertThrows (GrpcServiceParseException .class ,
245245 () -> parse (grpcService ,
246246 dummyBootstrapInfo (),
247247 dummyServerInfo ()));
@@ -285,7 +285,7 @@ public void parse_tlsCredentials_notSupported() {
285285 .addChannelCredentialsPlugin (tlsCreds ).addCallCredentialsPlugin (accessTokenCreds ).build ();
286286 GrpcService grpcService = GrpcService .newBuilder ().setGoogleGrpc (googleGrpc ).build ();
287287
288- UnsupportedOperationException exception = assertThrows (UnsupportedOperationException .class ,
288+ GrpcServiceParseException exception = assertThrows (GrpcServiceParseException .class ,
289289 () -> parse (grpcService ,
290290 dummyBootstrapInfo (),
291291 dummyServerInfo ()));
You can’t perform that action at this time.
0 commit comments