esoe 1 month ago
parent
commit
b281448cea
  1. 1
      face/docker-compose.yaml
  2. 78
      face/logs/teh.log
  3. BIN
      face/logs/teh.log.2024-10-14.0.gz
  4. BIN
      face/logs/teh.log.2024-10-18.0.gz
  5. BIN
      face/logs/teh.log.2024-10-21.0.gz
  6. 14
      face/src/main/java/gsp/technologies/face/controllers/api/v1/ApiController.java
  7. 10
      face/src/main/java/gsp/technologies/face/controllers/face/v1/MainframeController.java
  8. 5
      face/src/main/resources/application.yaml
  9. 69
      face/src/main/resources/links.yaml
  10. 2
      face/src/main/resources/templates/fragments/common/footer.html
  11. 18
      face/src/main/resources/templates/fragments/common/header.html
  12. 14
      face/src/main/resources/templates/fragments/storage.html
  13. 3
      face/src/main/resources/templates/mainframe.html
  14. 3
      face/src/main/resources/templates/storage.html
  15. 12
      logger/logs/teh.log
  16. BIN
      logger/logs/teh.log.2024-10-16.0.gz
  17. 28
      source/src/main/java/gsp/technologies/source/controllers/api/v1/StorageController.java
  18. 24
      storage/src/main/java/gsp/technologies/storage/controllers/api/ApiController.java

1
face/docker-compose.yaml

@ -1,4 +1,3 @@
version: "3.7"
services: services:
face: face:
container_name: "face" container_name: "face"

78
face/logs/teh.log

