From 34e2368a0326d25cd48e4d87ac19b94aa8f91e39 Mon Sep 17 00:00:00 2001 From: esoe Date: Wed, 23 Oct 2024 09:25:48 +0300 Subject: [PATCH] profiles works --- face/logs/teh.log | 27 +--- face/logs/teh.log.2024-10-15.0.gz | Bin 1735 -> 0 bytes face/logs/teh.log.2024-10-22.0.gz | Bin 0 -> 7025 bytes .../controllers/api/v1/ApiController.java | 24 ++- .../face/v1/MainframeController.java | 18 +-- .../technologies/face/services/LinksFace.java | 7 + .../face/services/LinksService.java | 149 ++++++++++++++++++ face/src/main/resources/application-face.yaml | 12 ++ .../main/resources/application-source.yaml | 14 ++ .../main/resources/application-storage.yaml | 44 ++++++ face/src/main/resources/application.yaml | 7 +- face/src/main/resources/links.yaml | 69 -------- 12 files changed, 264 insertions(+), 107 deletions(-) delete mode 100644 face/logs/teh.log.2024-10-15.0.gz create mode 100644 face/logs/teh.log.2024-10-22.0.gz create mode 100644 face/src/main/java/gsp/technologies/face/services/LinksFace.java create mode 100644 face/src/main/java/gsp/technologies/face/services/LinksService.java create mode 100644 face/src/main/resources/application-face.yaml create mode 100644 face/src/main/resources/application-source.yaml create mode 100644 face/src/main/resources/application-storage.yaml delete mode 100644 face/src/main/resources/links.yaml diff --git a/face/logs/teh.log b/face/logs/teh.log index 0271916..b10f4d2 100644 --- a/face/logs/teh.log +++ b/face/logs/teh.log @@ -1,24 +1,3 @@ -{"@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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-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-23T06:23:27.800975600Z","log.level":"INFO","process.pid":18696,"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 18696 (started by devuser in C:\\Users\\devuser\\Documents\\code\\teh\\face)","ecs.version":"8.11"} +{"@timestamp":"2024-10-23T06:23:27.814171300Z","log.level":"INFO","process.pid":18696,"process.thread.name":"main","service.name":"face","service.version":"1","service.environment":"Production","service.node.name":"Primary","log.logger":"gsp.technologies.face.FaceApplicationTests","message":"The following 3 profiles are active: \"face\", \"source\", \"storage\"","ecs.version":"8.11"} +{"@timestamp":"2024-10-23T06:23:29.758343700Z","log.level":"INFO","process.pid":18696,"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.446 seconds (process running for 3.608)","ecs.version":"8.11"} diff --git a/face/logs/teh.log.2024-10-15.0.gz b/face/logs/teh.log.2024-10-15.0.gz deleted file mode 100644 index 92cf4032212e457908b5937b31a9c384858d02f5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1735 zcmV;&1~~a2iwFP!00000|K*)cZyPrdhVT6q3!PFRAvnX~*PdE52#_Aq0BJ9UE*oiW z3za29E2{{C{`U?oDfS@+r@Rp00)Y`wyDMoP^X1HNIR3i$>A1Ncr{i${u;>@4k=}rQ z1NL|AdK-GQiZmE!QR_b!uNT|>t=f*KamyFK|M2cN9(p+JSK~CPhs}D?LoiN1j~(w0 z{?{9C%0}tO$59&Cs?sj_~+KiJ*@2%ePkDnhNwwu+E z9{D?4W8yp6D${VAp7!ZD9FCjaZTGz^yT>WL^y_dMI`B#>-~GKg-gO_}zwMr^(Y>0| z{o}g({H0rur$_$4-DcPQ(l3{P@c*af@-n(yzTK}L(|6>t6@Q)O@;Kftm+4df$e(Cj zO)tz76u{!2AHE6*qBewK#soj?yMf>BGaXs&?|}K- z43FF6^|HQOE-pjMMKJ-dfTGcXW=!DIWe$9I3h`_}1<^8<)qc00x>uJk-yI%zyF}<_ zf9QmsB!vQnqb3Q~QZnCb-D^-G25WOu#D> z$XN?BCXg30O^_2Zz#^CIiGm?T-a61i3SdaLNuemXOxCEZWQia<0~X?p3074yRhbS#_)rnjK1j*hICQ7{qPgis=6$rx32?92}=^Rx5iS5d|ofKfUI z4^Eh+Y!QIKA48v0F&&|B7En*5g13f9>W_gl*d&D_e=J#}s*arrhD1>6kF`j!qL48G zr)-SI&zeA9$xw%!l94T&2H<bL9)9yVQ0|dgr5<;uXNm>0xWtZ$qFnaBTp=FZ<>nT|x z;MgfP+K5wREfNqY8D`5biYEa9J7mOhiOBxiHfsMO4NKOjtYHZsXvQa9g<2$7Rl~?A z3oZsHP0h4OAg^K0WW&lBOT966i=Elc)b|z>;)Y2ld zCJ9zlGA6(=lhKy^oCyf3Ve>wj3%+C?gdS{f*rh`cAYMM7Ybf`$OZ z8L}1$)>5)F0jnZ-M3kOTYLP%*$*j%h`Xdx2$--sN3n_R5;yfjXGEGt_i!Rw3Rh8^a z&^nJ%9NRQVu%ePZ?OKB831p;kO^XBsK3U9`!?F&Q%>(1oIWfn9i3h1?Y+I#Jq-3_T zl3fV~_R409ubzx0^BV=^$cn4TS|lK-hqc)w<4~0C4?RITZ%hQnh}RN=M!n)96-(Br zsbW`x-njYVtEXawDMcBbH)N&TWi1jAoK4C%zRj#{b|%Qb0PKwYk0wkF60D_UX98A{0Rwu@1aeB24ufZuj8xD?VP))1NQcBAnn+&i zkm=BPs!u>8x4dI%kP}Yfztx;3PE(A?Lu)>9?NrLs1ED>;N*B@P&GXX(p>9VyK#X{zL zOG+a~kZyM&#YVd*6$x3gMpYp@6Er$RKQ5xGfNkFh+Nm(JYWt}gW zLQL^J>liq3V@uuYa#D6+ytYerA;@02v>3BVf)$l4rp^}uQ_ltQk^KeI@GkzgeyyAX)VlSSvHO4cF) zNt5erwjXTC`J_aFQVo&~h%rbhcxrUdrAWz=HL5Dvgh4aAofE?iafJW>Yhepf!%A(6qu^#rBpfMCdn&xbgU_~Wk0;G&L d(MdbVG)X|BWcfzd_P?Xce*s{pQ-juW002K6GWh@i diff --git a/face/logs/teh.log.2024-10-22.0.gz b/face/logs/teh.log.2024-10-22.0.gz new file mode 100644 index 0000000000000000000000000000000000000000..09c9323d2994a433e30a22cbc0392f29fcdf65a2 GIT binary patch literal 7025 zcmaKR1yCGOwl?nW?(Xh^0D%k|+#$FVLa^X2fkA>xa0xJBu;32C2MLk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NV9^^3*fkBjsT z(+SvamL0k^xCC||XHjo{Z|dvT>pRVfIW?A@8v5TX_WF==%S@T3shFC=%QY4Bo4W4D z+T0rXw9BVkQi}P}Z8_sd+NUm(x7~dQkVk8yR4i)(W4FCnWo;06`YvIw(q$5R#r$q# zIq2b3;Y1RbEm-B_wUCC#v%GMgX9a{|mr5dOAf{23i&}MI*;YcouMW*3d&`q%7T5c5 z|K>Z<2f}~U`x{%U7#LlU8NvNL$fCd)IUmJHU6}pJfXuKI6}lzt_%-Ny2$@Qt-y^p^ z`7s?4%i?dH-*;$KfND{Ez#XyEMn;iPxpGAG2)bg15MP*|_{Qt)F)6E&yo*n|yc3l( zvhoc?kE_=4q_ti^`&fht;22C9X2SnJ>U-01=s^Fz5G-I}v-_pWa(q<`sB-IbiXX=925y)vW7LH}J%d5$~ZU7QHs=K-pO@>C<oBM?JiR(eFI`;y!6zVmfa*_1B;`4 zsSxXPcIE#Bc(f6iKrD9BxQ`-q;%79(^*^0BG5Sp$t+t(d)>CK{^!)B9Zf zv7)-zvg{aYDm7V!0fiS|a+lNws!GA7LK9aYx#tX6b^02O@!n%|n^8>uio3RV0bzTp zJ%@-Py3gGrP!E>0{62Mg7T!rz0;4Lpqect}M4~i^hg|Kf@s+?aH zgy7V-iuIK!8vQ?bZh)*U{4CromKD)1#?f0cHkbg0>>_c-?8@dBLe8E+*6mV8RrNY= zao&BpDJ4xgdFu72=o5M2nlDy8wbl>uN1h`|X>0Us;*2%Hts%oM0y5~+Bh2JXFD(){}) + .block(); + //удаление метаданных + //удаление файла + client.delete() + .uri("http://source:8181/api/v1/storage/post/delete/" + id) + .retrieve() + .bodyToMono(new ParameterizedTypeReference (){}) + .block(); + + //переход на исходную страницу + String referer = request.getHeader("Referer"); + return "redirect:"+ referer; + } + @GetMapping("/delete{id}") - public String delete(@PathVariable Long id, + public String deleteById(@PathVariable Long id, HttpServletRequest request) { //удаление поста client.delete() diff --git a/face/src/main/java/gsp/technologies/face/controllers/face/v1/MainframeController.java b/face/src/main/java/gsp/technologies/face/controllers/face/v1/MainframeController.java index 83ae468..254d9d4 100644 --- a/face/src/main/java/gsp/technologies/face/controllers/face/v1/MainframeController.java +++ b/face/src/main/java/gsp/technologies/face/controllers/face/v1/MainframeController.java @@ -7,7 +7,6 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.core.ParameterizedTypeReference; -import org.springframework.core.env.Environment; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.web.bind.annotation.GetMapping; @@ -21,6 +20,7 @@ import gsp.technologies.face.models.Content; import gsp.technologies.face.models.ContentPage; import gsp.technologies.face.models.ContentRequest; import gsp.technologies.face.models.Post; +import gsp.technologies.face.services.LinksService; import gsp.technologies.face.teh.pagination.Page; @@ -31,22 +31,18 @@ public class MainframeController { @Autowired private WebClient client; - @Autowired - private Environment env; - // @Autowired - // private Storage storage; + @Autowired + private LinksService links; @GetMapping("") public String mainframe(Model model, @RequestParam(name = "postContentPage", required = false) ContentPage postContentPage) { log.info("GET /face/v1/mainframe"); - log.info("properties: "); - // String props = env.getProperty("links.storage.api.home"); - // log.info("links.storage.api.home: {}", props); - - - + log.info("********* properties ********* "); + // log.info("storage.api.home: {}", env.getProperty("storage.api.home")); + log.info("storage.api.home: {}", links.storageApiHome()); + log.info("face.api.home: {}", links.faceApiHome()); if (postContentPage == null) { //подготовка параметров запроса diff --git a/face/src/main/java/gsp/technologies/face/services/LinksFace.java b/face/src/main/java/gsp/technologies/face/services/LinksFace.java new file mode 100644 index 0000000..60c99e1 --- /dev/null +++ b/face/src/main/java/gsp/technologies/face/services/LinksFace.java @@ -0,0 +1,7 @@ +package gsp.technologies.face.services; + +public interface LinksFace { + + String storageApiHome(); + +} diff --git a/face/src/main/java/gsp/technologies/face/services/LinksService.java b/face/src/main/java/gsp/technologies/face/services/LinksService.java new file mode 100644 index 0000000..2fb0909 --- /dev/null +++ b/face/src/main/java/gsp/technologies/face/services/LinksService.java @@ -0,0 +1,149 @@ +package gsp.technologies.face.services; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.core.env.Environment; +import org.springframework.stereotype.Service; + +@Service +public class LinksService{ + + @Autowired + private Environment env; + + /** + * get links from env: storage + * @return + */ + + public String storageProtocol(){ + return env.getProperty("storage.protocol"); + } + + public String storageDomain(){ + return env.getProperty("storage.domain"); + } + + public String storagePort(){ + return env.getProperty("storage.port"); + } + + public String storageHello(){ + return env.getProperty("storage.hello"); + } + + + public String storageApiHome(){ + return env.getProperty("storage.api.home"); + } + + public String storageApiRoot(){ + return env.getProperty("storage.api.root"); + } + + public String storageApiFiles(){ + return env.getProperty("storage.api.files"); + } + + public String storageApiFileStore(){ + return env.getProperty("storage.api.file-store"); + } + + public String storageApiFileStoreMultiple(){ + return env.getProperty("storage.api.file-store-multiple"); + } + + public String storageApiFileDelete(){ + return env.getProperty("storage.api.file-delete"); + } + + public String storageApiFileDownload(){ + return env.getProperty("storage.api.file-download"); + } + + public String storageApiXlsxPage(){ + return env.getProperty("storage.api.xlsx-page"); + } + + public String storageApiDirectoryCreate(){ + return env.getProperty("storage.api.directory-create"); + } + + public String storageApiDirectoryDelete(){ + return env.getProperty("storage.api.directory-delete"); + } + + public String storageApiFileCreateEmpty(){ + return env.getProperty("storage.api.file-create-empty"); + } + + public String storageApiFileBytes(){ + return env.getProperty("storage.api.file-bytes"); + } + + public String storageFaceHome(){ + return env.getProperty("storage.face.home"); + } + public String storageFaceMainframe(){ + return env.getProperty("storage.face.mainframe"); + } + + public String storageFaceUploadFile(){ + return env.getProperty("storage.face.upload-file"); + } + + public String storageFaceUploadMultipleFiles(){ + return env.getProperty("storage.face.upload-multiple-files"); + } + + public String storageFaceDownloadFile(){ + return env.getProperty("storage.face.download-file"); + } + + public String storageFaceDeleteFile(){ + return env.getProperty("storage.face.delete-file"); + } + + public String storageFaceViewXlsx(){ + return env.getProperty("storage.face.view-xlsx"); + } + + /** + * Get links from env: face + * @return + */ + + public String faceProtocol(){ + return env.getProperty("face.protocol"); + } + public String faceDomain(){ + return env.getProperty("face.domain"); + } + public String facePort(){ + return env.getProperty("face.port"); + } + public String faceHello(){ + return env.getProperty("face.hello"); + } + public String faceApiHome(){ + return env.getProperty("face.api.home"); + } + public String faceApiUpload(){ + return env.getProperty("face.api.upload"); + } + + public String faceApiDownload(){ + return env.getProperty("face.api.download"); + } + public String faceFaceMainframe(){ + return env.getProperty("face.face.mainframe"); + } + public String faceFaceStorage(){ + return env.getProperty("face.face.storage"); + } + + /** + * get links from env: source + */ + + +} \ No newline at end of file diff --git a/face/src/main/resources/application-face.yaml b/face/src/main/resources/application-face.yaml new file mode 100644 index 0000000..9a5fefa --- /dev/null +++ b/face/src/main/resources/application-face.yaml @@ -0,0 +1,12 @@ +face: + protocol: http:// + domain: face + port: 8383 + hello: /hello + api: + home: /api/v1 + upload: /api/v1/upload + download: /api/v1/download + face: + mainframe: /face/v1/mainframe + storage: /face/v1/storage \ No newline at end of file diff --git a/face/src/main/resources/application-source.yaml b/face/src/main/resources/application-source.yaml new file mode 100644 index 0000000..e9c24cc --- /dev/null +++ b/face/src/main/resources/application-source.yaml @@ -0,0 +1,14 @@ +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 \ No newline at end of file diff --git a/face/src/main/resources/application-storage.yaml b/face/src/main/resources/application-storage.yaml new file mode 100644 index 0000000..2823d95 --- /dev/null +++ b/face/src/main/resources/application-storage.yaml @@ -0,0 +1,44 @@ +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 \ No newline at end of file diff --git a/face/src/main/resources/application.yaml b/face/src/main/resources/application.yaml index 8763713..13d5800 100644 --- a/face/src/main/resources/application.yaml +++ b/face/src/main/resources/application.yaml @@ -1,6 +1,9 @@ spring: - # config: - # import: classpath:/links.yaml + profiles: + include: + - face + - source + - storage application: name: face servlet: diff --git a/face/src/main/resources/links.yaml b/face/src/main/resources/links.yaml deleted file mode 100644 index 0f6be7e..0000000 --- a/face/src/main/resources/links.yaml +++ /dev/null @@ -1,69 +0,0 @@ -# Ссылки на ресурсы платформы -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: \ No newline at end of file