LDAP Read Adapter

Introduction

The TIBCO StreamBase® Adapter for LDAP Read allows an EventFlow module to use an existing LDAP connection to read data from an LDAP server.

Adapter Properties

This section describes the properties you can set for this adapter, using the various tabs of the Properties view in StreamBase Studio.

General Tab

Name: Use this required field to specify or change the name of this instance of this component, which must be unique in the current EventFlow module. The name must contain only alphabetic characters, numbers, and underscores, and no hyphens or other special characters. The first character must be alphabetic or an underscore.

Adapter: A read-only field that shows the formal name of the adapter.

Class name: Shows the fully qualified class name that implements the functionality of this adapter. If you need to reference this class name elsewhere in your application, you can right-click this field and select Copy from the context menu to place the full class name in the system clipboard.

Start options: This field provides a link to the Cluster Aware tab, where you configure the conditions under which this adapter starts.

Enable Error Output Port: Select this check box to add an Error Port to this component. In the EventFlow canvas, the Error Port shows as a red output port, always the last port for the component. See Using Error Ports to learn about Error Ports.

Description: Optionally enter text to briefly describe the component's purpose and function. In the EventFlow Editor canvas, you can see the description by pressing Ctrl while the component's tooltip is displayed.

Adapter Properties Tab

Property Description
Connection Adapter The name of the default LDAP Connection adapter to use. If the connection adapter is in the same EventFlow module, specify the connection adapter name. If the connection adapter is located in a different module, you must specify the fully qualified name of the connection adapter.
Always Output Name Value List If selected, the attribute name value list is always output, even if a schema is defined.
Enable Search If selected (default), this adapter instance has a search input port and corresponding search result output port.
Enable Get Entry If selected (default), this adapter instance has a Get Entry input port and corresponding Get Entry output port.
Enable Compare If selected (default), this adapter instance has a Compare input port and corresponding Compare result output port.
Log Level Controls the level of verbosity the adapter uses to send notifications to the console. This setting can be higher than the containing application's log level. If set lower, the system log level is used. Available values, in increasing order of verbosity, are: OFF, ERROR, WARN, INFO, DEBUG, TRACE.

Edit Schema Tab

If an attribute schema is set, the field names of the schema are sent as the attribute names for each search or get entry operation and attempts to fill this schema from the results.

Cluster Aware Tab

Use the settings in this tab to allow this operator or adapter to start and stop based on conditions that occur at runtime in a cluster with more than one node. During initial development of the fragment that contains this operator or adapter, and for maximum compatibility with TIBCO Streaming releases before 10.5.0, leave the Cluster start policy control in its default setting, Start with module.

Cluster awareness is an advanced topic that requires an understanding of StreamBase Runtime architecture features, including clusters, quorums, availability zones, and partitions. See Cluster Awareness Tab Settings on the Using Cluster Awareness page for instructions on configuring this tab.

Concurrency Tab

Use the Concurrency tab to specify parallel regions for this instance of this component, or multiplicity options, or both. The Concurrency tab settings are described in Concurrency Options, and dispatch styles are described in Dispatch Styles.

Caution

Concurrency settings are not suitable for every application, and using these settings requires a thorough analysis of your application. For details, see Execution Order and Concurrency, which includes important guidelines for using the concurrency options.

Search Input Port

The search input port is used to send search requests to the LDAP server.

Any values marked as optional use the value from the Adapters Properties tab if the field is missing or null.

The schema for the control input port is:

Field Name Field Type Description
ConnectionAdapter string Optional — The name of the LDAP Connection adapter to use.
BaseDN string The base DN for the search request.
SearchScope string Optional — The scope that specifies the range of entries that should be examined for the search. Valid values are: BASE,ONE,SUB,SUBORDINATE_SUBTREE
DereferencePolicy string Optional — The dereference policy the server should use for any aliases encountered while processing the search. Valid values are: NEVER,SEARCHING,FINDING,ALWAYS
SizeLimit int Optional — The maximum number of entries that the server should return for the search. A value of zero indicates that there should be no limit.
TimeLimit int Optional — The maximum length of time in seconds that the server should spend processing this search request. A value of zero indicates that there should be no limit.
TypesOnly boolean Optional — Indicates whether to return only attribute names in matching entries, or both attribute names and values.
Filter string The filter to use to identify matching entries. It must not be null.
Attributes list(string) Optional — A list of attribute fields to retrieve. If the adapter has a schema set, this field list is added to the schema field names as attributes to retrieve.
Controls list(tuple(OID string, Critical boolean, Value string)) Optional — Controls to use during search.

Get Entry Input Port

The get entry input port is used to send get entry requests to the LDAP server.

