From a5fbe130319cf4b9b6167c75608c508f460c1abf Mon Sep 17 00:00:00 2001 From: Dar Malovani Date: Tue, 9 Jan 2024 00:20:06 +0200 Subject: [PATCH] chore: realworld -> anythink market, readme change --- .framework/java/backend/README.md | 8 +++----- ...rldApplication.java => AnythinkMarketApplication.java} | 4 ++-- .../src/main/java/io/spring/JacksonCustomizations.java | 8 ++++---- ...ationTests.java => AythinkMarketApplicationTests.java} | 2 +- 4 files changed, 10 insertions(+), 12 deletions(-) rename .framework/java/backend/src/main/java/io/spring/{RealWorldApplication.java => AnythinkMarketApplication.java} (66%) rename .framework/java/backend/src/test/java/io/spring/{RealworldApplicationTests.java => AythinkMarketApplicationTests.java} (79%) diff --git a/.framework/java/backend/README.md b/.framework/java/backend/README.md index 64cb7fc7..acbddba5 100644 --- a/.framework/java/backend/README.md +++ b/.framework/java/backend/README.md @@ -1,7 +1,5 @@ # Anythink Market Backend -> ### Spring boot + MyBatis codebase containing real world examples (CRUD, auth, advanced patterns, etc) - # How it works The application uses Spring Boot (Web, Mybatis). @@ -19,10 +17,10 @@ You'll need Java 11 installed. ./gradlew bootRun -To test that it works, open a browser tab at http://localhost:3000/tags . -Alternatively, you can run +To test that it works, open a browser tab at http://localhost:3000/api/tags +Alternatively, you can run: - curl http://localhost:3000/tags + curl http://localhost:3000/api/tags # Run test diff --git a/.framework/java/backend/src/main/java/io/spring/RealWorldApplication.java b/.framework/java/backend/src/main/java/io/spring/AnythinkMarketApplication.java similarity index 66% rename from .framework/java/backend/src/main/java/io/spring/RealWorldApplication.java rename to .framework/java/backend/src/main/java/io/spring/AnythinkMarketApplication.java index c9f34e1a..8469390c 100644 --- a/.framework/java/backend/src/main/java/io/spring/RealWorldApplication.java +++ b/.framework/java/backend/src/main/java/io/spring/AnythinkMarketApplication.java @@ -4,9 +4,9 @@ import org.springframework.boot.autoconfigure.SpringBootApplication; @SpringBootApplication -public class RealWorldApplication { +public class AnythinkMarketApplication { public static void main(String[] args) { - SpringApplication.run(RealWorldApplication.class, args); + SpringApplication.run(AnythinkMarketApplication.class, args); } } diff --git a/.framework/java/backend/src/main/java/io/spring/JacksonCustomizations.java b/.framework/java/backend/src/main/java/io/spring/JacksonCustomizations.java index 86fab0ab..874a46ee 100644 --- a/.framework/java/backend/src/main/java/io/spring/JacksonCustomizations.java +++ b/.framework/java/backend/src/main/java/io/spring/JacksonCustomizations.java @@ -15,12 +15,12 @@ public class JacksonCustomizations { @Bean - public Module realWorldModules() { - return new RealWorldModules(); + public Module anythinkMarkerModules() { + return new AnythinkMarketModules(); } - public static class RealWorldModules extends SimpleModule { - public RealWorldModules() { + public static class AnythinkMarketModules extends SimpleModule { + public AnythinkMarketModules() { addSerializer(DateTime.class, new DateTimeSerializer()); } } diff --git a/.framework/java/backend/src/test/java/io/spring/RealworldApplicationTests.java b/.framework/java/backend/src/test/java/io/spring/AythinkMarketApplicationTests.java similarity index 79% rename from .framework/java/backend/src/test/java/io/spring/RealworldApplicationTests.java rename to .framework/java/backend/src/test/java/io/spring/AythinkMarketApplicationTests.java index bf36bbdc..af9d938a 100644 --- a/.framework/java/backend/src/test/java/io/spring/RealworldApplicationTests.java +++ b/.framework/java/backend/src/test/java/io/spring/AythinkMarketApplicationTests.java @@ -4,7 +4,7 @@ import org.springframework.boot.test.context.SpringBootTest; @SpringBootTest -public class RealworldApplicationTests { +public class AnythinkMarketApplicationTests { @Test public void contextLoads() {}