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

fix(catalog-generator): Use Label or Group for the EIP parameters grouping #1532

Merged
merged 1 commit into from
Oct 4, 2024
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
11 changes: 6 additions & 5 deletions packages/catalog-generator/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<artifactId>camel-catalog</artifactId>
<version>${version.camel}</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-yaml-dsl</artifactId>
<version>${version.camel}</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-catalog-maven</artifactId>
Expand Down Expand Up @@ -82,6 +77,12 @@
<artifactId>commons-cli</artifactId>
<version>1.9.0</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-yaml-dsl</artifactId>
<version>${version.camel}</version>
<scope>test</scope>
Copy link
Member Author

Choose a reason for hiding this comment

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

Without having <scope>test</scope>, this forces the runtime to load the latest Camel YAML DSL schema, making the catalog generation fail.

</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,13 @@ public String getPatternCatalog() throws Exception {
required.add(propertyName);
}

propertySchema.put("group", catalogOp.getGroup());
/* In Apache Camel previous to 4.5.0, the displayName is stored in the label property */
if (catalogOp.getLabel() != null) {
propertySchema.put("group", catalogOp.getLabel());
} else if (catalogOp.getGroup() != null) {
propertySchema.put("group", catalogOp.getGroup());
}

sortedSchemaProperties.set(propertyName, propertySchema);
}

Expand Down
Loading