package intern;

import io.sphere.sdk.client.SphereClient;
import io.sphere.sdk.client.SphereRequest;

import java.util.concurrent.*;

final class ClientImpl implements Client {
    private final SphereClient delegate;

    public ClientImpl(final SphereClient delegate) {
        this.delegate = delegate;
    }

    @Override
    public void close() {
        delegate.close();
    }

    @Override
    public <T> CompletionStage<T> execute(final SphereRequest<T> sphereRequest) {
        return delegate.execute(sphereRequest);
    }

    @Override
    public <T> T complete(final SphereRequest<T> sphereRequest) {
        try {
            return execute(sphereRequest).toCompletableFuture().get(5, TimeUnit.SECONDS);
        } catch (InterruptedException | ExecutionException | TimeoutException e) {
            final Throwable cause =
                    e.getCause() != null && e instanceof ExecutionException
                    ? e.getCause()
                    : e;
            throw new CompletionException(cause);
        }
    }
}

@@ -697,9 +697,10 @@
 get(
-5
+10
 , Ti
@@ -931,16 +931,24 @@
         
+        
 ? e.getC
@@ -954,16 +954,24 @@
 Cause()%0A
+        
         
@@ -1004,16 +1004,78 @@
    throw
+ cause instanceof RuntimeException? (RuntimeException) cause :
  new Com

Update ClientImpl.java