|
26 | 26 | import java.nio.charset.Charset; |
27 | 27 | import java.nio.charset.StandardCharsets; |
28 | 28 | import java.util.List; |
29 | | -import org.apache.polaris.core.auth.AuthenticatedPolarisPrincipal; |
30 | 29 | import org.apache.polaris.core.config.ProductionReadinessCheck; |
31 | 30 | import org.apache.polaris.core.config.ProductionReadinessCheck.Error; |
32 | 31 | import org.apache.polaris.core.persistence.MetaStoreManagerFactory; |
33 | 32 | import org.apache.polaris.service.auth.AuthenticationConfiguration; |
34 | 33 | import org.apache.polaris.service.auth.AuthenticationConfiguration.TokenBrokerConfiguration.RSAKeyPairConfiguration; |
35 | 34 | import org.apache.polaris.service.auth.AuthenticationConfiguration.TokenBrokerConfiguration.SymmetricKeyConfiguration; |
36 | | -import org.apache.polaris.service.auth.Authenticator; |
37 | 35 | import org.apache.polaris.service.auth.JWTRSAKeyPairFactory; |
38 | 36 | import org.apache.polaris.service.auth.JWTSymmetricKeyFactory; |
39 | | -import org.apache.polaris.service.auth.TestInlineBearerTokenPolarisAuthenticator; |
40 | | -import org.apache.polaris.service.auth.TestOAuth2ApiService; |
41 | 37 | import org.apache.polaris.service.auth.TokenBrokerFactory; |
42 | | -import org.apache.polaris.service.catalog.api.IcebergRestOAuth2ApiService; |
43 | 38 | import org.apache.polaris.service.context.DefaultRealmContextResolver; |
44 | 39 | import org.apache.polaris.service.context.RealmContextResolver; |
45 | 40 | import org.apache.polaris.service.context.TestRealmContextResolver; |
@@ -84,30 +79,6 @@ public void warnOnFailedChecks( |
84 | 79 | } |
85 | 80 | } |
86 | 81 |
|
87 | | - @Produces |
88 | | - public ProductionReadinessCheck checkAuthenticator( |
89 | | - Authenticator<String, AuthenticatedPolarisPrincipal> authenticator) { |
90 | | - if (authenticator instanceof TestInlineBearerTokenPolarisAuthenticator) { |
91 | | - return ProductionReadinessCheck.of( |
92 | | - Error.of( |
93 | | - "The current authenticator is intended for tests only.", |
94 | | - "polaris.authentication.authenticator.type")); |
95 | | - } |
96 | | - |
97 | | - return ProductionReadinessCheck.OK; |
98 | | - } |
99 | | - |
100 | | - @Produces |
101 | | - public ProductionReadinessCheck checkTokenService(IcebergRestOAuth2ApiService service) { |
102 | | - if (service instanceof TestOAuth2ApiService) { |
103 | | - return ProductionReadinessCheck.of( |
104 | | - Error.of( |
105 | | - "The current token service is intended for tests only.", |
106 | | - "polaris.authentication.token-service.type")); |
107 | | - } |
108 | | - return ProductionReadinessCheck.OK; |
109 | | - } |
110 | | - |
111 | 82 | @Produces |
112 | 83 | public ProductionReadinessCheck checkTokenBroker( |
113 | 84 | AuthenticationConfiguration configuration, TokenBrokerFactory factory) { |
|
0 commit comments