使用 PING Federate 8.x UnboundID SCIM 2 客户端 SDK
尝试检索结果时,我收到错误:
com.unboundid.scim2.client.ScimServiceException: MessageBodyReader not found for media type=text/plain, type=class com.unboundid.scim2.common.messages.ErrorResponse, genericType=class com.unboundid.scim2.common.messages.ErrorResponse.
at com.unboundid.scim2.client.requests.RequestBuilder.toScimException(RequestBuilder.java:136)
at com.unboundid.scim2.client.requests.SearchRequestBuilder.invoke(SearchRequestBuilder.java:325)
at com.unboundid.scim2.client.requests.SearchRequestBuilder.invoke(SearchRequestBuilder.java:152)
at com.unboundid.scim2.client.ScimService.getResourceTypes(ScimService.java:113)
at com.willeke.scim.Scim2Test01.main(Scim2Test01.java:100)
我认为这是因为 PING Federate 返回:Content-Type: application/json 并且显然 UnboundID 期望 type=text/plain。
我们如何配置 SCIM 客户端以期望 application/json?
使用时:PING Federate 8.x UnboundID SCIM 1.1 Client SDK
线程“主”java.lang.NoSuchMethodError 中的异常:
javax.ws.rs.core.MultivaluedMap.addAll(Ljava/lang/Object;[Ljava/lang/Object;)V
at org.glassfish.jersey.client.ClientRequest.accept(ClientRequest.java:326)
at org.glassfish.jersey.client.JerseyInvocation$Builder.accept(JerseyInvocation.java:237)
at org.glassfish.jersey.client.JerseyInvocation$Builder.accept(JerseyInvocation.java:154)
at org.apache.wink.client.Resource.get(Resource.java:177)
at com.unboundid.scim.sdk.SCIMEndpoint.query(SCIMEndpoint.java:347)
at com.unboundid.scim.sdk.SCIMEndpoint.query(SCIMEndpoint.java:271)
at com.unboundid.scim.sdk.SCIMEndpoint.query(SCIMEndpoint.java:249)
at com.willeke.scim.Client.main(Client.java:38)
谢谢-吉姆