quarkusio / quarkus

Quarkus: Supersonic Subatomic Java.
https://quarkus.io
Apache License 2.0
13.8k stars 2.68k forks source link

`uses` extension metadata to make some underlying library version visible to users of Quarkus Platrform and tooling #35404

Open ppalaga opened 1 year ago

ppalaga commented 1 year ago

Description

uses is just a working proposal. I am open to any better name.

  1. Camel Quarkus wraps some specific version of Camel and it would be great if we could make that version visible to end users.
  2. Camel Quarkus extensions may wrap some further library, such as HTTP or Hazelcast client and it would also be great to make those visible to users.
  3. The cases 1. and 2. could be seen as a bit different: while Camel version holds for all extensions provided by Camel Quarkus (hence it is Platform participant level), the Hazelcast and HTTP client versions are extension specific. I am not sure we really need to have two levels of the metadata, I just wanted to mention this.
  4. The cases 1. and 2. show that for a single extension, there might be more than one uses key-version pairs.
  5. While it is easy to generate this metadata on the participant side, the version of the underlying uses dependency may get changed in the platform. So the value of the metadata should perhaps not be the actual version, but rather a groupId:artifactId for which the real version should be querried by Platform BOM generator from the participant BOM.
  6. It would be great if the uses version information could also be visible on the Quarkus Platform compatibility matrix page I asked for when we discussed the new Platform BOM versioning scheme.

Implementation ideas

An example of quarkus-extension.yaml delivered by an extension:

---
name: "Camel AMQP"
...
metadata:
  ...
  uses:
    'Camel': 'org.apache.camel:camel-core'
    'ActiveMQ Client': 'org.apache.qpid:qpid-jms-client'

An example how the new metadata could be presented on code.quarkus.io: image

geoand commented 1 year ago

cc @ia3andy

ia3andy commented 1 year ago

@aloubyansky we already have this info right in the metadata? There is an issue about auto-adding the transitive extension in the list (and showing them some way): https://github.com/quarkusio/code.quarkus.io/issues/38

ia3andy commented 1 year ago

I would like to add those improvements, but there are so many stuff to do on all the fronts that it hard to fits things that are not essential. It would be nice to have some contributions and I would love to help anyone willing to add such features.

aloubyansky commented 1 year ago

No @ia3andy, generally, this info will be about libraries Quarkus extensions are developed for. Such as quarkus-hibernate-orm -> hibernate, quarkus-resteasy -> resteasy, etc

aloubyansky commented 1 year ago

I'd like to consider alternative names to express this info:

Any preferences? Other suggestions? So far I tend to prefer integrates.

aloubyansky commented 1 year ago

FYI @maxandersen

ppalaga commented 1 year ago
  • integrates
  • bundles
  • embeds

I like all of them!

maxandersen commented 1 year ago

I'm sure we can record the info in the model but I'm concerned how this will show up on code.quarkus and cli.

Having a (in worst case) an extra line of info on every extension is going to be very noisy. What is the issue we are trying to solve here ? could it just be a comment in a tooltip ?

and should the name and version referenced show up when searching ?

aloubyansky commented 1 year ago

The purpose would be to have a way for users to know which underlying library version is integrated. I agree we could start with a tooltip. Search ability sounds like a useful feature but could be implemented later, imo.

ppalaga commented 1 year ago

Having a (in worst case) an extra line of info on every extension is going to be very noisy. What is the issue we are trying to solve here ? could it just be a comment in a tooltip ?

I personally would not mind if the info is hidden in the default view. Showing it in tootip, or some details panel shown on click would be fine from my PoV.

and should the name and version referenced show up when searching ?

Indexing the names would not harm. Not sure for versions.