Any values marked as optional will use the value from the adapters properties if the field is missing or null.

The schema for the control input port is:

Field Name Field Type Description
ConnectionAdapter string Optional — The name of the LDAP Connection adapter to use.
DN string The DN of the entry to retrieve.
Attributes list(string) Optional — A list of attribute fields to retrieve. If the adapter has a schema set, this field list is added to the schema field names as attributes to retrieve.

Compare Input Port

Use the compare input port to send compare requests to the LDAP server.

Any values marked as optional will use the value from the adapters properties if the field is missing or null.

The schema for the control input port is:

Field Name Field Type Description
ConnectionAdapter string Optional — The name of the LDAP Connection adapter to use.
DN string The DN of the entry to compare.
AttributeName string The name of the target attribute for which the comparison is to be performed.
AttributeValue string The assertion value to verify within the entry.

Status Output Port

The status output port emits tuples providing information on this adapter's operations. The schema for the status output port is:

Field Name Field Type Description
Status String A string describing this status event.
Time timestamp The time that the status event occurred.
Info list(tuple(Name string, Value string)) A list of name-value pairs of data to provide more status context.

The following is a list of status output error types.

Status Info Elements
Search Error
  • Error — The error that occurred while trying to perform a search operation.

  • Tuple — The input tuple that caused this status message in string format. You can use parsecsv expression language method to convert this back into a tuple downstream if required.

  • ResultCode — The LDAP result code.

  • ResultName — The name for this result code.

  • DiagnosticMessage — The diagnostic message returned by the directory server.

Get Entry Error
  • Error — The error that occurred while trying to perform a get entry operation.

  • Tuple — The input tuple that caused this status message in string format. You can use parsecsv expression language method to convert this back into a tuple downstream if required.

  • ResultCode — The LDAP result code.

  • ResultName — The name for this result code.

  • DiagnosticMessage — The diagnostic message returned by the directory server.

Compare Error
  • Error — The error that occurred while trying to perform a compare operation.

  • Tuple — The input tuple that caused this status message in string format. You can use parsecsv expression language method to convert this back into a tuple downstream if required.

  • ResultCode — The LDAP result code.

  • ResultName — The name for this result code.

  • DiagnosticMessage — The diagnostic message returned by the directory server.

Send Search Result Error
  • Error — The error that occurred while trying to output a search result.

  • Tuple — The input tuple that caused this status message in string format. You can use parsecsv expression language method to convert this back into a tuple downstream if required.

Send Search Result Reference Error
  • Error — The error that occurred while trying to output a search reference.

  • Tuple — The input tuple that caused this status message in string format. You can use parsecsv expression language method to convert this back into a tuple downstream if required.

Search Result Output Port

The search result output port emits tuples in response to a search input tuple. One or more search result tuples are emitted for every search input tuple. An end tuple with the SearchResult field and SearchResultReference fields both null are always emitted to signify the end of search results.

The search result output port schema is:

Field Name Field Type Description
Search tuple The input search tuple. See Search Input port for its schema.
SearchResult tuple The search result. See Search Result Schema.
SearchResultReference tuple The search result reference. See Search Result Reference Schema.

Search Result Schema

The search result schema is:

Field Name Field Type Description
MessageId int The message ID for the LDAP message associated with this LDAP result.
DN string The DN of the entry.
AttributeNameValues list(tuple(Name string, Value string)) If no schema is defined on the edit schema tab, or the always output name value list is enabled, this field is output as a list of tuples which contain the name and value of the attributes received.
Attributes tuple If a schema is specified on the edit schema tab, the schema is output as this field. The field names of this schema are matched to attribute names and the value tries to be converted to the fields data type.
Controls list(tuple(OID string, Critical boolean, Value string)) Any controls used for this result.

Search Result Reference Schema

The search result reference schema is:

Field Name Field Type Description
MessageId int The message ID for the LDAP message associated with this LDAP result.
ReferralURLs list(string) A list of referral URLs.

Get Entry Output Port

The get entry output port outputs a single tuple in response to a get entry input tuple.

The get entry output port schema is:

Field Name Field Type Description
Entry tuple The input search tuple see Get Entry Input port for its schema.
SearchResult tuple The search result see Search Result Schema for its schema.

Compare Output Port

The compare output port outputs a single tuple in response to a compare tuple.

The compare output port schema is:

Field Name Field Type Description
Compare tuple The input compare tuple see Compare Input port for its schema.
CompareMatched boolean A true/false value if the compare matched or not.

Suspend and Resume Behavior

When suspended, the adapter no longer processes tuples. When resumed, the adapter starts processing input tuples.