Operator SolrDocumentSink

SolrDoc > com.ibm.streamsx.solr 1.0.0 > com.ibm.streamsx.solr > SolrDocumentSink

This operator is used for writing tuples as Solr documents to a Solr collection. It takes in a set of attributes and a map<ustring,ustring> on its import port. Those attributes are committed to a Solr collection on a configurable interval (time or number of tuples). If specified, the map (attribute: atomicUpdateMap) must specify the type of update for each attribute: set, add, remove, removeregex, or inc. The map should NOT include the uniqueIdentifier attribute, as this is provided by a parameter. See the SolrDocAddSample for map syntax.If no map is provided, all attributes will be committed as if the map were on "set". No ordering of the tuples within a buffer being committed is guaranteed.

Summary

Ports
This operator has 1 input port and 0 or more output port.
Windowing
This operator does not accept any windowing configurations.
Parameters
This operator supports 6 parameters. (collection, documentCommitSize, maxDocumentBufferAge, solrRequestParams, solrURL, uniqueKeyAttribute)
Metrics
This operator does not report any metrics.

Properties

Implementation
Java

Input Ports

Ports (0)

Port that ingests tuples

Properties

Output Ports

Assignments
Java operators do not support output assignments.
Ports (0...)

Error Port

Properties

Parameters

This operator supports 6 parameters.
collection

Solr collection to add documents to.

Properties
documentCommitSize

Number of tuples queued up before committing to Solr. Default: 1. If -1, buffer will never be flushed based on size and will rely soley on time-based flushing.

Properties
maxDocumentBufferAge

Max time allowed for the document buffer to fill before automatically flushing. Time in milliseconds. Default: 10000. If -1, buffer will never flush based on time and will rely solely on count-based flushing.

Properties
solrRequestParams

Add Solr request parameters. Parameters should be comma separatated like so: "name=value","name=value". Use this parameter to use a custom updateRequestProcessorChain ("update.chain=<chain-name>").

Properties
solrURL

URL of Solr server. Example: http://localhost:8983/solr

Properties
uniqueKeyAttribute

Incoming attribute to be used as the unique id.

Properties

Libraries

Operator class library
Library Path: ../../impl/java/bin, ../../opt/downloaded/*