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 some sugar for additional sources #1388

Closed
nicolaferraro opened this issue Apr 3, 2020 · 1 comment · Fixed by #1400
Closed

Add some sugar for additional sources #1388

nicolaferraro opened this issue Apr 3, 2020 · 1 comment · Fixed by #1400
Assignees
Labels
help wanted Extra attention is needed
Milestone

Comments

@nicolaferraro
Copy link
Member

nicolaferraro commented Apr 3, 2020

When I need to add a customizer (i.e. an additional source that adds a different behavior) to an integration I run something like:

kamel run Basic.java customizers/OpentracingCustomizer.java --name basic --another-arg --a-second-arg --many-other-args --save

The problem is that after I --save the arguments passed to the command, if I want to run the integration again, I still need to pass the customizer and the integration name:

# After saving the arguments
kamel run Basic.java
# Does not work, because the customizer is a positional argument, not a named one 

This works instead:

kamel run Basic.java customizers/OpentracingCustomizer.java --name basic

But the purpose of --save is to let you write as less arguments as possible, so it's not nice.

I wonder if we can add a --source argument.

With that option, one would run the integration the first time with:

kamel run Basic.java --source customizers/OpentracingCustomizer.java --another-arg --a-second-arg --many-other-args --save

And the second time, just:

kamel run Basic.java

The customizer will be saved in the configuration.

@nicolaferraro nicolaferraro added the help wanted Extra attention is needed label Apr 3, 2020
@nicolaferraro nicolaferraro added this to the 1.0.0 milestone Apr 3, 2020
@nicolaferraro
Copy link
Member Author

That also allow e.g. to create customizers for all integrations (e.g. an OpenTracingCustomizer) and reuse it automatically after saving it in the global config.

@nicolaferraro nicolaferraro changed the title Add some customizer sugar Add some sugar for additional sources Apr 3, 2020
@lburgazzoli lburgazzoli self-assigned this Apr 8, 2020
lburgazzoli added a commit to lburgazzoli/apache-camel-k that referenced this issue Apr 8, 2020
lburgazzoli added a commit to lburgazzoli/apache-camel-k that referenced this issue Apr 14, 2020
lburgazzoli added a commit to lburgazzoli/apache-camel-k that referenced this issue Apr 15, 2020
lburgazzoli added a commit to lburgazzoli/apache-camel-k that referenced this issue Apr 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants