|
7 | 7 | import com.sap.ai.sdk.core.DeploymentResolutionException; |
8 | 8 | import com.sap.ai.sdk.core.common.ClientResponseHandler; |
9 | 9 | import com.sap.ai.sdk.core.common.ClientStreamingHandler; |
10 | | -import com.sap.ai.sdk.orchestration.OrchestrationClientException.Streaming; |
11 | | -import com.sap.ai.sdk.orchestration.OrchestrationClientException.Synchronous; |
12 | 10 | import com.sap.cloud.sdk.cloudplatform.connectivity.ApacheHttpClient5Accessor; |
13 | 11 | import com.sap.cloud.sdk.cloudplatform.connectivity.HttpDestination; |
14 | 12 | import com.sap.cloud.sdk.cloudplatform.connectivity.exception.DestinationAccessException; |
@@ -51,7 +49,9 @@ <T> T execute( |
51 | 49 |
|
52 | 50 | val handler = |
53 | 51 | new ClientResponseHandler<>( |
54 | | - responseType, OrchestrationError.Synchronous.class, Synchronous.FACTORY) |
| 52 | + responseType, |
| 53 | + OrchestrationError.Synchronous.class, |
| 54 | + OrchestrationClientException.Synchronous.FACTORY) |
55 | 55 | .objectMapper(JACKSON); |
56 | 56 | return client.execute(request, handler); |
57 | 57 |
|
@@ -80,7 +80,7 @@ Stream<OrchestrationChatCompletionDelta> stream( |
80 | 80 | return new ClientStreamingHandler<>( |
81 | 81 | OrchestrationChatCompletionDelta.class, |
82 | 82 | OrchestrationError.Streaming.class, |
83 | | - Streaming.FACTORY) |
| 83 | + OrchestrationClientException.Streaming.FACTORY) |
84 | 84 | .objectMapper(JACKSON) |
85 | 85 | .handleStreamingResponse(client.executeOpen(null, request, null)); |
86 | 86 |
|
|
0 commit comments