diff --git a/backend/src/main/java/com/github/binpastes/paste/api/PasteController.java b/backend/src/main/java/com/github/binpastes/paste/api/PasteController.java
index 554540b..c4e7b11 100644
--- a/backend/src/main/java/com/github/binpastes/paste/api/PasteController.java
+++ b/backend/src/main/java/com/github/binpastes/paste/api/PasteController.java
@@ -6,7 +6,7 @@
import com.github.binpastes.paste.api.model.SearchView.SearchItemView;
import com.github.binpastes.paste.api.model.SingleView;
import com.github.binpastes.paste.domain.Paste;
-import com.github.binpastes.paste.domain.PasteService;
+import com.github.binpastes.paste.application.PasteService;
import jakarta.validation.ConstraintViolationException;
import jakarta.validation.Valid;
import jakarta.validation.constraints.NotBlank;
diff --git a/backend/src/main/java/com/github/binpastes/paste/domain/PasteService.java b/backend/src/main/java/com/github/binpastes/paste/application/PasteService.java
similarity index 92%
rename from backend/src/main/java/com/github/binpastes/paste/domain/PasteService.java
rename to backend/src/main/java/com/github/binpastes/paste/application/PasteService.java
index 7ac8789..efec282 100644
--- a/backend/src/main/java/com/github/binpastes/paste/domain/PasteService.java
+++ b/backend/src/main/java/com/github/binpastes/paste/application/PasteService.java
@@ -1,6 +1,8 @@
-package com.github.binpastes.paste.domain;
+package com.github.binpastes.paste.application;
-import com.github.binpastes.paste.business.tracking.TrackingService;
+import com.github.binpastes.paste.application.tracking.TrackingService;
+import com.github.binpastes.paste.domain.Paste;
+import com.github.binpastes.paste.domain.PasteRepository;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
diff --git a/backend/src/main/java/com/github/binpastes/paste/business/tracking/MessagingClient.java b/backend/src/main/java/com/github/binpastes/paste/application/tracking/MessagingClient.java
similarity index 98%
rename from backend/src/main/java/com/github/binpastes/paste/business/tracking/MessagingClient.java
rename to backend/src/main/java/com/github/binpastes/paste/application/tracking/MessagingClient.java
index 2b056e7..356354d 100644
--- a/backend/src/main/java/com/github/binpastes/paste/business/tracking/MessagingClient.java
+++ b/backend/src/main/java/com/github/binpastes/paste/application/tracking/MessagingClient.java
@@ -1,4 +1,4 @@
-package com.github.binpastes.paste.business.tracking;
+package com.github.binpastes.paste.application.tracking;
import org.apache.activemq.artemis.api.core.ActiveMQException;
import org.apache.activemq.artemis.api.core.ActiveMQObjectClosedException;
diff --git a/backend/src/main/java/com/github/binpastes/paste/business/tracking/MessagingConfig.java b/backend/src/main/java/com/github/binpastes/paste/application/tracking/MessagingConfig.java
similarity index 98%
rename from backend/src/main/java/com/github/binpastes/paste/business/tracking/MessagingConfig.java
rename to backend/src/main/java/com/github/binpastes/paste/application/tracking/MessagingConfig.java
index f1ba16f..fd6a3f3 100644
--- a/backend/src/main/java/com/github/binpastes/paste/business/tracking/MessagingConfig.java
+++ b/backend/src/main/java/com/github/binpastes/paste/application/tracking/MessagingConfig.java
@@ -1,4 +1,4 @@
-package com.github.binpastes.paste.business.tracking;
+package com.github.binpastes.paste.application.tracking;
import org.apache.activemq.artemis.api.core.QueueConfiguration;
import org.apache.activemq.artemis.api.core.RoutingType;
diff --git a/backend/src/main/java/com/github/binpastes/paste/business/tracking/TrackingService.java b/backend/src/main/java/com/github/binpastes/paste/application/tracking/TrackingService.java
similarity index 97%
rename from backend/src/main/java/com/github/binpastes/paste/business/tracking/TrackingService.java
rename to backend/src/main/java/com/github/binpastes/paste/application/tracking/TrackingService.java
index 1382fac..37c8c81 100644
--- a/backend/src/main/java/com/github/binpastes/paste/business/tracking/TrackingService.java
+++ b/backend/src/main/java/com/github/binpastes/paste/application/tracking/TrackingService.java
@@ -1,4 +1,4 @@
-package com.github.binpastes.paste.business.tracking;
+package com.github.binpastes.paste.application.tracking;
import com.github.binpastes.paste.domain.PasteRepository;
import jakarta.annotation.PostConstruct;
diff --git a/backend/src/main/resources/application-dev.properties b/backend/src/main/resources/application-dev.properties
index f1b1798..3a06073 100644
--- a/backend/src/main/resources/application-dev.properties
+++ b/backend/src/main/resources/application-dev.properties
@@ -2,7 +2,7 @@
#logging.level.io.r2dbc=TRACE
#logging.level.org.apache.activemq.artemis.core.server=INFO
#logging.level.org.flywaydb.core.internal.license.VersionPrinter=INFO
-logging.level.com.github.binpastes.paste.business.tracking=DEBUG
+logging.level.com.github.binpastes.paste.application.tracking=DEBUG
spring.flyway.enabled=true
spring.flyway.driver-class-name=org.h2.Driver
diff --git a/backend/src/test/java/com/github/binpastes/paste/api/PasteControllerTest.java b/backend/src/test/java/com/github/binpastes/paste/api/PasteControllerTest.java
index e7c585a..e7308ee 100644
--- a/backend/src/test/java/com/github/binpastes/paste/api/PasteControllerTest.java
+++ b/backend/src/test/java/com/github/binpastes/paste/api/PasteControllerTest.java
@@ -1,6 +1,6 @@
package com.github.binpastes.paste.api;
-import com.github.binpastes.paste.domain.PasteService;
+import com.github.binpastes.paste.application.PasteService;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.params.ParameterizedTest;
diff --git a/backend/src/test/java/com/github/binpastes/paste/api/TrackingIT.java b/backend/src/test/java/com/github/binpastes/paste/api/TrackingIT.java
index c91ed56..41d3be3 100644
--- a/backend/src/test/java/com/github/binpastes/paste/api/TrackingIT.java
+++ b/backend/src/test/java/com/github/binpastes/paste/api/TrackingIT.java
@@ -1,7 +1,7 @@
package com.github.binpastes.paste.api;
-import com.github.binpastes.paste.business.tracking.MessagingClient;
-import com.github.binpastes.paste.business.tracking.TrackingService;
+import com.github.binpastes.paste.application.tracking.MessagingClient;
+import com.github.binpastes.paste.application.tracking.TrackingService;
import com.github.binpastes.paste.domain.Paste;
import com.github.binpastes.paste.domain.Paste.PasteExposure;
import com.github.binpastes.paste.domain.PasteRepository;
diff --git a/backend/src/test/java/com/github/binpastes/paste/domain/PasteTest.java b/backend/src/test/java/com/github/binpastes/paste/domain/PasteTest.java
index 51da4c1..cc7e81f 100644
--- a/backend/src/test/java/com/github/binpastes/paste/domain/PasteTest.java
+++ b/backend/src/test/java/com/github/binpastes/paste/domain/PasteTest.java
@@ -58,13 +58,13 @@ void trackPasteViewCount() {
@DisplayName("track paste - updates lastViewed timestamp to most recent one")
void trackPasteLastViewed() {
var newPaste = Paste.newInstance(null, "someContent", null, false, PasteExposure.PUBLIC, null);
- var now = LocalDateTime.now();
- var yesterday = now.minusDays(1);
+ var today = LocalDateTime.now();
+ var yesterday = today.minusDays(1);
- newPaste.trackView(now);
+ newPaste.trackView(today);
newPaste.trackView(yesterday);
- assertThat(newPaste.getLastViewed()).isEqualTo(now);
+ assertThat(newPaste.getLastViewed()).isEqualTo(today);
assertThat(newPaste.getViews()).isEqualTo(2);
}
diff --git a/frontend/pom.xml b/frontend/pom.xml
index b7423ba..64519e4 100644
--- a/frontend/pom.xml
+++ b/frontend/pom.xml
@@ -49,21 +49,28 @@
- org.apache.maven.plugins
- maven-surefire-plugin
+ maven-resources-plugin
- default-test
+ generate-resources
+
+ resources
+
+
+
+
+ dist
+
+
+ ${project.build.outputDirectory}/static
+
+
+
+ default-resources
none
-
-
-
- org.apache.maven.plugins
- maven-failsafe-plugin
-
- default-test
+ default-testResources
none
@@ -83,21 +90,22 @@
- maven-resources-plugin
+ org.apache.maven.plugins
+ maven-surefire-plugin
- generate-resources
-
- resources
-
-
-
-
- dist
-
-
- ${project.build.outputDirectory}/static
-
+ default-test
+ none
+
+
+
+
+ org.apache.maven.plugins
+ maven-failsafe-plugin
+
+
+ default
+ none
diff --git a/pom.xml b/pom.xml
index 8609197..738e74c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -157,8 +157,8 @@
- scm:git:https://github.com/querwurzel/binpastes.git
- scm:git:https://github.com/querwurzel/binpastes.git
+ scm:git:https://github.com/querwurzel/BinPastes.git
+ scm:git:https://github.com/querwurzel/BinPastes.git
HEAD