Class RedisSource<TOutput>

A data flow source for Redis. Redis is a key/value store.
You can define a different scan pattern to describe which keys should be retrieved. (Default pattern is * which retrieves all key). By default, the stored values will be deserialized using Newtonsoft.Json and JsonConvert. This works only if your values contain json - for other values you can define your own serialization function.

Inheritance
System.Object
RedisSource<TOutput>
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ETLBox.DataFlow.Connectors
Assembly: ETLBox.Redis.dll
Syntax
    public class RedisSource<TOutput> : DataFlowExecutableSource<TOutput>, ILoggableTask, IDataFlowLogging, IDataFlowExecutableSource<TOutput>, IDataFlowSource<TOutput>, IDataFlowSource, IDataFlowComponent, IDataFlowExecutableSource
Type Parameters
NameDescription
TOutput

Type of outgoing data.

Constructors

RedisSource()

Declaration
    public RedisSource()

Properties

ConnectionString

If you provide a connection string, this component will create a new ConnectionMultiplexer object to connect with redis. If you already have a connection object instantiated in your application, use RedisConnection instead to pass it to the component.

Declaration
    public string ConnectionString { get; set; }
Property Value
TypeDescription
System.String

DatabaseNumber

Use the database number to store your data (redis databases are numbered from 0 to 15) The default database is 0.

Declaration
    public int DatabaseNumber { get; set; }
Property Value
TypeDescription
System.Int32

DeserializationFunc

Define your own deserialization function to read the stored data into your object.

Declaration
    public Func<string, TOutput> DeserializationFunc { get; set; }
Property Value
TypeDescription
System.Func<System.String, TOutput>

DeserializerSettings

The JsonSerializerSettings used to serialize or deserialize your object into json. By default, this component assumes your stored value is a json and tries to deserialize using JsonConvert. Use DeserializationFunc if you want to define your own deserialization function.

Declaration
    public JsonSerializerSettings DeserializerSettings { get; set; }
Property Value
TypeDescription
Newtonsoft.Json.JsonSerializerSettings

RedisConnection

An existing ConnectionMultiplexer that holds a redis connection.

Declaration
    public ConnectionMultiplexer RedisConnection { get; set; }
Property Value
TypeDescription
StackExchange.Redis.ConnectionMultiplexer

ScanCountSize

This will modify the count size used for the scan. Default is 1000.

Declaration
    public int ScanCountSize { get; set; }
Property Value
TypeDescription
System.Int32

ScanPattern

The scan pattern that describes which keys should be retrieved. The default is , which retrieves all keys from a database. Use e.g. ke to retrieve all keys that start with "ke".

Declaration
    public string ScanPattern { get; set; }
Property Value
TypeDescription
System.String

TaskName

A name to identify the task or component. Every component or task comes with a default name that can be overwritten.

Declaration
    public override string TaskName { get; set; }
Property Value
TypeDescription
System.String
Overrides

Methods

CheckParameter()

Declaration
    protected override void CheckParameter()
Overrides

CleanUpOnFaulted(Exception)

Declaration
    protected override void CleanUpOnFaulted(Exception e)
Parameters
TypeNameDescription
System.Exceptione
Overrides

CleanUpOnSuccess()

Declaration
    protected override void CleanUpOnSuccess()
Overrides

OnExecutionDoAsyncWork()

Declaration
    protected override void OnExecutionDoAsyncWork()
Overrides
ETLBox.DataFlow.DataFlowExecutableSource<TOutput>.OnExecutionDoAsyncWork()

OnExecutionDoSynchronousWork()

Declaration
    protected override void OnExecutionDoSynchronousWork()
Overrides
ETLBox.DataFlow.DataFlowExecutableSource<TOutput>.OnExecutionDoSynchronousWork()

Implements