13 Home
root edited this page 2025-06-26 17:19:48 +01:00

How to setup DEV environment

  1. Checkout the project
  2. Open CMD (as administrator)
  3. Build/Install front-end (node.js). Run : npm install
  4. Build & Run SpringBoot App. Run: mvnw
  5. Open browser: http://localhost:8081 (for testing)
  6. Open eclipse. Import project "Maven » Existing Maven Projects"

Pre-Requisits

  • Java version: 17.0.10 (JDK)
  • Apache Maven 3.8.1
  • Eclipse IDE 2024-03 (4.31.0)
  • MySQL 8.0 or MariaDB 10.6
  • NodeJS

Project Database Config

Using MySQL (active):
jdbc:mysql://localhost:3306/resilient_resilient?useUnicode=true&characterEncoding=utf8&useSSL=false&useLegacyDatetimeCode=false&createDatabaseIfNotExist=true

Using MariaDB:
jdbc:mariadb://localhost:3306/resilient_resilient?useUnicode=true&characterEncoding=utf8&useSSL=false&useLegacyDatetimeCode=false&createDatabaseIfNotExist=true

Eclipse IDE Settings

In the project there's a directory with several settings to apply to Eclipse: \ide\eclipse\

Import:

  1. Code Formatter: Preferences → Java → Code Style → Formatter → Import...
    Located in \ide\eclipse\formatter
  2. Run Configs: Run → Run Configurations → Import...
    Located in \ide\eclipse\run-configs

Make a release (with automated Forgejo actions)

See workflow configuration file: master/.forgejo/workflows/release.yml

  1. Create a new branch in release/*
  1. Fogejo Actions should fire
  1. Release validations
  • Branch release/v1.0.99
    • pom.xml, the version must be <version>1.0.99</version> without SNAPSHOT
    • an artifact was attached to the workflow run, with the name: app-backend
    • download the artifact and check contents. It mus be a valid ZIP file.
  • Branch master
    • pom.xml, the version must be <version>1.0.100-SNAPSHOT</version> with SNAPSHOT and incremented
    • a tag was added with the name v1.0.99
  • A Forgejo Release has been create
  1. Post release After the (successfull) release, the Milestone must be closed.
  • Goto https://git.oguerreiro.com/root/resilient/milestones
  • Create the next milestone: 1.0.100
  • Close the released milestone
    • Search for the Milestone 1.0.99
    • Evaluate if all associated issues are closed
      • If not, move the unresolved issues to another milestone
    • Click the action "Close"
  • In working Eclipse Workspace make PULL (this prevents future conflits, and updates the pom version)

Revert release

Procedures to execute when something go wrong in the release

  1. Delete the Tag
  1. Delete the Branch
  1. Evaluate master pom.xml version The update to master\pom.xml is the last thing done. In case of error in the release workflow its VERY unlike to after master\pom.xml change. That being sayed, validate:
  • Is master\pom.xml changed to the next working version? (Example: 1.0.100-SNAPSHOT)
  • If already is, manually change back and commit
  1. Make any necessary corrections to solve the problem in the release
  2. Now, just repeat the release