Giter VIP home page Giter VIP logo

conduit-connector-azure-storage's Introduction

Conduit Connector Azure Storage

General

The Azure Storage plugin is one of Conduit plugins. It currently provides only source connector.

How to build it

Run make.

Source

The Source connector monitors given Azure Blob container for file changes and generates appropriate Record when change is detected. It supports two reading modes and switches them automatically:

  • Snapshot
  • CDC

In Snapshot mode, connector reads the current state of the container, meaning it does not include changes made during this process. When interrupted, after restarted, it iterates all over container again.

After Snapshot reading is finished, connector switches to CDC mode. In this mode, connector monitors the container each pollingPeriod period and notifies about changes detected. The iterator stores the last modification timestamp of the files iterated in the previous cycle. When detecting new changes, this timestamp is used to discard files created before it. When interrupted, after restarted, it iterates using the timestamp stored in sdk.Position, passed to source's Open method.

Both iterators paginate over the container via List Blobs query, with up to maxResults items per page, to read the list of available items and their metadata (Last-Modified and Content-Type). When creating the sdk.Record, the contents of the file is additionally requested via Get Blob query.

Supported storage changes

Changes regarding adding new files to the storage or updating the existing ones are always detected. However, soft delete for blobs needs to be enabled to detect deleted files.

Configuration Options

name description required default
connectionString Azure Storage connection string as described here: https://docs.microsoft.com/azure/storage/common/storage-configure-connection-string true
containerName The name of the container to monitor. true
pollingPeriod The polling period for the CDC mode, formatted as a time.Duration string. Must be greater then 0. false "1s"
maxResults The maximum number of items, per page, when reading container's items. The minimum value is 1, maximum value is 5000. false "5000"

Testing

Run make test to run all the unit and integration tests, which require Docker to be installed and running. The command will handle starting and stopping docker containers for you.

Known Issues & Limitations

  • The connector is able to send record's Key and Payload as sdk.RawData only.

References

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.