Operator HTTPPost

IBMStreams com.ibm.streamsx.inet Toolkit > com.ibm.streamsx.inet 3.4.0 > com.ibm.streamsx.inet.http > HTTPPost

This operator is deprecated. Use HTTPRequest operator instead.

This operator sends incoming tuples to the specified HTTP server as part of a POST request. A single tuple will be sent as a body of one HTTP POST request. Certain authentication modes are supported. Tuples are sent to the server one at a time in order of receipt. If the HTTP server cannot be accessed, the operation will be retried on the current thread and may temporarily block any additional tuples that arrive on the input port. By default, the data is sent in application/x-www-form-urlencoded UTF-8 encoded format.

Behavior in a consistent region

This operator cannot be placed at the start of a consistent region.

Summary

Ports
This operator has 1 input port and 1 output port.
Windowing
This operator does not accept any windowing configurations.
Parameters
This operator supports 13 parameters.

Required: url

Optional: acceptAllCertificates, authenticationFile, authenticationProperty, authenticationType, connectionTimeout, extraHeaders, headerContentType, include, keyStoreFile, keyStorePassword, maxRetries, retryDelay

Metrics
This operator does not report any metrics.

Properties

Implementation
Java

Input Ports

Ports (0)

By default, all attributes of the input stream are sent as POST data to the specified HTTP server.

Properties

Output Ports

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

Emits a tuple containing the reponse received from the server and assignments automatically forwarded from the input. Tuple structure must conform to the HTTPResponse type specified in this namespace. Additional attributes with corresponding input attributes will be forwarded before the POST request.

Properties

Parameters

This operator supports 13 parameters.

Required: url

Optional: acceptAllCertificates, authenticationFile, authenticationProperty, authenticationType, connectionTimeout, extraHeaders, headerContentType, include, keyStoreFile, keyStorePassword, maxRetries, retryDelay

acceptAllCertificates

Accept all SSL certificates, even those that are self-signed. Setting this option will allow potentially insecure connections. Default is false.

Properties
authenticationFile

Path to the properties file containing authentication information. Authentication file is recommended to be stored in the application_dir/etc directory. Path of this file can be absolute or relative, if relative path is specified then it is relative to the application directory. See http_auth_basic.properties in the toolkits etc directory for a sample of basic authentication properties.

Properties
authenticationProperty

Properties to override those in the authentication file.

Properties
authenticationType

Valid options are "basic" and "none". Default is "none".

Properties
connectionTimeout

Optional parameter specifies amount of time (in seconds) that the operator waits for the connection for to be established. Default is 60.

Properties
extraHeaders

Extra headers to send with request, format is "Header-Name: value".

Properties
headerContentType

Set the content type of the HTTP request. If the value is set to "application/json" then the entire tuple is sent in JSON format using SPL's standard tuple to JSON encoding, if the input schema is tuple<rstring jsonString> then jsonString is assumed to already be JSON and its value is sent as the content. Default is "application/x-www-form-urlencoded". Note that if a value other than the above mentioned ones is specified, the input stream can only have a single attribute.

Properties
include

Specify attributes used to compose the POST. Comma separated list of attribute names that will be posted to the url. The parameter is invalid if HeaderContentType is not "application/json" or "application/x-www-form-urlencoded". Default is to send all attributes.

Properties
keyStoreFile

Path to .jks file used for server and client authentication

Properties
keyStorePassword

Password for the keyStore and the keys it contains

Properties
maxRetries

Maximum number of retries in case of failures/disconnects.

Properties
retryDelay

Wait time between retries in case of failures/disconnects.

Properties
url

URL to connect to

Properties

Libraries

Operator class library
Library Path: ../../impl/lib/com.ibm.streamsx.inet.jar