From ad5b6d493e39b5ac09a8f7560b97de90cb2d42b5 Mon Sep 17 00:00:00 2001 From: Dima Denysenko Date: Sat, 18 Nov 2023 12:06:28 +0200 Subject: [PATCH] chore: migrate to dev.knowhowto --- .drone/Dockerfile | 14 - .drone/pipelines.yml | 597 ------------------ .github/workflows/check-commit-message.yml | 4 +- .husky/pre-commit | 2 +- SEMANTIC_COMMITS.md | 35 - bookingdb-support/batch-job/pom.xml | 4 +- .../bookingdb/jobs/AbstractJobParameters.java | 2 +- .../jobs/CitiesImportParameters.java | 2 +- .../jobs/CityHotelsImportParameters.java | 2 +- .../jobs/CountriesImportParameters.java | 2 +- .../jobs/HotelsImportParameters.java | 2 +- .../bookingdb/jobs/JobParameters.java | 2 +- .../knowhowto}/bookingdb/jobs/JobType.java | 2 +- .../bookingdb/jobs/JobsConfiguration.java | 4 +- .../bookingdb/jobs/amqp/AbstractProducer.java | 4 +- .../jobs/amqp/AmqpQueuesProperties.java | 2 +- .../bookingdb/jobs/amqp/CommonAmqpConfig.java | 2 +- .../jobs/annotation/EnableJobSupport.java | 8 +- bookingdb-support/booking-api-client/pom.xml | 2 +- .../annotation/EnableBookingApiClient.java | 4 +- .../apiclient/client/AbstractNetClient.java | 6 +- .../apiclient/client/BookingcomNetClient.java | 4 +- .../apiclient/config/ClientConfig.java | 4 +- .../apiclient/config/NetClientProperties.java | 2 +- .../NetClientCommunicationException.java | 2 +- .../NetClientMisconfigurationException.java | 2 +- bookingdb-support/booking-persistence/pom.xml | 4 +- .../annotation/EnableBookingPersistence.java | 6 +- .../persistence/config/CacheConfig.java | 10 +- .../persistence/config/PersistenceConfig.java | 6 +- .../converter/HashMapConverter.java | 2 +- .../bookingdb/persistence/entity/City.java | 2 +- .../bookingdb/persistence/entity/Country.java | 2 +- .../bookingdb/persistence/entity/Hotel.java | 4 +- .../repository/CityRepository.java | 4 +- .../repository/CountryRepository.java | 4 +- .../repository/HotelRepository.java | 4 +- bookingdb-support/pom.xml | 4 +- dashboard-service/pom.xml | 14 +- .../dashboard/DashboardApplication.java | 2 +- .../dashboard/config/ApplicationConfig.java | 6 +- .../producer/ImportServiceProducer.java | 16 +- .../bookingdb/dashboard/web/CityResource.java | 10 +- .../dashboard/web/CountryResource.java | 10 +- .../dashboard/web/HotelResource.java | 10 +- .../dashboard/web/ImporterJobResource.java | 18 +- .../src/main/resources/application.yml | 2 +- .../src/main/resources/banner.txt | 5 - .../dashboard/DashboardApplicationIT.java | 2 +- .../dashboard}/config/TestDatabaseConfig.java | 2 +- .../src/test/resources/application.yml | 2 +- docker-compose.dev.yml | 2 +- edge-service/pom.xml | 6 +- .../bookingdb/edge/EdgeApplication.java | 2 +- .../edge/config/ApplicationConfig.java | 2 +- .../bookingdb/edge/config/GatewayConfig.java | 2 +- .../edge/config/ServicesProperties.java | 4 +- .../knowhowto}/bookingdb/edge/model/City.java | 2 +- .../bookingdb/edge/model/CityPage.java | 2 +- .../bookingdb/edge/model/Country.java | 2 +- .../bookingdb/edge/model/CountryPage.java | 2 +- .../bookingdb/edge/model/Hotel.java | 2 +- .../bookingdb/edge/model/HotelPage.java | 2 +- .../bookingdb/edge/model/Pageable.java | 2 +- .../edge/service/DashboardService.java | 10 +- .../bookingdb/edge/web/DashboardResource.java | 10 +- .../src/main/resources/application-local.yml | 2 +- .../src/main/resources/application.yml | 2 +- edge-service/src/main/resources/banner.txt | 5 - .../bookingdb/edge/EdgeApplicationIT.java | 2 +- .../src/test/resources/application.yml | 2 +- importer-service/pom.xml | 18 +- .../importer/ImporterApplication.java | 2 +- .../bookingdb/importer/config/AmqpConfig.java | 10 +- .../importer/config/ApplicationConfig.java | 8 +- .../consumer/ImportCitiesConsumer.java | 6 +- .../consumer/ImportCountriesConsumer.java | 6 +- .../consumer/ImportHotelConsumer.java | 6 +- .../importer/service/CityImporterService.java | 2 +- .../service/CountryImporterService.java | 2 +- .../service/HotelImporterService.java | 2 +- .../service/impl/CityImporterServiceImpl.java | 12 +- .../impl/CountryImporterServiceImpl.java | 10 +- .../impl/HotelImporterServiceImpl.java | 14 +- .../src/main/resources/application.yml | 2 +- .../src/main/resources/banner.txt | 5 - .../importer/ImporterApplicationIT.java | 2 +- .../importer/config/TestDatabaseConfig.java | 2 +- .../src/test/resources/application.yml | 2 +- init-container-service/pom.xml | 6 +- .../init/InitContainerApplication.java | 2 +- .../init/config/ApplicationConfig.java | 2 +- .../src/main/resources/banner.txt | 5 - .../20220704000000_create_countries_table.xml | 2 +- .../20220707000000_create_cities_table.xml | 4 +- .../20220708000000_create_hotels_table.xml | 4 +- .../init/InitContainerApplicationIT.java | 2 +- .../init}/config/TestDatabaseConfig.java | 2 +- package.json | 2 +- pom.xml | 16 +- src/main/docker/prometheus/prometheus.yml | 4 +- .../manifests/dashboard/deployment.yaml | 2 +- .../manifests/edge/deployment.yaml | 2 +- .../manifests/importer/deployment.yaml | 2 +- .../manifests/init-container/deployment.yaml | 2 +- 105 files changed, 218 insertions(+), 884 deletions(-) delete mode 100644 .drone/Dockerfile delete mode 100644 .drone/pipelines.yml delete mode 100644 SEMANTIC_COMMITS.md rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/AbstractJobParameters.java (92%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/CitiesImportParameters.java (87%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/CityHotelsImportParameters.java (87%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/CountriesImportParameters.java (86%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/HotelsImportParameters.java (88%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/JobParameters.java (75%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/JobType.java (67%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/JobsConfiguration.java (71%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/amqp/AbstractProducer.java (83%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/amqp/AmqpQueuesProperties.java (94%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/amqp/CommonAmqpConfig.java (98%) rename bookingdb-support/batch-job/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/jobs/annotation/EnableJobSupport.java (71%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/annotation/EnableBookingApiClient.java (78%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/client/AbstractNetClient.java (91%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/client/BookingcomNetClient.java (91%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/config/ClientConfig.java (74%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/config/NetClientProperties.java (96%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/exception/NetClientCommunicationException.java (74%) rename bookingdb-support/booking-api-client/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/apiclient/exception/NetClientMisconfigurationException.java (80%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/annotation/EnableBookingPersistence.java (70%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/config/CacheConfig.java (88%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/config/PersistenceConfig.java (70%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/converter/HashMapConverter.java (95%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/entity/City.java (96%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/entity/Country.java (95%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/entity/Hotel.java (92%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/repository/CityRepository.java (78%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/repository/CountryRepository.java (83%) rename bookingdb-support/booking-persistence/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/persistence/repository/HotelRepository.java (72%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/DashboardApplication.java (92%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/config/ApplicationConfig.java (63%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/producer/ImportServiceProducer.java (68%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/web/CityResource.java (91%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/web/CountryResource.java (91%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/web/HotelResource.java (91%) rename dashboard-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/web/ImporterJobResource.java (91%) rename dashboard-service/src/test/java/{org/ujar => dev/knowhowto}/bookingdb/dashboard/DashboardApplicationIT.java (89%) rename {init-container-service/src/test/java/org/ujar/bookingdb/init => dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard}/config/TestDatabaseConfig.java (88%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/EdgeApplication.java (93%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/config/ApplicationConfig.java (84%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/config/GatewayConfig.java (94%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/config/ServicesProperties.java (58%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/City.java (58%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/CityPage.java (86%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/Country.java (59%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/CountryPage.java (87%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/Hotel.java (52%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/HotelPage.java (86%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/model/Pageable.java (74%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/service/DashboardService.java (86%) rename edge-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/edge/web/DashboardResource.java (75%) rename edge-service/src/test/java/{org/ujar => dev/knowhowto}/bookingdb/edge/EdgeApplicationIT.java (90%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/ImporterApplication.java (92%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/config/AmqpConfig.java (89%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/config/ApplicationConfig.java (51%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/consumer/ImportCitiesConsumer.java (70%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/consumer/ImportCountriesConsumer.java (69%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/consumer/ImportHotelConsumer.java (69%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/service/CityImporterService.java (74%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/service/CountryImporterService.java (72%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/service/HotelImporterService.java (72%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/service/impl/CityImporterServiceImpl.java (84%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/service/impl/CountryImporterServiceImpl.java (86%) rename importer-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/importer/service/impl/HotelImporterServiceImpl.java (81%) rename importer-service/src/test/java/{org/ujar => dev/knowhowto}/bookingdb/importer/ImporterApplicationIT.java (89%) rename importer-service/src/test/java/{org/ujar => dev/knowhowto}/bookingdb/importer/config/TestDatabaseConfig.java (88%) rename init-container-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/init/InitContainerApplication.java (88%) rename init-container-service/src/main/java/{org/ujar => dev/knowhowto}/bookingdb/init/config/ApplicationConfig.java (70%) rename init-container-service/src/test/java/{org/ujar => dev/knowhowto}/bookingdb/init/InitContainerApplicationIT.java (90%) rename {dashboard-service/src/test/java/org/ujar/bookingdb/dashboard => init-container-service/src/test/java/dev/knowhowto/bookingdb/init}/config/TestDatabaseConfig.java (89%) diff --git a/.drone/Dockerfile b/.drone/Dockerfile deleted file mode 100644 index e864726..0000000 --- a/.drone/Dockerfile +++ /dev/null @@ -1,14 +0,0 @@ -ARG BASE_IMAGE - -FROM $BASE_IMAGE - -LABEL maintainer="dev@ujar.org" -ARG BUILD_VERSION -ENV APPLICATION_BUILD_VERSION ${BUILD_VERSION} - -WORKDIR /opt/app - -COPY ./target/*.jar /opt/app/app.jar - -ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -Duser.timezone=UTC -jar /opt/app/app.jar"] -EXPOSE 8080 diff --git a/.drone/pipelines.yml b/.drone/pipelines.yml deleted file mode 100644 index cce9295..0000000 --- a/.drone/pipelines.yml +++ /dev/null @@ -1,597 +0,0 @@ -kind : pipeline -name : CodeVerification -type : docker - -trigger : - event : - - push - - tag - -volumes : - - name : m2cache - host : - path : /app/.m2 - -steps : - - - name : mysql-healthcheck - image : mysql:5.7.42 - pull : if-not-exists - commands : - - while ! mysqladmin ping -h db -u svc_testing -psvc_testing --silent; do sleep 1; done - - mysql -h db -u svc_testing -psvc_testing -e "CREATE TABLE IF NOT EXISTS svc_testing_db.pipelines (id INT AUTO_INCREMENT PRIMARY KEY, name VARCHAR(50) NOT NULL);" - - - name : code-coverage-gate - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - volumes : - - name : m2cache - path : /root/.m2 - environment : - DATASOURCE_DRIVER : com.mysql.cj.jdbc.Driver - DATASOURCE_URL : jdbc:mysql://db:3306/svc_testing_db?serverTimezone=UTC&rewriteBatchedStatements=true&characterEncoding=UTF-8 - DEPLOYER_USERNAME : - from_secret : DEPLOYER_USERNAME - DEPLOYER_PASSWORD : - from_secret : DEPLOYER_PASSWORD - commands : - - mvn -version - - mvn clean verify -Dstyle.color=always -Dmaven.javadoc.skip=true -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD - - mvn install -Dstyle.color=always -Dmaven.javadoc.skip=true -DskipTests -Dmaven.test.skip=true --file bookingdb-support/pom.xml -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD - - - name : static-analysis-gate - depends_on : - - code-coverage-gate - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - volumes : - - name : m2cache - path : /root/.m2 - environment : - DEPLOYER_USERNAME : - from_secret : DEPLOYER_USERNAME - DEPLOYER_PASSWORD : - from_secret : DEPLOYER_PASSWORD - SONAR_HOST : - from_secret : SONAR_HOST - SONAR_TOKEN : - from_secret : SONAR_TOKEN - commands : - - mvn org.apache.maven.plugins:maven-dependency-plugin:3.5.0:copy-dependencies -Dmdep.prependGroupId=true -Dstyle.color=always -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD - - mvn sonar:sonar '-Dsonar.java.libraries=target/dependency/*.jar' '-Dsonar.java.test.libraries=target/classes,target/dependency/*.jar' -Dsonar.qualitygate.wait=true -Dsonar.qualitygate.timeout=300 -Dsonar.host.url=$SONAR_HOST -Dsonar.login=$SONAR_TOKEN -Dsonar.projectKey=${DRONE_REPO_OWNER}:${DRONE_REPO_NAME} -Dsonar.projectName=${DRONE_REPO_OWNER}:${DRONE_REPO_NAME} -Dstyle.color=always -Dmaven.javadoc.skip=true --batch-mode -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD - - pmd check -d src -f text -R https://raw.githubusercontent.com/pmd/pmd/master/pmd-java/src/main/resources/rulesets/java/basic.xml - - mvn com.github.spotbugs:spotbugs-maven-plugin:4.7.3.4:check -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD -Dspotbugs.xmlOutput=true -Dspotbugs.failOnError=true -Dspotbugs.excludeFilterFile=../spotbugs-exclude.xml -Dspotbugs.includeTests=true -Dstyle.color=always - - - name : notify-slack-on-failure - image : plugins/slack - settings : - webhook : - from_secret : SLACK_WEBHOOK - channel : dev - template : > - :red_circle: :thunder_cloud_and_rain: {{build.link}} ({{build.branch}}) by {{build.author}} - when : - status : - - failure - depends_on : - - code-coverage-gate - - static-analysis-gate - -services : - - name : db - image : mysql:5.7.42 - environment : - MYSQL_DATABASE : svc_testing_db - MYSQL_USER : svc_testing - MYSQL_PASSWORD : svc_testing - MYSQL_ROOT_PASSWORD : svc_root - TZ : UTC - ---- - -kind : pipeline -name : ArtifactsPublishing -type : docker - -trigger : - event : - - push - - tag - ref : - - refs/heads/develop - - refs/heads/prerelease* - - refs/heads/*.*.x - - refs/tags/* - -depends_on : - - CodeVerification - -volumes : - - name : m2cache - host : - path : /app/.m2 - -steps : - - - name : publish-snapshot-jar - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - volumes : - - name : m2cache - path : /root/.m2 - environment : - DEPLOYER_USERNAME : - from_secret : DEPLOYER_USERNAME - DEPLOYER_PASSWORD : - from_secret : DEPLOYER_PASSWORD - commands : - - mvn deploy -Dstyle.color=always -DskipTests -Dmaven.test.skip=true -Dmaven.javadoc.skip=true -Dcheckstyle.skip=true -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD -DaltDeploymentRepository=kh-contrib-snapshots-repo::https://know-how.nexus/repository/maven-snapshots - when : - branch : - include : - - "develop" - - "prerelease/*" - - "*.*.x" - - - name : publish-release-jar - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - volumes : - - name : m2cache - path : /root/.m2 - environment : - DEPLOYER_USERNAME : - from_secret : DEPLOYER_USERNAME - DEPLOYER_PASSWORD : - from_secret : DEPLOYER_PASSWORD - commands : - - mvn deploy -Dstyle.color=always -DskipTests -Dmaven.test.skip=true -Dmaven.javadoc.skip=true -Dcheckstyle.skip=true -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD -DaltDeploymentRepository=kh-contrib-releases-repo::https://know-how.nexus/repository/maven-releases - when : - ref : - - "refs/tags/*" - - - name : create-github-release - image : plugins/github-release - settings : - api_key : - from_secret : GITHUB_API_KEY - title : ${DRONE_TAG} - note : "**Full Changelog**: https://github.com/${DRONE_REPO}/commits/${DRONE_TAG}" - files : ./*/target/*.jar - when : - ref : - - "refs/tags/*" - depends_on : - - publish-release-jar - - - name : notify-slack - image : plugins/slack - settings : - webhook : - from_secret : SLACK_WEBHOOK - channel : dev - template : > - {{#success build.status}} - :large_green_circle: :package: *${DRONE_COMMIT_MESSAGE}* - {{build.link}} ({{build.branch}}) by {{build.author}} - {{else}} - :red_circle: :package: {{build.link}} ({{build.branch}}) by {{build.author}} - {{/success}} - when : - status : - - failure - - success - depends_on : - - publish-snapshot-jar - - publish-release-jar - ---- - -kind : pipeline -name : DockerImagePublishing -type : docker - -trigger : - event : - - push - - tag - -depends_on : - - ArtifactsPublishing - -volumes : - - name : m2cache - host : - path : /app/.m2 - -steps : - - - name : package-jar - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - volumes : - - name : m2cache - path : /root/.m2 - environment : - DEPLOYER_USERNAME : - from_secret : DEPLOYER_USERNAME - DEPLOYER_PASSWORD : - from_secret : DEPLOYER_PASSWORD - commands : - - mvn package -Dstyle.color=always -DskipTests -Dmaven.test.skip=true -Dmaven.javadoc.skip=true -Dcheckstyle.skip=true --batch-mode -s ../maven-settings.xml -Ddeployer.username=$DEPLOYER_USERNAME -Ddeployer.password=$DEPLOYER_PASSWORD - - - name : build-container-with-feature-for-init-container-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./init-container-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/init-container-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_BRANCH:22}-${CI_BUILD_NUMBER} - when : - branch : - include : - - "feature/containerized-*" - - - name : build-container-with-feature-for-edge-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./edge-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/edge-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_BRANCH:22}-${CI_BUILD_NUMBER} - when : - branch : - include : - - "feature/containerized-*" - - - name : build-container-with-feature-for-dashboard-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./dashboard-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/dashboard-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_BRANCH:22}-${CI_BUILD_NUMBER} - when : - branch : - include : - - "feature/containerized-*" - - - name : build-container-with-feature-for-importer-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./importer-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/importer-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_BRANCH:22}-${CI_BUILD_NUMBER} - when : - branch : - include : - - "feature/containerized-*" - - - name : build-container-release-init-container-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./init-container-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/init-container-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_TAG} - - "latest" - when : - ref : - - "refs/tags/*" - - - name : build-container-release-edge-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./edge-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/edge-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_TAG} - - "latest" - when : - ref : - - "refs/tags/*" - - - name : build-container-release-dashboard-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./dashboard-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/dashboard-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_TAG} - - "latest" - when : - ref : - - "refs/tags/*" - - - name : build-container-release-importer-service - image : plugins/docker - settings : - dockerfile : .drone/Dockerfile - context : ./importer-service/ - storage_driver : vfs - username : - from_secret : DOCKER_USERNAME - password : - from_secret : DOCKER_PASSWORD - repo : know-how.download/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/importer-service - registry : know-how.download - force_tag : true - build_args : - - BASE_IMAGE=know-how.download/jre:openjdk-21-slim-bookworm - - BUILD_VERSION=${DRONE_COMMIT} - tags : - - ${DRONE_TAG} - - "latest" - when : - ref : - - "refs/tags/*" - - ---- - -kind : pipeline -name : PromoteFeatureDeployment -type : docker -trigger : - event : - - promote - target : - - sit - ref : - - "refs/heads/feature/containerized-*" - -steps : - - name : deploy - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - environment : - HELM_CHARTS_REPOSITORY : - from_secret : HELM_CHARTS_REPOSITORY - commands : - - git clone $${HELM_CHARTS_REPOSITORY} charts && cd charts/${DRONE_REPO_NAME} - - kubectl version --output=yaml - - helm upgrade --install --atomic --wait --timeout 2m ${DRONE_REPO_NAME} ./ --values ./values.yaml --values ./${DRONE_DEPLOY_TO}-values.yaml --set image.tag=${DRONE_BRANCH:22}-${CI_PARENT_BUILD_NUMBER} -n ${DRONE_DEPLOY_TO}-env - - - name : notify-slack - image : plugins/slack - settings : - webhook : - from_secret : SLACK_WEBHOOK - channel : dev - template : > - {{#success build.status}} - :large_green_circle: :ship: *${DRONE_COMMIT_MESSAGE}* - {{build.link}} ({{build.branch}}) by {{build.author}} - {{else}} - :red_circle: :anchor: {{build.link}} ({{build.branch}}) by {{build.author}} - {{/success}} - when : - status : - - failure - - success - depends_on : - - deploy - ---- - -kind : pipeline -name : RollbackFeatureDeployment -type : docker -trigger : - event : - - rollback - target : - - sit - ref : - - "refs/heads/feature/containerized-*" - -steps : - - name : rollback - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - environment : - HELM_CHARTS_REPOSITORY : - from_secret : HELM_CHARTS_REPOSITORY - commands : - - git clone $${HELM_CHARTS_REPOSITORY} charts && cd charts/${DRONE_REPO_NAME} - - helm uninstall --wait --timeout 2m ${DRONE_REPO_NAME} -n ${DRONE_DEPLOY_TO}-env - ---- - -kind : pipeline -name : PromoteDeployment -type : docker -trigger : - event : - - promote - target : - - uat - - production - ref : - - "refs/tags/*" - -steps : - - name : deploy - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - environment : - HELM_CHARTS_REPOSITORY : - from_secret : HELM_CHARTS_REPOSITORY - commands : - - git clone $${HELM_CHARTS_REPOSITORY} charts && cd charts/${DRONE_REPO_NAME} - - kubectl version --output=yaml - - helm upgrade --install --atomic --wait --timeout 2m ${DRONE_REPO_NAME} ./ --values ./values.yaml --values ./${DRONE_DEPLOY_TO}-values.yaml --set image.tag=${DRONE_TAG} -n ${DRONE_DEPLOY_TO}-env - - - name : notify-slack - image : plugins/slack - settings : - webhook : - from_secret : SLACK_WEBHOOK - channel : dev - template : > - {{#success build.status}} - :large_green_circle: :ship: *${DRONE_COMMIT_MESSAGE}* - {{build.link}} ({{build.branch}}) by {{build.author}} - {{else}} - :red_circle: :anchor: {{build.link}} ({{build.branch}}) by {{build.author}} - {{/success}} - when : - status : - - failure - - success - depends_on : - - deploy - ---- - -kind : pipeline -name : RollbackDeployment -type : docker -trigger : - event : - - rollback - target : - - uat - - production - ref : - - "refs/tags/*" - -steps : - - name : rollback - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - environment : - HELM_CHARTS_REPOSITORY : - from_secret : HELM_CHARTS_REPOSITORY - commands : - - git clone $${HELM_CHARTS_REPOSITORY} charts && cd charts/${DRONE_REPO_NAME} - - helm uninstall --wait --timeout 2m ${DRONE_REPO_NAME} -n ${DRONE_DEPLOY_TO}-env - ---- - -kind : pipeline -name : ManualRelease -type : docker -trigger : - event : - - custom - branch : - - "develop" - - "*.*.x" - -volumes : - - name : m2cache - host : - path : /app/.m2 - -steps : - - - name : create-release-tag - failure : ignore - image : know-how.download/svc-builder:openjdk-21-slim-bookworm - pull : if-not-exists - volumes : - - name : m2cache - path : /root/.m2 - commands : - - echo Prepare new version ${RELEASE_VERSION} - - export NEXT_SNAPSHOT=${SNAPSHOT_VERSION}-SNAPSHOT - - export GIT_AUTHOR_NAME="$${SVC_BUILD_GIT_USERNAME}" - - export GIT_AUTHOR_EMAIL=$${SVC_BUILD_GIT_EMAIL} - - export GIT_COMMITTER_NAME="$${SVC_BUILD_GIT_USERNAME}" - - export GIT_COMMITTER_EMAIL=$${SVC_BUILD_GIT_EMAIL} - - git remote set-url --push origin ${DRONE_GIT_SSH_URL} - - git checkout -b v${RELEASE_VERSION} - - mvn versions:set -DremoveSnapshot - - mvn versions:set -DnewVersion=${RELEASE_VERSION} - - mvn versions:update-parent - - >- - git commit -a -m "feat: bump version to $${RELEASE_VERSION}" - - git tag ${RELEASE_VERSION} && git push origin ${RELEASE_VERSION} - - echo "✅ Release tag ${RELEASE_VERSION} was created." - - sleep 10 - - git tag -d ${RELEASE_VERSION} && git checkout ${DRONE_COMMIT_BRANCH} && git branch -D v${RELEASE_VERSION} - - mvn versions:set -DnewVersion=$${NEXT_SNAPSHOT} - - mvn versions:update-parent -DallowSnapshots=true - - >- - git commit -a -m "feat: create new $${NEXT_SNAPSHOT}" - - git push origin ${DRONE_COMMIT_BRANCH} - - echo "✅ Started $${NEXT_SNAPSHOT}." - - echo "🚀 Good job, new version ${RELEASE_VERSION} was released successfully." diff --git a/.github/workflows/check-commit-message.yml b/.github/workflows/check-commit-message.yml index 0647443..96396e9 100644 --- a/.github/workflows/check-commit-message.yml +++ b/.github/workflows/check-commit-message.yml @@ -9,7 +9,7 @@ on : - synchronize push : branches : - - "develop" + - "dev" - "feature/*" - "bugfix/*" - "improvement/*" @@ -28,7 +28,7 @@ jobs : with : pattern : '^(feat|fix|docs|style|refactor|perf|test|chore|build)(.+?)?: .+' flags : 'gm' - error : 'Your commit title did not follow semantic versioning. Please see https://github.com/uJarOrg/.github/blob/develop/SEMANTIC_COMMITS.md' + error : 'Your commit title did not follow semantic versioning. Please see https://github.com/IQKV/.github/blob/dev/SEMANTIC_COMMITS.md' - name : Check Line Length uses : gsactions/commit-message-checker@v2 with : diff --git a/.husky/pre-commit b/.husky/pre-commit index 1bffa43..c1344cb 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -2,7 +2,7 @@ current_branch=$(git rev-parse --abbrev-ref HEAD) -main_branch="(main|master|develop)" +main_branch="(main|master|dev|develop)" if [[ $current_branch =~ $main_branch ]]; then echo -e "\033[1;31m[ERROR] Please don't commit directly to $current_branch.\033[0m"; exit 1 diff --git a/SEMANTIC_COMMITS.md b/SEMANTIC_COMMITS.md deleted file mode 100644 index bc1b47c..0000000 --- a/SEMANTIC_COMMITS.md +++ /dev/null @@ -1,35 +0,0 @@ -# Semantic Commit Messages - -See how a minor change to your commit message style can make you a better programmer. - -Format: `(): ` - -`` is optional - -## Example - -``` -feat: add hat wobble -^--^ ^------------^ -| | -| +-> Summary in present tense. -| -+-------> Type: chore, docs, feat, fix, refactor, style, or test. -``` - -More Examples: - -- `feat`: (new feature for the user, not a new feature for build script) -- `fix`: (bug fix for the user, not a fix to a build script) -- `docs`: (changes to the documentation) -- `style`: (formatting, missing semi colons, etc; no production code change) -- `refactor`: (refactoring production code, eg. renaming a variable) -- `test`: (adding missing tests, refactoring tests; no production code change) -- `chore`: (updating grunt tasks etc; no production code change) - -References: - -- https://www.conventionalcommits.org/ -- https://seesparkbox.com/foundry/semantic_commit_messages -- http://karma-runner.github.io/1.0/dev/git-commit-msg.html - diff --git a/bookingdb-support/batch-job/pom.xml b/bookingdb-support/batch-job/pom.xml index 874ef04..547b1ed 100644 --- a/bookingdb-support/batch-job/pom.xml +++ b/bookingdb-support/batch-job/pom.xml @@ -11,7 +11,7 @@ Batch Jobs Support - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb-support 23.0.0-SNAPSHOT @@ -24,7 +24,7 @@ - org.ujar.boot + dev.knowhowto.boot boot-starter-amqp diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/AbstractJobParameters.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/AbstractJobParameters.java similarity index 92% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/AbstractJobParameters.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/AbstractJobParameters.java index 872b114..1445195 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/AbstractJobParameters.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/AbstractJobParameters.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; import java.io.Serial; import java.io.Serializable; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CitiesImportParameters.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CitiesImportParameters.java similarity index 87% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CitiesImportParameters.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CitiesImportParameters.java index 10ab621..dadf98b 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CitiesImportParameters.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CitiesImportParameters.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; import lombok.Builder; import lombok.Getter; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CityHotelsImportParameters.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CityHotelsImportParameters.java similarity index 87% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CityHotelsImportParameters.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CityHotelsImportParameters.java index c31291b..6c90ae6 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CityHotelsImportParameters.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CityHotelsImportParameters.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; import lombok.Builder; import lombok.Getter; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CountriesImportParameters.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CountriesImportParameters.java similarity index 86% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CountriesImportParameters.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CountriesImportParameters.java index 31a00a3..a20b142 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/CountriesImportParameters.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/CountriesImportParameters.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; import lombok.Builder; import lombok.Getter; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/HotelsImportParameters.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/HotelsImportParameters.java similarity index 88% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/HotelsImportParameters.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/HotelsImportParameters.java index 2da6ba6..69e3a6b 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/HotelsImportParameters.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/HotelsImportParameters.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; import java.util.List; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobParameters.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobParameters.java similarity index 75% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobParameters.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobParameters.java index 8ec3cf3..ccad923 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobParameters.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobParameters.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; import java.time.Instant; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobType.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobType.java similarity index 67% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobType.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobType.java index 9879964..8d7cc03 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobType.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobType.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; public enum JobType { IMPORT_COUNTRIES, diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobsConfiguration.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobsConfiguration.java similarity index 71% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobsConfiguration.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobsConfiguration.java index 16ba7f7..2a88d2f 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/JobsConfiguration.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/JobsConfiguration.java @@ -1,8 +1,8 @@ -package org.ujar.bookingdb.jobs; +package dev.knowhowto.bookingdb.jobs; +import dev.knowhowto.bookingdb.jobs.amqp.AmqpQueuesProperties; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.context.annotation.Configuration; -import org.ujar.bookingdb.jobs.amqp.AmqpQueuesProperties; @Configuration @EnableConfigurationProperties({AmqpQueuesProperties.class}) diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/AbstractProducer.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/AbstractProducer.java similarity index 83% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/AbstractProducer.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/AbstractProducer.java index 5ab61cc..04d2b1b 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/AbstractProducer.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/AbstractProducer.java @@ -1,7 +1,7 @@ -package org.ujar.bookingdb.jobs.amqp; +package dev.knowhowto.bookingdb.jobs.amqp; +import dev.knowhowto.bookingdb.jobs.AbstractJobParameters; import org.springframework.amqp.rabbit.core.RabbitTemplate; -import org.ujar.bookingdb.jobs.AbstractJobParameters; public abstract class AbstractProducer { protected final RabbitTemplate template; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/AmqpQueuesProperties.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/AmqpQueuesProperties.java similarity index 94% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/AmqpQueuesProperties.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/AmqpQueuesProperties.java index b591c39..ad775e9 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/AmqpQueuesProperties.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/AmqpQueuesProperties.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs.amqp; +package dev.knowhowto.bookingdb.jobs.amqp; import jakarta.validation.constraints.NotNull; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/CommonAmqpConfig.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/CommonAmqpConfig.java similarity index 98% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/CommonAmqpConfig.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/CommonAmqpConfig.java index 92d6998..922d0c8 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/amqp/CommonAmqpConfig.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/amqp/CommonAmqpConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.jobs.amqp; +package dev.knowhowto.bookingdb.jobs.amqp; import lombok.RequiredArgsConstructor; import org.springframework.amqp.core.AmqpAdmin; diff --git a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/annotation/EnableJobSupport.java b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/annotation/EnableJobSupport.java similarity index 71% rename from bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/annotation/EnableJobSupport.java rename to bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/annotation/EnableJobSupport.java index 2fed0a1..712b7d3 100644 --- a/bookingdb-support/batch-job/src/main/java/org/ujar/bookingdb/jobs/annotation/EnableJobSupport.java +++ b/bookingdb-support/batch-job/src/main/java/dev/knowhowto/bookingdb/jobs/annotation/EnableJobSupport.java @@ -1,20 +1,20 @@ -package org.ujar.bookingdb.jobs.annotation; +package dev.knowhowto.bookingdb.jobs.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; +import dev.knowhowto.bookingdb.jobs.JobsConfiguration; +import dev.knowhowto.bookingdb.jobs.amqp.CommonAmqpConfig; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Import; -import org.ujar.bookingdb.jobs.JobsConfiguration; -import org.ujar.bookingdb.jobs.amqp.CommonAmqpConfig; @Retention(RetentionPolicy.RUNTIME) @Target({ElementType.TYPE}) @Import({JobsConfiguration.class, CommonAmqpConfig.class}) @Configuration -@ComponentScan("org.ujar.bookingdb.jobs") +@ComponentScan("dev.knowhowto.bookingdb.jobs") public @interface EnableJobSupport { } diff --git a/bookingdb-support/booking-api-client/pom.xml b/bookingdb-support/booking-api-client/pom.xml index ee04f06..5316d78 100644 --- a/bookingdb-support/booking-api-client/pom.xml +++ b/bookingdb-support/booking-api-client/pom.xml @@ -12,7 +12,7 @@ - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb-support 23.0.0-SNAPSHOT diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/annotation/EnableBookingApiClient.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/annotation/EnableBookingApiClient.java similarity index 78% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/annotation/EnableBookingApiClient.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/annotation/EnableBookingApiClient.java index dd8f4e7..e22cf8b 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/annotation/EnableBookingApiClient.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/annotation/EnableBookingApiClient.java @@ -1,13 +1,13 @@ -package org.ujar.bookingdb.apiclient.annotation; +package dev.knowhowto.bookingdb.apiclient.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; +import dev.knowhowto.bookingdb.apiclient.config.ClientConfig; import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Import; -import org.ujar.bookingdb.apiclient.config.ClientConfig; @Retention(RetentionPolicy.RUNTIME) @Target({ElementType.TYPE}) diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/client/AbstractNetClient.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/client/AbstractNetClient.java similarity index 91% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/client/AbstractNetClient.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/client/AbstractNetClient.java index 240e1db..46e5999 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/client/AbstractNetClient.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/client/AbstractNetClient.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.apiclient.client; +package dev.knowhowto.bookingdb.apiclient.client; import java.io.IOException; import java.net.http.HttpClient; @@ -8,9 +8,9 @@ import java.util.Base64; import java.util.Map; +import dev.knowhowto.bookingdb.apiclient.config.NetClientProperties; +import dev.knowhowto.bookingdb.apiclient.exception.NetClientCommunicationException; import org.springframework.web.util.UriComponentsBuilder; -import org.ujar.bookingdb.apiclient.config.NetClientProperties; -import org.ujar.bookingdb.apiclient.exception.NetClientCommunicationException; public class AbstractNetClient { protected static final String LANGUAGE_CODE = "en"; diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/client/BookingcomNetClient.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/client/BookingcomNetClient.java similarity index 91% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/client/BookingcomNetClient.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/client/BookingcomNetClient.java index c411d5d..1690811 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/client/BookingcomNetClient.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/client/BookingcomNetClient.java @@ -1,9 +1,9 @@ -package org.ujar.bookingdb.apiclient.client; +package dev.knowhowto.bookingdb.apiclient.client; import java.util.Map; +import dev.knowhowto.bookingdb.apiclient.config.NetClientProperties; import org.springframework.stereotype.Service; -import org.ujar.bookingdb.apiclient.config.NetClientProperties; @Service public class BookingcomNetClient extends AbstractNetClient { diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/config/ClientConfig.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/config/ClientConfig.java similarity index 74% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/config/ClientConfig.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/config/ClientConfig.java index 5116220..50e0209 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/config/ClientConfig.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/config/ClientConfig.java @@ -1,11 +1,11 @@ -package org.ujar.bookingdb.apiclient.config; +package dev.knowhowto.bookingdb.apiclient.config; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; @Configuration -@ComponentScan("org.ujar.bookingdb.apiclient.*") +@ComponentScan("dev.knowhowto.bookingdb.apiclient.*") @EnableConfigurationProperties(NetClientProperties.class) public class ClientConfig { } diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/config/NetClientProperties.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/config/NetClientProperties.java similarity index 96% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/config/NetClientProperties.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/config/NetClientProperties.java index db2df18..c3a706d 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/config/NetClientProperties.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/config/NetClientProperties.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.apiclient.config; +package dev.knowhowto.bookingdb.apiclient.config; import jakarta.validation.constraints.NotNull; diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/exception/NetClientCommunicationException.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/exception/NetClientCommunicationException.java similarity index 74% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/exception/NetClientCommunicationException.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/exception/NetClientCommunicationException.java index 937a951..932ed4e 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/exception/NetClientCommunicationException.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/exception/NetClientCommunicationException.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.apiclient.exception; +package dev.knowhowto.bookingdb.apiclient.exception; public class NetClientCommunicationException extends RuntimeException { public NetClientCommunicationException(Throwable cause) { diff --git a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/exception/NetClientMisconfigurationException.java b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/exception/NetClientMisconfigurationException.java similarity index 80% rename from bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/exception/NetClientMisconfigurationException.java rename to bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/exception/NetClientMisconfigurationException.java index 7584367..5bcb05d 100644 --- a/bookingdb-support/booking-api-client/src/main/java/org/ujar/bookingdb/apiclient/exception/NetClientMisconfigurationException.java +++ b/bookingdb-support/booking-api-client/src/main/java/dev/knowhowto/bookingdb/apiclient/exception/NetClientMisconfigurationException.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.apiclient.exception; +package dev.knowhowto.bookingdb.apiclient.exception; public class NetClientMisconfigurationException extends IllegalStateException { public NetClientMisconfigurationException(Throwable cause) { diff --git a/bookingdb-support/booking-persistence/pom.xml b/bookingdb-support/booking-persistence/pom.xml index 6e3f57d..5be064d 100644 --- a/bookingdb-support/booking-persistence/pom.xml +++ b/bookingdb-support/booking-persistence/pom.xml @@ -11,7 +11,7 @@ Common repositories and entities - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb-support 23.0.0-SNAPSHOT @@ -24,7 +24,7 @@ - org.ujar.boot + dev.knowhowto.boot boot-starter-cache diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/annotation/EnableBookingPersistence.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/annotation/EnableBookingPersistence.java similarity index 70% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/annotation/EnableBookingPersistence.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/annotation/EnableBookingPersistence.java index 11d5832..7a65400 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/annotation/EnableBookingPersistence.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/annotation/EnableBookingPersistence.java @@ -1,14 +1,14 @@ -package org.ujar.bookingdb.persistence.annotation; +package dev.knowhowto.bookingdb.persistence.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; +import dev.knowhowto.bookingdb.persistence.config.CacheConfig; +import dev.knowhowto.bookingdb.persistence.config.PersistenceConfig; import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Import; -import org.ujar.bookingdb.persistence.config.CacheConfig; -import org.ujar.bookingdb.persistence.config.PersistenceConfig; @Retention(RetentionPolicy.RUNTIME) @Target({ElementType.TYPE}) diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/config/CacheConfig.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/config/CacheConfig.java similarity index 88% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/config/CacheConfig.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/config/CacheConfig.java index 93e90f5..ca80a92 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/config/CacheConfig.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/config/CacheConfig.java @@ -1,7 +1,11 @@ -package org.ujar.bookingdb.persistence.config; +package dev.knowhowto.bookingdb.persistence.config; import java.time.Duration; +import dev.knowhowto.bookingdb.persistence.entity.City; +import dev.knowhowto.bookingdb.persistence.entity.Country; +import dev.knowhowto.bookingdb.persistence.entity.Hotel; +import dev.knowhowto.boot.cache.CacheProperties; import org.ehcache.config.builders.CacheConfigurationBuilder; import org.ehcache.config.builders.ExpiryPolicyBuilder; import org.ehcache.config.builders.ResourcePoolsBuilder; @@ -12,10 +16,6 @@ import org.springframework.cache.annotation.EnableCaching; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; -import org.ujar.bookingdb.persistence.entity.City; -import org.ujar.bookingdb.persistence.entity.Country; -import org.ujar.bookingdb.persistence.entity.Hotel; -import org.ujar.boot.cache.CacheProperties; @Configuration @EnableCaching diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/config/PersistenceConfig.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/config/PersistenceConfig.java similarity index 70% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/config/PersistenceConfig.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/config/PersistenceConfig.java index 7528fa8..108190d 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/config/PersistenceConfig.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/config/PersistenceConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.persistence.config; +package dev.knowhowto.bookingdb.persistence.config; import org.springframework.boot.autoconfigure.domain.EntityScan; import org.springframework.context.annotation.Configuration; @@ -7,8 +7,8 @@ import org.springframework.transaction.annotation.EnableTransactionManagement; @Configuration -@EnableJpaRepositories({"org.ujar.bookingdb.persistence.repository"}) -@EntityScan({"org.ujar.bookingdb.persistence.entity"}) +@EnableJpaRepositories({"dev.knowhowto.bookingdb.persistence.repository"}) +@EntityScan({"dev.knowhowto.bookingdb.persistence.entity"}) @EnableJpaAuditing @EnableTransactionManagement public class PersistenceConfig { diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/converter/HashMapConverter.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/converter/HashMapConverter.java similarity index 95% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/converter/HashMapConverter.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/converter/HashMapConverter.java index 28bcb63..15524aa 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/converter/HashMapConverter.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/converter/HashMapConverter.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.persistence.converter; +package dev.knowhowto.bookingdb.persistence.converter; import jakarta.persistence.AttributeConverter; import java.io.IOException; diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/City.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/City.java similarity index 96% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/City.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/City.java index 920702c..bb8d537 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/City.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/City.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.persistence.entity; +package dev.knowhowto.bookingdb.persistence.entity; import jakarta.persistence.CascadeType; import jakarta.persistence.Entity; diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/Country.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/Country.java similarity index 95% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/Country.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/Country.java index f493d20..9568797 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/Country.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/Country.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.persistence.entity; +package dev.knowhowto.bookingdb.persistence.entity; import jakarta.persistence.CascadeType; import jakarta.persistence.Entity; diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/Hotel.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/Hotel.java similarity index 92% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/Hotel.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/Hotel.java index c2e1f20..d127dd9 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/entity/Hotel.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/entity/Hotel.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.persistence.entity; +package dev.knowhowto.bookingdb.persistence.entity; import jakarta.persistence.Column; import jakarta.persistence.Convert; @@ -14,11 +14,11 @@ import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonProperty; +import dev.knowhowto.bookingdb.persistence.converter.HashMapConverter; import lombok.AllArgsConstructor; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; -import org.ujar.bookingdb.persistence.converter.HashMapConverter; @Entity @Getter diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/CityRepository.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/CityRepository.java similarity index 78% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/CityRepository.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/CityRepository.java index 48fc55d..1329aad 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/CityRepository.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/CityRepository.java @@ -1,11 +1,11 @@ -package org.ujar.bookingdb.persistence.repository; +package dev.knowhowto.bookingdb.persistence.repository; import java.util.List; import java.util.Optional; +import dev.knowhowto.bookingdb.persistence.entity.City; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.repository.PagingAndSortingRepository; -import org.ujar.bookingdb.persistence.entity.City; public interface CityRepository extends PagingAndSortingRepository, JpaRepository { diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/CountryRepository.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/CountryRepository.java similarity index 83% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/CountryRepository.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/CountryRepository.java index 8f41b3b..f142194 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/CountryRepository.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/CountryRepository.java @@ -1,12 +1,12 @@ -package org.ujar.bookingdb.persistence.repository; +package dev.knowhowto.bookingdb.persistence.repository; import java.util.List; import java.util.Optional; +import dev.knowhowto.bookingdb.persistence.entity.Country; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.Query; import org.springframework.data.repository.PagingAndSortingRepository; -import org.ujar.bookingdb.persistence.entity.Country; public interface CountryRepository extends PagingAndSortingRepository, JpaRepository { diff --git a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/HotelRepository.java b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/HotelRepository.java similarity index 72% rename from bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/HotelRepository.java rename to bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/HotelRepository.java index ca4600c..1ddb7d7 100644 --- a/bookingdb-support/booking-persistence/src/main/java/org/ujar/bookingdb/persistence/repository/HotelRepository.java +++ b/bookingdb-support/booking-persistence/src/main/java/dev/knowhowto/bookingdb/persistence/repository/HotelRepository.java @@ -1,8 +1,8 @@ -package org.ujar.bookingdb.persistence.repository; +package dev.knowhowto.bookingdb.persistence.repository; +import dev.knowhowto.bookingdb.persistence.entity.Hotel; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.repository.PagingAndSortingRepository; -import org.ujar.bookingdb.persistence.entity.Hotel; public interface HotelRepository extends PagingAndSortingRepository, JpaRepository { diff --git a/bookingdb-support/pom.xml b/bookingdb-support/pom.xml index 3b93fdb..14d68f2 100644 --- a/bookingdb-support/pom.xml +++ b/bookingdb-support/pom.xml @@ -3,14 +3,14 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> 4.0.0 - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb-support 23.0.0-SNAPSHOT pom bookingdb-support - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb 23.0.0-SNAPSHOT diff --git a/dashboard-service/pom.xml b/dashboard-service/pom.xml index 973caf8..618c87d 100644 --- a/dashboard-service/pom.xml +++ b/dashboard-service/pom.xml @@ -11,7 +11,7 @@ Admin REST API Service - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb 23.0.0-SNAPSHOT @@ -22,16 +22,16 @@ ${java.version} false false - org.ujar.bookingdb.dashboard.DashboardApplication + dev.knowhowto.bookingdb.dashboard.DashboardApplication - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp batch-job - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp booking-persistence @@ -39,7 +39,7 @@ spring-boot-starter-web - org.ujar.boot + dev.knowhowto.boot boot-starter-restful @@ -52,11 +52,11 @@ runtime - org.ujar.boot + dev.knowhowto.boot boot-starter-amqp - org.ujar.boot + dev.knowhowto.boot boot-starter-observability diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/DashboardApplication.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/DashboardApplication.java similarity index 92% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/DashboardApplication.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/DashboardApplication.java index ea20dc1..d7badc7 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/DashboardApplication.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/DashboardApplication.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.dashboard; +package dev.knowhowto.bookingdb.dashboard; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/config/ApplicationConfig.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/config/ApplicationConfig.java similarity index 63% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/config/ApplicationConfig.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/config/ApplicationConfig.java index 3e87cdc..b877a66 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/config/ApplicationConfig.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/config/ApplicationConfig.java @@ -1,10 +1,10 @@ -package org.ujar.bookingdb.dashboard.config; +package dev.knowhowto.bookingdb.dashboard.config; +import dev.knowhowto.bookingdb.jobs.annotation.EnableJobSupport; +import dev.knowhowto.bookingdb.persistence.annotation.EnableBookingPersistence; import io.swagger.v3.oas.annotations.OpenAPIDefinition; import io.swagger.v3.oas.annotations.info.Info; import org.springframework.context.annotation.Configuration; -import org.ujar.bookingdb.jobs.annotation.EnableJobSupport; -import org.ujar.bookingdb.persistence.annotation.EnableBookingPersistence; @Configuration @EnableJobSupport diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/producer/ImportServiceProducer.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/producer/ImportServiceProducer.java similarity index 68% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/producer/ImportServiceProducer.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/producer/ImportServiceProducer.java index 523c5e8..6100c03 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/producer/ImportServiceProducer.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/producer/ImportServiceProducer.java @@ -1,14 +1,14 @@ -package org.ujar.bookingdb.dashboard.producer; +package dev.knowhowto.bookingdb.dashboard.producer; +import dev.knowhowto.bookingdb.jobs.CitiesImportParameters; +import dev.knowhowto.bookingdb.jobs.CityHotelsImportParameters; +import dev.knowhowto.bookingdb.jobs.CountriesImportParameters; +import dev.knowhowto.bookingdb.jobs.HotelsImportParameters; +import dev.knowhowto.bookingdb.jobs.JobParameters; +import dev.knowhowto.bookingdb.jobs.amqp.AbstractProducer; +import dev.knowhowto.bookingdb.jobs.amqp.AmqpQueuesProperties; import org.springframework.amqp.rabbit.core.RabbitTemplate; import org.springframework.stereotype.Component; -import org.ujar.bookingdb.jobs.CitiesImportParameters; -import org.ujar.bookingdb.jobs.CityHotelsImportParameters; -import org.ujar.bookingdb.jobs.CountriesImportParameters; -import org.ujar.bookingdb.jobs.HotelsImportParameters; -import org.ujar.bookingdb.jobs.JobParameters; -import org.ujar.bookingdb.jobs.amqp.AbstractProducer; -import org.ujar.bookingdb.jobs.amqp.AmqpQueuesProperties; @Component public class ImportServiceProducer extends AbstractProducer { diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/CityResource.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/CityResource.java similarity index 91% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/CityResource.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/CityResource.java index fbb5c1e..bd2ffbd 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/CityResource.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/CityResource.java @@ -1,7 +1,11 @@ -package org.ujar.bookingdb.dashboard.web; +package dev.knowhowto.bookingdb.dashboard.web; import jakarta.validation.Valid; +import dev.knowhowto.bookingdb.persistence.entity.City; +import dev.knowhowto.bookingdb.persistence.repository.CityRepository; +import dev.knowhowto.boot.restful.web.ApiError; +import dev.knowhowto.boot.restful.web.PaginationRequest; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.media.Content; import io.swagger.v3.oas.annotations.media.Schema; @@ -17,10 +21,6 @@ import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RestController; -import org.ujar.bookingdb.persistence.entity.City; -import org.ujar.bookingdb.persistence.repository.CityRepository; -import org.ujar.boot.restful.web.ApiError; -import org.ujar.boot.restful.web.PaginationRequest; @RestController @Tag(name = "Cities resource", description = "API for cities management") diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/CountryResource.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/CountryResource.java similarity index 91% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/CountryResource.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/CountryResource.java index 0d09e84..a52e054 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/CountryResource.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/CountryResource.java @@ -1,7 +1,11 @@ -package org.ujar.bookingdb.dashboard.web; +package dev.knowhowto.bookingdb.dashboard.web; import jakarta.validation.Valid; +import dev.knowhowto.bookingdb.persistence.entity.Country; +import dev.knowhowto.bookingdb.persistence.repository.CountryRepository; +import dev.knowhowto.boot.restful.web.ApiError; +import dev.knowhowto.boot.restful.web.PaginationRequest; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.media.Content; import io.swagger.v3.oas.annotations.media.Schema; @@ -17,10 +21,6 @@ import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RestController; -import org.ujar.bookingdb.persistence.entity.Country; -import org.ujar.bookingdb.persistence.repository.CountryRepository; -import org.ujar.boot.restful.web.ApiError; -import org.ujar.boot.restful.web.PaginationRequest; @RestController @Tag(name = "Countries resource", description = "API for countries management") diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/HotelResource.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/HotelResource.java similarity index 91% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/HotelResource.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/HotelResource.java index 271c708..d6d6307 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/HotelResource.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/HotelResource.java @@ -1,7 +1,11 @@ -package org.ujar.bookingdb.dashboard.web; +package dev.knowhowto.bookingdb.dashboard.web; import jakarta.validation.Valid; +import dev.knowhowto.bookingdb.persistence.entity.Hotel; +import dev.knowhowto.bookingdb.persistence.repository.HotelRepository; +import dev.knowhowto.boot.restful.web.ApiError; +import dev.knowhowto.boot.restful.web.PaginationRequest; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.media.Content; import io.swagger.v3.oas.annotations.media.Schema; @@ -17,10 +21,6 @@ import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RestController; -import org.ujar.bookingdb.persistence.entity.Hotel; -import org.ujar.bookingdb.persistence.repository.HotelRepository; -import org.ujar.boot.restful.web.ApiError; -import org.ujar.boot.restful.web.PaginationRequest; @RestController @Tag(name = "Countries resource", description = "API for hotels management") diff --git a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/ImporterJobResource.java b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/ImporterJobResource.java similarity index 91% rename from dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/ImporterJobResource.java rename to dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/ImporterJobResource.java index 81e7723..9c3c506 100644 --- a/dashboard-service/src/main/java/org/ujar/bookingdb/dashboard/web/ImporterJobResource.java +++ b/dashboard-service/src/main/java/dev/knowhowto/bookingdb/dashboard/web/ImporterJobResource.java @@ -1,7 +1,15 @@ -package org.ujar.bookingdb.dashboard.web; +package dev.knowhowto.bookingdb.dashboard.web; import java.util.List; +import dev.knowhowto.bookingdb.dashboard.producer.ImportServiceProducer; +import dev.knowhowto.bookingdb.jobs.CitiesImportParameters; +import dev.knowhowto.bookingdb.jobs.CountriesImportParameters; +import dev.knowhowto.bookingdb.jobs.HotelsImportParameters; +import dev.knowhowto.bookingdb.jobs.JobParameters; +import dev.knowhowto.bookingdb.persistence.entity.Country; +import dev.knowhowto.bookingdb.persistence.repository.CountryRepository; +import dev.knowhowto.boot.restful.web.ApiError; import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.media.Content; import io.swagger.v3.oas.annotations.media.Schema; @@ -15,14 +23,6 @@ import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RestController; -import org.ujar.bookingdb.dashboard.producer.ImportServiceProducer; -import org.ujar.bookingdb.jobs.CitiesImportParameters; -import org.ujar.bookingdb.jobs.CountriesImportParameters; -import org.ujar.bookingdb.jobs.HotelsImportParameters; -import org.ujar.bookingdb.jobs.JobParameters; -import org.ujar.bookingdb.persistence.entity.Country; -import org.ujar.bookingdb.persistence.repository.CountryRepository; -import org.ujar.boot.restful.web.ApiError; @RestController @Tag(name = "Importer job resource", description = "API for job management") diff --git a/dashboard-service/src/main/resources/application.yml b/dashboard-service/src/main/resources/application.yml index 573b0f1..81b9a24 100644 --- a/dashboard-service/src/main/resources/application.yml +++ b/dashboard-service/src/main/resources/application.yml @@ -132,7 +132,7 @@ management : prometheus : enabled : true -ujar : +knowhowto : build : description : '@project.description@' relative-path : ${SERVER_SERVLET_CONTEXT_PATH:/} diff --git a/dashboard-service/src/main/resources/banner.txt b/dashboard-service/src/main/resources/banner.txt index 41a5f76..9415f70 100644 --- a/dashboard-service/src/main/resources/banner.txt +++ b/dashboard-service/src/main/resources/banner.txt @@ -1,8 +1,3 @@ -${AnsiColor.GREEN} | | -${AnsiColor.GREEN} _ _ | | __ _ _ __ -${AnsiColor.GREEN} | | | | _ | | / _` | | '__| -${AnsiColor.GREEN} | |_| | | |__| | | (_| | | | -${AnsiColor.GREEN} \__,_| \____/ \__,_| |_| ${AnsiColor.BLUE} =============================== ${AnsiColor.BLUE} Admin Dashboard Service ${AnsiColor.BLUE} Running Spring Boot ${spring-boot.version} diff --git a/dashboard-service/src/test/java/org/ujar/bookingdb/dashboard/DashboardApplicationIT.java b/dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard/DashboardApplicationIT.java similarity index 89% rename from dashboard-service/src/test/java/org/ujar/bookingdb/dashboard/DashboardApplicationIT.java rename to dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard/DashboardApplicationIT.java index a1d88bd..49640be 100644 --- a/dashboard-service/src/test/java/org/ujar/bookingdb/dashboard/DashboardApplicationIT.java +++ b/dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard/DashboardApplicationIT.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.dashboard; +package dev.knowhowto.bookingdb.dashboard; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; diff --git a/init-container-service/src/test/java/org/ujar/bookingdb/init/config/TestDatabaseConfig.java b/dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard/config/TestDatabaseConfig.java similarity index 88% rename from init-container-service/src/test/java/org/ujar/bookingdb/init/config/TestDatabaseConfig.java rename to dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard/config/TestDatabaseConfig.java index f80b60c..31c45a7 100644 --- a/init-container-service/src/test/java/org/ujar/bookingdb/init/config/TestDatabaseConfig.java +++ b/dashboard-service/src/test/java/dev/knowhowto/bookingdb/dashboard/config/TestDatabaseConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.init.config; +package dev.knowhowto.bookingdb.dashboard.config; import org.springframework.boot.test.autoconfigure.jdbc.AutoConfigureTestDatabase; import org.springframework.boot.test.autoconfigure.orm.jpa.DataJpaTest; diff --git a/dashboard-service/src/test/resources/application.yml b/dashboard-service/src/test/resources/application.yml index 37273ce..fa9a61a 100644 --- a/dashboard-service/src/test/resources/application.yml +++ b/dashboard-service/src/test/resources/application.yml @@ -44,7 +44,7 @@ embedded : reuse-container : true docker-image : rabbitmq:3.12-management-alpine -ujar : +knowhowto : build : description : '@project.description@' relative-path : '/' diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index f819fed..da32fef 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -1,4 +1,4 @@ -# This configuration is intended for development purpose +# This configuration is intended for dev purpose version : '3.8' services : mysql : diff --git a/edge-service/pom.xml b/edge-service/pom.xml index 92af7ed..8f13e42 100644 --- a/edge-service/pom.xml +++ b/edge-service/pom.xml @@ -11,7 +11,7 @@ Gateway service - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb 23.0.0-SNAPSHOT @@ -22,12 +22,12 @@ ${java.version} false false - org.ujar.bookingdb.edge.EdgeApplication + dev.knowhowto.bookingdb.edge.EdgeApplication - org.ujar.boot + dev.knowhowto.boot boot-starter-observability diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/EdgeApplication.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/EdgeApplication.java similarity index 93% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/EdgeApplication.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/EdgeApplication.java index 2a5c9ab..71aa989 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/EdgeApplication.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/EdgeApplication.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge; +package dev.knowhowto.bookingdb.edge; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/config/ApplicationConfig.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/ApplicationConfig.java similarity index 84% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/config/ApplicationConfig.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/ApplicationConfig.java index 3a9c0db..e4ce666 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/config/ApplicationConfig.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/ApplicationConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.config; +package dev.knowhowto.bookingdb.edge.config; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.context.annotation.Configuration; diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/config/GatewayConfig.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/GatewayConfig.java similarity index 94% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/config/GatewayConfig.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/GatewayConfig.java index 79c0112..4fee9bc 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/config/GatewayConfig.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/GatewayConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.config; +package dev.knowhowto.bookingdb.edge.config; import org.springframework.cloud.gateway.route.RouteLocator; import org.springframework.cloud.gateway.route.builder.RouteLocatorBuilder; diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/config/ServicesProperties.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/ServicesProperties.java similarity index 58% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/config/ServicesProperties.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/ServicesProperties.java index d547533..9a5f1a6 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/config/ServicesProperties.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/config/ServicesProperties.java @@ -1,7 +1,7 @@ -package org.ujar.bookingdb.edge.config; +package dev.knowhowto.bookingdb.edge.config; import org.springframework.boot.context.properties.ConfigurationProperties; -@ConfigurationProperties(prefix = "ujar.services") +@ConfigurationProperties(prefix = "knowhowto.services") public record ServicesProperties(String dashboardService) { } diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/City.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/City.java similarity index 58% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/City.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/City.java index 97a23f7..cd3e4b7 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/City.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/City.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; public record City(Long id, String name, Long cityId) { diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/CityPage.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/CityPage.java similarity index 86% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/CityPage.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/CityPage.java index e4d0958..1a87c48 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/CityPage.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/CityPage.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; import java.util.List; diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/Country.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Country.java similarity index 59% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/Country.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Country.java index a2bbcfa..ed163ba 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/Country.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Country.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; public record Country(Long id, String name, String country) { } diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/CountryPage.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/CountryPage.java similarity index 87% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/CountryPage.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/CountryPage.java index 3bcfb84..3c6ca84 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/CountryPage.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/CountryPage.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; import java.util.List; diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/Hotel.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Hotel.java similarity index 52% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/Hotel.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Hotel.java index f4b7fab..0e625d8 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/Hotel.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Hotel.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; public record Hotel(Long id, Long hotelId) { diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/HotelPage.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/HotelPage.java similarity index 86% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/HotelPage.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/HotelPage.java index d165d90..cff7f13 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/HotelPage.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/HotelPage.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; import java.util.List; diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/Pageable.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Pageable.java similarity index 74% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/model/Pageable.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Pageable.java index 08f59e5..1091beb 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/model/Pageable.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/model/Pageable.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge.model; +package dev.knowhowto.bookingdb.edge.model; public record Pageable(Integer offset, Integer pageNumber, diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/service/DashboardService.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/service/DashboardService.java similarity index 86% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/service/DashboardService.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/service/DashboardService.java index f2f21c9..9de6f23 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/service/DashboardService.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/service/DashboardService.java @@ -1,13 +1,13 @@ -package org.ujar.bookingdb.edge.service; +package dev.knowhowto.bookingdb.edge.service; +import dev.knowhowto.bookingdb.edge.config.ServicesProperties; +import dev.knowhowto.bookingdb.edge.model.CityPage; +import dev.knowhowto.bookingdb.edge.model.CountryPage; +import dev.knowhowto.bookingdb.edge.model.HotelPage; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Service; import org.springframework.web.reactive.function.client.WebClient; -import org.ujar.bookingdb.edge.config.ServicesProperties; -import org.ujar.bookingdb.edge.model.CityPage; -import org.ujar.bookingdb.edge.model.CountryPage; -import org.ujar.bookingdb.edge.model.HotelPage; import reactor.core.publisher.Mono; @Service diff --git a/edge-service/src/main/java/org/ujar/bookingdb/edge/web/DashboardResource.java b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/web/DashboardResource.java similarity index 75% rename from edge-service/src/main/java/org/ujar/bookingdb/edge/web/DashboardResource.java rename to edge-service/src/main/java/dev/knowhowto/bookingdb/edge/web/DashboardResource.java index d9c0c2c..de8912e 100644 --- a/edge-service/src/main/java/org/ujar/bookingdb/edge/web/DashboardResource.java +++ b/edge-service/src/main/java/dev/knowhowto/bookingdb/edge/web/DashboardResource.java @@ -1,14 +1,14 @@ -package org.ujar.bookingdb.edge.web; +package dev.knowhowto.bookingdb.edge.web; import jakarta.validation.constraints.NotNull; +import dev.knowhowto.bookingdb.edge.model.CityPage; +import dev.knowhowto.bookingdb.edge.model.CountryPage; +import dev.knowhowto.bookingdb.edge.model.HotelPage; +import dev.knowhowto.bookingdb.edge.service.DashboardService; import org.springframework.graphql.data.method.annotation.Argument; import org.springframework.graphql.data.method.annotation.QueryMapping; import org.springframework.stereotype.Controller; -import org.ujar.bookingdb.edge.model.CityPage; -import org.ujar.bookingdb.edge.model.CountryPage; -import org.ujar.bookingdb.edge.model.HotelPage; -import org.ujar.bookingdb.edge.service.DashboardService; import reactor.core.publisher.Mono; @Controller diff --git a/edge-service/src/main/resources/application-local.yml b/edge-service/src/main/resources/application-local.yml index 893689d..bd0bbc1 100644 --- a/edge-service/src/main/resources/application-local.yml +++ b/edge-service/src/main/resources/application-local.yml @@ -14,6 +14,6 @@ management : server : port : 2999 -ujar : +knowhowto : services : dashboard-service : http://localhost:3000 diff --git a/edge-service/src/main/resources/application.yml b/edge-service/src/main/resources/application.yml index 792f0b6..d80f6c6 100644 --- a/edge-service/src/main/resources/application.yml +++ b/edge-service/src/main/resources/application.yml @@ -90,6 +90,6 @@ management : show-values : always prometheus : enabled : true -ujar : +knowhowto : services : dashboard-service : ${DASHBOARD_SERVICE_URL:http://dashboard-service} diff --git a/edge-service/src/main/resources/banner.txt b/edge-service/src/main/resources/banner.txt index be6de9f..112377f 100644 --- a/edge-service/src/main/resources/banner.txt +++ b/edge-service/src/main/resources/banner.txt @@ -1,8 +1,3 @@ -${AnsiColor.GREEN} | | -${AnsiColor.GREEN} _ _ | | __ _ _ __ -${AnsiColor.GREEN} | | | | _ | | / _` | | '__| -${AnsiColor.GREEN} | |_| | | |__| | | (_| | | | -${AnsiColor.GREEN} \__,_| \____/ \__,_| |_| ${AnsiColor.BLUE} =============================== ${AnsiColor.BLUE} Gateway Service ${AnsiColor.BLUE} Running Spring Boot ${spring-boot.version} diff --git a/edge-service/src/test/java/org/ujar/bookingdb/edge/EdgeApplicationIT.java b/edge-service/src/test/java/dev/knowhowto/bookingdb/edge/EdgeApplicationIT.java similarity index 90% rename from edge-service/src/test/java/org/ujar/bookingdb/edge/EdgeApplicationIT.java rename to edge-service/src/test/java/dev/knowhowto/bookingdb/edge/EdgeApplicationIT.java index 15ab2bc..aa5d51b 100644 --- a/edge-service/src/test/java/org/ujar/bookingdb/edge/EdgeApplicationIT.java +++ b/edge-service/src/test/java/dev/knowhowto/bookingdb/edge/EdgeApplicationIT.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.edge; +package dev.knowhowto.bookingdb.edge; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; diff --git a/edge-service/src/test/resources/application.yml b/edge-service/src/test/resources/application.yml index 99f831e..6d77c0b 100644 --- a/edge-service/src/test/resources/application.yml +++ b/edge-service/src/test/resources/application.yml @@ -2,6 +2,6 @@ spring : application : name : edge-service -ujar : +knowhowto : services : dashboard-service : http://dashboard-service diff --git a/importer-service/pom.xml b/importer-service/pom.xml index 2e74ec9..49d41e6 100644 --- a/importer-service/pom.xml +++ b/importer-service/pom.xml @@ -11,7 +11,7 @@ Import GEO data form Booking.com API - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb 23.0.0-SNAPSHOT @@ -22,20 +22,20 @@ ${java.version} false false - org.ujar.bookingdb.importer.ImporterApplication + dev.knowhowto.bookingdb.importer.ImporterApplication - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp booking-api-client - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp batch-job - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp booking-persistence @@ -43,11 +43,11 @@ spring-boot-starter-web - org.ujar.boot + dev.knowhowto.boot boot-starter-cache - org.ujar.boot + dev.knowhowto.boot boot-starter-restful @@ -64,11 +64,11 @@ hibernate-types-60 - org.ujar.boot + dev.knowhowto.boot boot-starter-amqp - org.ujar.boot + dev.knowhowto.boot boot-starter-observability diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/ImporterApplication.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/ImporterApplication.java similarity index 92% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/ImporterApplication.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/ImporterApplication.java index 7fa2e09..784c78e 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/ImporterApplication.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/ImporterApplication.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer; +package dev.knowhowto.bookingdb.importer; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/config/AmqpConfig.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/config/AmqpConfig.java similarity index 89% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/config/AmqpConfig.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/config/AmqpConfig.java index 82437d4..6572a1f 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/config/AmqpConfig.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/config/AmqpConfig.java @@ -1,5 +1,9 @@ -package org.ujar.bookingdb.importer.config; +package dev.knowhowto.bookingdb.importer.config; +import dev.knowhowto.bookingdb.importer.consumer.ImportCitiesConsumer; +import dev.knowhowto.bookingdb.importer.consumer.ImportCountriesConsumer; +import dev.knowhowto.bookingdb.importer.consumer.ImportHotelConsumer; +import dev.knowhowto.bookingdb.jobs.amqp.AmqpQueuesProperties; import lombok.RequiredArgsConstructor; import org.springframework.amqp.core.AcknowledgeMode; import org.springframework.amqp.rabbit.connection.ConnectionFactory; @@ -7,10 +11,6 @@ import org.springframework.amqp.rabbit.listener.adapter.MessageListenerAdapter; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; -import org.ujar.bookingdb.importer.consumer.ImportCitiesConsumer; -import org.ujar.bookingdb.importer.consumer.ImportCountriesConsumer; -import org.ujar.bookingdb.importer.consumer.ImportHotelConsumer; -import org.ujar.bookingdb.jobs.amqp.AmqpQueuesProperties; @Configuration @RequiredArgsConstructor diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/config/ApplicationConfig.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/config/ApplicationConfig.java similarity index 51% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/config/ApplicationConfig.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/config/ApplicationConfig.java index f2be0bd..c4448f4 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/config/ApplicationConfig.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/config/ApplicationConfig.java @@ -1,10 +1,10 @@ -package org.ujar.bookingdb.importer.config; +package dev.knowhowto.bookingdb.importer.config; +import dev.knowhowto.bookingdb.apiclient.annotation.EnableBookingApiClient; +import dev.knowhowto.bookingdb.jobs.annotation.EnableJobSupport; +import dev.knowhowto.bookingdb.persistence.annotation.EnableBookingPersistence; import org.springframework.context.annotation.Configuration; import org.springframework.transaction.annotation.EnableTransactionManagement; -import org.ujar.bookingdb.apiclient.annotation.EnableBookingApiClient; -import org.ujar.bookingdb.jobs.annotation.EnableJobSupport; -import org.ujar.bookingdb.persistence.annotation.EnableBookingPersistence; @Configuration @EnableJobSupport diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportCitiesConsumer.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportCitiesConsumer.java similarity index 70% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportCitiesConsumer.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportCitiesConsumer.java index 70ef73c..a2dc001 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportCitiesConsumer.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportCitiesConsumer.java @@ -1,10 +1,10 @@ -package org.ujar.bookingdb.importer.consumer; +package dev.knowhowto.bookingdb.importer.consumer; +import dev.knowhowto.bookingdb.importer.service.CityImporterService; +import dev.knowhowto.bookingdb.jobs.CitiesImportParameters; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Component; -import org.ujar.bookingdb.importer.service.CityImporterService; -import org.ujar.bookingdb.jobs.CitiesImportParameters; @Component @RequiredArgsConstructor diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportCountriesConsumer.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportCountriesConsumer.java similarity index 69% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportCountriesConsumer.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportCountriesConsumer.java index 4da0b6c..2f18584 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportCountriesConsumer.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportCountriesConsumer.java @@ -1,10 +1,10 @@ -package org.ujar.bookingdb.importer.consumer; +package dev.knowhowto.bookingdb.importer.consumer; +import dev.knowhowto.bookingdb.importer.service.CountryImporterService; +import dev.knowhowto.bookingdb.jobs.CountriesImportParameters; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Component; -import org.ujar.bookingdb.importer.service.CountryImporterService; -import org.ujar.bookingdb.jobs.CountriesImportParameters; @Component @RequiredArgsConstructor diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportHotelConsumer.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportHotelConsumer.java similarity index 69% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportHotelConsumer.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportHotelConsumer.java index a044b04..ad51d21 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/consumer/ImportHotelConsumer.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/consumer/ImportHotelConsumer.java @@ -1,10 +1,10 @@ -package org.ujar.bookingdb.importer.consumer; +package dev.knowhowto.bookingdb.importer.consumer; +import dev.knowhowto.bookingdb.importer.service.HotelImporterService; +import dev.knowhowto.bookingdb.jobs.CityHotelsImportParameters; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Component; -import org.ujar.bookingdb.importer.service.HotelImporterService; -import org.ujar.bookingdb.jobs.CityHotelsImportParameters; @Component @RequiredArgsConstructor diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/CityImporterService.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/CityImporterService.java similarity index 74% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/service/CityImporterService.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/CityImporterService.java index 24ad6f6..8c25599 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/CityImporterService.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/CityImporterService.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.service; +package dev.knowhowto.bookingdb.importer.service; import org.springframework.stereotype.Service; diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/CountryImporterService.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/CountryImporterService.java similarity index 72% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/service/CountryImporterService.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/CountryImporterService.java index 3415f73..478dee1 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/CountryImporterService.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/CountryImporterService.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.service; +package dev.knowhowto.bookingdb.importer.service; import org.springframework.stereotype.Service; diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/HotelImporterService.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/HotelImporterService.java similarity index 72% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/service/HotelImporterService.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/HotelImporterService.java index 124aa0c..529b84c 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/HotelImporterService.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/HotelImporterService.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.service; +package dev.knowhowto.bookingdb.importer.service; import org.springframework.stereotype.Service; diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/CityImporterServiceImpl.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/CityImporterServiceImpl.java similarity index 84% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/CityImporterServiceImpl.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/CityImporterServiceImpl.java index b9abb4e..de91e0a 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/CityImporterServiceImpl.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/CityImporterServiceImpl.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.service.impl; +package dev.knowhowto.bookingdb.importer.service.impl; import jakarta.transaction.Transactional; import java.util.ArrayList; @@ -10,14 +10,14 @@ import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; +import dev.knowhowto.bookingdb.apiclient.client.BookingcomNetClient; +import dev.knowhowto.bookingdb.importer.service.CityImporterService; +import dev.knowhowto.bookingdb.persistence.entity.City; +import dev.knowhowto.bookingdb.persistence.repository.CityRepository; +import dev.knowhowto.bookingdb.persistence.repository.CountryRepository; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Service; -import org.ujar.bookingdb.apiclient.client.BookingcomNetClient; -import org.ujar.bookingdb.importer.service.CityImporterService; -import org.ujar.bookingdb.persistence.entity.City; -import org.ujar.bookingdb.persistence.repository.CityRepository; -import org.ujar.bookingdb.persistence.repository.CountryRepository; @Service @Slf4j diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/CountryImporterServiceImpl.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/CountryImporterServiceImpl.java similarity index 86% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/CountryImporterServiceImpl.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/CountryImporterServiceImpl.java index d610a76..2374d04 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/CountryImporterServiceImpl.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/CountryImporterServiceImpl.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.service.impl; +package dev.knowhowto.bookingdb.importer.service.impl; import jakarta.transaction.Transactional; import java.util.List; @@ -9,12 +9,12 @@ import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; +import dev.knowhowto.bookingdb.apiclient.client.BookingcomNetClient; +import dev.knowhowto.bookingdb.importer.service.CountryImporterService; +import dev.knowhowto.bookingdb.persistence.entity.Country; +import dev.knowhowto.bookingdb.persistence.repository.CountryRepository; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Service; -import org.ujar.bookingdb.apiclient.client.BookingcomNetClient; -import org.ujar.bookingdb.importer.service.CountryImporterService; -import org.ujar.bookingdb.persistence.entity.Country; -import org.ujar.bookingdb.persistence.repository.CountryRepository; @Service @Slf4j diff --git a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/HotelImporterServiceImpl.java b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/HotelImporterServiceImpl.java similarity index 81% rename from importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/HotelImporterServiceImpl.java rename to importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/HotelImporterServiceImpl.java index 068494c..aa625ae 100644 --- a/importer-service/src/main/java/org/ujar/bookingdb/importer/service/impl/HotelImporterServiceImpl.java +++ b/importer-service/src/main/java/dev/knowhowto/bookingdb/importer/service/impl/HotelImporterServiceImpl.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.service.impl; +package dev.knowhowto.bookingdb.importer.service.impl; import jakarta.transaction.Transactional; import java.util.List; @@ -7,14 +7,14 @@ import com.fasterxml.jackson.core.type.TypeReference; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; +import dev.knowhowto.bookingdb.apiclient.client.BookingcomNetClient; +import dev.knowhowto.bookingdb.importer.service.HotelImporterService; +import dev.knowhowto.bookingdb.persistence.entity.City; +import dev.knowhowto.bookingdb.persistence.entity.Hotel; +import dev.knowhowto.bookingdb.persistence.repository.CityRepository; +import dev.knowhowto.bookingdb.persistence.repository.HotelRepository; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Service; -import org.ujar.bookingdb.apiclient.client.BookingcomNetClient; -import org.ujar.bookingdb.importer.service.HotelImporterService; -import org.ujar.bookingdb.persistence.entity.City; -import org.ujar.bookingdb.persistence.entity.Hotel; -import org.ujar.bookingdb.persistence.repository.CityRepository; -import org.ujar.bookingdb.persistence.repository.HotelRepository; @Service @Slf4j diff --git a/importer-service/src/main/resources/application.yml b/importer-service/src/main/resources/application.yml index d9d1deb..8662298 100644 --- a/importer-service/src/main/resources/application.yml +++ b/importer-service/src/main/resources/application.yml @@ -132,7 +132,7 @@ management : prometheus : enabled : true -ujar : +knowhowto : build : description : '@project.description@' relative-path : ${SERVER_SERVLET_CONTEXT_PATH:/} diff --git a/importer-service/src/main/resources/banner.txt b/importer-service/src/main/resources/banner.txt index 987ef9b..2fc1686 100644 --- a/importer-service/src/main/resources/banner.txt +++ b/importer-service/src/main/resources/banner.txt @@ -1,8 +1,3 @@ -${AnsiColor.GREEN} | | -${AnsiColor.GREEN} _ _ | | __ _ _ __ -${AnsiColor.GREEN} | | | | _ | | / _` | | '__| -${AnsiColor.GREEN} | |_| | | |__| | | (_| | | | -${AnsiColor.GREEN} \__,_| \____/ \__,_| |_| ${AnsiColor.BLUE} =============================== ${AnsiColor.BLUE} Importer ${AnsiColor.BLUE} Running Spring Boot ${spring-boot.version} diff --git a/importer-service/src/test/java/org/ujar/bookingdb/importer/ImporterApplicationIT.java b/importer-service/src/test/java/dev/knowhowto/bookingdb/importer/ImporterApplicationIT.java similarity index 89% rename from importer-service/src/test/java/org/ujar/bookingdb/importer/ImporterApplicationIT.java rename to importer-service/src/test/java/dev/knowhowto/bookingdb/importer/ImporterApplicationIT.java index aeb24f3..37026e2 100644 --- a/importer-service/src/test/java/org/ujar/bookingdb/importer/ImporterApplicationIT.java +++ b/importer-service/src/test/java/dev/knowhowto/bookingdb/importer/ImporterApplicationIT.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer; +package dev.knowhowto.bookingdb.importer; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; diff --git a/importer-service/src/test/java/org/ujar/bookingdb/importer/config/TestDatabaseConfig.java b/importer-service/src/test/java/dev/knowhowto/bookingdb/importer/config/TestDatabaseConfig.java similarity index 88% rename from importer-service/src/test/java/org/ujar/bookingdb/importer/config/TestDatabaseConfig.java rename to importer-service/src/test/java/dev/knowhowto/bookingdb/importer/config/TestDatabaseConfig.java index 1cf743f..92777c0 100644 --- a/importer-service/src/test/java/org/ujar/bookingdb/importer/config/TestDatabaseConfig.java +++ b/importer-service/src/test/java/dev/knowhowto/bookingdb/importer/config/TestDatabaseConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.importer.config; +package dev.knowhowto.bookingdb.importer.config; import org.springframework.boot.test.autoconfigure.jdbc.AutoConfigureTestDatabase; import org.springframework.boot.test.autoconfigure.orm.jpa.DataJpaTest; diff --git a/importer-service/src/test/resources/application.yml b/importer-service/src/test/resources/application.yml index ccd2ba3..28d6a7c 100644 --- a/importer-service/src/test/resources/application.yml +++ b/importer-service/src/test/resources/application.yml @@ -44,7 +44,7 @@ embedded : reuse-container : true docker-image : rabbitmq:3.12-management-alpine -ujar : +knowhowto : build : description : '@project.description@' relative-path : '/' diff --git a/init-container-service/pom.xml b/init-container-service/pom.xml index b3c55b4..a4b1ba6 100644 --- a/init-container-service/pom.xml +++ b/init-container-service/pom.xml @@ -11,7 +11,7 @@ Update database structure using Liquibase - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb 23.0.0-SNAPSHOT @@ -22,7 +22,7 @@ ${java.version} false false - org.ujar.bookingdb.init.InitContainerApplication + dev.knowhowto.bookingdb.init.InitContainerApplication @@ -31,7 +31,7 @@ spring-boot-starter-web - org.ujar.boot + dev.knowhowto.boot boot-starter-observability diff --git a/init-container-service/src/main/java/org/ujar/bookingdb/init/InitContainerApplication.java b/init-container-service/src/main/java/dev/knowhowto/bookingdb/init/InitContainerApplication.java similarity index 88% rename from init-container-service/src/main/java/org/ujar/bookingdb/init/InitContainerApplication.java rename to init-container-service/src/main/java/dev/knowhowto/bookingdb/init/InitContainerApplication.java index 9bfc1db..186f503 100644 --- a/init-container-service/src/main/java/org/ujar/bookingdb/init/InitContainerApplication.java +++ b/init-container-service/src/main/java/dev/knowhowto/bookingdb/init/InitContainerApplication.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.init; +package dev.knowhowto.bookingdb.init; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; diff --git a/init-container-service/src/main/java/org/ujar/bookingdb/init/config/ApplicationConfig.java b/init-container-service/src/main/java/dev/knowhowto/bookingdb/init/config/ApplicationConfig.java similarity index 70% rename from init-container-service/src/main/java/org/ujar/bookingdb/init/config/ApplicationConfig.java rename to init-container-service/src/main/java/dev/knowhowto/bookingdb/init/config/ApplicationConfig.java index 72fd88d..517f813 100644 --- a/init-container-service/src/main/java/org/ujar/bookingdb/init/config/ApplicationConfig.java +++ b/init-container-service/src/main/java/dev/knowhowto/bookingdb/init/config/ApplicationConfig.java @@ -1,4 +1,4 @@ -package org.ujar.bookingdb.init.config; +package dev.knowhowto.bookingdb.init.config; import org.springframework.context.annotation.Configuration; diff --git a/init-container-service/src/main/resources/banner.txt b/init-container-service/src/main/resources/banner.txt index 4ca5183..6cf78ff 100644 --- a/init-container-service/src/main/resources/banner.txt +++ b/init-container-service/src/main/resources/banner.txt @@ -1,8 +1,3 @@ -${AnsiColor.GREEN} | | -${AnsiColor.GREEN} _ _ | | __ _ _ __ -${AnsiColor.GREEN} | | | | _ | | / _` | | '__| -${AnsiColor.GREEN} | |_| | | |__| | | (_| | | | -${AnsiColor.GREEN} \__,_| \____/ \__,_| |_| ${AnsiColor.BLUE} =============================== ${AnsiColor.BLUE} Init Container ${AnsiColor.BLUE} Running Spring Boot ${spring-boot.version} diff --git a/init-container-service/src/main/resources/migrations/changelog/20220704000000_create_countries_table.xml b/init-container-service/src/main/resources/migrations/changelog/20220704000000_create_countries_table.xml index 9ec228c..2ad6a63 100644 --- a/init-container-service/src/main/resources/migrations/changelog/20220704000000_create_countries_table.xml +++ b/init-container-service/src/main/resources/migrations/changelog/20220704000000_create_countries_table.xml @@ -5,7 +5,7 @@ http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.4.xsd"> - + diff --git a/init-container-service/src/main/resources/migrations/changelog/20220707000000_create_cities_table.xml b/init-container-service/src/main/resources/migrations/changelog/20220707000000_create_cities_table.xml index 9a6fb8f..f9ea68f 100644 --- a/init-container-service/src/main/resources/migrations/changelog/20220707000000_create_cities_table.xml +++ b/init-container-service/src/main/resources/migrations/changelog/20220707000000_create_cities_table.xml @@ -5,7 +5,7 @@ http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.4.xsd"> - + @@ -24,7 +24,7 @@ - + - + @@ -25,7 +25,7 @@ - + 4.0.0 - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp bookingdb 23.0.0-SNAPSHOT pom @@ -18,12 +18,12 @@ - uJar Bootcamp - https://www.ujar.org + KnowHowSpringBoot Bootcamp + https://knowhowto.dev - 1 + dimdnk Dima Denysenko coding@dimdnk.com @@ -33,7 +33,7 @@ - org.ujar.boot + dev.knowhowto.boot boot-parent-pom 23.0.0-SNAPSHOT @@ -55,17 +55,17 @@ - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp batch-job ${project.version} - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp booking-persistence ${project.version} - org.ujar.sample-bookingdb-mix-rest-graphql-amqp + dev.knowhowto.sample-bookingdb-mix-rest-graphql-amqp booking-api-client ${project.version} diff --git a/src/main/docker/prometheus/prometheus.yml b/src/main/docker/prometheus/prometheus.yml index 462f09f..2696564 100644 --- a/src/main/docker/prometheus/prometheus.yml +++ b/src/main/docker/prometheus/prometheus.yml @@ -1,4 +1,4 @@ -# Sample global config for monitoring uJar applications +# Sample global config for monitoring KnowHowSpringBoot applications global : scrape_interval : 15s # By default, scrape targets every 15 seconds. evaluation_interval : 15s # By default, scrape targets every 15 seconds. @@ -7,7 +7,7 @@ global : # Attach these labels to any time series or alerts when communicating with # external systems (federation, remote storage, Alertmanager). external_labels : - monitor : 'ujar' + monitor : 'knowhowto' # A scrape configuration containing exactly one endpoint to scrape: # Here it's Prometheus itself. diff --git a/src/main/kubernetes-minikube-samples/manifests/dashboard/deployment.yaml b/src/main/kubernetes-minikube-samples/manifests/dashboard/deployment.yaml index 87c7a36..e03590c 100644 --- a/src/main/kubernetes-minikube-samples/manifests/dashboard/deployment.yaml +++ b/src/main/kubernetes-minikube-samples/manifests/dashboard/deployment.yaml @@ -18,7 +18,7 @@ spec : spec : containers : - name : dashboard-service - image : know-how.download/uJarOrg/sample-bookingdb-mix-dashboard-service:latest + image : know-how.download/KnowHowSpringBoot/sample-bookingdb-mix-dashboard-service:latest imagePullPolicy : Always ports : - containerPort : 8080 diff --git a/src/main/kubernetes-minikube-samples/manifests/edge/deployment.yaml b/src/main/kubernetes-minikube-samples/manifests/edge/deployment.yaml index 3bf916a..2a3e282 100644 --- a/src/main/kubernetes-minikube-samples/manifests/edge/deployment.yaml +++ b/src/main/kubernetes-minikube-samples/manifests/edge/deployment.yaml @@ -18,7 +18,7 @@ spec : spec : containers : - name : edge-service - image : know-how.download/uJarOrg/sample-bookingdb-mix-edge-service:latest + image : know-how.download/KnowHowSpringBoot/sample-bookingdb-mix-edge-service:latest imagePullPolicy : Always ports : - containerPort : 8080 diff --git a/src/main/kubernetes-minikube-samples/manifests/importer/deployment.yaml b/src/main/kubernetes-minikube-samples/manifests/importer/deployment.yaml index 245a0c8..355d956 100644 --- a/src/main/kubernetes-minikube-samples/manifests/importer/deployment.yaml +++ b/src/main/kubernetes-minikube-samples/manifests/importer/deployment.yaml @@ -18,7 +18,7 @@ spec : spec : containers : - name : importer-service - image : know-how.download/uJarOrg/sample-bookingdb-mix-importer-service:latest + image : know-how.download/KnowHowSpringBoot/sample-bookingdb-mix-importer-service:latest imagePullPolicy : Always ports : - containerPort : 8080 diff --git a/src/main/kubernetes-minikube-samples/manifests/init-container/deployment.yaml b/src/main/kubernetes-minikube-samples/manifests/init-container/deployment.yaml index 96ff273..915194c 100644 --- a/src/main/kubernetes-minikube-samples/manifests/init-container/deployment.yaml +++ b/src/main/kubernetes-minikube-samples/manifests/init-container/deployment.yaml @@ -18,7 +18,7 @@ spec : spec : containers : - name : init-container-service - image : know-how.download/uJarOrg/sample-bookingdb-mix-init-container-service:latest + image : know-how.download/KnowHowSpringBoot/sample-bookingdb-mix-init-container-service:latest imagePullPolicy : Always ports : - containerPort : 8080