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

Define input variable types #44

Open
mtojek opened this issue Sep 10, 2020 · 5 comments
Open

Define input variable types #44

mtojek opened this issue Sep 10, 2020 · 5 comments

Comments

@mtojek
Copy link
Contributor

mtojek commented Sep 10, 2020

This issue defines all input variable types and is a meta ticket for potential adjustments.

Right now we have:

  • text
  • password
  • bool
  • integer
  • yaml

For reference:
https://github.com/elastic/package-registry/blob/33c9f9df5881a879ced083cc626ba973f928b32d/testdata/package/reference/1.0.0/dataset/reference/manifest.yml#L47
https://github.com/elastic/package-spec/blob/master/versions/1/dataset/manifest.spec.yml#L24

/cc @ruflin @ycombinator @jen-huang

@mtojek
Copy link
Contributor Author

mtojek commented Sep 10, 2020

New type: duration

Based on discussion here: elastic/integrations#266 (comment)

@ruflin
Copy link
Contributor

ruflin commented Sep 10, 2020

It will be great to have it defined in the package spec for validation but also for documentation purpose (single source of truth)

@mtojek
Copy link
Contributor Author

mtojek commented Sep 10, 2020

They are already defined. I linked it above: https://github.com/elastic/package-spec/blob/master/versions/1/data_stream/manifest.spec.yml#L24

rw-access pushed a commit to rw-access/package-spec that referenced this issue Mar 23, 2021
* Stub out system test command

* Add --ignoreMissing flag

* Add TODO for composing other test actions later

* Adding runner stub

* Adding godoc

* Adding godoc

* Change --ignoreMissing to --failOnMissing

* Use kebab case for flag long name

* Making sub-command logic more generic

* Implement --dataset flag

* Use composeCommandActions

* Refactoring: moving composeCmdActions to internal

* Adding godoc for exported types

* Removing internal/cmd
@simitt
Copy link

simitt commented Feb 2, 2022

+1 for adding duration to the accepted types, as suggested in #44 (comment).
APM is using the custom policy editor, but the type and default values are defined in the package. Given the type restrictions, the package can only define a text input where duration is expected. Without duplicating the knowledge that a specific field should be a duration, it is currently not possible to add UI validations for durations in the way needed. This is currently causing problems related to fixing elastic/kibana#121640.

cc @elastic/apm-ui @elastic/apm-server

@andrewkroh
Copy link
Member

A proper duration type would also help address elastic/integrations#6684.

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

4 participants