NOTE: Archived as evalutation is over
Making UML diagrams for backend and frontend.
Working site
Have Java 17, postgresql installed. Create a database named silkroad
in psql.
- Clone the git repo
- In
src/main/resources/
create a folder namedcerts
. Nowcd
into thecerts
folder and run the following commands.openssl genrsa -out keypair.pem 2048 openssl rsa -in keypair.pem -pubout -out public.pem openssl pkcs8 -topk8 -inform PEM -outform PEM -nocrypt -in keypair.pem -out private.pem
- In
src/main/resources/
renameapplication.properties.example
toapplication.properties
, Openapplication.properties
and fill out the blank fields. - In the root directory, run
./mvnw spring-boot:run
or you can use the spring boot dashboard extension in VSCode to run.
Have yarn
(preferable) or npm
installed.
- Clone the git repo.
cd
into thefrontend
folder.- Run
yarn
to install the dependencies. - Run
yarn dev
to start it.
- Have VSCode.
- Install this extension VSCode plantuml.
- Install plantuml. Follow either the local render or server render method.Instructions. I use the server render method specifically the third one with picoweb.
- Add these settings in VScode settings json file. Can be accessed with Ctrl + Shift + P
"plantuml.diagramsRoot": "docs/src",
"plantuml.exportOutDir": "docs/",
"plantuml.exportOutDir": "docs/diagrams/out",
"plantuml.server": "http://192.168.1.100:8080",
"plantuml.render": "PlantUMLServer"
- Open
Backend.wsd
in./docs/diagrams/src/
directory. - Open the preview of the file by using Alt + D
- Refer this to make the UML diagrams.
We are using Java 17 so install it.
-
Clone the git repo.
-
Checkout to a new branch named with the feature you want to work on. Use the command center( Ctrl + Shift + P and search for
Git:Checkout to ...
) in VSCode. -
Download postgresql.
- Follow this link for instructions.
- TLDR of the link after installing using your respective package managers. While creating user create with the same name as your linux username.
sudo -iu postgres sudo systemctl enable --now postgresql.service createuser --interactive createdb dataBaseNameSameAsTheAboveUserName psql
- Watch this video. I am not sure about windows, contact Pranav for troubleshooting.
-
After having your postgresql setup done. Install
Extension Pack for Java
andSpring Boot Extension Pack
extensions on VSCode. -
Go to the psql shell by typing
psql
orpsql -U postgres
and create a new usingCREATE DATABASE silkroad;
-
In
src/main/resources
create a file namedapplication.properties
and add the following lines.spring.datasource.url=jdbc:postgresql://localhost:5432/silkroad spring.datasource.username= spring.datasource.password= spring.jpa.hibernate.ddl-auto=create-drop spring.jpa.show-sql=true spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect spring.jpa.properties.hibernate.format_sql=true server.error.include-message=always
Add the username and password.
cd
into thefrontend
folder and runyarn
.- Create a
.env
file similar to.env.example
. yarn dev
will run the project.
Hopefully one day I'll come back to this make few more changes.