-
Notifications
You must be signed in to change notification settings - Fork 2
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
Consider generating nextCatalog entries based on Maven dependencies #6
Comments
Thanks for creating the issue Jostein. Putting that dependency to the POM vs. Catalog vs. OSGi manifest was indeed an "open" question at the time we refactored the whole build system.
yes, it is.
correct, POM dependencies are only used for Java dependencies. One issue with declaring the dependencies in the POM is that there is no straightforward way to know wether the dependency is an "XML module", i.e. if it needs to be converted as a We could provide an explicit OSGi header via the configuration of the Maven Bundle Plugin, but the idea was that a module developer s/b able to create a simple module with a very minimalist POM, and just manually edit the catalog, with minimum knowledge of Maven. I'd be happy to improve the situation, so any idea or experiment is welcome! |
Cool, I'll assign it to me for now, just so the issue is assigned, and in case I get time to experiment. |
If we know that a module is a pure-XML module, and if we assume that the bundle symbolic names are on the form Modules with non-module-dependencies will always need to declare a custom service component (I think); which means that they have to configure the maven-bundle-plugin in the POM along with an explicit ...which leaves modules that depend on modules with OSGi symbolic names other than In most cases, at least for "simple XML modules", I think we can generate the wdyt? |
Right, but the primary issue is to know whether a POM dependency is a Pipeline module or not. It would be doable by inspecting the jar to look for
yeah, unless we start to use Java annotations to declare that class provides a DS component :)
no, see for instance the POM of the |
mmhm, I see.
|
While I don't think this idea is impossible to implement, a better approach is to generate the Require-Bundle headers not from the pom.xml but from the source files (.xpl, .xsl) (see daisy/pipeline-tasks#41). Does everybody agree? Note that ideally we shouldn't use Require-Bundle at all (daisy/pipeline-tasks#29, daisy/pipeline-tasks#33). |
The
nextCatalog
entries in the XML catalogs are only used when the modules are deployed into the framework (or is it only for building the OSGi "Require-Bundle" declarations?). We want to maintain a valid dependency graph both in Maven (in the pom) and OSGi (through the catalog nextCatalog declarations). However, we don't have a way to test that the dependency graph is valid at the moment, and we have to maintain the dependencies in both the catalog and the pom (although we don't really do it in the pom atm I think?).By generating the nextCatalog entries based on the maven dependencies, we only have to maintain the graph in one place.
The maven dependencies can also potentially be used for integration testing (daisy/xproc-maven-plugin#7) which would work as a way to make sure that all necessary dependencies are declared.
The text was updated successfully, but these errors were encountered: