Mongo DB Reader
This page covers configuration details for the Mongo DB Reader component.
Last updated
This page covers configuration details for the Mongo DB Reader component.
Last updated
All component configurations are classified broadly into the following sections:
Basic
Metadata
Please follow the demonstration to configure the component.
MongoDB Reader reads the data from the specified collection of Mongo Database. It has an option to filter data using spark SQL query.
Drag & Drop the Mongo DB Reader on the Workflow Editor.
Click on the dragged reader component to open the component properties tabs below.
Basic Information: It is the default tab to open for the Mongo DB reader while configuring the component.
Select an Invocation type from the drop-down menu to confirm the running mode of the reader component. Select ‘Real-Time’ or ‘Batch’ from the drop-down menu.
Deployment Type: It displays the deployment type for the component. This field comes pre-selected.
Container Image Version: It displays the image version for the docker container. This field comes pre-selected.
Failover Event: Select a failover Event from the drop-down menu.
Batch Size: Provide the maximum number of records to be processed in one execution cycle.
Open the ‘Meta Information’ tab and fill in all the connection-specific details of Mogo DB.
Connection Type: Select either of the connection type choices out of the given choices:
Standard
SRV
Connection String
Host IP Address (*): Hadoop IP address of the host.
Port(*): Port number (It appears only with the ‘Standard’ Connection Type).
Username(*): Provide username.
Password(*): Provide a valid password to access the Mongo DB.
Database Name(*): Provide the name of the database from where you wish to read data.
Collection Name(*): Provide the name of the collection.
Query: Insert an SQL query (it takes a query containing a Join statement as well).
Limit: Set a limit for the number of records.10. Additional Parameters: Provide the additional parameters.
Enable SSL: Check this box to enable SSL for this components. Credentials will be different for this.
Please Note: The Meta Information fields vary based on the selected Connection Type option.
The following images display the various possibilities of the Meta Information:
i. Meta Information Tab with Standard as Connection Type.
ii. Meta Information Tab with SRV as Connection Type.
iii. Meta Information Tab with Connection String as Connection Type.
Selected Columns: The users can select some specific columns from the table to read data instead of selecting a complete table; this can be achieved via the ‘Selected Columns’ section. Select the columns which you want to read and if you want to change the name of the column, then put that name in the alias name section otherwise keep the alias name the same as of column name and then select a Column Type from the drop-down menu.
or
Use ‘Download Data’ and ‘Upload File’ options to select the desired columns.
1. Upload File: The user can upload the existing system files (CSV, JSON) using the Upload File icon (file size must be less than 2 MB).
2. Download Data (Schema): Users can download the schema structure in JSON format by using the ‘Download Data’ icon.
After doing all the configurations click the Save Component in Storage icon provided in the reader configuration panel to save the component.
A notification message appears to inform about the component configuration success.