Skip to content
This repository has been archived by the owner on Nov 27, 2023. It is now read-only.

Avoid adding parameters in the source code with default value #503

Closed
lhein opened this issue Mar 3, 2023 · 7 comments · Fixed by #561
Closed

Avoid adding parameters in the source code with default value #503

lhein opened this issue Mar 3, 2023 · 7 comments · Fixed by #561
Assignees
Labels
enhancement New feature or request

Comments

@lhein
Copy link

lhein commented Mar 3, 2023

Is your feature request related to a problem? Please describe.
Step configuration parameters have sometimes default values which are also mentioned in the Camel Catalog. If you are dropping a timer component on the canvas and just change the name to foo it generates quite a lot of code which doesn't need to be there because its default values. (see screenshot)

grafik

Describe the solution you'd like
Avoid generating code for default values of parameters. In the above example uri: timer:foo would have been enough.

@lhein lhein added the enhancement New feature or request label Mar 3, 2023
@apupier
Copy link
Member

apupier commented Mar 3, 2023

duplicates of #558

@lhein
Copy link
Author

lhein commented Mar 3, 2023

Oh....thanks for pointing out, Aurelien. As this is a backend issue I wasn't checking in the UI issues.

@lhein
Copy link
Author

lhein commented Mar 3, 2023

adding another example which makes it even more obvious:
grafik

@Delawen
Copy link
Member

Delawen commented Mar 6, 2023

On the other hand, we have been requested to add those values explicitly...

@apupier
Copy link
Member

apupier commented Mar 6, 2023

On the other hand, we have been requested to add those values explicitly...

i think, we were asked to have them visible in the UI. Not to have them serialized

@Delawen
Copy link
Member

Delawen commented Mar 6, 2023

Just making sure. Because this was not happening before, so this is a new implementation (I think) based on that feedback.

@kahboom
Copy link
Contributor

kahboom commented Mar 6, 2023

relates to KaotoIO/kaoto-ui#1396

@Delawen Delawen changed the title Avoid generating unnecessary code Avoid adding parameters in the source code with default value Mar 21, 2023
@Delawen Delawen self-assigned this Mar 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants