code: public Observable<ServiceResponse<SourceUploadDefinitionInner>> getBuildSourceUploadUrlWithServiceResponseAsync(String resourceGroupName, String registryName) {
          if (this.client.subscriptionId() == null) {
              throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null.");
          }
          if (resourceGroupName == null) {
              throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.");
          }
          if (registryName == null) {
              throw new IllegalArgumentException("Parameter registryName is required and cannot be null.");
          }
          final String apiVersion = "2018-09-01";
          return service.getBuildSourceUploadUrl(this.client.subscriptionId(), resourceGroupName, registryName, apiVersion, this.client.acceptLanguage(), this.client.userAgent())
              .flatMap(new Func1<Response<ResponseBody>, Observable<ServiceResponse<SourceUploadDefinitionInner>>>() {
                  @Override
                  public Observable<ServiceResponse<SourceUploadDefinitionInner>> call(Response<ResponseBody> response) {
                      try {
                          ServiceResponse<SourceUploadDefinitionInner> clientResponse = getBuildSourceUploadUrlDelegate(response);
                          return Observable.just(clientResponse);
                      } catch (Throwable t) {
                          return Observable.error(t);
                      }
                  }
              });
      }
docs: Get the upload location for the user to be able to upload the source.
  
  @param resourceGroupName The name of the resource group to which the container registry belongs.
  @param registryName The name of the container registry.
  @throws IllegalArgumentException thrown if parameters fail the validation
  @return the observable to the SourceUploadDefinitionInner object