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

Attempt to make the POM, assemblies and dependencies more structured #4114 #4168

Merged
merged 2 commits into from
Jul 31, 2024

Conversation

hansva
Copy link
Contributor

@hansva hansva commented Jul 26, 2024

This PR removes almost all Assembly files and simplifies the build process.

Note: you have to remove the unused folders from /assemblies else the client will contain the plugins twice (it will fetch the zips from target not sure why... but does not happen with a clean install)

  • All shared libraries that end up in lib/core are specified under /lib but each plugin will add their own jars to lib/core.
    This allows us to create a hop version with only the dependencies needed for the selected plugins while still using globally shared versions

  • hop-engine-beam now contains the minimal set of dependencies needed for to make hop work without the Beam plugin

  • The Beam plugin has been moved to lib/beam future step would be to split this further down to the specific runners

  • Each plugin zip is now build from the root directory so they can add files to lib/core and the samples are contained within the plugin zip during build time

  • Tried to simplify the assembly files by fetching all runtime dependencies in stead of manually listing the jars
    This did not fully work as planned because of maven limitations eg this three gives issues:

hop-core (provided)
├─ httpclient (provided)
├─ 3rd party jar
│├─ httpclient (compile)

Provided does not traverse to transient dependencies (which I would have expected it did)

  • Beam dependencies are fetched using dependency management no need to manage individual version only the global ${beam.version} is used
  • We can now run the project inside the IDE (tested with intellij) the debug assembly can be run it does not yet contain all components configuration I used:
    image

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Run mvn clean install apache-rat:check to make sure basic checks pass. A more thorough check will be performed on your pull request automatically.
  • If you have a group of commits related to the same change, please squash your commits into one and force push your branch using git rebase -i.
  • Mention the appropriate issue in your description (for example: addresses #123), if applicable.

To make clear that you license your contribution under the Apache License Version 2.0, January 2004
you have to acknowledge this by using the following check-box.

WIP: dependency restructure

WIP: Database plugin cleanup

WIP: transforms

WIP: tech transforms

WIP: Beam

WIP: Beam + Samples

Samples, cleanup, hop-web build

WIP remove duplicate jars
@hansva
Copy link
Contributor Author

hansva commented Jul 26, 2024

@nadment, let me know what you think about this. It's been a lot of work but I think it greatly simplifies things

@nadment
Copy link
Contributor

nadment commented Jul 28, 2024

I'm not sure I understand everything about org.apache.hop:hop-libs. Each plugin can optionally specify a shared library it uses that will be assembled in /lib/core to avoid redundancy (but without specifying versions?), but the plugin can also decide to have a specific version in its own /plugins/xxx/lib folder if it needs it.

Ok for samples, each plugin can contribute itself in the common folder /projects/samples.

And as for the JDBC drivers, I didn't understand a thing, but I'm not in my right mind because it was a festive weekend!

But in any case, good work as usual!

@hansva
Copy link
Contributor Author

hansva commented Jul 28, 2024

Yes, I want people to be able to build a "hop" that fits their needs. But all shared libs were seen as part of core and not of the specific plugins. This solution creates a bit of redundancy but you should now be able to make a minimal Hop version. That only contains the minimal set of dependencies.

@hansva hansva marked this pull request as ready for review July 31, 2024 08:58
@hansva hansva merged commit 3ca1152 into apache:main Jul 31, 2024
3 checks passed
@hansva hansva deleted the 4114 branch July 31, 2024 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants