You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+183Lines changed: 183 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,189 @@
2
2
# CS3219 Project (PeerPrep) - AY2526S1
3
3
## Group: G12
4
4
5
+
## Services:
6
+
7
+
### Frontend
8
+
9
+
Folder: `PeerPrep`
10
+
11
+
Contains the project files for our frontend service built with Vite
12
+
13
+
#### Development:
14
+
15
+
Copy the `.env.template` to `.env` and update variables.
16
+
17
+
```
18
+
npm install
19
+
npm run dev
20
+
```
21
+
22
+
### API Gateway
23
+
24
+
Folder: `api-gateway`
25
+
26
+
#### Functionality:
27
+
28
+
* Routes API traffic from users to the corresponding internal services
29
+
* Handles the checking of access token cookies to enforce authentication and authorisation
30
+
31
+
#### Development:
32
+
33
+
Copy the `.env.template` to `.env` and update variables.
34
+
35
+
```
36
+
uv sync
37
+
uv run fastapi dev main.py
38
+
```
39
+
40
+
### Collaboration Service
41
+
42
+
Folder: `collaboration-svc`
43
+
44
+
#### Functionality:
45
+
46
+
* Facilitate room/session creation
47
+
* Coordinating users
48
+
49
+
#### Development:
50
+
51
+
Copy the `.env.template` to `.env` and update variables.
52
+
53
+
```
54
+
uv sync
55
+
uv run fastapi dev routes.py
56
+
```
57
+
58
+
### Expire Observer Service
59
+
60
+
Folder: `expire-observer-svc`
61
+
62
+
#### Functionality:
63
+
64
+
* Handles TTL Matching Expire event from redis
65
+
66
+
#### Development:
67
+
68
+
Copy the `.env.template` to `.env` and update variables.
69
+
70
+
```
71
+
uv sync
72
+
uv run fastapi dev main.py
73
+
```
74
+
75
+
### Matching Service
76
+
77
+
Folder: `matching-svc`
78
+
79
+
#### Functionality:
80
+
81
+
* Handles user matching requests
82
+
* Corrdinating user acknowledgement for requests
83
+
84
+
#### Development:
85
+
86
+
Copy the `.env.template` to `.env` and update variables.
87
+
88
+
```
89
+
uv sync
90
+
uv run fastapi dev routes.py
91
+
```
92
+
93
+
### Question History Service
94
+
95
+
Folder: `qns-hist-svc`
96
+
97
+
#### Functionality:
98
+
99
+
* Handles retrieval of users past attempts
100
+
* Generate AI Summary Review on users past attempts
101
+
102
+
#### Development:
103
+
104
+
Copy the `.env.template` to `.env` and update variables.
105
+
106
+
```
107
+
uv sync
108
+
uv run fastapi dev routes.py
109
+
```
110
+
111
+
### Question Service
112
+
113
+
Folder: `qns-svc`
114
+
115
+
#### Functionality:
116
+
117
+
* Handles retrieval of questions for users
118
+
* Create, Update and Deletion of Question for admins
119
+
120
+
#### Development:
121
+
122
+
Copy the `.env.template` to `.env` and update variables.
123
+
124
+
```
125
+
uv sync
126
+
uv run fastapi dev routes.py
127
+
```
128
+
129
+
#### Support:
130
+
131
+
Question Service has a supplimentary files for importing questions located under `support\qns-svc-import`
132
+
133
+
### Signaling Service
134
+
135
+
Folder: `signaling-svc`
136
+
137
+
#### Functionality:
138
+
139
+
* Coordinate WebRTC traffic between users
140
+
141
+
#### Development:
142
+
143
+
```
144
+
npm install
145
+
node server.js
146
+
```
147
+
148
+
### User Service
149
+
150
+
Folder: `user-svc`
151
+
152
+
#### Functionality:
153
+
154
+
* Handles authentication of users
155
+
* Retrieve profile information for users
156
+
157
+
#### Development:
158
+
159
+
Copy the `.env.template` to `.env` and update variables.
160
+
161
+
```
162
+
uv sync
163
+
uv run fastapi dev main.py
164
+
```
165
+
166
+
## Running Locally
167
+
168
+
We support running our services as containers using docker compose
169
+
170
+
> Prerequisite
171
+
> * Ensure that docker is installed
172
+
> * Ensure 4 Redis instances and 3 PostgreSQL instance are setup for the various services
173
+
174
+
To startup the containers:
175
+
176
+
```
177
+
docker compose up -d --build
178
+
```
179
+
180
+
To tear everything down
181
+
182
+
```
183
+
docker compose down
184
+
```
185
+
186
+
187
+
5
188
### Note:
6
189
- You are required to develop individual microservices within separate folders within this repository.
7
190
- The teaching team should be given access to the repositories as we may require viewing the history of the repository in case of any disputes or disagreements.
0 commit comments