Skip to content

Commit deb8106

Browse files
authored
Merge pull request #34 from dwasinge/feature/user-processing
Initial Refactor of GIT API
2 parents c522cb9 + 17ce609 commit deb8106

File tree

79 files changed

+2597
-1881
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

79 files changed

+2597
-1881
lines changed

pom.xml

Lines changed: 169 additions & 184 deletions
Original file line numberDiff line numberDiff line change
@@ -1,186 +1,171 @@
11
<?xml version="1.0"?>
2-
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
3-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
4-
<modelVersion>4.0.0</modelVersion>
5-
<groupId>com.rht_labs</groupId>
6-
<artifactId>open-management-portal-git-api</artifactId>
7-
<version>1.0.0-SNAPSHOT</version>
8-
<properties>
9-
<compiler-plugin.version>3.8.1</compiler-plugin.version>
10-
<jackson.version>2.10.1</jackson.version>
11-
<maven.compiler.parameters>true</maven.compiler.parameters>
12-
<maven.compiler.source>1.8</maven.compiler.source>
13-
<maven.compiler.target>1.8</maven.compiler.target>
14-
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
15-
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
16-
<quarkus-plugin.version>1.2.0.Final</quarkus-plugin.version>
17-
<quarkus.platform.artifact-id>quarkus-universe-bom</quarkus.platform.artifact-id>
18-
<quarkus.platform.group-id>io.quarkus</quarkus.platform.group-id>
19-
<quarkus.platform.version>1.2.0.Final</quarkus.platform.version>
20-
<surefire-plugin.version>2.22.1</surefire-plugin.version>
21-
</properties>
22-
<dependencyManagement>
23-
<dependencies>
24-
<dependency>
25-
<groupId>${quarkus.platform.group-id}</groupId>
26-
<artifactId>${quarkus.platform.artifact-id}</artifactId>
27-
<version>${quarkus.platform.version}</version>
28-
<type>pom</type>
29-
<scope>import</scope>
30-
</dependency>
31-
</dependencies>
32-
</dependencyManagement>
33-
<dependencies>
34-
<dependency>
35-
<groupId>io.quarkus</groupId>
36-
<artifactId>quarkus-resteasy</artifactId>
37-
</dependency>
38-
<dependency>
39-
<groupId>io.quarkus</groupId>
40-
<artifactId>quarkus-junit5</artifactId>
41-
<scope>test</scope>
42-
</dependency>
43-
<dependency>
44-
<groupId>io.rest-assured</groupId>
45-
<artifactId>rest-assured</artifactId>
46-
<scope>test</scope>
47-
</dependency>
48-
<dependency>
49-
<groupId>io.quarkus</groupId>
50-
<artifactId>quarkus-rest-client</artifactId>
51-
</dependency>
52-
<dependency>
53-
<groupId>io.quarkus</groupId>
54-
<artifactId>quarkus-resteasy-jsonb</artifactId>
55-
</dependency>
56-
<dependency>
57-
<groupId>io.quarkus</groupId>
58-
<artifactId>quarkus-resteasy-qute</artifactId>
59-
</dependency>
60-
<dependency>
61-
<groupId>io.quarkus</groupId>
62-
<artifactId>quarkus-vertx</artifactId>
63-
</dependency>
64-
<dependency>
65-
<groupId>io.quarkus</groupId>
66-
<artifactId>quarkus-infinispan-client</artifactId>
67-
</dependency>
68-
<dependency>
69-
<groupId>io.quarkus</groupId>
70-
<artifactId>quarkus-logging-json</artifactId>
71-
</dependency>
72-
<dependency>
73-
<groupId>io.vertx</groupId>
74-
<artifactId>vertx-junit5</artifactId>
75-
<scope>test</scope>
76-
</dependency>
77-
<dependency>
78-
<groupId>org.mockito</groupId>
79-
<artifactId>mockito-core</artifactId>
80-
<version>3.2.4</version>
81-
<scope>test</scope>
82-
</dependency>
83-
<dependency>
84-
<groupId>org.mockito</groupId>
85-
<artifactId>mockito-junit-jupiter</artifactId>
86-
<version>3.2.4</version>
87-
<scope>test</scope>
88-
</dependency>
89-
<dependency>
90-
<groupId>org.infinispan</groupId>
91-
<artifactId>infinispan-junit-5</artifactId>
92-
<version>0.1</version>
93-
</dependency>
94-
<dependency>
95-
<groupId>com.fasterxml.jackson.core</groupId>
96-
<artifactId>jackson-core</artifactId>
97-
<version>${jackson.version}</version>
98-
</dependency>
99-
<dependency>
100-
<groupId>com.fasterxml.jackson.core</groupId>
101-
<artifactId>jackson-databind</artifactId>
102-
<version>${jackson.version}</version>
103-
</dependency>
104-
<dependency>
105-
<groupId>com.fasterxml.jackson.core</groupId>
106-
<artifactId>jackson-annotations</artifactId>
107-
<version>${jackson.version}</version>
108-
</dependency>
109-
<dependency>
110-
<groupId>com.fasterxml.jackson.dataformat</groupId>
111-
<artifactId>jackson-dataformat-yaml</artifactId>
112-
<version>${jackson.version}</version>
113-
</dependency>
114-
<dependency>
115-
<groupId>io.quarkus</groupId>
116-
<artifactId>quarkus-smallrye-health</artifactId>
117-
</dependency>
118-
<dependency>
119-
<groupId>io.quarkus</groupId>
120-
<artifactId>quarkus-smallrye-openapi</artifactId>
121-
</dependency>
122-
</dependencies>
123-
<build>
124-
<plugins>
125-
<plugin>
126-
<groupId>io.quarkus</groupId>
127-
<artifactId>quarkus-maven-plugin</artifactId>
128-
<version>${quarkus-plugin.version}</version>
129-
<executions>
130-
<execution>
131-
<goals>
132-
<goal>build</goal>
133-
</goals>
134-
</execution>
135-
</executions>
136-
</plugin>
137-
<plugin>
138-
<artifactId>maven-compiler-plugin</artifactId>
139-
<version>${compiler-plugin.version}</version>
140-
</plugin>
141-
<plugin>
142-
<artifactId>maven-surefire-plugin</artifactId>
143-
<version>${surefire-plugin.version}</version>
144-
<configuration>
145-
<systemProperties>
146-
<java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager>
147-
</systemProperties>
148-
</configuration>
149-
</plugin>
150-
</plugins>
151-
</build>
152-
<profiles>
153-
<profile>
154-
<id>native</id>
155-
<activation>
156-
<property>
157-
<name>native</name>
158-
</property>
159-
</activation>
160-
<build>
161-
<plugins>
162-
<plugin>
163-
<artifactId>maven-failsafe-plugin</artifactId>
164-
<version>${surefire-plugin.version}</version>
165-
<executions>
166-
<execution>
167-
<goals>
168-
<goal>integration-test</goal>
169-
<goal>verify</goal>
170-
</goals>
171-
<configuration>
172-
<systemProperties>
173-
<native.image.path>${project.build.directory}/${project.build.finalName}-runner</native.image.path>
174-
</systemProperties>
175-
</configuration>
176-
</execution>
177-
</executions>
178-
</plugin>
179-
</plugins>
180-
</build>
181-
<properties>
182-
<quarkus.package.type>native</quarkus.package.type>
183-
</properties>
184-
</profile>
185-
</profiles>
2+
<project
3+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
4+
xmlns="http://maven.apache.org/POM/4.0.0"
5+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
6+
<modelVersion>4.0.0</modelVersion>
7+
<groupId>com.rht_labs</groupId>
8+
<artifactId>open-management-portal-git-api</artifactId>
9+
<version>1.0.0-SNAPSHOT</version>
10+
<properties>
11+
<compiler-plugin.version>3.8.1</compiler-plugin.version>
12+
<maven.compiler.parameters>true</maven.compiler.parameters>
13+
<maven.compiler.source>1.8</maven.compiler.source>
14+
<maven.compiler.target>1.8</maven.compiler.target>
15+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
16+
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
17+
<quarkus-plugin.version>1.3.0.Final</quarkus-plugin.version>
18+
<quarkus.platform.artifact-id>quarkus-bom</quarkus.platform.artifact-id>
19+
<quarkus.platform.group-id>io.quarkus</quarkus.platform.group-id>
20+
<quarkus.platform.version>1.3.0.Final</quarkus.platform.version>
21+
<surefire-plugin.version>2.22.1</surefire-plugin.version>
22+
<lombok.version>1.18.12</lombok.version>
23+
</properties>
24+
<dependencyManagement>
25+
<dependencies>
26+
<dependency>
27+
<groupId>${quarkus.platform.group-id}</groupId>
28+
<artifactId>${quarkus.platform.artifact-id}</artifactId>
29+
<version>${quarkus.platform.version}</version>
30+
<type>pom</type>
31+
<scope>import</scope>
32+
</dependency>
33+
</dependencies>
34+
</dependencyManagement>
35+
<dependencies>
36+
<!-- Web -->
37+
<dependency>
38+
<groupId>io.quarkus</groupId>
39+
<artifactId>quarkus-resteasy</artifactId>
40+
</dependency>
41+
<dependency>
42+
<groupId>io.quarkus</groupId>
43+
<artifactId>quarkus-hibernate-validator</artifactId>
44+
</dependency>
45+
<dependency>
46+
<groupId>io.quarkus</groupId>
47+
<artifactId>quarkus-resteasy-jsonb</artifactId>
48+
</dependency>
49+
<!-- REST Client -->
50+
<dependency>
51+
<groupId>io.quarkus</groupId>
52+
<artifactId>quarkus-rest-client</artifactId>
53+
</dependency>
54+
<!-- Templates -->
55+
<dependency>
56+
<groupId>io.quarkus</groupId>
57+
<artifactId>quarkus-resteasy-qute</artifactId>
58+
</dependency>
59+
<!-- Events -->
60+
<dependency>
61+
<groupId>io.quarkus</groupId>
62+
<artifactId>quarkus-vertx</artifactId>
63+
</dependency>
64+
<!-- Cache -->
65+
<dependency>
66+
<groupId>io.quarkus</groupId>
67+
<artifactId>quarkus-infinispan-client</artifactId>
68+
</dependency>
69+
<!-- Health Checks -->
70+
<dependency>
71+
<groupId>io.quarkus</groupId>
72+
<artifactId>quarkus-smallrye-health</artifactId>
73+
</dependency>
74+
<!-- OpenApi/Swagger -->
75+
<dependency>
76+
<groupId>io.quarkus</groupId>
77+
<artifactId>quarkus-smallrye-openapi</artifactId>
78+
</dependency>
79+
<!-- Metrics -->
80+
<dependency>
81+
<groupId>org.eclipse.microprofile.metrics</groupId>
82+
<artifactId>microprofile-metrics-api</artifactId>
83+
</dependency>
84+
<!-- Other -->
85+
<dependency>
86+
<groupId>org.projectlombok</groupId>
87+
<artifactId>lombok</artifactId>
88+
<version>${lombok.version}</version>
89+
<scope>provided</scope>
90+
</dependency>
91+
<!-- Test -->
92+
<dependency>
93+
<groupId>io.quarkus</groupId>
94+
<artifactId>quarkus-junit5</artifactId>
95+
<scope>test</scope>
96+
</dependency>
97+
<dependency>
98+
<groupId>io.rest-assured</groupId>
99+
<artifactId>rest-assured</artifactId>
100+
<scope>test</scope>
101+
</dependency>
102+
<dependency>
103+
<groupId>io.vertx</groupId>
104+
<artifactId>vertx-junit5</artifactId>
105+
<scope>test</scope>
106+
</dependency>
107+
</dependencies>
108+
<build>
109+
<plugins>
110+
<plugin>
111+
<groupId>io.quarkus</groupId>
112+
<artifactId>quarkus-maven-plugin</artifactId>
113+
<version>${quarkus-plugin.version}</version>
114+
<executions>
115+
<execution>
116+
<goals>
117+
<goal>build</goal>
118+
</goals>
119+
</execution>
120+
</executions>
121+
</plugin>
122+
<plugin>
123+
<artifactId>maven-compiler-plugin</artifactId>
124+
<version>${compiler-plugin.version}</version>
125+
</plugin>
126+
<plugin>
127+
<artifactId>maven-surefire-plugin</artifactId>
128+
<version>${surefire-plugin.version}</version>
129+
<configuration>
130+
<systemProperties>
131+
<java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager>
132+
</systemProperties>
133+
</configuration>
134+
</plugin>
135+
</plugins>
136+
</build>
137+
<profiles>
138+
<profile>
139+
<id>native</id>
140+
<activation>
141+
<property>
142+
<name>native</name>
143+
</property>
144+
</activation>
145+
<build>
146+
<plugins>
147+
<plugin>
148+
<artifactId>maven-failsafe-plugin</artifactId>
149+
<version>${surefire-plugin.version}</version>
150+
<executions>
151+
<execution>
152+
<goals>
153+
<goal>integration-test</goal>
154+
<goal>verify</goal>
155+
</goals>
156+
<configuration>
157+
<systemProperties>
158+
<native.image.path>${project.build.directory}/${project.build.finalName}-runner</native.image.path>
159+
</systemProperties>
160+
</configuration>
161+
</execution>
162+
</executions>
163+
</plugin>
164+
</plugins>
165+
</build>
166+
<properties>
167+
<quarkus.package.type>native</quarkus.package.type>
168+
</properties>
169+
</profile>
170+
</profiles>
186171
</project>

src/main/java/com/redhat/labs/cache/ResidencyDataStore.java renamed to src/main/java/com/redhat/labs/cache/EngagementDataStore.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@
22

33
import java.util.List;
44

5-
import com.redhat.labs.omp.models.filesmanagement.SingleFileResponse;
5+
import com.redhat.labs.omp.models.gitlab.File;
66

77
/**
88
* This interface defines the contract to store data for the received events.
99
*
1010
* @author faisalmasood
1111
*/
12-
public interface ResidencyDataStore {
12+
public interface EngagementDataStore {
1313

1414
/**
1515
* throws {@link RuntimeException} if the store call is not successfull
@@ -20,9 +20,9 @@ public interface ResidencyDataStore {
2020
* @param key
2121
* @param residencyInformation
2222
*/
23-
public void store(String key, ResidencyInformation residencyInformation);
23+
public void store(String key, EngagementInformation residencyInformation);
2424

25-
public void store(SingleFileResponse file);
25+
public void store(File file);
2626

2727
/**
2828
* return NULL if the key is not present

0 commit comments

Comments
 (0)