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 an optional schemaUri to the context #184

Merged
merged 2 commits into from
Mar 4, 2024

Conversation

afrittoli
Copy link
Contributor

@afrittoli afrittoli commented Feb 22, 2024

Changes

Add schemaURI to the context. It can be used to link to a custom schema that further refines the event content.

Context:

Also fixes a small issue in the event-version.sh tool that prevented example versions from being updated.

Fixes: #91

Submitter Checklist

As the author of this PR, please check off the items in this checklist:

Add schemaURI to the context. It can be used to link to
a custom schema that further refines the event content.

Context:
- cdevents#168
- cdevents#91

Fixes: cdevents#91

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
@afrittoli afrittoli requested a review from a team as a code owner February 22, 2024 12:20
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Feb 22, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Feb 22, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
@afrittoli afrittoli mentioned this pull request Feb 22, 2024
4 tasks
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Feb 22, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Feb 22, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Feb 22, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Feb 22, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
Copy link
Contributor

@e-backmark-ericsson e-backmark-ericsson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks mostly good to me.

But, regarding the capitalized 'URI' in this proposal - I see that we have noted it differently on e.g. viewUrl here: https://github.com/cdevents/spec/blob/main/schemas/repositorycreated.json#L74
We also have an old (forgotten?) action to capitalize words such as URI from https://hackmd.io/2FRGlw9fTMmKN1OQUVvguA?view#Jan-29-2024.
What is the best to do?

  • Update this PR to instead define schemaUri?
  • Update all existing occurrences of Uri/Url to URI/URL?
  • Keep this PR as-is, but create a dedicated issue to deal with the inconsistencies separately?

spec.md Outdated Show resolved Hide resolved
spec.md Outdated Show resolved Hide resolved
spec.md Outdated Show resolved Hide resolved
@afrittoli
Copy link
Contributor Author

This looks mostly good to me.

But, regarding the capitalized 'URI' in this proposal - I see that we have noted it differently on e.g. viewUrl here: https://github.com/cdevents/spec/blob/main/schemas/repositorycreated.json#L74 We also have an old (forgotten?) action to capitalize words such as URI from https://hackmd.io/2FRGlw9fTMmKN1OQUVvguA?view#Jan-29-2024. What is the best to do?

  • Update this PR to instead define schemaUri?
  • Update all existing occurrences of Uri/Url to URI/URL?
  • Keep this PR as-is, but create a dedicated issue to deal with the inconsistencies separately?

The issue was initially brought up in Dec 2023 https://github.com/cdevents/community/blob/main/working-group-notes-2023.md#dec-4-2023. There are different opinions about this on the internet, but I don't think there is a definite answer out there. One point that I found relatively compelling is that two acronyms next to each other become indistinguishable if their case is all upper.

I will update this PR to use Uri instead of URI to be consistent with viewUrl - we can then open a separate issue if anyone feels strongly that this should be all uppercase instead

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
@afrittoli afrittoli added this to the v0.4 milestone Mar 4, 2024
@afrittoli afrittoli changed the title Add an optional schemaURI to the context Add an optional schemaUri to the context Mar 4, 2024
@afrittoli afrittoli merged commit f1aafdb into cdevents:main Mar 4, 2024
4 checks passed
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Mar 6, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Mar 6, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaURI (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit to afrittoli/cdevents-spec that referenced this pull request Mar 13, 2024
As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaUri (cdevents#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: cdevents#168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
afrittoli added a commit that referenced this pull request Mar 13, 2024
* Add support for CDEvents custom events

As previously discussed in https://hackmd.io/LftfRirGRbKuAcLg9pdOag,
this introduces support for custom events:

- add a schemaUri (#184)
- add dev.cdeventsx types in spec.md
- add a custom folder which includes
  - README.md with context about custom events
  - registry.md to register external specs
  - schema.json - a common schema for custom events

Fixes: #168

Signed-off-by: Andrea Frittoli <andrea.frittoli@gmail.com>
@afrittoli afrittoli mentioned this pull request Apr 3, 2024
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

Successfully merging this pull request may close these issues.

Add a schema uri property to the context
4 participants