@ -1,54 +1,24 @@
{"@timestamp":"2024-10-18T10:16:46.079309500Z","log.level":"INFO","process.pid":24296,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 24296 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T05:51:13.613370900Z","log.level":"INFO","process.pid":11604,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 11604 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:16:46.095064500Z","log.level":"INFO","process.pid":24296,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T05:51:13.625339Z","log.level":"INFO","process.pid":11604,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:16:48.100768Z","log.level":"INFO","process.pid":24296,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.472 seconds (process running for 3.708)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T05:51:15.385425500Z","log.level":"INFO","process.pid":11604,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.214 seconds (process running for 3.322)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:23:17.232261800Z","log.level":"INFO","process.pid":22552,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 22552 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:13:34.478381600Z","log.level":"INFO","process.pid":24956,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 24956 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:23:17.241804600Z","log.level":"INFO","process.pid":22552,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:13:34.485429Z","log.level":"INFO","process.pid":24956,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:23:19.245705100Z","log.level":"INFO","process.pid":22552,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.487 seconds (process running for 3.573)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:13:36.231668100Z","log.level":"INFO","process.pid":24956,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.241 seconds (process running for 3.281)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:24:54.040883Z","log.level":"INFO","process.pid":22820,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 22820 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:17:33.632635100Z","log.level":"INFO","process.pid":1720,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 1720 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:24:54.049883800Z","log.level":"INFO","process.pid":22820,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:17:33.639643600Z","log.level":"INFO","process.pid":1720,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:24:55.785223400Z","log.level":"INFO","process.pid":22820,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.175 seconds (process running for 3.348)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:17:35.353879300Z","log.level":"INFO","process.pid":1720,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.178 seconds (process running for 3.248)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:27:38.324585800Z","log.level":"INFO","process.pid":14936,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 14936 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:22:42.828757600Z","log.level":"INFO","process.pid":24008,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 24008 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:27:38.331601700Z","log.level":"INFO","process.pid":14936,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:22:42.835951300Z","log.level":"INFO","process.pid":24008,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:27:39.959435200Z","log.level":"INFO","process.pid":14936,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.056 seconds (process running for 3.197)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:22:44.530605400Z","log.level":"INFO","process.pid":24008,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.152 seconds (process running for 3.177)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:29:41.171170700Z","log.level":"INFO","process.pid":24428,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 24428 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:26:08.831712800Z","log.level":"INFO","process.pid":12312,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 12312 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:29:41.185144600Z","log.level":"INFO","process.pid":24428,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:26:08.836714Z","log.level":"INFO","process.pid":12312,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:29:43.101572Z","log.level":"INFO","process.pid":24428,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.44 seconds (process running for 3.641)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:26:11.046571100Z","log.level":"INFO","process.pid":12312,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.662 seconds (process running for 3.882)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:37:45.231688200Z","log.level":"INFO","process.pid":20796,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 20796 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:26:25.326554400Z","log.level":"INFO","process.pid":16424,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 16424 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:37:45.241253300Z","log.level":"INFO","process.pid":20796,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:26:25.337667100Z","log.level":"INFO","process.pid":16424,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:37:47.130034600Z","log.level":"INFO","process.pid":20796,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.401 seconds (process running for 3.54)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:26:27.549622700Z","log.level":"INFO","process.pid":16424,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 3.043 seconds (process running for 4.816)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:46:16.639952800Z","log.level":"INFO","process.pid":3112,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 3112 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:31:27.436894Z","log.level":"INFO","process.pid":21560,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 21560 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:46:16.646668300Z","log.level":"INFO","process.pid":3112,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:31:27.443382Z","log.level":"INFO","process.pid":21560,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:46:18.478662500Z","log.level":"INFO","process.pid":3112,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.318 seconds (process running for 3.426)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:31:29.382403500Z","log.level":"INFO","process.pid":21560,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.43 seconds (process running for 3.528)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:49:57.548313200Z","log.level":"INFO","process.pid":2688,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 2688 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T11:41:13.485475100Z","log.level":"INFO","process.pid":2492,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 2492 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:49:57.553365Z","log.level":"INFO","process.pid":2688,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T11:41:13.491427400Z","log.level":"INFO","process.pid":2492,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:49:59.314861100Z","log.level":"INFO","process.pid":2688,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.196 seconds (process running for 3.339)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T11:41:15.414923700Z","log.level":"INFO","process.pid":2492,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.397 seconds (process running for 3.59)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:53:14.621045400Z","log.level":"INFO","process.pid":11700,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 11700 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:53:14.628042300Z","log.level":"INFO","process.pid":11700,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T10:53:16.288819300Z","log.level":"INFO","process.pid":11700,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.122 seconds (process running for 3.288)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:15:36.217426Z","log.level":"INFO","process.pid":24292,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 24292 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:15:36.223457100Z","log.level":"INFO","process.pid":24292,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:15:38.093703900Z","log.level":"INFO","process.pid":24292,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.338 seconds (process running for 3.64)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:18:44.330707900Z","log.level":"INFO","process.pid":19940,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 19940 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:18:44.335751200Z","log.level":"INFO","process.pid":19940,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:18:46.201905900Z","log.level":"INFO","process.pid":19940,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.361 seconds (process running for 3.457)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:24:01.555947800Z","log.level":"INFO","process.pid":25132,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 25132 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:24:01.561978Z","log.level":"INFO","process.pid":25132,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:24:03.331856200Z","log.level":"INFO","process.pid":25132,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.201 seconds (process running for 3.372)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:25:53.499215500Z","log.level":"INFO","process.pid":7500,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 7500 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:25:53.506194700Z","log.level":"INFO","process.pid":7500,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:25:55.229347800Z","log.level":"INFO","process.pid":7500,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.17 seconds (process running for 3.249)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:37:05.138747500Z","log.level":"INFO","process.pid":8564,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 8564 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:37:05.142751600Z","log.level":"INFO","process.pid":8564,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:37:06.798824Z","log.level":"INFO","process.pid":8564,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.127 seconds (process running for 3.224)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:57:48.016430900Z","log.level":"INFO","process.pid":6544,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 6544 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:57:48.025399700Z","log.level":"INFO","process.pid":6544,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T11:57:49.794494700Z","log.level":"INFO","process.pid":6544,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.253 seconds (process running for 3.358)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:01:35.344508100Z","log.level":"INFO","process.pid":19712,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 19712 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:01:35.351512800Z","log.level":"INFO","process.pid":19712,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:01:37.452723400Z","log.level":"INFO","process.pid":19712,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.633 seconds (process running for 4.064)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:38:18.522022200Z","log.level":"INFO","process.pid":12104,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 12104 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:38:18.531028500Z","log.level":"INFO","process.pid":12104,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:38:20.392866200Z","log.level":"INFO","process.pid":12104,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.353 seconds (process running for 3.458)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:58:33.374123Z","log.level":"INFO","process.pid":1008,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Starting FaceApplicationTests using Java 17.0.7 with PID 1008 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:58:33.380123900Z","log.level":"INFO","process.pid":1008,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-18T12:58:35.283274400Z","log.level":"INFO","process.pid":1008,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"Started FaceApplicationTests in 2.376 seconds (process running for 3.481)","ecs.version":"8.11"}

BIN
face/logs/teh.log.2024-10-14.0.gz

Binary file not shown.

BIN
face/logs/teh.log.2024-10-18.0.gz

Binary file not shown.

BIN
face/logs/teh.log.2024-10-21.0.gz

Binary file not shown.

14
face/src/main/java/gsp/technologies/face/controllers/api/v1/ApiController.java

@ -69,8 +69,6 @@ public class ApiController {
metadata.setExtension(Filer.extension(file.getOriginalFilename())); metadata.setExtension(Filer.extension(file.getOriginalFilename()));
metadata.setSize(file.getSize()); metadata.setSize(file.getSize());
// получаем объект метаданных с id // получаем объект метаданных с id
try { try {
metadata = client.post() metadata = client.post()
@ -159,10 +157,22 @@ public class ApiController {
return "redirect:"+ referer; return "redirect:"+ referer;
} }
/**
* удаляет пост, метаданные и файл
*
* @param id
* @param request
* @return
*/
@GetMapping("/delete{id}") @GetMapping("/delete{id}")
public String delete(@PathVariable Long id, public String delete(@PathVariable Long id,
HttpServletRequest request) { HttpServletRequest request) {
//удаление поста //удаление поста
client.delete()
.uri("http://source:8181/api/v1/storage/post/delete/" + id)
.retrieve()
.bodyToMono(new ParameterizedTypeReference <Void>(){})
.block();
//удаление метаданных //удаление метаданных
//удаление файла //удаление файла
client.delete() client.delete()

10
face/src/main/java/gsp/technologies/face/controllers/face/v1/MainframeController.java

@ -7,6 +7,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.ParameterizedTypeReference; import org.springframework.core.ParameterizedTypeReference;
import org.springframework.core.env.Environment;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.ui.Model; import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
@ -30,6 +31,8 @@ public class MainframeController {
@Autowired @Autowired
private WebClient client; private WebClient client;
@Autowired
private Environment env;
// @Autowired // @Autowired
// private Storage storage; // private Storage storage;
@ -38,6 +41,13 @@ public class MainframeController {
public String mainframe(Model model, @RequestParam(name = "postContentPage", required = false) ContentPage<Post> postContentPage) { public String mainframe(Model model, @RequestParam(name = "postContentPage", required = false) ContentPage<Post> postContentPage) {
log.info("GET /face/v1/mainframe"); log.info("GET /face/v1/mainframe");
log.info("properties: ");
// String props = env.getProperty("links.storage.api.home");
// log.info("links.storage.api.home: {}", props);
if (postContentPage == null) { if (postContentPage == null) {
//подготовка параметров запроса //подготовка параметров запроса
ContentRequest req = new ContentRequest(); ContentRequest req = new ContentRequest();

5
face/src/main/resources/application.yaml

@ -1,4 +1,6 @@
spring: spring:
# config:
# import: classpath:/links.yaml
application: application:
name: face name: face
servlet: servlet:
@ -25,11 +27,10 @@ logging:
file: ecs file: ecs
file: file:
name: logs/teh.log name: logs/teh.log
# path:
server: server:
port: 8383 port: 8383
max-http-request-header-size: 50MB max-http-request-header-size: 50MB
tomcat: tomcat:
max-swallow-size: 1000MB max-swallow-size: 1000MB
max-http-form-post-size: 1000MB max-http-form-post-size: 1000MB
# maxParameterCount: 10000

69
face/src/main/resources/links.yaml

@ -0,0 +1,69 @@
# Ссылки на ресурсы платформы
links:
storage:
protocol: http://
domain: storage
port: 8282
# страница описания сервиса
hello: /hello
api:
###################################
# основные возможности api
# корневая директория сервиса "storage"
home: /api/v1
# перечень файлов, размещенных в хранилище
files: /api/v1/files
# получение пути к корню файлового хранилища
root: /api/v1/root
# сохранение файла в хранилище
file-store: /api/v1/files/store
# сохранение нескольких файлов в хранилище
file-store-multiple: /api/v1/files/store-multiple
# удаление файла из хранилища
file-delete: /api/v1/files/delete
# скачивание файла из хранилища
file-download: /api/v1/files/download
# постраничное извлечение данных xlsx-файла в json формате
xlsx-page: /api/v1/files/xlsx
###################################
# дополнительные возможности api
# создание пустого файла
file-create-empty: /api/v1/files/create
# создание диектории
directory-create: /api/v1/dirs/create
# удаление директории
directory-delete: /api/v1/dirs/delete
# получение массива байтов файла, без буферизации
file-bytes: /files/get-bytes
# face:
# home: /face/v1
# mainframe: /face/v1/mainframe
# upload-file: /face/v1/upload-file
# upload-multiple-files: /face/v1/upload-multiple-files
# download: /files/download-file
# delete: /files/delete-file
# view-xlsx: /files/view
# source:
# protocol: http://
# domain: storage
# port: 8181
# hello: /hello
# api:
# home: /api/v1
# metadata-list: /api/v1/storage/metadata/list
# post-list: /api/v1/storage/post/list
# post-page: /api/v1/storage/post/page
# post-page-distinct: /api/v1/storage/post/page/distinct
# metadata-create: /api/v1/storage/metadata/create
# post-create: /api/v1/storage/post/create
# metadata-update: /api/v1/storage/metadata/update
# face:
# protocol: http://
# domain: face
# port: 8383
# hello: /hello
# api:
# home: /api/v1
# upload: /api/v1/upload
# face:

2
face/src/main/resources/templates/fragments/common/footer.html

@ -3,7 +3,7 @@
<body> <body>
<div th:fragment="copy"> <div th:fragment="copy">
<hr> <hr>
© 2024 ООО "ГСП-Технологии" : gsp.technologies.teh.services { face, storage, sources, base, logger } © 2024 ООО "ГСП-Технологии" : gsp.technologies.services.teh { face, storage, sources, base, logger }
</div> </div>
<div th:fragment="info"> <div th:fragment="info">
<hr> <hr>

18
face/src/main/resources/templates/fragments/common/header.html

@ -0,0 +1,18 @@
<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<body>
<div th:fragment="mainframe">
<form th:action="@{/face/v1/mainframe}" th:method="get">
<button type="submit">mainframe</button>
</form>
</div>
<div th:fragment="storage">
<form th:action="@{/face/v1/storage}" th:method="get">
<button type="submit">storage</button>
</form>
</div>
<div th:fragment="info">
</div>
</body>
</html>

14
face/src/main/resources/templates/fragments/storage.html

@ -8,10 +8,7 @@
<div th:fragment="upload (post)"> <div th:fragment="upload (post)">
<h2>Добавление пакетов:</h2> <h2>Добавление пакетов:</h2>
<form th:method="post" th:action="@{/api/v1/upload}" enctype="multipart/form-data" th:object="${post}"> <form th:method="post" th:action="@{/api/v1/upload}" enctype="multipart/form-data" th:object="${post}">
<!-- <p th:text="${post}"></p> -->
<!-- <input type="text" id="type" name="type" th:value="*{type}"> -->
<select id="type" name="type" th:value="*{type}"> <select id="type" name="type" th:value="*{type}">
<!-- <select th:field="${post.type}"> -->
<option value="" disabled selected>--Выберите вид загружаемого документа--</option> <option value="" disabled selected>--Выберите вид загружаемого документа--</option>
<option value="Реестр обученных">Реестр обученных</option> <option value="Реестр обученных">Реестр обученных</option>
<option value="Списочный состав">Списочный состав</option> <option value="Списочный состав">Списочный состав</option>
@ -47,13 +44,17 @@
<th>post.id</th> <th>post.id</th>
<th>post.type</th> <th>post.type</th>
<th>metadata.name</th> <th>metadata.name</th>
<!-- <th>metadata.extension</th> -->
<th>metadata.createdDate</th> <th>metadata.createdDate</th>
<!-- Удаление документа -->
<th>-</th> <th>-</th>
<!-- просмотр сведений о документе -->
<th>view</th> <th>view</th>
<!-- скачать документ -->
<th>get</th> <th>get</th>
<!-- проверка документа -->
<th>check</th> <th>check</th>
<!-- экспорт документа -->
<th>export</th>
</thead> </thead>
<tbody> <tbody>
<tr th:each="post : ${postContentPage.content}"> <tr th:each="post : ${postContentPage.content}">
@ -67,8 +68,9 @@
</form> </form>
</td> </td>
<td>view</td> <td>view</td>
<td>get</td> <td>download</td>
<td>check</td> <td>check</td>
<td>export</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>

3
face/src/main/resources/templates/mainframe.html

@ -33,9 +33,8 @@ xmlns:th="http://www.thymeleaf.org">
</head> </head>
<body> <body>
<header> <header>
<h1>teh-mainframe</h1> <div th:insert="~{fragments/common/header :: storage}"></div>
<hr> <hr>
</header> </header>
<main> <main>
<!-- Хранилище данных --> <!-- Хранилище данных -->

3
face/src/main/resources/templates/storage.html

@ -33,9 +33,8 @@ xmlns:th="http://www.thymeleaf.org">
</head> </head>
<body> <body>
<header> <header>
<h1>teh-storage</h1> <div th:insert="~{fragments/common/header :: mainframe}"></div>
<hr> <hr>
</header> </header>
<main> <main>
<!-- Импорт данных в базу --> <!-- Импорт данных в базу -->

12
logger/logs/teh.log

@ -1,4 +1,8 @@
{"@timestamp":"2024-10-16T08:24:27.827057800Z","log.level":"WARN","process.pid":22816,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"org.springframework.boot.test.json.DuplicateJsonObjectContextCustomizerFactory$DuplicateJsonObjectContextCustomizer","message":"\r\n\r\nFound multiple occurrences of org.json.JSONObject on the class path:\r\n\r\n\tjar:file:\/C:\/Users\/devuser\/.m2\/repository\/org\/json\/json\/20240303\/json-20240303.jar!\/org\/json\/JSONObject.class\r\n\tjar:file:\/C:\/Users\/devuser\/.m2\/repository\/com\/vaadin\/external\/google\/android-json\/0.0.20131108.vaadin1\/android-json-0.0.20131108.vaadin1.jar!\/org\/json\/JSONObject.class\r\n\r\nYou may wish to exclude one of them to ensure predictable runtime behavior\r\n","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:29:18.233329200Z","log.level":"WARN","process.pid":13644,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"org.springframework.boot.test.json.DuplicateJsonObjectContextCustomizerFactory$DuplicateJsonObjectContextCustomizer","message":"\r\n\r\nFound multiple occurrences of org.json.JSONObject on the class path:\r\n\r\n\tjar:file:\/C:\/Users\/devuser\/.m2\/repository\/org\/json\/json\/20240303\/json-20240303.jar!\/org\/json\/JSONObject.class\r\n\tjar:file:\/C:\/Users\/devuser\/.m2\/repository\/com\/vaadin\/external\/google\/android-json\/0.0.20131108.vaadin1\/android-json-0.0.20131108.vaadin1.jar!\/org\/json\/JSONObject.class\r\n\r\nYou may wish to exclude one of them to ensure predictable runtime behavior\r\n","ecs.version":"8.11"}
{"@timestamp":"2024-10-16T08:24:27.888598300Z","log.level":"INFO","process.pid":22816,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"Starting LoggerApplicationTests using Java 17.0.7 with PID 22816 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\logger)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:29:18.281418300Z","log.level":"INFO","process.pid":13644,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"Starting LoggerApplicationTests using Java 17.0.7 with PID 13644 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\logger)","ecs.version":"8.11"}
{"@timestamp":"2024-10-16T08:24:27.892815400Z","log.level":"INFO","process.pid":22816,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:29:18.285387400Z","log.level":"INFO","process.pid":13644,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-16T08:24:29.744820600Z","log.level":"INFO","process.pid":22816,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"Started LoggerApplicationTests in 2.538 seconds (process running for 4.072)","ecs.version":"8.11"} {"@timestamp":"2024-10-22T06:29:19.736965800Z","log.level":"INFO","process.pid":13644,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"Started LoggerApplicationTests in 1.917 seconds (process running for 2.886)","ecs.version":"8.11"}
{"@timestamp":"2024-10-22T11:40:09.665396100Z","log.level":"WARN","process.pid":21300,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"org.springframework.boot.test.json.DuplicateJsonObjectContextCustomizerFactory$DuplicateJsonObjectContextCustomizer","message":"\r\n\r\nFound multiple occurrences of org.json.JSONObject on the class path:\r\n\r\n\tjar:file:\/C:\/Users\/devuser\/.m2\/repository\/org\/json\/json\/20240303\/json-20240303.jar!\/org\/json\/JSONObject.class\r\n\tjar:file:\/C:\/Users\/devuser\/.m2\/repository\/com\/vaadin\/external\/google\/android-json\/0.0.20131108.vaadin1\/android-json-0.0.20131108.vaadin1.jar!\/org\/json\/JSONObject.class\r\n\r\nYou may wish to exclude one of them to ensure predictable runtime behavior\r\n","ecs.version":"8.11"}
{"@timestamp":"2024-10-22T11:40:09.709404800Z","log.level":"INFO","process.pid":21300,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"Starting LoggerApplicationTests using Java 17.0.7 with PID 21300 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\logger)","ecs.version":"8.11"}
{"@timestamp":"2024-10-22T11:40:09.713405Z","log.level":"INFO","process.pid":21300,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"No active profile set, falling back to 1 default profile: \"default\"","ecs.version":"8.11"}
{"@timestamp":"2024-10-22T11:40:11.139464Z","log.level":"INFO","process.pid":21300,"process.thread.name":"main","service.name":"logger","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.logger.LoggerApplicationTests","message":"Started LoggerApplicationTests in 1.954 seconds (process running for 3.003)","ecs.version":"8.11"}

BIN
logger/logs/teh.log.2024-10-16.0.gz

Binary file not shown.

28
source/src/main/java/gsp/technologies/source/controllers/api/v1/StorageController.java

@ -93,20 +93,20 @@ public class StorageController {
return new ResponseEntity<>(post, HttpStatus.CREATED); return new ResponseEntity<>(post, HttpStatus.CREATED);
} }
@PutMapping(path = "/metadata/update/{id}", // @PutMapping(path = "/metadata/update/{id}",
consumes = MediaType.APPLICATION_JSON_VALUE, // consumes = MediaType.APPLICATION_JSON_VALUE,
produces = MediaType.APPLICATION_JSON_VALUE) // produces = MediaType.APPLICATION_JSON_VALUE)
public ResponseEntity<?> updateStorageEntry(@PathVariable Long id, @RequestBody FileMetadata metadata) { // public ResponseEntity<?> updateStorageEntry(@PathVariable Long id, @RequestBody FileMetadata metadata) {
log.info("PUT /metadata/update/{id}, metadata: {}", metadata); // log.info("PUT /metadata/update/{id}, metadata: {}", metadata);
Optional<FileMetadata> ometa = metaRepo.findById(id); // Optional<FileMetadata> ometa = metaRepo.findById(id);
FileMetadata meta = ometa.get(); // FileMetadata meta = ometa.get();
// meta.setName(metadata.getName()); // // meta.setName(metadata.getName());
// meta.setRelativePath(metadata.getRelativePath()); // // meta.setRelativePath(metadata.getRelativePath());
// meta.setExtension(metadata.getExtension()); // // meta.setExtension(metadata.getExtension());
// meta.setSize(metadata.getSize()); // // meta.setSize(metadata.getSize());
metaRepo.save(meta); // metaRepo.save(meta);
return new ResponseEntity<>(metaRepo.findById(id), HttpStatus.CREATED); // return new ResponseEntity<>(metaRepo.findById(id), HttpStatus.CREATED);
} // }
@PutMapping(path = "/metadata/update", @PutMapping(path = "/metadata/update",
consumes = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE,

24
storage/src/main/java/gsp/technologies/storage/controllers/api/ApiController.java

@ -106,15 +106,7 @@ public class ApiController {
LOG.info("DELETE /files/delete"); LOG.info("DELETE /files/delete");
fs.deleteFile(filename); fs.deleteFile(filename);
} }
// Метод для получения содержимого файлов
@GetMapping("/files/{filename}")
public @ResponseBody
byte[] getFile(@PathVariable String filename) {
LOG.info("GET /files/{filename}");
return fs.getFile(filename);
}
/** /**
* Скачивание файла с сервера * Скачивание файла с сервера
*/ */
@ -182,18 +174,28 @@ public class ApiController {
// Создаем директорию с указанным именем в указанной директории. // Создаем директорию с указанным именем в указанной директории.
fs.createDirectory(path, name); fs.createDirectory(path, name);
} }
/** /**
* Удаляет директорию с указанным именем * Удаляет директорию с указанным именем
* *
* @param name имя директории, которую нужно удалить * @param name имя директории, которую нужно удалить
*/ */
@DeleteMapping("/dirs/{name}") @DeleteMapping("/dirs/delete")
public @ResponseBody public @ResponseBody
void deleteDir(@PathVariable String name) { void deleteDir(@RequestParam(name = "name", required = true) String name) {
LOG.info("DELETE /dirs/{name}"); LOG.info("DELETE /dirs/{name}");
fs.deleteDirectory(name); fs.deleteDirectory(name);
} }
// Метод для получения содержимого файлов
@GetMapping("/files/get-bytes")
public @ResponseBody
byte[] getFile(@RequestParam(name = "filename", required = true) String filename) {
LOG.info("GET /files/{filename}");
return fs.getFile(filename);
}
} }

Loading…
Cancel
Save