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

Import/Export config #6

Open
tmaiaroto opened this issue Nov 7, 2015 · 3 comments
Open

Import/Export config #6

tmaiaroto opened this issue Nov 7, 2015 · 3 comments

Comments

@tmaiaroto
Copy link
Owner

Something not seen in etcd, an export configuration command. One could use the REST API to get the root key with the recursive option to get a full JSON tree structure of the entire config...But from the CLI it should be possible to dump the entire configuration to a JSON file.

This point of this is save, share, and/or "cache" configurations. While it's very critical to have up to date configurations for many situations (especially for systems concerns), it's not always so critical for application concerns. In fact, configurations may not update all too frequently at all for applications. This means if you use discfg for your web app, you'll be unnecessarily slowing it down with remote requests for the data unless the config is cached somehow. This is a concern of the application and maybe discfg helper libraries can be built in the future...But from the ability to save a JSON file from the CLI is a very convenient thing.

@tmaiaroto tmaiaroto added this to the Alpha Features milestone Nov 7, 2015
@tmaiaroto
Copy link
Owner Author

Though this package solves the problem for etcd. https://github.com/mickep76/etcd-export ... Maybe look at that for some ideas. +1 for TOML support.

@tmaiaroto
Copy link
Owner Author

Note that values are stored as byte arrays and it is becoming more expected to see binary data in there. Not just strings. So this export still works, but note that can be of little benefit when there's a string representation of some image in the middle of your JSON or TOML export.

Having a content type field may be really important here (so it's known what to skip).

@tmaiaroto tmaiaroto changed the title Export config Import/Export config Jan 24, 2016
@tmaiaroto
Copy link
Owner Author

Have to think about this some more... There are some limits with DynamoDB and also AWS Lambda (the intended host for discfg).

If the configuration is quite large, export/import begins to take some time and then there's the size concerns as well. Depending on the size of the config, there may even need to be some batching going on. So this is definitely a much larger feature than originally anticipated.

It's pretty useful to have, but I think it isn't pressing and shouldn't hold up the boat. Will definitely need feedback here.

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

No branches or pull requests

1 participant