tCouchbaseInput Properties - 6.3

Talend Open Studio for Big Data Components Reference Guide

EnrichVersion
6.3
EnrichProdName
Talend Open Studio for Big Data
task
Data Governance
Data Quality and Preparation
Design and Development
EnrichPlatform
Talend Studio

Component family

Big Data / Couchbase

 

Basic settings

Schema and Edit Schema

A schema is a row description. It defines the number of fields (columns) to be processed and passed on to the next component. The schema is either Built-In or stored remotely in the Repository.

Since version 5.6, both the Built-In mode and the Repository mode are available in any of the Talend solutions.

Click Edit schema to make changes to the schema. If the current schema is of the Repository type, three options are available:

  • View schema: choose this option to view the schema only.

  • Change to built-in property: choose this option to change the schema to Built-in for local changes.

  • Update repository connection: choose this option to change the schema stored in the repository and decide whether to propagate the changes to all the Jobs upon completion. If you just want to propagate the changes to the current Job, you can select No upon completion and choose this schema metadata again in the [Repository Content] window.

 

Use existing connection

Select this check box and in the Component List click the relevant connection component to reuse the connection details you already defined.

 

DB Version

List of database versions.

 

Data Bucket

Name of the data bucket in the Couchbase database.

 

Username and Password

Authentication credentials for a data bucket, instead of those for a server node.

To enter the password, click the [...] button next to the password field, and then in the pop-up dialog box enter the password between double quotes and click OK to save the settings.

 

URIs

URIs of server nodes in the Couchbase cluster, in the form of "http://127.0.0.1:8091/pools" or "http://localhost:8091/pools".

View

Key

(not in the Query by view mode)

IDs of the documents stored in the Couchbase database, in the form of "1", "2" or "Integration at any scale", etc.

 Query by view

 Query by view

Select this check box to view the document information according to the Map/Reduce functions and other settings.

Note

When this check box is selected, the schema has three pre-defined fields, Id, Key and Value.

Where, Id holds the document ID, Key holds the information specified by the key of the Map function and Value holds the information specified by the value of the Map function.

 

Design document

Name of the design document in the Query by view mode.

Note

  • This document appears in the Production Views area under the View tab in the Couchbase web console.

  • Multiple views can be created for each design document.

Doc action

Actions below are available:

None: no action is taken on the document specified in the Design document field.

Create: create the document specified in the Design document field.

Drop and Create: drop and then create the document specified in the Design document field.

 

View

Name of the view for extracting the document information.

View action

Actions below are available:

Create: create the view specified in the View field.

 

Map

Type in the code for the Map function.

Available when Create is selected in the View action list.

 

Reduce

Type in the code for the Reduce function.

Available when Create is selected in the View action list.

 

Startkey

Type in the startkey of a key range.

 

Endkey

Type in the endkey of a key range.

 

Startkey docid

Type in the start document ID of a docid range.

 

Endkey docid

Type in the end document ID of a docid range.

 

Use complex key

Select this check box to show the Complexkey field, where you can type in the complex keys for the view queries.

Note that here the keys refer to the values of the key defined in the Map function.

 

Key

(in the Query by view mode)

The values of the key defined in the Map function.

Not available when Use complex key is selected in the Query by view mode.

 

Include docs

Select this check box to include the document specified by the Key in the view results.

Note that the JSONDoc field appears in the schema once this check box is selected.

 

Inclusive end

Select this check box to include the specified end key in the result.

 

Descending

Returns the documents in descending order, by key.

 

Stale

Allows the results from a Stale view to be used.

false: forces a view update before returning data.

ok: allows stale views.

update_after: allows stale view and updates view after it has been accessed.

 

Limit

Limits the number of the returned documents to the specified number.

 

Skip

Skips this number of records before starting to return the results.

JSON Configuration

Extract JSON field

Select this check box to extract data from a JSON field.

 

JSON field

List of JSON fields for data extraction.

 

Loop XPath query

XPath query to specify the loop node of the JSON data.

 

Mapping

Schema output column: output columns for holding the JSON data extracted.

XPath Query: specifies the JSON node that holds the desired data.

Get nodes: select this check box to extract the JSON data of all the nodes specified in the XPath query list or select the check box next to a specific node to extract its JSON data only.

 

Die on error

This check box is cleared by default, meaning to skip the row on error and to complete the process for error-free rows.

Advanced settings

Debug

Outputs the debug information.

Available in the Query by view mode.

 

tStatCatcher Statistics

Select this check box to collect the log data at the component level.

Global Variables

NB_LINE: the number of rows read by an input component or transferred to an output component. This is an After variable and it returns an integer.

ERROR_MESSAGE: the error message generated by the component when an error occurs. This is an After variable and it returns a string. This variable functions only if the Die on error check box is cleared, if the component has this check box.

A Flow variable functions during the execution of a component while an After variable functions after the execution of the component.

To fill up a field or expression with a variable, press Ctrl + Space to access the variable list and choose the variable to use from it.

For further information about variables, see Talend Studio User Guide.

Usage

As a start component, tCouchbaseInput reads the documents from the Couchbase database either by the unique key or through Views.

Log4j

If you are using a subscription-based version of the Studio, the activity of this component can be logged using the log4j feature. For more information on this feature, see Talend Studio User Guide.

For more information on the log4j logging levels, see the Apache documentation at http://logging.apache.org/log4j/1.2/apidocs/org/apache/log4j/Level.html.

Limitation

n/a