Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add file source #13

Merged
merged 2 commits into from
Nov 24, 2020
Merged

Add file source #13

merged 2 commits into from
Nov 24, 2020

Conversation

andrewhare
Copy link
Contributor

This adds a file source so that we can read files off disk as an input source (the CLI flag is --input-file).

This PR can also be used a as reference implementation for how to implement a new source.

Closes #12

@ztreinhart
Copy link
Contributor

Maybe I'm missing something, but don't we need either an addition to the flow parser to allow this input source to be specified, or some code in main that watches for the command line flag and inserts the source into the input flow when the file flag is specified (à la --prometheus-address)?

@andrewhare
Copy link
Contributor Author

@ztreinhart Good call, I forgot to add it to the default parser.

@andrewhare
Copy link
Contributor Author

@ztreinhart: d22f934

Copy link
Contributor

@ztreinhart ztreinhart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, and I like the idea of using this as an example source. It's nice and straightforward.

@andrewhare andrewhare merged commit bf68514 into main Nov 24, 2020
@andrewhare andrewhare deleted the andrewhare/file-source branch November 24, 2020 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add file source
2 participants