University of Minho - School of Engineering - Integrated Master's, Software Engineering
Notice: You can view the dissertation document here.
#ID | Name |
---|---|
saga | Saga |
cp | Command Product |
qp | Query Product |
cc | Command Category |
qcvp | Query Category Visible Products |
qcap | Query Category All Products |
qct | Query Category Tree |
co | Order |
inventory | Inventory |
sc | Shopping Cart |
consumer | Consumer |
manager | Manager |
- Docker and Docker compose;
- Makefile;
- 16+ GB of RAM;
- the repository folders (src/deployment);
- Download the repository:
git clone https://github.com/josepereira1/dissertation.git
-
Set the docker volumes dir or leave the default (/tmp/dissertation/docker-volumes)
- open .env (src/deployment/.env) and set the DOCKER_VOLUMES_DIR var with docker volumes directory.
- open makefile (src/deployment/makefile) and set the DOCKER_VOLUMES_DIR var with same docker volumes directory defined above.
-
Execute deployment:
cd src/deployment
make deployment
-
Wait some time (3 minutes, or check the cpu usage, when it decrease significantly, probably the deployment ended).
-
Setup base data and configurations:
make setup
- Populate data (products, categories and associate them):
make populate
The create product functionality is asynchronous process, than when populate process ends, it will take some time until all products are created and associated with categories.
After first deployment, to stop or start the application just need to run make up or make down and reuse data saved in volumes. There is one more command, make upf, it is similar to make up, but forces the docker images update.
After deploy application, access via web browser to http://localhost:8080 and use the application. Check the default users section.
-
Consumer:
- username: bob
- password: password
-
Manager:
- username: alice
- password: password
- MongoDB databases
- PostgreSQL databases:
- System: PostgreSQL
- Username: root
- Password: password
- Servers:
- postgres-cp
- postgres-cc
- postgres-inventory
- postgres-sc
- RabbitMQ:
- Username: guest
- Password: guest
Can consult logs per service to see command and reply messages used in microservices patterns, using the next command:
make <<service_name>>
Examples:
make cp