ElasticSearch Connector for SSIS : Get index or alias metadata

Integrate SSIS and ElasticSearch
Integrate SSIS and ElasticSearch

Learn how to get index or alias metadata using the ElasticSearch Connector for SSIS. This connector enables you to read and write Elasticsearch data effortlessly. Integrate, manage, and automate indexes and documents — almost no coding required. We'll walk you through the exact setup.

Let's dive in!

Video tutorial

Watch this quick video to see the integration in action. It walks you through the end-to-end setup, including:

  • Installing the SSIS PowerPack
  • Configuring a secure connection to ElasticSearch
  • Working with ElasticSearch data directly inside SSIS
  • Exploring advanced API Source features
While this video uses the OData Connector as an example, the core concepts and setup process are exactly the same for the ElasticSearch Connector.

Once you are done watching, simply follow the step-by-step written guide below to configure your data source.

Prerequisites

Before we begin, make sure the following prerequisites are met:

  1. SSIS designer installed. Sometimes it is referred as BIDS or SSDT (download it from Microsoft).
  2. Basic knowledge of SSIS package development using Microsoft SQL Server Integration Services.
  3. SSIS PowerPack is installed (if you are new to SSIS PowerPack, then get started!).

Get index or alias metadata in SSIS

  1. Open Visual Studio and click Create a new project.

  2. Select Integration Services Project. Enter a name and location for your project, then click OK.

  3. From the SSIS Toolbox, drag and drop a Data Flow Task onto the Control Flow surface, and double-click it:

    Drag Data Flow Task onto Control Flow to use SSIS PowerPack Data Flow components
  4. Make sure you are in the Data Flow Task designer:

    Make sure you are in Data Flow designer in SSIS package
  5. From the SSIS toolbox drag and API Source (Predefined Templates) on the data flow designer surface, and double click on it to edit it:

    SSIS API Source (Predefined Templates) - Drag and Drop
  6. Select New Connection to create a new connection:

    API Source - New Connection
  7. 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
    ElasticSearch Connector Selection
  8. Select your authentication scenario below to expand connection configuration steps to:

    • Configure the authentication in ElasticSearch.
    • Enter those details into the API Connection Manager configuration.
    ElasticSearch authentication

    For Local / Hosted Instance by you

    1. 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
    1. Go to https://app.bonsai.io/clusters/{your-instance-id}/tokens
    2. Copy Access Key and Access Secret and enter on the connection UI. Click Test connection.
    3. 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:

    1. Set Authentication Type to Basic Authentication (UserId/Password) [Http]
    2. Optional step. Modify API Base URL if needed (in most cases default will work).
    3. Fill in all the required parameters and set optional parameters if needed.
    4. Finally, hit OK button:
    ElasticSearch
    Basic Authentication (UserId/Password) [Http]
    http://localhost:9200
    Optional Parameters
    User Name (or Access Key)
    Password (or Access Secret)
    Ignore certificate related errors
    ZappySys Http Connection
    Find full details in the ElasticSearch Connector authentication reference.
    ElasticSearch authentication

    No instructions available.

    API Connection Manager configuration

    Just perform these simple steps to finish authentication configuration:

    1. Set Authentication Type to Windows Authentication (No Password) [Http]
    2. Optional step. Modify API Base URL if needed (in most cases default will work).
    3. Fill in all the required parameters and set optional parameters if needed.
    4. Finally, hit OK button:
    ElasticSearch
    Windows Authentication (No Password) [Http]
    http://localhost:9200
    Optional Parameters
    Ignore certificate related errors
    ZappySys Http Connection
    Find full details in the ElasticSearch Connector authentication reference.
  9. Select Metadata table from the dropdown and hit Preview Data:

    API Source - ElasticSearch
    Read and write Elasticsearch data effortlessly. Integrate, manage, and automate indexes and documents — almost no coding required.
    ElasticSearch
    Metadata
    Optional Parameters
    EnablePivot True
    IncludePivotPath True
    EnablePivotPathSearchReplace True
    PivotPathSearchFor -
    PivotPathReplaceWith
    SSIS API Source - Read from table or endpoint
  10. 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)

    Execute Package - Reading data from ElasticSearch and load into target

Conclusion

And there you have it — a complete guide on how to get index or alias metadata in SSIS without writing complex code. All of this was powered by ElasticSearch Connector, which handled the REST API pagination and authentication for us automatically.

Download the trial now or ping us via chat if you have any questions or are looking for a specific feature (you can also reach out to us by submitting a ticket):

More actions supported by ElasticSearch Connector

Got another use case in mind? We've documented the exact setups for a variety of essential ElasticSearch operations directly in SSIS, so you can skip the trial and error. Find your next step-by-step guide below:

More ElasticSearch integrations

All
Data Integration
Database
BI & Reporting
Productivity
Programming Languages
Automation & Scripting
ODBC applications