ContentUploadServiceImpl

public class ContentUploadServiceImpl extends BaseApiService<CloudSearch>
implements ContentUploadService

Concrete class implementing ContentUploadService

Document content uploads normally occur "in-line" as part of the item's upload request. However, when the content is large, this upload service can optimize content uploads by separating the content from the item's upload request. This results in a "two-step" process for indexing a document into Cloud Search.

The deterministic threshold for "in-line" versus using this service is settable using the configuration parameter com.google.enterprise.cloudsearch.sdk.indexing.IndexingServiceImpl.UPLOAD_THRESHOLD_BYTES. The SDK default byte value is com.google.enterprise.cloudsearch.sdk.indexing.IndexingServiceImpl.DEFAULT_CONTENT_UPLOAD_THRESHOLD_BYTES.

Nested Class Summary

class ContentUploadServiceImpl.Builder Builder to create an instance of ContentUploadServiceImpl

Field Summary

public static final Set<String> API_SCOPES API scope for uploading content using Cloud Search API.

Public Method Summary

ListenableFuture<Void>
uploadContent(String resourceName, AbstractInputStreamContent content)
Uploads AbstractInputStreamContent content for specified resource name obtained using the Cloud Search upload method.

Inherited Method Summary

Fields

public static final Set<String> API_SCOPES

API scope for uploading content using Cloud Search API.

Public Methods

public ListenableFuture<Void> uploadContent (String resourceName, AbstractInputStreamContent content)

Uploads AbstractInputStreamContent content for specified resource name obtained using the Cloud Search upload method.

Parameters
resourceName resource name for content to be uploaded.
content AbstractInputStreamContent to upload
Returns
Throws
IOException