GreenLoop is a Java-based desktop portal designed to streamline sustainable order tracking, inventory control, and delivery scheduling. The application leverages a FlatLaf-styled Swing UI and links directly to a MongoDB database.
Before running the application, make sure you have the following installed:
- Java Development Kit (JDK 17) or higher.
- Apache Maven (tested with 3.x).
- MongoDB Instance: Connected via the properties file.
Database connection configurations are pre-defined in:
src/main/resources/application.properties
Ensure that the connection string mongodb.uri points to a reachable MongoDB database.
Open your terminal inside the project root directory and run the following command to compile and build the package:
mvn clean compileTo run the main Logistics Portal UI console, execute:
mvn exec:java -Dexec.mainClass="org.example.OrderManagementExample"Alternatively, you can run the org.example.OrderManagementGUI class from your preferred IDE (IntelliJ, Eclipse, VS Code).
To run a headless demo simulation of placing orders, assigning agents, completing deliveries, and refunding cancelled orders in the CLI:
mvn exec:java -Dexec.mainClass="org.example.OrderManagementExample" -Dexec.args="cli"To execute all JUnit unit and integration tests checking database integrity and business logic:
mvn test