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

Tokenized scripts to be persisted as is #419

Open
DmitrySenin opened this issue Sep 22, 2020 · 2 comments
Open

Tokenized scripts to be persisted as is #419

DmitrySenin opened this issue Sep 22, 2020 · 2 comments

Comments

@DmitrySenin
Copy link

It's rather a feature request or maybe I'm missing something in the docs.
I quite often need to have different behaviour for new DBs vs existing ones. Thus, we leveraged the User Tokens feature which is great but scripts having such tokens are persisted to RH tables with tokens replaced which makes it impossible to use such scripts in 20.up at least in my scenario.
What I would like to have in RH is to be able to tell that tokens should not be replaced before storing them to DB. I'd say the ultimate goal would be to define it at the token level.

@erikbra
Copy link
Member

erikbra commented Oct 4, 2020

This is an interesting idea. But, it does imply that you never want to run the script again if you change the tokens. I myself do not use the token replacement feature a lot, so I don't know what the most usual scenarios are.

How would you imagine to be able to specify this at a token level? Any ideas?

@DmitrySenin
Copy link
Author

The most flexible implementation I can imagine is introducing a new parameter holding the list of nonpersistable tokens. There could be two "special" values - ALL and NONE - to apply a universal strategy for all or none of tokens.
Another options which I'm personally fine with is just a boolean flag to wether persist or not token values. But, apparently, it's less flexible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants