Skip to content

Commit

Permalink
Update registry for stream.* to dataset.* change (#492)
Browse files Browse the repository at this point in the history
Now the dataset intsead of the stream fields are added and validated.

Updating also the base package. This will have to be pushed to the package-storage.

Part of #491
  • Loading branch information
ruflin authored Jun 8, 2020
1 parent 7832fa6 commit 955239d
Show file tree
Hide file tree
Showing 22 changed files with 113 additions and 111 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Breaking changes

* Change stream.* fields to dataset.* fields. [#492](https://github.com/elastic/package-registry/pull/492)

### Bugfixes

### Added
Expand Down
6 changes: 3 additions & 3 deletions dev/generator/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,9 @@ func validateRequiredFields(datasetPath string) error {
}

// Verify required keys
err = requireField(allFields, "stream.type", "constant_keyword", err)
err = requireField(allFields, "stream.dataset", "constant_keyword", err)
err = requireField(allFields, "stream.namespace", "constant_keyword", err)
err = requireField(allFields, "dataset.type", "constant_keyword", err)
err = requireField(allFields, "dataset.name", "constant_keyword", err)
err = requireField(allFields, "dataset.namespace", "constant_keyword", err)
err = requireField(allFields, "@timestamp", "date", err)
return err
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@
"@timestamp": {
"type": "date"
},
"stream": {
"dataset": {
"properties": {
"type": {
"type": "constant_keyword",
"value": "events"
},
"dataset": {
"name": {
"type": "constant_keyword"
},
"namespace": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@
"@timestamp": {
"type": "date"
},
"stream": {
"dataset": {
"properties": {
"type": {
"type": "constant_keyword",
"value": "logs"
},
"dataset": {
"name": {
"type": "constant_keyword"
},
"namespace": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@
"@timestamp": {
"type": "date"
},
"stream": {
"dataset": {
"properties": {
"type": {
"type": "constant_keyword",
"value": "metrics"
},
"dataset": {
"name": {
"type": "constant_keyword"
},
"namespace": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
- name: stream.type
- name: dataset.type
type: constant_keyword
description: >
Stream type
- name: stream.dataset
Dataset type.
- name: dataset.name
type: constant_keyword
description: >
Stream dataset.
- name: stream.namespace
Dataset name.
- name: dataset.namespace
type: constant_keyword
description: >
Stream namespace.
Dataset namespace.
- name: "@timestamp"
type: date
description: >
Expand Down
Loading

0 comments on commit 955239d

Please sign in to comment.