How to Search / Query documents — ElasticSearch Connector for SSIS
Prerequisites
Before we begin, make sure the following prerequisites are met:
- SSIS designer installed. Sometimes it is referred as BIDS or SSDT (download it from Microsoft).
- Basic knowledge of SSIS package development using Microsoft SQL Server Integration Services.
- SSIS PowerPack is installed (if you are new to SSIS PowerPack, then get started!).
Search / Query documents in SSIS
-
Begin with opening Visual Studio and Create a New Project.
-
Select Integration Service Project and in new project window set the appropriate name and location for project. And click OK.
In the new SSIS project screen you will find the following:
- SSIS ToolBox on left side bar
- Solution Explorer and Property Window on right bar
- Control flow, data flow, event Handlers, Package Explorer in tab windows
- Connection Manager Window in the bottom
Note: If you don't see ZappySys SSIS PowerPack Task or Components in SSIS Toolbox, please refer to this help link. -
Now, Drag and Drop SSIS Data Flow Task from SSIS Toolbox. Double click on the Data Flow Task to see Data Flow designer.
-
From the SSIS toolbox drag and API Source (Predefined Templates) on the data flow designer surface, and double click on it to edit it:
-
Select New Connection to create a new connection:
-
Use a preinstalled ElasticSearch Connector from Popular Connector List or press Search Online radio button to download ElasticSearch Connector. Once downloaded simply use it in the configuration:
ElasticSearch -
Now it's time to configure authentication. Firstly, configure authentication settings in ElasticSearch service and then proceed by configuring API Connection Manager. Start by expanding an authentication type:
ElasticSearch authentication
For Local / Hosted Instance by you
- Get your userid / password and enter on the connection UI
For Managed Instance (By Bonsai search)
If your instance is hosted by bonsai then perform these steps to get your credentials for API call- Go to https://app.bonsai.io/clusters/{your-instance-id}/tokens
- Copy Access Key and Access Secret and enter on the connection UI. Click Test connection.
- If your Cluster has no data you can generate sample data by visiting this URL and click Add Sample Data https://{your-cluster-id}.apps.bonsaisearch.net/app/home#/tutorial_directory
API Connection Manager configuration
Just perform these simple steps to finish authentication configuration:
-
Set Authentication Type to
Basic Authentication (UserId/Password) [Http]
- Optional step. Modify API Base URL if needed (in most cases default will work).
- Fill in all the required parameters and set optional parameters if needed.
- Finally, hit OK button:
ElasticSearchBasic Authentication (UserId/Password) [Http]http://localhost:9200Optional Parameters User Name (or Access Key) Password (or Access Secret) Ignore certificate related errors ElasticSearch authentication
No instructions available.
API Connection Manager configuration
Just perform these simple steps to finish authentication configuration:
-
Set Authentication Type to
Windows Authentication (No Password) [Http]
- Optional step. Modify API Base URL if needed (in most cases default will work).
- Fill in all the required parameters and set optional parameters if needed.
- Finally, hit OK button:
ElasticSearchWindows Authentication (No Password) [Http]http://localhost:9200Optional Parameters Ignore certificate related errors -
Select Search / Query documents endpoint from the dropdown and hit Preview Data:
API Source - ElasticSearchRead / write ElasticSearch data inside your app; perform many ElasticSearch operations without coding, just use easy to use high performance API Connector for ElasticSearchElasticSearchSearch / Query documentsThere are no parameters to configure. -
That's it! We are done! Just in a few clicks we configured the call to ElasticSearch using ElasticSearch Connector.
You can load the source data into your desired destination using the Upsert Destination , which supports SQL Server, PostgreSQL, and Amazon Redshift. We also offer other destinations such as CSV , Excel , Azure Table , Salesforce , and more . You can check out our SSIS PowerPack Tasks and components for more options. (*loaded in Trash Destination)
More actions supported by ElasticSearch Connector
Learn how to perform other actions directly in SSIS with these how-to guides:
- Count documents
- Create Index
- Delete documents
- Delete Index
- Get document by ID from Index or Alias
- Get documents from Index or Alias
- Get Index or Alias metadata
- Insert documents
- List aliases
- List indexes
- Update documents
- Upsert documents
- Make Generic API Request
- Make Generic API Request (Bulk Write)