-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Configuration decoding with pureconfig (closes #105)
- Loading branch information
1 parent
51b7c38
commit febfb97
Showing
13 changed files
with
282 additions
and
224 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,106 +1,102 @@ | ||
# Default configuration for kinesis-lzo-s3-sink | ||
# Default configuration for s3-loader | ||
|
||
# Sources currently supported are: | ||
# 'kinesis' for reading records from a Kinesis stream | ||
# 'nsq' for reading records from a NSQ topic | ||
source: "{{source}}" | ||
source = "{{source}}" | ||
|
||
# Sink is used for sending events which processing failed. | ||
# Sinks currently supported are: | ||
# 'kinesis' for writing records to a Kinesis stream | ||
# 'nsq' for writing records to a NSQ topic | ||
sink: "{{sink}}" | ||
sink = "{{sink}}" | ||
|
||
# The following are used to authenticate for the Amazon Kinesis sink. | ||
# | ||
# If both are set to 'default', the default provider chain is used | ||
# (see http://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/DefaultAWSCredentialsProviderChain.html) | ||
# | ||
# If both are set to 'iam', use AWS IAM Roles to provision credentials. | ||
# | ||
# If both are set to 'env', use environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY | ||
aws { | ||
access-key: "iam" | ||
secret-key: "iam" | ||
accessKey = "iam" | ||
secretKey = "iam" | ||
} | ||
|
||
# Config for NSQ | ||
nsq { | ||
# Channel name for NSQ source | ||
channel-name: "{{NsqSourceChannelName}}" | ||
# If more than one application reading from the same NSQ topic at the same time, | ||
# all of them must have unique channel name for getting all the data from the same topic | ||
channelName = "{{nsqSourceChannelName}}" | ||
|
||
# Host name for NSQ tools | ||
host: "{{NsqHost}}" | ||
host = "{{nsqHost}}" | ||
|
||
# Port for nsqd | ||
port: "{{NsqdPort}}" | ||
# HTTP port for nsqd | ||
port = {{nsqdPort}} | ||
|
||
# Port for nsqlookupd | ||
lookup-port: {{NsqlookupdPort}} | ||
# HTTP port for nsqlookupd | ||
lookupPort = {{nsqlookupdPort}} | ||
} | ||
|
||
kinesis { | ||
# LATEST: most recent data. | ||
# TRIM_HORIZON: oldest available data. | ||
# Note: This only affects the first run of this application | ||
# on a stream. | ||
initial-position: "TRIM_HORIZON" | ||
# "AT_TIMESTAMP": Start from the record at or after the specified timestamp | ||
# Note: This only affects the first run of this application on a stream. | ||
initialPosition = "{{kinesisInitialPosition}}" | ||
|
||
# Maximum number of records to read per GetRecords call | ||
max-records: {{sinkKinesisMaxRecords}} | ||
maxRecords = {{kinesisMaxRecords}} | ||
|
||
region: "{{sinkKinesisRegion}}" | ||
region = "{{kinesisRegion}}" | ||
|
||
# "app-name" is used for a DynamoDB table to maintain stream state. | ||
# You can set it automatically using: "SnowplowLzoS3Sink-$\\{sink.kinesis.in.stream-name\\}" | ||
app-name: "{{sinkKinesisAppName}}" | ||
# "appName" is used for a DynamoDB table to maintain stream state. | ||
appName = "{{appName}}" | ||
} | ||
|
||
streams { | ||
# Input stream name | ||
stream-name-in = "{{InStreamName}}" | ||
inStreamName = "{{inStreamName}}" | ||
|
||
# Stream for events for which the storage process fails | ||
stream-name-out = "{{OutStreamName}}" | ||
outStreamName = "{{outStreamName}}" | ||
|
||
# Events are accumulated in a buffer before being sent to S3. | ||
# The buffer is emptied whenever: | ||
# - the combined size of the stored records exceeds byte-limit or | ||
# - the number of stored records exceeds record-limit or | ||
# - the time in milliseconds since it was last emptied exceeds time-limit | ||
# - the combined size of the stored records exceeds byteLimit or | ||
# - the number of stored records exceeds recordLimit or | ||
# - the time in milliseconds since it was last emptied exceeds timeLimit | ||
buffer { | ||
byte-limit: {{sinkLzoBufferByteThreshold}} # Not supported by NSQ; will be ignored | ||
record-limit: {{sinkLzoBufferRecordThreshold}} | ||
time-limit: {{sinkLzoBufferTimeThreshold}} # Not supported by NSQ; will be ignored | ||
byteLimit = {{bufferByteThreshold}} # Not supported by NSQ; will be ignored | ||
recordLimit = {{bufferRecordThreshold}} | ||
timeLimit = {{bufferTimeThreshold}} # Not supported by NSQ; will be ignored | ||
} | ||
} | ||
|
||
s3 { | ||
# If using us-east-1, then endpoint should be "http://s3.amazonaws.com". | ||
# Otherwise "http://s3-<<region>>.s3.amazonaws.com", e.g. | ||
# http://s3-eu-west-1.amazonaws.com | ||
region: "{{sinkKinesisS3Region}}" | ||
bucket: "{{sinkKinesisS3Bucket}}" | ||
region = "{{s3Region}}" | ||
bucket = "{{s3bucket}}" | ||
|
||
# Format is one of lzo or gzip | ||
# Note, that you can use gzip only for enriched data stream. | ||
format: "{{sinkKinesisFormat}}" | ||
format = "{{format}}" | ||
|
||
# Maximum Timeout that the application is allowed to fail for | ||
max-timeout: {{sinkKinesisMaxTimeout}} | ||
maxTimeout = {{maxTimeout}} | ||
} | ||
|
||
# Set the Logging Level for the S3 Sink | ||
# Options: ERROR, WARN, INFO, DEBUG, TRACE | ||
logging { | ||
level: "{{sinkLzoLogLevel}}" | ||
level = "{{LogLevel}}" | ||
} | ||
|
||
# Optional section for tracking endpoints | ||
monitoring { | ||
snowplow { | ||
collector-uri: "{{collectorUri}}" | ||
collector-port: 80 | ||
app-id: "{{sinkLzoAppName}}" | ||
method: "GET" | ||
snowplow{ | ||
collectorUri = "{{collectorUri}}" | ||
collectorPort = 80 | ||
appId = "{{appName}}" | ||
method = "{{method}}" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.