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

chore: ugprade Service Binding Operator v0.7.1 #2235

Merged
merged 1 commit into from
Apr 28, 2021

Conversation

johnpoth
Copy link
Member

Thanks !

Release Note

NONE

@nicolaferraro nicolaferraro merged commit fa01028 into apache:main Apr 28, 2021
@nicolaferraro nicolaferraro mentioned this pull request Jul 2, 2021
@arthurdm
Copy link

arthurdm commented Jul 8, 2021

hey @johnpoth - quick question: is the strategy here to use SBO as a library, instead of requiring it to be fully installed as an Operator? If so, does it mean the Camel K Operator listens for ServiceBinding CRs?

@johnpoth
Copy link
Member Author

johnpoth commented Jul 9, 2021

Hi @arthurdm !

For now, the strategy is to rely on the Service Binding Operator (SBO) to construct the binding Secret. The Camel-k Operator then mounts the Secret referenced in the ServiceBinding CR into the operand's Pod and then Quarkus takes over to construct the relevant POJOs.

As the spec is still evolving the above approach might evolve with it. Specification adopters are scarce so it's hard to say. We therefore test this using a mock service.

The drawback of the above approach is that the SBO needs to be installed before Camel-k as we listen to ServiceBinding CR to know when the Secret has been correctly created. Another drawback is that the ServiceBinding CR is "shared" between two Operators.

A benefit of the approach is that we only create the Pod once the binding Secret is created so there are no useless Pod restarts (which is AFAIK the traditional workflow of the SBO).

Using the SBO as a library is definitely worth exploring!

Hope this helps !

@arthurdm
Copy link

arthurdm commented Jul 9, 2021

thanks @johnpoth!

So If I wanted to construct the ServiceBinding manually (instead of passing the list of provisioned services), what is the kind/apiVersion/name I should use for the application element? Or does that not matter, since the Camel K Operator just needs the Secret generated and referenced from the ServiceBinding CR, and essentially ignore the application element?

btw, I am the co-chair of the Service Binding Spec, so very happy to see this adoption! 👍 🚀

@johnpoth
Copy link
Member Author

Hi @arthurdm ! Sorry was on PTO :)

Yes. You can tell Camel-k to use a manually built ServiceBinding by specifying the ServiceBinding URI you want to use in the --connect flag for the run command:

-c, --connect stringArray            A ServiceBinding or Provisioned Service that the integration should bind to, specified as [[apigroup/]version:]kind:[namespace/]name

e.g for a ServiceBinding called foo in the bar Namespace:

kamel run App.java --connect binding.operators.coreos.com/v1alpha1:ServiceBinding:bar/foo

This was done to allow users to use complex Service Binding mappings but not expose the details in the Kamel CLI.

There was talk of having a library of ServiceBinding mappings for specific Services that haven't yet implemented the ServiceBinding specification; not sure if that is still the case.

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.

None yet

4 participants