Open cpatel321 opened 4 days ago
@bichhawat @cpatel321 In your logappend input, all the individuals who entered the campus eventually left, leaving no one on campus. As a result, the logread command for listing current state of the campus produces an empty output. However, other logread features continue to function correctly. For reference, I am attaching the logread commands I executed with the same input: The logread commands can be found at the end.
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logappend -T 1 -K token123 -E Alice -A log
./logappend -T 2 -K token123 -E Bob -A log
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logappend -T 3 -K token123 -E Alice -A -R 101 log
./logappend -T 4 -K token123 -E Bob -A -R 102 log
./logappend -T 5 -K token123 -E Alice -L -R 101 log
./logappend -T 6 -K token123 -E Bob -L -R 102 log
./logappend -T 7 -K token123 -E Alice -L log
./logappend -T 8 -K token123 -E Bob -L log
./logappend -T 9 -K token123 -G Charlie -A log
./logappend -T 10 -K token123 -G Dana -A log
./logappend -T 11 -K token123 -G Charlie -A -R 201 log
./logappend -T 12 -K token123 -G Dana -A -R 202 log
./logappend -T 13 -K token123 -G Charlie -L -R 201 log
./logappend -T 14 -K token123 -G Dana -L -R 202 log
./logappend -T 15 -K token123 -G Charlie -L log
./logappend -T 21 -K token123 -G Frank -A log1 log
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logappend -T 22 -K token123 -G Frank -A -R 401 log
./logappend -T 23 -K token123 -G Frank -L -R 401 log
./logappend -T 24 -K token123 -G Frank -L log
./logappend -T 25 -K token123 -E George -A log
./logappend -T 26 -K token123 -E Helen -A log
./logappend -T 27 -K token123 -E George -A -R 501 log
./logappend -T 28 -K token123 -E Helen -A -R 502 log
./logappend -T 29 -K token123 -E George -L -R 501 log
./logappend -T 30 -K token123 -E Helen -L -R 502 log
./logappend -T 31 -K token123 -E George -L log
./logappend -T 32 -K token123 -E Helen -L log
./logappend -T 33 -K token123 -G Ian -A log
./logappend -T 34 -K token123 -G Judy -A log
./logappend -T 53 -K token123 -G Nina -A log901 logg
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logappend -T 54 -K token123 -G Nina -A -R 1001 log
./logappend -T 55 -K token123 -G Nina -L -R 1001 log
./logappend -T 56 -K token123 -G Nina -L log
./logappend -T 57 -K token123 -E Owen -A log
./logappend -T 58 -K token123 -E Owen -A -R 1101 log
./logappend -T 59 -K token123 -E Owen -L -R 1101 log
./logappend -T 60 -K token123 -E Owen -L log
./logappend -T 61 -K token123 -G Paula -A log
./logappend -T 62 -K token123 -G Paula -A -R 1201 log
./logappend -T 63 -K token123 -G Paula -L -R 1201 log
./logappend -T 64 -K token123 -G Paula -L log
./logappend -T 65 -K token123 -E Quinn -A log
./logappend -T 66 -K token123 -E Quinn -L log
./logappend -T 76 -K token123 -G Tara -L log1401 logg
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
Message sent
4
Successfully_executed
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -K token123 -S log
Message sent
5
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -T -E Alice -K token123 log
Message sent
4
6 <-- Total time spent by Alice in campus
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -T -E Bob -K token123 log
Message sent
4
6 <-- Total time spent by Bob in campus
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -T -G Dana -K token123 log
Message sent
4
6 <-- Total time spent by Dana in campus
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -T -E Eve -K token123 log
Message sent
3
3 <-- Total time spent by Eve in campus
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -R -E Alice -K token123 log
Message sent
4
101 <-- Output
pakambo@Quagrinn:~/Documents/Security_Guard/build$ ./logread -R -G Dana -K token123 log
Message sent
5
202 <-- Output
Please find the video of the demonstration.
Also these are the commands used to logappend,
And these are the output
The expected output would be to print all the persons present there room wise.
it is not that the log are not saved, this is the snapshot of the log file It has exactly 76 entries as expected.