Skip to content

Conversion to edn should be opt-in IMO #100

@ieugen

Description

@ieugen

Hi,

Using version 1.x for vault-clj with kv2 secret engine.
I have some code to fetch a secret and write it as a file (a software to streamline docker stack deployment).
The secret is a plain json and it should be written as a plain json file since the app that consumes it expects it to be json.

I noticed a couple of things:

  • Secret is converted to edn by default
  • There is no option to OPT-OUT of this feature

When dealing with clojure, having to work with EDN is a good thing.
Not so much when you have to use the original data type stored in the secret.

For version 1.x there is no way to opt out of EDN conversion so I will have to implement a step to serialize edn -> json.
Not hard but:

  • I need to depend on json library
  • There is extra work needed to be done for nothing: json -> edn -> json .

IMO edn conversion should be opt-in in vault-clj, or at least opt-out.
I am favoring it to be opt-in but it might not be ok now unless we break backward compatibility (version 2.x :D ) .

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions