FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

api: Stabilize io.grpc.CallCredentials (#10208) · Java-Edge/grpc-java@dd2dc21 · GitHub

forked from grpc/grpc-java

Commit dd2dc21

Browse files
authored
api: Stabilize io.grpc.CallCredentials (grpc#10208)
1 parent 478f30e commit dd2dc21

5 files changed

Lines changed: 6 additions & 16 deletions

File tree

‎api/src/main/java/io/grpc/CallCredentials.java‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,18 +56,19 @@ public abstract void applyRequestMetadata(
5656
RequestInfo requestInfo, Executor appExecutor, CallCredentials.MetadataApplier applier);
5757

5858
/**
59-
* Should be a noop but never called; tries to make it clearer to implementors that they may break
60-
* in the future.
59+
* With this class now being stable this method moves from an abstract one to a normal one with
60+
* a no-op implementation. This method is marked deprecated to allow extenders time to remove the
61+
* method before it is removed here.
6162
*/
62-
@ExperimentalApi("https://github.com/grpc/grpc-java/issues/1914")
63-
public abstract void thisUsesUnstableApi();
63+
@Deprecated
64+
public void thisUsesUnstableApi() {
65+
}
6466

6567
/**
6668
* The outlet of the produced headers. Not thread-safe.
6769
*
6870
* <p>Exactly one of its methods must be called to make the RPC proceed.
6971
*/
70-
@ExperimentalApi("https://github.com/grpc/grpc-java/issues/1914")
7172
public abstract static class MetadataApplier {
7273
/**
7374
* Called when headers are successfully generated. They will be merged into the original
@@ -84,7 +85,6 @@ public abstract static class MetadataApplier {
8485
/**
8586
* The request-related information passed to {@code CallCredentials.applyRequestMetadata()}.
8687
*/
87-
@ExperimentalApi("https://github.com/grpc/grpc-java/issues/1914")
8888
public abstract static class RequestInfo {
8989
/**
9090
* The method descriptor of this RPC.

‎api/src/main/java/io/grpc/CompositeCallCredentials.java‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,6 @@ public void applyRequestMetadata(
4040
new WrappingMetadataApplier(requestInfo, appExecutor, applier, Context.current()));
4141
}
4242

43-
@Override
44-
public void thisUsesUnstableApi() {}
45-
4643
private final class WrappingMetadataApplier extends MetadataApplier {
4744
private final RequestInfo requestInfo;
4845
private final Executor appExecutor;

‎api/src/test/java/io/grpc/CompositeCallCredentialsTest.java‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,5 @@ public FakeCallCredentials(Status status) {
109109
applier.fail(status);
110110
}
111111
}
112-
113-
@Override public void thisUsesUnstableApi() {}
114112
}
115113
}

‎auth/src/main/java/io/grpc/auth/GoogleAuthLibraryCallCredentials.java‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,6 @@ public GoogleAuthLibraryCallCredentials(Credentials creds) {
9494
}
9595
}
9696

97-
@Override
98-
public void thisUsesUnstableApi() {}
99-
10097
@Override
10198
public void applyRequestMetadata(
10299
RequestInfo info, Executor appExecutor, final MetadataApplier applier) {

‎core/src/test/java/io/grpc/internal/FakeCallCredentials.java‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,4 @@ public void applyRequestMetadata(
3838
CallCredentials.MetadataApplier applier) {
3939
applier.apply(headers);
4040
}
41-
42-
@Override public void thisUsesUnstableApi() {}
4341
}

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL