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 "dataset_is_prefix" field to data_stream, if present. #674

Merged
merged 3 commits into from
Jan 26, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Added

* Add "dataset_is_prefix" field to data stream. [#674] (https://github.com/elastic/package-registry/pull/674)

### Deprecated

### Known Issues
Expand Down
9 changes: 5 additions & 4 deletions util/data_stream.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,11 @@ var validTypes = map[string]string{

type DataStream struct {
// Name and type of the data stream. This is linked to data_stream.dataset and data_stream.type fields.
Type string `config:"type" json:"type" validate:"required"`
Dataset string `config:"dataset" json:"dataset,omitempty" yaml:"dataset,omitempty"`
Hidden bool `config:"hidden" json:"hidden,omitempty" yaml:"hidden,omitempty"`
IlmPolicy string `config:"ilm_policy" json:"ilm_policy,omitempty" yaml:"ilm_policy,omitempty"`
Type string `config:"type" json:"type" validate:"required"`
Dataset string `config:"dataset" json:"dataset,omitempty" yaml:"dataset,omitempty"`
Hidden bool `config:"hidden" json:"hidden,omitempty" yaml:"hidden,omitempty"`
IlmPolicy string `config:"ilm_policy" json:"ilm_policy,omitempty" yaml:"ilm_policy,omitempty"`
DatasetIsPrefix bool `config:"dataset_is_prefix" json:"dataset_is_prefix,omitempty" yaml:"dataset_is_prefix,omitempty"`

Title string `config:"title" json:"title" validate:"required"`
Release string `config:"release" json:"release"`
Expand Down