- Entities:
- Resources
- Permissions
- Users
- Roles or Groups
- Resources requires (1 or more) Permissions
- Roles are collection of (1 or more) Permissions
Advantages
Disadvantages
Global testing is difficult as we need to make sure each individual service is up and running without issues
version: '3.7' | |
services: | |
redis: | |
image: 'redis' | |
ports: | |
# Host : Container | |
- 6379:6379 | |
volumes: | |
- './host/data/redis:/var/lib/redis/data' | |
mongodb: |
1 | |
2 |
1 | |
1549 | |
983 | |
1538 | |
873 | |
827 | |
53 | |
1207 | |
359 | |
560 |
{ | |
"user_name": "", | |
"num_solved": 0, | |
"num_total": 1788, | |
"ac_easy": 0, | |
"ac_medium": 0, | |
"ac_hard": 0, | |
"stat_status_pairs": [ | |
{ |
#define ll long long | |
#define pi pair<ll, ll> | |
#define trace(...) __f(#__VA_ARGS__, __VA_ARGS__) | |
template <typename T, typename S> ostream& operator<<(ostream& os, const pair<T, S>& p) {os << "(" << p.first << ", " << p.second << ")";return os;} | |
template <typename T> ostream& operator<<(ostream& os, const vector<T>& v) {os << "[";for (auto i : v) os << i << " ";os << "\b]";return os;} | |
template <typename T> ostream& operator<<(ostream& os, const multiset<T>& s) {os << "{";for (auto i : s) os << i << " ";os << "\b}";return os; } | |
template <typename T> ostream& operator<<(ostream& os, const set<T>& s) {os << "{";for (auto i : s) os << i << " ";os << "\b}";return os; } | |
template <typename T> ostream& operator<<(ostream& os, const unordered_set<T>& s) {os << "{";for (auto i : s) os << i << " ";os << "\b}";return os; } | |
template <typename T1, typename T2> ostream& operator<<(ostream& os, const map<T1, T2>& s) {for (auto i : s) os << i << endl;return os; } | |
template <typename T1, typename T2> ostream& operator<<(ostream& |