*
Metamerge logo
Search

Advanced Search
*
*
*
* HOME DOCUMENTS & RESOURCES DOWNLOADS EARLY TECH ACCESS SUPPORT FAQ KNOWN ISSUES OLD VERSIONS
*

HTTP Server Connector

Overview

The HTTP server Connector listens for incoming HTTP connections and returns the GET parameters as an entry. If a Parser is specified then the Connectors will process POST requests and parse the contents using the specified Parser. GET requests will not use the Parser. If a POST request is received and no Parser is specified the contents of the POST data will be returned as an attribute ("postdata") in the returned entry.

The Connector will parse URL requests and populate an entry in the following manner: 

Request Parsed Entry
http://host/path?p1=v1&p2=v2  entry.path = "/path"
entry.p1="v1"
entry.p2="v2"
http://host?p1=v1&p2=v2  entry.path="/"
entry.p1="v1"
entry.p2="v2"

If a POST request is used then it is expected that the requestor is sending data on the connection as well. Depending on the value for the parser parameter the Connector will do the following:

Parser Present? Action
Yes Instantiate the Parser with the HTTP input stream. Connector will delegate getNext to the Parser's getEntry and return whatever the Parser returns.
No Put contents of post data in a attribute called postdata.

entry.postdata = "<post data>"

The session with the HTTP client is closed when the Connector receives a getNext request from the AssemblyLine and there is no more data to fetch. I.e. if the Parser has returned a null value, or on the second call to getNext if no Parser is present. If you call getNext (i.e. iterate) after having received a null from the Connector.

Configuration

The Connector needs the following parameters:

Parameter

Description

connectorType com.architech.connector.rscHttpServer
port The TCP port to listen to (default = 80)
parser The name of a Parser to handle the contents of POST requests

 Downloads

Included in base product

See Also

URL Connector

 

 

 

 

*
  Metamerge Integrator version 4.5 ©Copyright Metamerge AS 2000-2002 Last edited 2002-04-30 contact us