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

Break job engine to rest api dependency #4073

Open
wants to merge 31 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
a9a69be
:heavy_minus_sign: removing unneeded dependencies from kapua-service-…
dseurotech Apr 11, 2024
50bfc0a
:heavy_minus_sign: removing unneeded dependencies from kapua-client-s…
dseurotech Apr 11, 2024
c66e270
:heavy_minus_sign: removing the checker framework as it was not activ…
dseurotech Apr 12, 2024
782a8eb
:heavy_minus_sign: removing unused guava dependency
dseurotech Apr 12, 2024
2d2ba34
partially restoring javax validation
dseurotech May 10, 2024
c7adabd
:heavy_minus_sign: removed unused or indirect dependencies from clien…
dseurotech May 13, 2024
7e916e3
:heavy_minus_sign: absorbed job-engine-app-core into job-engine-app-w…
dseurotech May 14, 2024
0dbf5a7
:heavy_minus_sign: trying to clean up job-engine-app's dependencies a…
dseurotech May 14, 2024
3c4a125
:bug: was throwing npe on null isRunning properties (for jobs that do…
dseurotech May 15, 2024
b0a5602
:heavy_minus_sign: removing unused logging bridges
dseurotech May 15, 2024
0936ed5
:heavy_minus_sign: removing inherited dependencies from job-engine-jb…
dseurotech May 15, 2024
07f5286
:heavy_minus_sign: removing inherited dependency commons-configurationh
dseurotech May 15, 2024
a81a218
:fire: removed unused postcontruct feature
dseurotech May 15, 2024
44bbd49
restoring some logging
dseurotech May 15, 2024
be232e1
Revert ":heavy_minus_sign: trying to clean up job-engine-app's depend…
dseurotech May 16, 2024
c3dca6c
better dependencies cleanup in job-engine
dseurotech May 16, 2024
fb508e5
:memo: fixing and improving javadoc for Initializing Methods
dseurotech May 16, 2024
f0de83c
when referencing the internal, the api already comes indirectly
dseurotech May 20, 2024
8cbbb6b
Revert ":heavy_minus_sign: absorbed job-engine-app-core into job-engi…
dseurotech May 20, 2024
9e07636
cleanup
dseurotech May 21, 2024
d9e833c
:heavy_minus_sign: breaking the dependency between job-engine app and…
dseurotech Jun 5, 2024
41e4c35
:heavy_minus_sign: no longer necessary to exclude job-engine-client f…
dseurotech Jun 7, 2024
260b5dd
:heavy_minus_sign: absorbed job-engine-app-core into job-engine-app-w…
dseurotech May 14, 2024
ef3e38a
Revert ":heavy_minus_sign: absorbed job-engine-app-core into job-engi…
dseurotech May 20, 2024
7c117bf
:heavy_minus_sign: breaking the dependency between job-engine app and…
dseurotech Jun 5, 2024
7eef0eb
:recycle: breaking the dependency between job-engine and rest-api by …
dseurotech Jun 10, 2024
cbca563
:recycle: reorganizing web and rest libraries
dseurotech Jun 14, 2024
0b60da4
:recycle: better module naming
dseurotech Jun 19, 2024
d0aad72
:recycle: using base class provided in library instead of reheating t…
dseurotech Jun 20, 2024
92d3e20
:heavy_plus_sign: post-rebase adjustments
dseurotech Dec 3, 2024
1435d79
:fix: moving job-engine exception to job-engine modules as to not pol…
dseurotech Dec 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions assembly/api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -148,10 +148,6 @@
<groupId>org.eclipse.persistence</groupId>
<artifactId>javax.persistence</artifactId>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>
<dependency>
<groupId>commons-configuration</groupId>
<artifactId>commons-configuration</artifactId>
Expand Down
4 changes: 0 additions & 4 deletions assembly/console/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,6 @@
<groupId>org.eclipse.persistence</groupId>
<artifactId>javax.persistence</artifactId>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>
<dependency>
<groupId>commons-configuration</groupId>
<artifactId>commons-configuration</artifactId>
Expand Down
6 changes: 1 addition & 5 deletions broker/artemis/plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-security-authentication-api</artifactId>
<artifactId>kapua-service-client</artifactId>
</dependency>

<dependency>
Expand Down Expand Up @@ -93,10 +93,6 @@
<artifactId>logback-classic</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-service-client</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
Expand Down
12 changes: 1 addition & 11 deletions client/gateway/profile/kura/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-client-gateway</artifactId>
<version>2.1.0-SNAPSHOT</version>
<relativePath>../..</relativePath>
<relativePath>../../pom.xml</relativePath>
</parent>

<name>Eclipse Kapua :: Gateway Client :: Profile :: Eclipse Kura</name>
Expand All @@ -41,16 +41,6 @@
<artifactId>kapua-client-gateway-provider-mqtt</artifactId>
</dependency>

<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-client-gateway-spi</artifactId>
</dependency>

<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>

<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
Expand Down
12 changes: 1 addition & 11 deletions client/gateway/provider/fuse/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,7 @@
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-client-gateway-provider-mqtt</artifactId>
</dependency>

<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-client-gateway-spi</artifactId>
</dependency>

<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>


<dependency>
<groupId>org.fusesource.mqtt-client</groupId>
<artifactId>mqtt-client</artifactId>
Expand Down
10 changes: 0 additions & 10 deletions client/gateway/provider/paho/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,6 @@
<artifactId>kapua-client-gateway-provider-mqtt</artifactId>
</dependency>

<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-client-gateway-spi</artifactId>
</dependency>

<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>

<dependency>
<groupId>org.eclipse.paho</groupId>
<artifactId>org.eclipse.paho.client.mqttv3</artifactId>
Expand Down
85 changes: 6 additions & 79 deletions client/security/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,97 +23,24 @@
<artifactId>kapua-client-security</artifactId>

<dependencies>
<!-- ActiveMQ Artemis -->
<dependency>
<groupId>org.apache.activemq</groupId>
<artifactId>artemis-amqp-protocol</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.activemq</groupId>
<artifactId>artemis-commons</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.activemq</groupId>
<artifactId>artemis-server</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.activemq</groupId>
<artifactId>artemis-core-client</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.qpid</groupId>
<artifactId>qpid-jms-client</artifactId>
</dependency>

<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-service-api</artifactId>
</dependency>
<!-- just for service bus settings - should be moved to service-api???? -->
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-commons</artifactId>
</dependency>
<!-- External Dependencies -->
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-datastore-api</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-device-management-api</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-device-registry-api</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-security-authentication-api</artifactId>
</dependency>

<!-- needed to set the theadcontext on login
TODO find a way to remove this dependency -->
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-core</artifactId>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<groupId>org.apache.activemq</groupId>
<artifactId>artemis-server</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<!-- Dependencies are required to provide ActiveMQ the JARs -->
<id>copy-dependencies</id>
<phase>package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,12 @@
*******************************************************************************/
package org.eclipse.kapua.client.security.bean;

import org.eclipse.kapua.model.id.KapuaId;
import org.eclipse.kapua.service.device.registry.connection.DeviceConnection;

import java.security.cert.Certificate;
import java.util.HashMap;
import java.util.Map;

import org.eclipse.kapua.model.id.KapuaId;

public class AuthContext {

private String clusterName;
Expand Down Expand Up @@ -136,19 +135,20 @@ public boolean getSslEnabled() {
}

/**
* Gets the {@link DeviceConnection#getAuthenticationType()} used when connecting.
* Gets the device connection's authentication type used when connecting.
*
* @return The {@link DeviceConnection#getAuthenticationType()} used when connecting.
* @return The device connection's authentication type used when connecting.
* @since 2.0.0
*/
public String getAuthenticationType() {
return authenticationType;
}

/**
* Sets the {@link DeviceConnection#getAuthenticationType()} used to connection.
* Sets the device connection's authentication type used to connection.
*
* @param authenticationType The {@link DeviceConnection#getAuthenticationType()} used to connection.
* @param authenticationType
* The device connection's authentication type used to connection.
* @since 2.0.0
*/
public void setAuthenticationType(String authenticationType) {
Expand Down
7 changes: 3 additions & 4 deletions commons-rest/pom.xml → commons-jersey/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,10 @@
<version>2.1.0-SNAPSHOT</version>
</parent>

<artifactId>kapua-commons-rest</artifactId>
<artifactId>kapua-commons-jersey</artifactId>
<packaging>pom</packaging>
<modules>
<module>model</module>
<module>errors</module>
<module>filters</module>
<module>rest</module>
<module>web</module>
</modules>
</project>
File renamed without changes.
54 changes: 42 additions & 12 deletions commons-rest/model/pom.xml → commons-jersey/rest/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,13 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<artifactId>kapua-commons-rest</artifactId>
<artifactId>kapua-commons-jersey</artifactId>
<groupId>org.eclipse.kapua</groupId>
<version>2.1.0-SNAPSHOT</version>
</parent>

<artifactId>kapua-commons-rest-model</artifactId>
<artifactId>kapua-commons-jersey-rest</artifactId>

<dependencies>
<!-- Internal dependencies -->
Expand All @@ -36,33 +35,64 @@
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-job-engine-api</artifactId>
<artifactId>kapua-endpoint-api</artifactId>
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-scheduler-api</artifactId>
<artifactId>kapua-security-shiro</artifactId>
</dependency>

<!-- re-declare as provided as our web container will provide this -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<scope>provided</scope>
</dependency>

<!-- Testing dependencies -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.core</groupId>
<artifactId>jersey-server</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.shiro</groupId>
<artifactId>shiro-web</artifactId>
</dependency>
<!-- Moxy for object marshalling unmarshalling -->
<dependency>
<groupId>org.glassfish.jersey.media</groupId>
<artifactId>jersey-media-moxy</artifactId>
</dependency>

<!-- Test dependencies -->
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-locator-guice</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-qa-markers</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>jakarta.ws.rs</groupId>
<artifactId>jakarta.ws.rs-api</artifactId>
<scope>test</scope>
<groupId>org.eclipse.kapua</groupId>
<artifactId>kapua-scheduler-api</artifactId>
</dependency>
</dependencies>
</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
* Contributors:
* Eurotech - initial API and implementation
*******************************************************************************/
package org.eclipse.kapua.commons.rest.errors;

package org.eclipse.kapua.commons.jersey.rest;

public interface ExceptionConfigurationProvider {

boolean showStackTrace();
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@
* Contributors:
* Eurotech - initial API and implementation
*******************************************************************************/
package org.eclipse.kapua.app.api.web;

import org.eclipse.kapua.commons.rest.errors.ExceptionConfigurationProvider;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
package org.eclipse.kapua.commons.jersey.rest;

import javax.inject.Inject;
import javax.inject.Named;
import javax.inject.Singleton;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

@Singleton
public class ExceptionConfigurationProviderImpl implements ExceptionConfigurationProvider {

private final boolean showStackTrace;
private final Logger logger = LoggerFactory.getLogger(this.getClass());

Expand Down
Loading
Loading