vaadin / observability-kit

Other
5 stars 2 forks source link

Convert the project to Maven #147

Closed heruan closed 1 year ago

heruan commented 1 year ago

This PR converts the repository structure to a Maven multi-module project. This helps the release process which is currently based on Maven and makes room for additional modules, e.g. the client-side module and a demo project.

The resulting project structure is now:

|- observability-kit
\--- observability-kit-agent

The observability-kit-agent submodule contains the correct Maven dependencies to build and test the project, but to produce the OpenTelemetry agent extension it still contains the Gradle scripts which can be run with the Maven command:

mvn -pl :observability-kit-agent package

A separate PR will possibly remove the Gradle stuff and use Maven to produce the extended agent.

sissbruecker commented 1 year ago

If we intend to use the gradle build only for building the agent, but not developing it, we could move / remove all the development related setup:

Code formatting

Since the Maven build adds its own formatter plugin, the Spotless code formatter / linter can be removed: https://github.com/vaadin/observability-kit/blob/75265a0f44772f88a6b588491351ae96812090f0/observability-kit-agent/build.gradle#L15 https://github.com/vaadin/observability-kit/blob/75265a0f44772f88a6b588491351ae96812090f0/observability-kit-agent/build.gradle#L200-L206

Unit tests

Tests should probably be run through Maven as well? Currently running mvn test from the agent module does not seem to pick up any tests. If running tests has been added to the Maven config, then the test related setup can be removed from Gradle:

https://github.com/vaadin/observability-kit/blob/75265a0f44772f88a6b588491351ae96812090f0/observability-kit-agent/build.gradle#L27 https://github.com/vaadin/observability-kit/blob/75265a0f44772f88a6b588491351ae96812090f0/observability-kit-agent/build.gradle#L33 https://github.com/vaadin/observability-kit/blob/75265a0f44772f88a6b588491351ae96812090f0/observability-kit-agent/build.gradle#L103-L115