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

Camel Catalog plugin is writing default boolean values as string #969

Closed
lordrip opened this issue Mar 21, 2024 · 1 comment · Fixed by #980
Closed

Camel Catalog plugin is writing default boolean values as string #969

lordrip opened this issue Mar 21, 2024 · 1 comment · Fixed by #980
Assignees
Labels
bug Something isn't working build Build and GitHub related issues catalog Catalog-related issues
Milestone

Comments

@lordrip
Copy link
Member

lordrip commented Mar 21, 2024

Describe the Bug

When creating the schema for the RestConfiguration entity, default boolean values are written as string.

For instance, the useXForwardHeaders property is defined with a "true" default value:

    useXForwardHeaders: {
      type: 'boolean',
      title: 'Use XForward Headers',
      description: 'Whether to use X-Forward headers for Host and related setting. The default value is true.',
      default: "true",
    },

This causes issues with the Ajv validator.

image

Original useXForwardHeaders field definitions:

Notes

This might also be happening for number default values, as seen in the errorHandler.redeliveryPolicy properties:
image

Steps to Reproduce the Bug or Issue

  1. Build the Camel Catalog using the Kaoto plugin
  2. Inspect the aggregate-entities.json file and check the default value for the useXForwardHeaders (among others)
  3. Notice the "default": "true", instead of "default": true (mind the string)

Screenshots or Videos

No response

Platform

  • OS: [e.g. macOS, Windows, Linux]
  • Browser: [e.g. Chrome, Safari, Firefox]
  • Version: [e.g. 0.30.0]
@lordrip lordrip added the bug Something isn't working label Mar 21, 2024
@lordrip lordrip added catalog Catalog-related issues build Build and GitHub related issues labels Mar 21, 2024
@lordrip
Copy link
Member Author

lordrip commented Mar 21, 2024

After resolving this issue, we would need to enable the skip test in the RestConfigurationVisualEntity

@lordrip lordrip moved this from New to Todo in Kanban Board Mar 21, 2024
@lordrip lordrip added this to the 2.0.0 TP3 milestone Mar 21, 2024
lordrip added a commit to lordrip/kaoto that referenced this issue Mar 21, 2024
This commit adds support for RestConfiguration entity.

Note:
The node validation is still pending due to an issue with the
JSONSchema, please see KaotoIO#969 for more details.

fix: KaotoIO#562
relates: KaotoIO#969
lordrip added a commit to lordrip/kaoto that referenced this issue Mar 21, 2024
This commit adds support for RestConfiguration entity.

Note:
The node validation is still pending due to an issue with the
JSONSchema, please see KaotoIO#969 for more details.

fix: KaotoIO#562
relates: KaotoIO#969
lordrip added a commit that referenced this issue Mar 21, 2024
This commit adds support for RestConfiguration entity.

Note:
The node validation is still pending due to an issue with the
JSONSchema, please see #969 for more details.

fix: #562
relates: #969
@tplevko tplevko self-assigned this Mar 28, 2024
@github-project-automation github-project-automation bot moved this from Todo to Done in Kanban Board Mar 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working build Build and GitHub related issues catalog Catalog-related issues
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants