From 522b7efd2bb178c43e1697c02d9202c24f1fb70d Mon Sep 17 00:00:00 2001 From: Rajmund Bocsi Date: Wed, 17 Mar 2021 13:39:48 +0100 Subject: [PATCH 01/11] fixing alias pom changes (version, licence) --- client-skeleton-consumer/.classpath | 14 +++++++++---- client-skeleton-consumer/pom.xml | 2 +- .../src/main/resources/application.properties | 2 +- client-skeleton-provider/.classpath | 14 +++++++++---- client-skeleton-provider/pom.xml | 2 +- .../src/main/resources/application.properties | 2 +- client-skeleton-publisher/.classpath | 20 ++++++++++++------- client-skeleton-publisher/pom.xml | 2 +- client-skeleton-subscriber/.classpath | 14 +++++++++---- client-skeleton-subscriber/pom.xml | 2 +- pom.xml | 8 ++++---- 11 files changed, 53 insertions(+), 29 deletions(-) diff --git a/client-skeleton-consumer/.classpath b/client-skeleton-consumer/.classpath index fb22b95..8c720ae 100644 --- a/client-skeleton-consumer/.classpath +++ b/client-skeleton-consumer/.classpath @@ -21,21 +21,27 @@ - + + + - + - + + + - + + + diff --git a/client-skeleton-consumer/pom.xml b/client-skeleton-consumer/pom.xml index 5385160..d80ea8c 100644 --- a/client-skeleton-consumer/pom.xml +++ b/client-skeleton-consumer/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.4.1 arrowhead-client-skeleton-consumer diff --git a/client-skeleton-consumer/src/main/resources/application.properties b/client-skeleton-consumer/src/main/resources/application.properties index 014329d..492c239 100644 --- a/client-skeleton-consumer/src/main/resources/application.properties +++ b/client-skeleton-consumer/src/main/resources/application.properties @@ -27,7 +27,7 @@ server.ssl.enabled=true server.ssl.key-store-type=PKCS12 server.ssl.key-store=classpath:certificates/consumer_skeleton.p12 server.ssl.key-store-password=123456 -server.ssl.key-alias=consumerskeleton +server.ssl.key-alias=consumer_skeleton server.ssl.key-password=123456 server.ssl.client-auth=need server.ssl.trust-store-type=PKCS12 diff --git a/client-skeleton-provider/.classpath b/client-skeleton-provider/.classpath index fb22b95..8c720ae 100644 --- a/client-skeleton-provider/.classpath +++ b/client-skeleton-provider/.classpath @@ -21,21 +21,27 @@ - + + + - + - + + + - + + + diff --git a/client-skeleton-provider/pom.xml b/client-skeleton-provider/pom.xml index 04e5eec..3e9c258 100644 --- a/client-skeleton-provider/pom.xml +++ b/client-skeleton-provider/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.4.1 arrowhead-client-skeleton-provider diff --git a/client-skeleton-provider/src/main/resources/application.properties b/client-skeleton-provider/src/main/resources/application.properties index 7e8b8a9..10d38a8 100644 --- a/client-skeleton-provider/src/main/resources/application.properties +++ b/client-skeleton-provider/src/main/resources/application.properties @@ -30,7 +30,7 @@ token.security.filter.enabled=true server.ssl.key-store-type=PKCS12 server.ssl.key-store=classpath:certificates/provider_skeleton.p12 server.ssl.key-store-password=123456 -server.ssl.key-alias=providerskeleton +server.ssl.key-alias=provider_skeleton server.ssl.key-password=123456 server.ssl.client-auth=need server.ssl.trust-store-type=PKCS12 diff --git a/client-skeleton-publisher/.classpath b/client-skeleton-publisher/.classpath index 8690355..62a2bcf 100644 --- a/client-skeleton-publisher/.classpath +++ b/client-skeleton-publisher/.classpath @@ -16,27 +16,33 @@ - + + + - + - - + - + - + + - + + + + + diff --git a/client-skeleton-publisher/pom.xml b/client-skeleton-publisher/pom.xml index 49c69bf..3b97a6e 100644 --- a/client-skeleton-publisher/pom.xml +++ b/client-skeleton-publisher/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.4.1 arrowhead-client-skeleton-publisher diff --git a/client-skeleton-subscriber/.classpath b/client-skeleton-subscriber/.classpath index fb22b95..8c720ae 100644 --- a/client-skeleton-subscriber/.classpath +++ b/client-skeleton-subscriber/.classpath @@ -21,21 +21,27 @@ - + + + - + - + + + - + + + diff --git a/client-skeleton-subscriber/pom.xml b/client-skeleton-subscriber/pom.xml index 205d547..e72098b 100644 --- a/client-skeleton-subscriber/pom.xml +++ b/client-skeleton-subscriber/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.4.1 arrowhead-client-skeleton-subscriber diff --git a/pom.xml b/pom.xml index f5e0324..9e48f86 100644 --- a/pom.xml +++ b/pom.xml @@ -10,7 +10,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.4.1 pom client-skeleton-java-spring Arrowhead Client Skeleton using Spring Boot @@ -18,8 +18,8 @@ https://github.com/arrowhead-f/client-java-spring - Apache License, Version 2.0 - https://www.apache.org/licenses/LICENSE-2.0.txt + Eclipse Public License - v 2.0 + https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt @@ -34,7 +34,7 @@ eu.arrowhead client-library - 4.1.3.13 + 4.4.1 From d36b6b294c668260852c1e7e26e0d11675b04ef4 Mon Sep 17 00:00:00 2001 From: Rajmund Bocsi Date: Fri, 9 Apr 2021 13:56:56 +0200 Subject: [PATCH 02/11] no underscores in system names (and cloud names and operators) anymore newly generated certificates some code formatting --- README.md | 6 ++--- .../src/main/resources/application.properties | 6 ++--- .../certificates/consumer_skeleton.p12 | Bin 4365 -> 0 bytes .../certificates/consumerskeleton.p12 | Bin 0 -> 4355 bytes .../configuration/ContainerConfiguration.java | 5 ++-- .../security/ProviderSecurityConfig.java | 1 - .../src/main/resources/application.properties | 6 ++--- .../certificates/provider_skeleton.p12 | Bin 4365 -> 0 bytes .../certificates/providerskeleton.p12 | Bin 0 -> 4355 bytes .../PublisherApplicationInitListener.java | 12 +++------ .../configuration/ContainerConfiguration.java | 8 +++--- .../controller/PublisherController.java | 5 ++-- .../PublisherAccessControlFilter.java | 14 +++++------ .../security/PublisherSecurityConfig.java | 4 +-- .../publisher/service/PublisherService.java | 3 +-- .../src/main/resources/application.properties | 6 ++--- .../certificates/publisher_skeleton.p12 | Bin 6215 -> 0 bytes .../certificates/publisherskeleton.p12 | Bin 0 -> 4389 bytes .../SubscriberApplicationInitListener.java | 23 ++++++------------ .../subscriber/SubscriberUtilities.java | 6 ++--- .../configuration/ContainerConfiguration.java | 6 ++--- .../controller/SubscriberController.java | 12 ++++----- ...criberNotificationAccessControlFilter.java | 10 ++++---- .../security/SubscriberSecurityConfig.java | 6 +---- .../SubscriberTokenSecurityFilter.java | 6 ++--- .../src/main/resources/application.properties | 6 ++--- .../certificates/subscriber_skeleton.p12 | Bin 6217 -> 0 bytes .../certificates/subscriberskeleton.p12 | Bin 0 -> 4399 bytes 28 files changed, 62 insertions(+), 89 deletions(-) delete mode 100644 client-skeleton-consumer/src/main/resources/certificates/consumer_skeleton.p12 create mode 100644 client-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 delete mode 100644 client-skeleton-provider/src/main/resources/certificates/provider_skeleton.p12 create mode 100644 client-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 delete mode 100644 client-skeleton-publisher/src/main/resources/certificates/publisher_skeleton.p12 create mode 100644 client-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 delete mode 100644 client-skeleton-subscriber/src/main/resources/certificates/subscriber_skeleton.p12 create mode 100644 client-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 diff --git a/README.md b/README.md index 1755155..0f7d1b7 100644 --- a/README.md +++ b/README.md @@ -34,10 +34,10 @@ Each client skeleton has a default 'ApplicationInitListener' and a default 'Secu ##### (1st) application.properties Location: `src/main/resources` -* * Decide the required security level and set the `server.ssl.enabled` and `token.security.filter.enabled` properties accordingly. -* * If `token.security.filter.enabled` is true, `server.ssl.enabled` also has to be true !!! +* Decide the required security level and set the `server.ssl.enabled` and `token.security.filter.enabled` properties accordingly. +* If `token.security.filter.enabled` is true, `server.ssl.enabled` also has to be true !!! * [Create](https://github.com/arrowhead-f/core-java-spring#certificates) your own client certificate (or for demo purpose use the provided one) and update the further `server.ssl...` properties accordingly. *(**Note** that `server.ssl.key-store-password` and `server.ssl.key-password` must be the same.)* -* Change the `client_system_name` property to your system name. *(**Note** that it should be in line with your certificate common name e.g.: when your certificate common name is `my_awesome_client.my_cloud.my_company.arrowhed.eu`, then your system name is  `my_awesome_client`)* +* Change the `client_system_name` property to your system name. *(**Note** that it should be in line with your certificate common name e.g.: when your certificate common name is `my-awesome-client.my-cloud.my-company.arrowhed.eu`, then your system name is  `my-awesome-client`)* * Adjust the Service Registry Core System location by the `sr_address` and `sr_port` properties. * In case of a provider you have to set its web-server parameters by the `server.address` and `server.port` properties. * In case of a consumer decide whether it should act as a web-server or not. If yes, then set the `spring.main.web-application-type` to 'servlet' and set further server parameters like in the provider case. If not, just leave these properties unchanged. diff --git a/client-skeleton-consumer/src/main/resources/application.properties b/client-skeleton-consumer/src/main/resources/application.properties index 492c239..fa4286d 100644 --- a/client-skeleton-consumer/src/main/resources/application.properties +++ b/client-skeleton-consumer/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=CONSUMER_SKELETON +client_system_name=CONSUMERSKELETON # Set the web application type to 'servlet' if your consumer client should act as a web-server # and fill the address and port propetries with valid values [Defaults, when not adjusted: localhost:8080] @@ -25,9 +25,9 @@ sr_port=8443 server.ssl.enabled=true server.ssl.key-store-type=PKCS12 -server.ssl.key-store=classpath:certificates/consumer_skeleton.p12 +server.ssl.key-store=classpath:certificates/consumerskeleton.p12 server.ssl.key-store-password=123456 -server.ssl.key-alias=consumer_skeleton +server.ssl.key-alias=consumerskeleton server.ssl.key-password=123456 server.ssl.client-auth=need server.ssl.trust-store-type=PKCS12 diff --git a/client-skeleton-consumer/src/main/resources/certificates/consumer_skeleton.p12 b/client-skeleton-consumer/src/main/resources/certificates/consumer_skeleton.p12 deleted file mode 100644 index 3d4b8b6bf4914556548d92e3d734d8b6f28b1707..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4365 zcmY*ZWmFW5wjG86q!~h_YXA|1p@tHWZlpsQ>69E&kQ!1thn5&by1S)YIvfyDO6mB3 zk$T>@-n)0*AA6m>_CEXkI6pQN2_^*M;6jlUefWe=B2^;;hY4^i7eOQX#9CxM@)bos#BwHPw8Zj zuCP~Uu`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q8{OWO$g+2*`05b82q_~U?J6M%uoB+2_Z1ZYI96S+*>n$gd-+YVFP6nTgSny0~U za4b7`BVbg_$|(7}`LL2HwysbRD!z<}vcrkG`;sHCqkQ2ABXOQ(_-$+4BVi#L0f;RV{bMyN$S5Z7Gw}28n2c`#g<#c z&Y0ObIlRw2BD*yR*ZZT`_3o`brQel52J_@yFm~-Q)EMJK*@2d+#WVq^{_R8r>A@sB zD1&mkRK-pPuxCnLHXeVDjR-1s=8vB6u5pu*$-~P7nLYP<+DNpnb$y&poaynAvF&F; z;)hF08@U^@7lI+@8&5Yx9mpgT)!tU#-g^h18+;WNcpmS)!QpoB7UF0mhkfMC_i@!F z)Y?$CEWZ=43YjntJcVD6WYdSY$B6nzV9e8S(IvB2n=iN4@!DcOUoOL)W$Hy9hnHA4 zwvsd~5~%XNck~TZxhQ_}y2dh)%lU{>ttXde*f|x~e`Xky6&(L$<(h9*I!_)vHu6U% zU`CI9bS{a_9Ou4&!_>aPuYC?J-<3qNGJljj4T^itbApTky}>d5eb{m^{q7*;rtri~ z38DNoi`Q@A@ey7>`|I#*m->e%nPk&y7U00)=pE1E&CcICC}Q`M0drW}&wiP&ThXG<$KrZK$MU3B#2>M$B89!Kz5=&EbIX zxB+#aQ;sh@{si|5`txXzACH#|7f6o>08wAKJyXFF`6i#M qEWD+_qv9}U^h^a&e<@IZ#f(#*7Terg2v>o$1x7@M0C9053;qYBG)LP2 diff --git a/client-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 b/client-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 new file mode 100644 index 0000000000000000000000000000000000000000..d171004a9fb073ae406e18edb0c23ba30160a9de GIT binary patch literal 4355 zcmY*ZXE+-S+ZAHOrgrUFMI{JTTWvLJrS=}7cx<(zDM69ivqnY59#v|zsI6#gHi+0t z)!wzfzTfqI?|Z#J&UNnVocr8A?jHw?q`x5skbsf&Eo7j(C>_)(4S*a_jHIssBI)1$ zmEVAoq>=w+k@^6Uq@I6ex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kzDcR#qz}ahxw>BDGha{*ybdB4R%Rv-(b29#0$b>w`x*E2TcNx(E|F-J@_z} za}BDH`k+XFx+T8;VaBq6X4v`wbz2a_kz8-Gz~wU)rbkppKg`vN=8)3a+hy&Y9jD=k zY^Ez~I`>$kZmsi+Q)jJZ(<#qR@p_}xNj~?p^|W~hmj{pjHWg{3jit#Sdu%c;9ON z^uQ!%Lj1Y^LUv3pNqL-}BwFCtLR>eOR2xKeK zTET?orz4`DGPEACsBO|bje&M()%uFhJQBZUOQQn1L>+77i4xkj&$_m2t8vg6xtXk< zm6`Mm3(eiq$s3=y{xcbZwbEmo@;68Nt&{aGE9V(?ore(nk}tBs-Pg9^06~DIkhUe^ za@Q;^;t={+>TL_OG`Z2KXm#Z=G&N!Upi#P+=B2jrG^MSk;DxkPy0P#h%Ze-}Raqg5 z8%tYzQ)?k{#y-^xsnoPDOkK>T|CsL8c##~~mO38Z|tvI!R( z{=w~}taM=L7d1Mobj)LmsAi!^Ikmsw`Ha!5dgS&#pI`NqlyE4Fwr8wa+Q_d~lly*Z z`J{%9Hw6Nyd(hMn@gle{w<3)-<(d>z0tsUL5|8wAA#>0u0znthbqhIBEgh*IGaT)y|mqe4xKHHiM&q}#v>~C_^Mr(zCuQesXRDAPWLM2>1#8fa9G6l4~ z<z`n8m z<1W-~i#x3dt1^8= z%iXR@zFzM#1^xXOwbsk1&xevmqsD}T0hXiy z<p(7UtzoC{<>EIZ@V_praRW4iBbq2K~Ob+^nCYcoJ^-fGs~IC z>w!JBS#AaAQ3`%otI!w*0#*j|fk9-XVzea09Hc}*rZ+UpM%HWw!CHluTezlUK5H(B g36P26Jz*z`dPqc@NK!)I&!;s=TJoHj1b{039|5B<&j0`b literal 0 HcmV?d00001 diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java b/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java index 453f323..7cc7e67 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java +++ b/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java @@ -23,6 +23,7 @@ public class ContainerConfiguration implements WebServerFactoryCustomizer { @@ -30,7 +31,6 @@ public void customize(TomcatServletWebServerFactory factory) { protocol.setMaxKeepAliveRequests(containerConfProperties.getMaxKeepAliveRequests()); - // log.info("####################################################################################"); log.info("#"); log.info("# TomcatCustomizer"); @@ -41,8 +41,7 @@ public void customize(TomcatServletWebServerFactory factory) { log.info("# connection timeout: {} ms", protocol.getConnectionTimeout()); log.info("# max connections: {}", protocol.getMaxConnections()); log.info("#"); - log.info( - "####################################################################################"); + log.info("####################################################################################"); }); } diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java b/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java index 08cdca2..0d90221 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java +++ b/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java @@ -8,7 +8,6 @@ import eu.arrowhead.client.library.config.DefaultSecurityConfig; import eu.arrowhead.client.library.util.ClientCommonConstants; -import eu.arrowhead.common.CommonConstants; @Configuration @EnableWebSecurity diff --git a/client-skeleton-provider/src/main/resources/application.properties b/client-skeleton-provider/src/main/resources/application.properties index 10d38a8..82bf337 100644 --- a/client-skeleton-provider/src/main/resources/application.properties +++ b/client-skeleton-provider/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=PROVIDER_SKELETON +client_system_name=PROVIDERSKELETON # Client web-server parameters server.address=127.0.0.1 @@ -28,9 +28,9 @@ server.ssl.enabled=true token.security.filter.enabled=true server.ssl.key-store-type=PKCS12 -server.ssl.key-store=classpath:certificates/provider_skeleton.p12 +server.ssl.key-store=classpath:certificates/providerskeleton.p12 server.ssl.key-store-password=123456 -server.ssl.key-alias=provider_skeleton +server.ssl.key-alias=providerskeleton server.ssl.key-password=123456 server.ssl.client-auth=need server.ssl.trust-store-type=PKCS12 diff --git a/client-skeleton-provider/src/main/resources/certificates/provider_skeleton.p12 b/client-skeleton-provider/src/main/resources/certificates/provider_skeleton.p12 deleted file mode 100644 index 21a062735a9cb0145aff5d4aeeff0138a52d8eb4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4365 zcmY+EWmFW7w#A2G0O>|bx+I375s;7+kVZgy=U{GyoXUVfnXG|F{1>X9Ce6q!m|jg^jAw z-)3=lgH=jK6o(%IaRCE*AQ)&Ac!+-L<*UQ)@Yy6i_5>-jd|aCJ+{ECClhy|KTK7(* z3(>?GnJI0N<8)j5+w$2paqJ@IOm!`A1$CdZo-a*{a&Pf>l8XgfN)2}GjgLQZCCeur z6shVzEETn+Y&`nRm0&%rv?r`ryRFZdI2pTS_76o{KIn(<%(zU_5%rV-x~oWgduMI{ zAeM3RZudaSJLb8g-=tBJq0=i4@IUlZgY!HJn;$MJC{Cwv7BcsXWqoXvWhr&)^$d&(w2DL##=vYi)0?QQS~5Od|;pK!Pr@>^dc=F}#bgK?)rd$#M4m2n=q ziT~meRqxnB=Sa1q)nP_9)XH$GF*@>@JXt7?%DVdo>2crVM8BaHzO;jPmOzAA!C6wh zkt~%%R}IQ8ikFS%f;@Gj7_0duK zCxZU_s}J!;FL`DtuD(uJ(;?SLBn4zxC1@W@WTX4vRsk zM0?-%K9$;EucYWNF!h#h4oX`)Dc)gov44P)FcTa5-i07$UmjuS&Xz#>2 zGwU*G_pAgFG9L<1r%(J!WarBx6pEXis6!Uz>6?CWZl&pID8hofZ&mn_b^bm?8Mo+qrVXHEvpZ$9s(JC4#{e{}MZOu(f`mKNZ` zqykRExNsg#Wxp(*%Ig*px35hF@UQM5k(X^L8XiYxB1?3IIC{T5wUplK{V_Jq;#jFN zA2x3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;jWpj!`G= zCK^h5M#@G1GGGmfh*3}oqLE4&ehaANBuortF{eB)ggeN}ucH~EpK`@*)tG;c--6pH zf{mOq^OPR-+6L<3oiW7`+-M$$`iHo#dmJAjxYOJ#g+!{~NaQpM29r`%>%+KJlouOc zylc=-hRra{AuU=aMwH%Jr;#183d>-Ys&=P=W8DZYH4zV1${rk{hDytHK=*FMy6J#~ zkZ+hk-GU-;8z8n@q%9rYBrs&-p3q|C7=mAUJSSOjxM~ag=fNz^mH%QW1#=6Pt5|^0 z53Fm6Pg(LSb(3OiW-SMi`98(%T(SpG1?8BWwU`=6)yN90q^S1D{A$TEiGLVynYFEw^PG}GZzudtH}UM3-|%5;J^Wn8y?J)CrVWi) z*Er6yvrAj!IruXr&P59A7L0?|%ixQnd*|Z=)bV=9J%ilEmb_%fHcJEFkwlI)(Deyu zE^ls95*IS}y;R<(PhrFwVH*>6Uk|m?v0P1@Yd=u_+;B6@hTyy)c~4DGb8L_1j$?G2 zs4K!-?Y6=AM5ES@J^7tTwFI&VIiz?s(g4GrNWWDw;OCjU(KaiHxyr%reOb^a6Ab37 z>4m`E)xG~-LB=z1l(IlRcX^&uH-R4W;g{x{q%`;2{km8_%$}B<_W23H$Dj~6q&u?u zXZjF}*t=cA+DRX%ahJLoMSqw4ni#CXSJ9B`3d*;ZXcC#(r8VY+l3BDf)sFX|wlQw{ zWmlOp1ipwJq#*(=!};x2H3?&$;<9Ah3(&Qo$m7+b(6S0p@mhu#ZQ7bf$%~hUewjSfwqMajz-veT!~HbosGeMNWK9W6;q3%v>)Oid+WlICaVkwDCn#2V)o#TduT%uM zhV>2{)O&^5V?xSbC3+nDN)dg+Th=i%>Us*1hp#e6loc-U07v qwST)X>$pEsbBzu}vjn~ZvBs20o2L-y?o6hereYo{195TU-~S78emiUc diff --git a/client-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 b/client-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 new file mode 100644 index 0000000000000000000000000000000000000000..c5b579924f83f5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^QgXAC_x23Z*S}?oDQCj53@ z&%kN^wOS)7de}EeW3|ft++)7NDO><5C}BFef}oSev$fq=B^Dux>64!T7_%rkr*79EXojOyJ-Mg~Q9`^~K>>&&&Sxk^NWBl@F;=^p4gPmX#1 zx^CslA(YpYDm&*bb)|(1C=zF09$RXXq3~Qq>s3g|=5^_RBeeR@97J$vdf1O;%KR8| zZO-92jG26WVm?u;Vhtn(m_B;tN*Cd(PgKJWL#Y~F=|nL2h8b5>rhfM3qln*LvV_GqQ_n0IDgvMdcEcYH zYAO3w@y2GERGflRX}F2jBuO_m=097$UhWZibM6)ir#zpdQVFeHiCA7HbA9tVBjCF~hy69pzHkp_rz8<*QEA?GBsa?ZZkn4L-EXIDpJ60RogI;zCcA_| z!s6p7;*FL?Q*1h6k6~;u0$d0mDGrDp0svFH*J{+4#4zHCY4T65_^1?5G literal 0 HcmV?d00001 diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java index 807c971..ec3b239 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java @@ -66,7 +66,6 @@ public class PublisherApplicationInitListener extends ApplicationInitListener { //------------------------------------------------------------------------------------------------- @Override protected void customInit(final ContextRefreshedEvent event) { - //Checking the availability of necessary core systems checkCoreSystemReachability(CoreSystem.SERVICE_REGISTRY); @@ -77,13 +76,11 @@ protected void customInit(final ContextRefreshedEvent event) { arrowheadService.updateCoreServiceURIs(CoreSystem.AUTHORIZATION); setTokenSecurityFilter(); - - }else { + } else { logger.info("TokenSecurityFilter in not active"); } - if ( arrowheadService.echoCoreSystem(CoreSystem.EVENT_HANDLER) ) { - + if (arrowheadService.echoCoreSystem(CoreSystem.EVENT_HANDLER)) { arrowheadService.updateCoreServiceURIs(CoreSystem.EVENT_HANDLER); publishInitStartedEvent(); @@ -103,7 +100,6 @@ public void customDestroy() { //------------------------------------------------------------------------------------------------- private void setTokenSecurityFilter() { - final PublicKey authorizationPublicKey = arrowheadService.queryAuthorizationPublicKey(); if (authorizationPublicKey == null) { throw new ArrowheadException("Authorization public key is null"); @@ -113,7 +109,7 @@ private void setTokenSecurityFilter() { try { keystore = KeyStore.getInstance(sslProperties.getKeyStoreType()); keystore.load(sslProperties.getKeyStore().getInputStream(), sslProperties.getKeyStorePassword().toCharArray()); - } catch (KeyStoreException | NoSuchAlgorithmException | CertificateException | IOException ex) { + } catch (final KeyStoreException | NoSuchAlgorithmException | CertificateException | IOException ex) { throw new ArrowheadException(ex.getMessage()); } final PrivateKey publisherPrivateKey = Utilities.getPrivateKey(keystore, sslProperties.getKeyPassword()); @@ -144,4 +140,4 @@ private void publishInitStartedEvent() { arrowheadService.publishToEventHandler(publishRequestDTO); } -} +} \ No newline at end of file diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java index 11abc83..35fd5a6 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java @@ -17,12 +17,13 @@ public class ContainerConfiguration implements WebServerFactoryCustomizer { @@ -30,7 +31,6 @@ public void customize(TomcatServletWebServerFactory factory) { protocol.setMaxKeepAliveRequests(containerConfProperties.getMaxKeepAliveRequests()); - // log.info("####################################################################################"); log.info("#"); log.info("# TomcatCustomizer"); @@ -41,9 +41,7 @@ public void customize(TomcatServletWebServerFactory factory) { log.info("# connection timeout: {} ms", protocol.getConnectionTimeout()); log.info("# max connections: {}", protocol.getMaxConnections()); log.info("#"); - log.info( - "####################################################################################"); + log.info("####################################################################################"); }); } - } \ No newline at end of file diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java index 006fb9f..5593fb6 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java @@ -33,12 +33,11 @@ public class PublisherController { public String echoService() { logger.debug("echoService started..."); - publisherService.publish(PresetEventType.REQUEST_RECEIVED, Map.of( EventTypeConstants.EVENT_TYPE_REQUEST_RECEIVED_METADATA_REQUEST_TYPE, HttpMethod.GET.name() ), CommonConstants.ECHO_URI); + publisherService.publish(PresetEventType.REQUEST_RECEIVED, Map.of(EventTypeConstants.EVENT_TYPE_REQUEST_RECEIVED_METADATA_REQUEST_TYPE, HttpMethod.GET.name()), CommonConstants.ECHO_URI); return "Got it!"; } //------------------------------------------------------------------------------------------------- //TODO: implement here your provider related REST end points - -} +} \ No newline at end of file diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java index c6aaf88..7f08659 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java @@ -13,10 +13,10 @@ @ConditionalOnExpression(CommonConstants.$SERVER_SSL_ENABLED_WD + " and !" + ClientCommonConstants.$TOKEN_SECURITY_FILTER_ENABLED_WD) public class PublisherAccessControlFilter extends AccessControlFilter { -@Override -protected void checkClientAuthorized(final String clientCN, final String method, final String requestTarget, final String requestJSON, final Map queryParams) { - super.checkClientAuthorized(clientCN, method, requestTarget, requestJSON, queryParams); - - //TODO: implement here your custom access filter if any further -} -} + @Override + protected void checkClientAuthorized(final String clientCN, final String method, final String requestTarget, final String requestJSON, final Map queryParams) { + super.checkClientAuthorized(clientCN, method, requestTarget, requestJSON, queryParams); + + //TODO: implement here your custom access filter if any further + } +} \ No newline at end of file diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java index 37fb9ca..00f8559 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java @@ -30,7 +30,7 @@ protected void configure(HttpSecurity http) throws Exception { super.configure(http); if (tokenSecurityFilterEnabled) { tokenSecurityFilter = new PublisherTokenSecurityFilter(); - http.addFilterAfter(tokenSecurityFilter, SecurityContextHolderAwareRequestFilter.class); + http.addFilterAfter(tokenSecurityFilter, SecurityContextHolderAwareRequestFilter.class); } } @@ -38,4 +38,4 @@ protected void configure(HttpSecurity http) throws Exception { public PublisherTokenSecurityFilter getTokenSecurityFilter() { return tokenSecurityFilter; } -} +} \ No newline at end of file diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java index a23cfe3..20cd646 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java @@ -47,7 +47,6 @@ public class PublisherService { //------------------------------------------------------------------------------------------------- //Sample implementation of event publishing of preset event types public void publish(final PresetEventType eventType, final Map metadata, final String payload) { - final EventPublishRequestDTO request = getPublishRequest(eventType, metadata, payload); arrowheadService.publishToEventHandler(request); } @@ -78,4 +77,4 @@ private SystemRequestDTO getSource() { return source; } -} +} \ No newline at end of file diff --git a/client-skeleton-publisher/src/main/resources/application.properties b/client-skeleton-publisher/src/main/resources/application.properties index d794cb2..ddbdfd8 100644 --- a/client-skeleton-publisher/src/main/resources/application.properties +++ b/client-skeleton-publisher/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=PUBLISHER_SKELETON +client_system_name=PUBLISHERSKELETON # Client web-server parameters server.address=127.0.0.1 @@ -25,9 +25,9 @@ server.ssl.enabled=true token.security.filter.enabled=false server.ssl.key-store-type=PKCS12 -server.ssl.key-store=classpath:certificates/publisher_skeleton.p12 +server.ssl.key-store=classpath:certificates/publisherskeleton.p12 server.ssl.key-store-password=123456 -server.ssl.key-alias=publisher_skeleton +server.ssl.key-alias=publisherskeleton server.ssl.key-password=123456 server.ssl.client-auth=need server.ssl.trust-store-type=PKCS12 diff --git a/client-skeleton-publisher/src/main/resources/certificates/publisher_skeleton.p12 b/client-skeleton-publisher/src/main/resources/certificates/publisher_skeleton.p12 deleted file mode 100644 index 3a5840d30bc5101ef1966e6325aafabf06e0bf6a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6215 zcmY*cRZJWJkX>Yv;_mM5#i3YnXp!RX?p9!drT9XTV#Td!ac6NWvbYsrT#6KTu6H@f zW%4qU_h#m2l9voGm{blC0f`q(@`QrU9;p<0i-mxSkPjv~K?ai?{-bw!!N9QpCjmW? z!9dr4wBtY6qG0^@6y_TQ#C$OFBQF^FmX{6X&HvE39`}NiL?6)trl(^baBpl7PuF2NmqXFFSx=Gnv8B%bsyb` zxx;8Is=Nb=%Ykwzyy+>BDCj!(& zY8Tz3@p1>fTcos{+YXMi4F^r>|9}jBnfefr;`?;YBdRlQ&FCPUwib={J}1QDnz;gq zxO$)WfgCz;5|_7>oND2yl8730_2RA(8c~lA&RfPPQ~B*5$<_aMoli3i)#Mei&B;*@PJ?tHW;(^ z79RF&Z)>4X9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I_mzoc zNu{B*OmqFY>CR!Y^|&P=5kqGmbyFu~A5-c01LpMC=QX5q1%$8FDEh;N-%zxGMdGxG zqX4V!9GSr3qnLb~{4ur&YE+VlLrontb_U}#Rhc(>3KqWf&) zy&|L6Z$b~}Ze1L29C{w?O%gTBx5-pvpMh5r6OnIKvqdY5*%IJXndiAqxj7N@f0>c2 z9eJ$ZHRfnPlXXS@{H(sch>_oxX)fxsfZCibqTIO`FH2G>ab-{6WR-&7OH?;UC#0!u zV!GYe)rFNp>WLo7;2?ce{^`f&*d1%@bTEbLCZ9Lrv2-7{{HpM3*vr)WyW46`!a(z6 zP;6&?BwmmAatF6p73 zqsfw<%75qU4(GA3DDoFgxj6`Gr69kIUBHRArb3~x=TT^1G zkineIDS>@Rs9Ae|hK}14`%>NH|T;I9? diff --git a/client-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 b/client-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 new file mode 100644 index 0000000000000000000000000000000000000000..c7c0a7a4b7444e2f67bad30129aee1b064bc539f GIT binary patch literal 4389 zcmY+EWmFW5x`l^f7^I}TyJ6_@qZ^bK7#it@0R-t7YUmJT0I5NcknZkoNdW;VLAq7K z*IsMycfUU$2!fayh=B<~5Uqf5c%s#!ZwWB4F$xew;~)gl@ZY!}g1`#> zuL=teLSVW6jUE5W7L50QD|}oGU;zSj2SI>tA>3fx|BwGZrv;G(o>r4V_tC0^!_Dmq z`^Ztzh$(y^CZJyjgaD1`J$)nsz$0_KaV2pncjf=w0d5zS>&7iRi&u-zpo$wGQ`qp_ zZnl^<_2tAyX1kq!UTs|2&3jJfUs*0#FaXyL@`SesS(?a=fnbWA?ijXXw*#{fpFQ=R zq=v{fZA$+#g%to*FUxZ+SWbm6!m#?Tj_$mXGt`Yse4Y>|!;pip1+iTqBPUbg} z#PDN69SvJ#-NFMj;G@D|P#JR>SiTvnmrACH%A5=Tj4* z-72da6wQ5T(fT@=lDhDk=jzKHqkaxdq$7rH)Ht&*K7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H&^ja6bJ2{4gUzKo#_Vv JF)^YG{sngLE(ZVr literal 0 HcmV?d00001 diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java index 0f273cc..7b097f0 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java @@ -66,7 +66,6 @@ public class SubscriberApplicationInitListener extends ApplicationInitListener { //------------------------------------------------------------------------------------------------- @Override protected void customInit(final ContextRefreshedEvent event) { - //Checking the availability of necessary core systems checkCoreSystemReachability(CoreSystem.SERVICE_REGISTRY); @@ -74,7 +73,6 @@ protected void customInit(final ContextRefreshedEvent event) { arrowheadService.updateCoreServiceURIs(CoreSystem.ORCHESTRATOR); if (sslEnabled) { - if (tokenSecurityFilterEnabled) { checkCoreSystemReachability(CoreSystem.AUTHORIZATION); @@ -82,17 +80,14 @@ protected void customInit(final ContextRefreshedEvent event) { arrowheadService.updateCoreServiceURIs(CoreSystem.AUTHORIZATION); setTokenSecurityFilter(); - } else { logger.info("TokenSecurityFilter in not active"); } setNotificationFilter(); - } - - if ( arrowheadService.echoCoreSystem(CoreSystem.EVENT_HANDLER)) { + if (arrowheadService.echoCoreSystem(CoreSystem.EVENT_HANDLER)) { arrowheadService.updateCoreServiceURIs(CoreSystem.EVENT_HANDLER); subscribeToPresetEvents(); } @@ -104,9 +99,8 @@ protected void customInit(final ContextRefreshedEvent event) { //------------------------------------------------------------------------------------------------- @Override public void customDestroy() { - final Map eventTypeMap = configEventProperites.getEventTypeURIMap(); - if( eventTypeMap == null) { + if (eventTypeMap == null) { logger.info("No preset events to unsubscribe."); } else { for (final String eventType : eventTypeMap.keySet()) { @@ -120,7 +114,6 @@ public void customDestroy() { //------------------------------------------------------------------------------------------------- private void setTokenSecurityFilter() { - final PublicKey authorizationPublicKey = arrowheadService.queryAuthorizationPublicKey(); if (authorizationPublicKey == null) { throw new ArrowheadException("Authorization public key is null"); @@ -130,7 +123,7 @@ private void setTokenSecurityFilter() { try { keystore = KeyStore.getInstance(sslProperties.getKeyStoreType()); keystore.load(sslProperties.getKeyStore().getInputStream(), sslProperties.getKeyStorePassword().toCharArray()); - } catch (KeyStoreException | NoSuchAlgorithmException | CertificateException | IOException ex) { + } catch (final KeyStoreException | NoSuchAlgorithmException | CertificateException | IOException ex) { throw new ArrowheadException(ex.getMessage()); } final PrivateKey subscriberPrivateKey = Utilities.getPrivateKey(keystore, sslProperties.getKeyPassword()); @@ -140,15 +133,13 @@ private void setTokenSecurityFilter() { subscriberSecurityConfig.getTokenSecurityFilter().setEventTypeMap( eventTypeMap ); subscriberSecurityConfig.getTokenSecurityFilter().setAuthorizationPublicKey(authorizationPublicKey); subscriberSecurityConfig.getTokenSecurityFilter().setMyPrivateKey(subscriberPrivateKey); - } //------------------------------------------------------------------------------------------------- private void subscribeToPresetEvents() { - final Map eventTypeMap = configEventProperites.getEventTypeURIMap(); - if(eventTypeMap == null) { + if (eventTypeMap == null) { logger.info("No preset events to subscribe."); } else { final SystemRequestDTO subscriber = new SystemRequestDTO(); @@ -168,8 +159,8 @@ private void subscribeToPresetEvents() { try { arrowheadService.subscribeToEventHandler(SubscriberUtilities.createSubscriptionRequestDTO(eventType, subscriber, eventTypeMap.get(eventType))); - } catch ( final InvalidParameterException ex) { - if( ex.getMessage().contains("Subscription violates uniqueConstraint rules")) { + } catch (final InvalidParameterException ex) { + if (ex.getMessage().contains("Subscription violates uniqueConstraint rules")) { logger.debug("Subscription is already in DB"); } } catch (final Exception ex) { @@ -188,4 +179,4 @@ private void setNotificationFilter() { subscriberSecurityConfig.getNotificationFilter().setEventTypeMap( eventTypeMap ); subscriberSecurityConfig.getNotificationFilter().setServerCN(arrowheadService.getServerCN()); } -} +} \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java index ead7adb..ebe75e1 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java @@ -11,7 +11,6 @@ public class SubscriberUtilities { //------------------------------------------------------------------------------------------------- public static SubscriptionRequestDTO createSubscriptionRequestDTO(final String eventType, final SystemRequestDTO subscriber, final String notificationUri) { - final SubscriptionRequestDTO subscription = new SubscriptionRequestDTO(eventType.toUpperCase(), subscriber, null, @@ -19,7 +18,8 @@ public static SubscriptionRequestDTO createSubscriptionRequestDTO(final String e false, null, null, - null); + null); + return subscription; } -} +} \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java index 4a39cdb..662ecfb 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java @@ -23,6 +23,7 @@ public class ContainerConfiguration implements WebServerFactoryCustomizer { @@ -30,7 +31,6 @@ public void customize(TomcatServletWebServerFactory factory) { protocol.setMaxKeepAliveRequests(containerConfProperties.getMaxKeepAliveRequests()); - // log.info("####################################################################################"); log.info("#"); log.info("# TomcatCustomizer"); @@ -41,9 +41,7 @@ public void customize(TomcatServletWebServerFactory factory) { log.info("# connection timeout: {} ms", protocol.getConnectionTimeout()); log.info("# max connections: {}", protocol.getMaxConnections()); log.info("#"); - log.info( - "####################################################################################"); + log.info("####################################################################################"); }); } - } \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java index c7e14dd..bfc01de 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java @@ -36,7 +36,7 @@ public String echoService() { public void receivePublisherReceivedRequestEvent(@RequestBody final EventDTO event ) { logger.debug("receivePublisherReceivedRequestEvent started..."); - if( event.getEventType() == null) { + if (event.getEventType() == null) { logger.debug("EventType is null."); } @@ -45,10 +45,10 @@ public void receivePublisherReceivedRequestEvent(@RequestBody final EventDTO eve //------------------------------------------------------------------------------------------------- @PostMapping(path = SubscriberConstants.START_INIT_NOTIFICATION_URI) - public void receivePublsisherStartedInitEvent(@RequestBody final EventDTO event) { + public void receivePublisherStartedInitEvent(@RequestBody final EventDTO event) { logger.debug("receivePublsisherStartedInitEvent started... "); - if( event.getEventType() == null) { + if (event.getEventType() == null) { logger.debug("EventType is null."); } @@ -57,10 +57,10 @@ public void receivePublsisherStartedInitEvent(@RequestBody final EventDTO event) //------------------------------------------------------------------------------------------------- @PostMapping(path = SubscriberConstants.START_RUN_NOTIFICATION_URI) - public void receivePublsisherStartedRunEvent(@RequestBody final EventDTO event ) { + public void receivePublisherStartedRunEvent(@RequestBody final EventDTO event ) { logger.debug("receivePublsisherStartedRunEvent started... "); - if( event.getEventType() == null) { + if (event.getEventType() == null) { logger.debug("EventType is null."); } @@ -69,4 +69,4 @@ public void receivePublsisherStartedRunEvent(@RequestBody final EventDTO event ) //------------------------------------------------------------------------------------------------- //TODO: implement here additional subscriber related REST end points -} +} \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java index ab21e18..e4b1a7a 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java @@ -39,9 +39,6 @@ public class SubscriberNotificationAccessControlFilter extends ArrowheadFilter { public void setEventTypeMap( final Map eventTypeMap) { this.eventTypeMap = eventTypeMap;} public void setServerCN( final String serverCN) { this.serverCN = serverCN; } - //================================================================================================= - // assistant methods - //------------------------------------------------------------------------------------------------- @Override public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain) throws IOException, ServletException { @@ -53,7 +50,7 @@ public void doFilter(final ServletRequest request, final ServletResponse respons if (eventTypeMap != null) { for (final String notificationUri : eventTypeMap.values()) { - if (requestTarget.endsWith( SubscriberDefaults.DEFAULT_EVENT_NOTIFICATION_BASE_URI + "/" + notificationUri )) { + if (requestTarget.endsWith(SubscriberDefaults.DEFAULT_EVENT_NOTIFICATION_BASE_URI + "/" + notificationUri)) { checkIfClientIsAnAllowedCoreSystem(getCertificateCNFromRequest(httpRequest), getServerCloudCN(serverCN), allowedCoreSystemsForSendingNotification, requestTarget); } } @@ -65,6 +62,9 @@ public void doFilter(final ServletRequest request, final ServletResponse respons chain.doFilter(request, response); } + //================================================================================================= + // assistant methods + //------------------------------------------------------------------------------------------------- @Nullable private String getCertificateCNFromRequest(final HttpServletRequest request) { @@ -108,4 +108,4 @@ protected String getServerCloudCN( final String serverCN ) { return serverFields[1]; } -} +} \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java index 41f0013..8f13f9f 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java @@ -35,16 +35,13 @@ protected void configure( final HttpSecurity http) throws Exception { super.configure(http); if (sslEnabled) { - notificationFilter = new SubscriberNotificationAccessControlFilter(); http.addFilterBefore( notificationFilter , SecurityContextHolderAwareRequestFilter.class ); - if (tokenSecurityFilterEnabled) { tokenSecurityFilter = new SubscriberTokenSecurityFilter(); http.addFilterAfter(tokenSecurityFilter, SecurityContextHolderAwareRequestFilter.class); } - } } @@ -57,5 +54,4 @@ public SubscriberTokenSecurityFilter getTokenSecurityFilter() { public SubscriberNotificationAccessControlFilter getNotificationFilter() { return notificationFilter; } - -} +} \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java index 89f590e..ea1d46a 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java @@ -72,7 +72,7 @@ public void doFilter(final ServletRequest request, final ServletResponse respons if (eventTypeMap != null) { for (final String notificationUri : eventTypeMap.values()) { - if ( requestTarget.endsWith(SubscriberDefaults.DEFAULT_EVENT_NOTIFICATION_BASE_URI + "/" + notificationUri)) { + if (requestTarget.endsWith(SubscriberDefaults.DEFAULT_EVENT_NOTIFICATION_BASE_URI + "/" + notificationUri)) { chain.doFilter(request, response); return; } @@ -92,7 +92,6 @@ public void doFilter(final ServletRequest request, final ServletResponse respons } checkToken(clientCN, token, requestTarget); - } catch (final ArrowheadException ex) { handleException(ex, response); } @@ -112,5 +111,4 @@ private String getCertificateCNFromRequest(final HttpServletRequest request) { return null; } - -} +} \ No newline at end of file diff --git a/client-skeleton-subscriber/src/main/resources/application.properties b/client-skeleton-subscriber/src/main/resources/application.properties index 792e5ac..9aa1587 100644 --- a/client-skeleton-subscriber/src/main/resources/application.properties +++ b/client-skeleton-subscriber/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=SUBSCRIBER_SKELETON +client_system_name=SUBSCRIBERSKELETON # Client web-server parameters server.address=127.0.0.1 @@ -38,9 +38,9 @@ server.ssl.enabled=true token.security.filter.enabled=true server.ssl.key-store-type=PKCS12 -server.ssl.key-store=classpath:certificates/subscriber_skeleton.p12 +server.ssl.key-store=classpath:certificates/subscriberskeleton.p12 server.ssl.key-store-password=123456 -server.ssl.key-alias=subscriber_skeleton +server.ssl.key-alias=subscriberskeleton server.ssl.key-password=123456 server.ssl.client-auth=need server.ssl.trust-store-type=PKCS12 diff --git a/client-skeleton-subscriber/src/main/resources/certificates/subscriber_skeleton.p12 b/client-skeleton-subscriber/src/main/resources/certificates/subscriber_skeleton.p12 deleted file mode 100644 index f5f968196de38c3cf6625f1fb40a4621a73ef944..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6217 zcmY*dRa6uJuw9m=8|emFTIrDPF6me)>F$zTN?205V*x=rrKP*O6j-{E4#DSp=f!y+ zGjr!oeBN_rxS(WmKqO=?DCr9-23w?Ja^mD(3&t|CUpNh>U$Ux6dVRq87?-t8WGVU{7Rw z-~*8XeVQOBXxO4NTu3S~sDa&rIZ^U`Q?B-1Lw_ySSmAe*n~X?|=FAuMj%7`=55cFZ zF)C5+8&_-HQpQ^XrenGofx4vb1&ksXv6}=D;9lF>+ZFwn?cVnByf+tVaq?GEWpjQ% z**;JyvH5UkC9~o?)}prQ;rD>CUM^ooR|WK*Ju{m+cex>|}F1;&hji{MSXPQJc^;{k!rR|c#g0!k^aN!wq(F@9lp-XJ6Fl$}q%ErSZJ2(D1PJqBfP zZE6PbrYVE9Z#>rx(nysLWC3m^dW}sWt44PQ8fAGNd3H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5WtD_N|U z&za70QZQlFzvK9bFnkZJSM$Zb8V!C$hhsApE?`q(X;0d1WNH|6uxw@cNS@Jr?L!dr?H5i8XL{sm`mly@%}b`eS(;pWo+0 zIVP8iMWn5{wO>8m&TJC3NCzXC7kLU$Y~dFT#~xyCa(x#i>922&584^SulBPNf2GZr z!4bbsj*9m9#cAe5jpbCpUB^*oo4WW$pCTLS@IkhIh+|xG1b~%QHv@5%Wnb>IlAict z2Oi@rDp&D%?{ahd?=@JwlD>+EnK!gVN}Z{toDG9=1^*iRcnz93mNt8;h2(1HKj>jJmbM`bVg}? z^+j3FsyB4-nZ~nrU}W;?5D;xi6^yKtwfROwy2Hn#Y~&aI=Nr@#IJTd|=BR|? zH%f`kysx#RSY9t;@!JyH1&K5o!jBF+_7+(uF)Xtpap~F9Qab40hQ-fS300=1_gdAM zd`kzJ;PoA!8j}VeE)=}$)MC9r%km+vJSQ>daP>(fJc_;6z_0=sz2;GPE@xA{V|}qg z*zzp=^jEa*b^Ie4zoY(VIlXk?h<|)4xR2OO58u$;1PlqiX8tYy`9-(T+?MXr^=IG) zS?N-|x}yHuihyEf6{w+mAvwFD_|xQk`na}kc79%c@J;@$qNV?wNUYsFv8mFgBbPWA zJr@Ql3Og<`kOBn&B1&jr2mh74aU=L@+ULEV>a<%$y9pxVB+d<@gKhnFiUwNdq9;Yi NE#Dvmk&z+`{sX0Y=!yUU diff --git a/client-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 b/client-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 new file mode 100644 index 0000000000000000000000000000000000000000..24084004c8eebdf71a3dce248d68762d2a5fdada GIT binary patch literal 4399 zcmY*ZXFMAY*9{^@>`<#lZQ5w8#%OICYAd0Lp!VJrMeNav-I}qg)Tr6U-m7-4zg22S zshU;A<9&bc`#itr!@cMJ&bjA)xE~G-Lw}c;hy;eATL)2yL?fclsENpka2UF2Ack(@ zh8}@oNW=e2BJ~1dNZoE|r<<|^f&b4%MM*@A!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jJr&?6 z3CJQ|J9@lWH>c|DR^VSgL=(YlPWjhZe`$nSY@|wF&mF2Z$U>JA*K<^$`pIH96Fv2w zkDh%Q$)2CTa~TFGB`EQe%n(Z&+b$HHXy`5lSh)UW&g)2FI!V_lU(>dD2aa+llXf4I zwtUWwykiw+R~0nK6FZU^|1P@n65qY+rPeK34UHqS@=A#p%HjQVa(^|jDcnmDV%yJB zTO2>H$uD}~*TKEeot(woaLHFcco&+2yV zQwFiM$;^_fZbO~dxrV@AAS(!(85_H(yl5sTNZC7wdPKh~5RE8rF>o(CUA~2^_$LQ{w>A~@4)RDmuX+@=f6738SSG{v^9a8sjvG&ysItxN2fJBedr=l z)juO z9QYidAt}XxUf)-}PBd+8GC-9IuoI=oC&RwcS$a{14@oNfs5B52(r(9~jgb_T6^rN@ zMm%A%Nxf=GYq_eXDYUKCdzqUuUCRUcD)lGRps=ASMD{B{UU)o&fIfhg8?TOMPl zM=M`Yn{A0$_YPGtQ~s06^o1aM_GS4>*Y&w+l4N@|rw6Z#4dhX(r_L*@){)`2_`C8^ zP2`@-B*`T-+I@jsjQvr;Wy37P<14x!$PCRsup#Xmv;y}=A7S774mSybkz~KMub4$O zCS(0hfkMH(tT998OL`}Fvy{cs)A6>Fe%5j2L=@r*0GR(s?a5~k59&mJw}w?SrH=t| zrT6Ha24V8BJ1`0m>0KHUVm49$kdY|s-duQ@VeAlzh9!GJ*=-4zV1FQ^+NGjsoY^!? V=35n|9ud(8fD)3An1m=A_b(7jM9KgF literal 0 HcmV?d00001 From 37530bb0cb3d1b48f5db2bd01be13ba790d406fb Mon Sep 17 00:00:00 2001 From: Rajmund Bocsi Date: Mon, 19 Apr 2021 15:53:16 +0200 Subject: [PATCH 03/11] adjust skeletons to changes in constants and enums --- .../skeleton/consumer/ConsumerApplicationInitListener.java | 2 +- .../skeleton/provider/ProviderApplicationInitListener.java | 2 +- .../publisher/PublisherApplicationInitListener.java | 6 +++--- .../subscriber/SubscriberApplicationInitListener.java | 6 +++--- .../security/SubscriberNotificationAccessControlFilter.java | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java b/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java index 74158b6..0789f4d 100644 --- a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java +++ b/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java @@ -29,7 +29,7 @@ public class ConsumerApplicationInitListener extends ApplicationInitListener { protected void customInit(final ContextRefreshedEvent event) { //Checking the availability of necessary core systems - checkCoreSystemReachability(CoreSystem.SERVICE_REGISTRY); + checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); checkCoreSystemReachability(CoreSystem.ORCHESTRATOR); diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java b/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java index f92a44b..7c80394 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java +++ b/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java @@ -52,7 +52,7 @@ public class ProviderApplicationInitListener extends ApplicationInitListener { protected void customInit(final ContextRefreshedEvent event) { //Checking the availability of necessary core systems - checkCoreSystemReachability(CoreSystem.SERVICE_REGISTRY); + checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); if (sslEnabled && tokenSecurityFilterEnabled) { checkCoreSystemReachability(CoreSystem.AUTHORIZATION); diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java index ec3b239..b8a553f 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java +++ b/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java @@ -67,7 +67,7 @@ public class PublisherApplicationInitListener extends ApplicationInitListener { @Override protected void customInit(final ContextRefreshedEvent event) { //Checking the availability of necessary core systems - checkCoreSystemReachability(CoreSystem.SERVICE_REGISTRY); + checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); if (sslEnabled && tokenSecurityFilterEnabled) { checkCoreSystemReachability(CoreSystem.AUTHORIZATION); @@ -80,8 +80,8 @@ protected void customInit(final ContextRefreshedEvent event) { logger.info("TokenSecurityFilter in not active"); } - if (arrowheadService.echoCoreSystem(CoreSystem.EVENT_HANDLER)) { - arrowheadService.updateCoreServiceURIs(CoreSystem.EVENT_HANDLER); + if (arrowheadService.echoCoreSystem(CoreSystem.EVENTHANDLER)) { + arrowheadService.updateCoreServiceURIs(CoreSystem.EVENTHANDLER); publishInitStartedEvent(); } diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java index 7b097f0..e725161 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java @@ -67,7 +67,7 @@ public class SubscriberApplicationInitListener extends ApplicationInitListener { @Override protected void customInit(final ContextRefreshedEvent event) { //Checking the availability of necessary core systems - checkCoreSystemReachability(CoreSystem.SERVICE_REGISTRY); + checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); checkCoreSystemReachability(CoreSystem.ORCHESTRATOR); arrowheadService.updateCoreServiceURIs(CoreSystem.ORCHESTRATOR); @@ -87,8 +87,8 @@ protected void customInit(final ContextRefreshedEvent event) { setNotificationFilter(); } - if (arrowheadService.echoCoreSystem(CoreSystem.EVENT_HANDLER)) { - arrowheadService.updateCoreServiceURIs(CoreSystem.EVENT_HANDLER); + if (arrowheadService.echoCoreSystem(CoreSystem.EVENTHANDLER)) { + arrowheadService.updateCoreServiceURIs(CoreSystem.EVENTHANDLER); subscribeToPresetEvents(); } diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java index e4b1a7a..762b437 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java +++ b/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java @@ -26,7 +26,7 @@ public class SubscriberNotificationAccessControlFilter extends ArrowheadFilter { //================================================================================================= // members - private static final CoreSystem[] allowedCoreSystemsForSendingNotification = { CoreSystem.EVENT_HANDLER }; + private static final CoreSystem[] allowedCoreSystemsForSendingNotification = { CoreSystem.EVENTHANDLER }; private Map eventTypeMap; private String serverCN; From de1ba6b59051256d5127b7a2be3de6394b1a381a Mon Sep 17 00:00:00 2001 From: Tamas Bordi Date: Tue, 20 Apr 2021 16:54:31 +0200 Subject: [PATCH 04/11] upgrade to client-library v4.3.0.0 --- client-skeleton-consumer/pom.xml | 2 +- client-skeleton-provider/pom.xml | 2 +- client-skeleton-publisher/pom.xml | 2 +- client-skeleton-subscriber/pom.xml | 2 +- pom.xml | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/client-skeleton-consumer/pom.xml b/client-skeleton-consumer/pom.xml index 5385160..5c3607e 100644 --- a/client-skeleton-consumer/pom.xml +++ b/client-skeleton-consumer/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.3.0.0 arrowhead-client-skeleton-consumer diff --git a/client-skeleton-provider/pom.xml b/client-skeleton-provider/pom.xml index 04e5eec..643438d 100644 --- a/client-skeleton-provider/pom.xml +++ b/client-skeleton-provider/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.3.0.0 arrowhead-client-skeleton-provider diff --git a/client-skeleton-publisher/pom.xml b/client-skeleton-publisher/pom.xml index 49c69bf..24ad1ef 100644 --- a/client-skeleton-publisher/pom.xml +++ b/client-skeleton-publisher/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.3.0.0 arrowhead-client-skeleton-publisher diff --git a/client-skeleton-subscriber/pom.xml b/client-skeleton-subscriber/pom.xml index 205d547..04c0908 100644 --- a/client-skeleton-subscriber/pom.xml +++ b/client-skeleton-subscriber/pom.xml @@ -4,7 +4,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.3.0.0 arrowhead-client-skeleton-subscriber diff --git a/pom.xml b/pom.xml index f5e0324..09e6fb0 100644 --- a/pom.xml +++ b/pom.xml @@ -10,7 +10,7 @@ eu.arrowhead client-skeleton - 4.1.3.3 + 4.3.0.0 pom client-skeleton-java-spring Arrowhead Client Skeleton using Spring Boot @@ -34,7 +34,7 @@ eu.arrowhead client-library - 4.1.3.13 + 4.3.0.0 From b8accfba0bc95a5212894809c1eacf1443dd712b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bordi=20Tam=C3=A1s?= Date: Tue, 20 Jul 2021 16:48:20 +0200 Subject: [PATCH 05/11] Update README.md --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index d1c6a7c..bfd0910 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,6 @@ Fork this repo and extend the skeletons with your own application code. ([check The project has the following dependencies: * JRE/JDK 11 [Download from here](https://www.oracle.com/technetwork/java/javase/downloads/jdk11-downloads-5066655.html) * Maven 3.5+ [Download from here](http://maven.apache.org/download.cgi) | [Install guide](https://www.baeldung.com/install-maven-on-windows-linux-mac) -* GitHub Packages [Configuring Maven for GitHub Packages](https://help.github.com/en/packages/using-github-packages-with-your-projects-ecosystem/configuring-apache-maven-for-use-with-github-packages) | [Example](https://github.com/arrowhead-f/client-library-java-spring/blob/master/docs/example_mvn_settings.xml) ### Project structure From 21db0c5c28d94eb955c074dfd958765d698ec82c Mon Sep 17 00:00:00 2001 From: Tamas Bordi Date: Tue, 20 Jul 2021 17:39:29 +0200 Subject: [PATCH 06/11] change client to application --- .gitignore | 8 +++---- .project | 2 +- .../.classpath | 0 .../.project | 2 +- .../pom.xml | 2 +- .../ConsumerApplicationInitListener.java | 2 +- .../skeleton/consumer/ConsumerMain.java | 2 +- .../security/ConsumerAccessControlFilter.java | 2 +- .../security/ConsumerSecurityConfig.java | 2 +- ...itional-spring-configuration-metadata.json | 0 .../src/main/resources/application.properties | 2 +- .../certificates/consumerskeleton.p12 | Bin .../resources/certificates/truststore.p12 | Bin .../.classpath | 0 .../.project | 2 +- .../.springBeans | 0 .../pom.xml | 2 +- .../ProviderApplicationInitListener.java | 4 ++-- .../skeleton/provider/ProviderMain.java | 2 +- .../configuration/ConfigConstants.java | 2 +- .../ContainerConfProperties.java | 2 +- .../configuration/ContainerConfiguration.java | 2 +- .../controller/ProviderController.java | 2 +- .../security/ProviderAccessControlFilter.java | 2 +- .../security/ProviderSecurityConfig.java | 2 +- .../security/ProviderTokenSecurityFilter.java | 2 +- ...itional-spring-configuration-metadata.json | 0 .../src/main/resources/application.properties | 2 +- .../certificates/providerskeleton.p12 | Bin .../resources/certificates/truststore.p12 | Bin .../.classpath | 0 .../.project | 2 +- ....eclipse.wst.common.project.facet.core.xml | 0 .../.springBeans | 0 .../pom.xml | 2 +- .../PublisherApplicationInitListener.java | 20 +++++++++--------- .../skeleton/publisher/PublisherMain.java | 18 ++++++++-------- .../configuration/ConfigConstants.java | 2 +- .../ContainerConfProperties.java | 2 +- .../configuration/ContainerConfiguration.java | 2 +- .../constants/PublisherConstants.java | 2 +- .../controller/PublisherController.java | 8 +++---- .../publisher/event/EventTypeConstants.java | 2 +- .../publisher/event/PresetEventType.java | 2 +- .../PublisherAccessControlFilter.java | 2 +- .../security/PublisherSecurityConfig.java | 2 +- .../PublisherTokenSecurityFilter.java | 2 +- .../publisher/service/PublisherService.java | 18 ++++++++-------- ...itional-spring-configuration-metadata.json | 0 .../src/main/resources/application.properties | 2 +- .../certificates/publisherskeleton.p12 | Bin .../resources/certificates/truststore.p12 | Bin .../.classpath | 0 .../.project | 2 +- ....eclipse.wst.common.project.facet.core.xml | 0 .../.springBeans | 0 .../pom.xml | 2 +- .../subscriber/ConfigEventProperites.java | 2 +- .../SubscriberApplicationInitListener.java | 20 +++++++++--------- .../skeleton/subscriber/SubscriberMain.java | 18 ++++++++-------- .../subscriber/SubscriberUtilities.java | 4 ++-- .../configuration/ConfigConstants.java | 2 +- .../ContainerConfProperties.java | 2 +- .../configuration/ContainerConfiguration.java | 2 +- .../constants/SubscriberConstants.java | 2 +- .../constants/SubscriberDefaults.java | 2 +- .../controller/SubscriberController.java | 6 +++--- .../SubscriberAccessControlFilter.java | 2 +- ...criberNotificationAccessControlFilter.java | 4 ++-- .../security/SubscriberSecurityConfig.java | 2 +- .../SubscriberTokenSecurityFilter.java | 4 ++-- ...itional-spring-configuration-metadata.json | 0 .../src/main/resources/application.properties | 2 +- .../certificates/subscriberskeleton.p12 | Bin .../resources/certificates/truststore.p12 | Bin pom.xml | 10 ++++----- 76 files changed, 113 insertions(+), 113 deletions(-) rename {client-skeleton-consumer => application-skeleton-consumer}/.classpath (100%) rename {client-skeleton-consumer => application-skeleton-consumer}/.project (94%) rename {client-skeleton-consumer => application-skeleton-consumer}/pom.xml (96%) rename {client-skeleton-consumer/src/main/java/eu/arrowhead/client => application-skeleton-consumer/src/main/java/eu/arrowhead/application}/skeleton/consumer/ConsumerApplicationInitListener.java (96%) rename {client-skeleton-consumer/src/main/java/eu/arrowhead/client => application-skeleton-consumer/src/main/java/eu/arrowhead/application}/skeleton/consumer/ConsumerMain.java (98%) rename {client-skeleton-consumer/src/main/java/eu/arrowhead/client => application-skeleton-consumer/src/main/java/eu/arrowhead/application}/skeleton/consumer/security/ConsumerAccessControlFilter.java (93%) rename {client-skeleton-consumer/src/main/java/eu/arrowhead/client => application-skeleton-consumer/src/main/java/eu/arrowhead/application}/skeleton/consumer/security/ConsumerSecurityConfig.java (88%) rename {client-skeleton-consumer => application-skeleton-consumer}/src/main/resources/META-INF/additional-spring-configuration-metadata.json (100%) rename {client-skeleton-consumer => application-skeleton-consumer}/src/main/resources/application.properties (96%) rename {client-skeleton-consumer => application-skeleton-consumer}/src/main/resources/certificates/consumerskeleton.p12 (100%) rename {client-skeleton-consumer => application-skeleton-consumer}/src/main/resources/certificates/truststore.p12 (100%) rename {client-skeleton-provider => application-skeleton-provider}/.classpath (100%) rename {client-skeleton-provider => application-skeleton-provider}/.project (94%) rename {client-skeleton-provider => application-skeleton-provider}/.springBeans (100%) rename {client-skeleton-provider => application-skeleton-provider}/pom.xml (96%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/ProviderApplicationInitListener.java (96%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/ProviderMain.java (93%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/configuration/ConfigConstants.java (89%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/configuration/ContainerConfProperties.java (94%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/configuration/ContainerConfiguration.java (97%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/controller/ProviderController.java (93%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/security/ProviderAccessControlFilter.java (93%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/security/ProviderSecurityConfig.java (96%) rename {client-skeleton-provider/src/main/java/eu/arrowhead/client => application-skeleton-provider/src/main/java/eu/arrowhead/application}/skeleton/provider/security/ProviderTokenSecurityFilter.java (95%) rename {client-skeleton-provider => application-skeleton-provider}/src/main/resources/META-INF/additional-spring-configuration-metadata.json (100%) rename {client-skeleton-provider => application-skeleton-provider}/src/main/resources/application.properties (96%) rename {client-skeleton-provider => application-skeleton-provider}/src/main/resources/certificates/providerskeleton.p12 (100%) rename {client-skeleton-provider => application-skeleton-provider}/src/main/resources/certificates/truststore.p12 (100%) rename {client-skeleton-publisher => application-skeleton-publisher}/.classpath (100%) rename {client-skeleton-publisher => application-skeleton-publisher}/.project (95%) rename {client-skeleton-publisher => application-skeleton-publisher}/.settings/org.eclipse.wst.common.project.facet.core.xml (100%) rename {client-skeleton-publisher => application-skeleton-publisher}/.springBeans (100%) rename {client-skeleton-publisher => application-skeleton-publisher}/pom.xml (96%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/PublisherApplicationInitListener.java (90%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/PublisherMain.java (87%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/configuration/ConfigConstants.java (89%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/configuration/ContainerConfProperties.java (94%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/configuration/ContainerConfiguration.java (97%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/constants/PublisherConstants.java (90%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/controller/PublisherController.java (82%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/event/EventTypeConstants.java (92%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/event/PresetEventType.java (96%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/security/PublisherAccessControlFilter.java (93%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/security/PublisherSecurityConfig.java (96%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/security/PublisherTokenSecurityFilter.java (95%) rename {client-skeleton-publisher/src/main/java/eu/arrowhead/client => application-skeleton-publisher/src/main/java/eu/arrowhead/application}/skeleton/publisher/service/PublisherService.java (86%) rename {client-skeleton-publisher => application-skeleton-publisher}/src/main/resources/META-INF/additional-spring-configuration-metadata.json (100%) rename {client-skeleton-publisher => application-skeleton-publisher}/src/main/resources/application.properties (96%) rename {client-skeleton-publisher => application-skeleton-publisher}/src/main/resources/certificates/publisherskeleton.p12 (100%) rename {client-skeleton-publisher => application-skeleton-publisher}/src/main/resources/certificates/truststore.p12 (100%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/.classpath (100%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/.project (95%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/.settings/org.eclipse.wst.common.project.facet.core.xml (100%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/.springBeans (100%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/pom.xml (96%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/ConfigEventProperites.java (94%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/SubscriberApplicationInitListener.java (90%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/SubscriberMain.java (87%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/SubscriberUtilities.java (87%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/configuration/ConfigConstants.java (89%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/configuration/ContainerConfProperties.java (94%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/configuration/ContainerConfiguration.java (96%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/constants/SubscriberConstants.java (93%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/constants/SubscriberDefaults.java (89%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/controller/SubscriberController.java (92%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/security/SubscriberAccessControlFilter.java (93%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java (97%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/security/SubscriberSecurityConfig.java (97%) rename {client-skeleton-subscriber/src/main/java/eu/arrowhead/client => application-skeleton-subscriber/src/main/java/eu/arrowhead/application}/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java (96%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/src/main/resources/META-INF/additional-spring-configuration-metadata.json (100%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/src/main/resources/application.properties (97%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/src/main/resources/certificates/subscriberskeleton.p12 (100%) rename {client-skeleton-subscriber => application-skeleton-subscriber}/src/main/resources/certificates/truststore.p12 (100%) diff --git a/.gitignore b/.gitignore index 792c2ee..59abfc9 100644 --- a/.gitignore +++ b/.gitignore @@ -23,10 +23,10 @@ ### VS Code ### .vscode/ wrapper -/client-skeleton-provider/target -/client-skeleton-consumer/target -/client-skeleton-publisher/target -/client-skeleton-subscriber/target +/application-skeleton-provider/target +/application-skeleton-consumer/target +/application-skeleton-publisher/target +/application-skeleton-subscriber/target /mvnw /mvnw.cmd /.settings diff --git a/.project b/.project index f84cc55..303cf47 100644 --- a/.project +++ b/.project @@ -1,6 +1,6 @@ - client + application-skeleton diff --git a/client-skeleton-consumer/.classpath b/application-skeleton-consumer/.classpath similarity index 100% rename from client-skeleton-consumer/.classpath rename to application-skeleton-consumer/.classpath diff --git a/client-skeleton-consumer/.project b/application-skeleton-consumer/.project similarity index 94% rename from client-skeleton-consumer/.project rename to application-skeleton-consumer/.project index 71da5d4..b381f95 100644 --- a/client-skeleton-consumer/.project +++ b/application-skeleton-consumer/.project @@ -1,6 +1,6 @@ - client-skeleton-consumer + arrowhead-application-skeleton-consumer diff --git a/client-skeleton-consumer/pom.xml b/application-skeleton-consumer/pom.xml similarity index 96% rename from client-skeleton-consumer/pom.xml rename to application-skeleton-consumer/pom.xml index 324316b..8330ed1 100644 --- a/client-skeleton-consumer/pom.xml +++ b/application-skeleton-consumer/pom.xml @@ -7,7 +7,7 @@ 4.4.0.0 - arrowhead-client-skeleton-consumer + arrowhead-application-skeleton-consumer Arrowhead Consumer Skeleton diff --git a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerApplicationInitListener.java similarity index 96% rename from client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java rename to application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerApplicationInitListener.java index cfdc571..c2ac821 100644 --- a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerApplicationInitListener.java +++ b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerApplicationInitListener.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.consumer; +package eu.arrowhead.application.skeleton.consumer; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; diff --git a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerMain.java b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java similarity index 98% rename from client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerMain.java rename to application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java index af8b2fe..37bb986 100644 --- a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/ConsumerMain.java +++ b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.consumer; +package eu.arrowhead.application.skeleton.consumer; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; diff --git a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/security/ConsumerAccessControlFilter.java b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/security/ConsumerAccessControlFilter.java similarity index 93% rename from client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/security/ConsumerAccessControlFilter.java rename to application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/security/ConsumerAccessControlFilter.java index b96a761..f06b1ef 100644 --- a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/security/ConsumerAccessControlFilter.java +++ b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/security/ConsumerAccessControlFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.consumer.security; +package eu.arrowhead.application.skeleton.consumer.security; import java.util.Map; diff --git a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/security/ConsumerSecurityConfig.java b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/security/ConsumerSecurityConfig.java similarity index 88% rename from client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/security/ConsumerSecurityConfig.java rename to application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/security/ConsumerSecurityConfig.java index 009645a..14f791a 100644 --- a/client-skeleton-consumer/src/main/java/eu/arrowhead/client/skeleton/consumer/security/ConsumerSecurityConfig.java +++ b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/security/ConsumerSecurityConfig.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.consumer.security; +package eu.arrowhead.application.skeleton.consumer.security; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; import org.springframework.context.annotation.Configuration; diff --git a/client-skeleton-consumer/src/main/resources/META-INF/additional-spring-configuration-metadata.json b/application-skeleton-consumer/src/main/resources/META-INF/additional-spring-configuration-metadata.json similarity index 100% rename from client-skeleton-consumer/src/main/resources/META-INF/additional-spring-configuration-metadata.json rename to application-skeleton-consumer/src/main/resources/META-INF/additional-spring-configuration-metadata.json diff --git a/client-skeleton-consumer/src/main/resources/application.properties b/application-skeleton-consumer/src/main/resources/application.properties similarity index 96% rename from client-skeleton-consumer/src/main/resources/application.properties rename to application-skeleton-consumer/src/main/resources/application.properties index fa4286d..7e740b1 100644 --- a/client-skeleton-consumer/src/main/resources/application.properties +++ b/application-skeleton-consumer/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=CONSUMERSKELETON +application_system_name=CONSUMERSKELETON # Set the web application type to 'servlet' if your consumer client should act as a web-server # and fill the address and port propetries with valid values [Defaults, when not adjusted: localhost:8080] diff --git a/client-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 b/application-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 similarity index 100% rename from client-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 rename to application-skeleton-consumer/src/main/resources/certificates/consumerskeleton.p12 diff --git a/client-skeleton-consumer/src/main/resources/certificates/truststore.p12 b/application-skeleton-consumer/src/main/resources/certificates/truststore.p12 similarity index 100% rename from client-skeleton-consumer/src/main/resources/certificates/truststore.p12 rename to application-skeleton-consumer/src/main/resources/certificates/truststore.p12 diff --git a/client-skeleton-provider/.classpath b/application-skeleton-provider/.classpath similarity index 100% rename from client-skeleton-provider/.classpath rename to application-skeleton-provider/.classpath diff --git a/client-skeleton-provider/.project b/application-skeleton-provider/.project similarity index 94% rename from client-skeleton-provider/.project rename to application-skeleton-provider/.project index 49f50fb..92578d0 100644 --- a/client-skeleton-provider/.project +++ b/application-skeleton-provider/.project @@ -1,6 +1,6 @@ - client-skeleton-provider + arrowhead-application-skeleton-provider diff --git a/client-skeleton-provider/.springBeans b/application-skeleton-provider/.springBeans similarity index 100% rename from client-skeleton-provider/.springBeans rename to application-skeleton-provider/.springBeans diff --git a/client-skeleton-provider/pom.xml b/application-skeleton-provider/pom.xml similarity index 96% rename from client-skeleton-provider/pom.xml rename to application-skeleton-provider/pom.xml index 367ca50..bd3a507 100644 --- a/client-skeleton-provider/pom.xml +++ b/application-skeleton-provider/pom.xml @@ -7,7 +7,7 @@ 4.4.0.0 - arrowhead-client-skeleton-provider + arrowhead-application-skeleton-provider Arrowhead Provider Skeleton diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java similarity index 96% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java index 0b894b1..1f5e0f5 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderApplicationInitListener.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider; +package eu.arrowhead.application.skeleton.provider; import java.io.IOException; import java.security.KeyStore; @@ -18,7 +18,7 @@ import ai.aitia.arrowhead.application.library.ArrowheadService; import ai.aitia.arrowhead.application.library.config.ApplicationInitListener; import ai.aitia.arrowhead.application.library.util.ApplicationCommonConstants; -import eu.arrowhead.client.skeleton.provider.security.ProviderSecurityConfig; +import eu.arrowhead.application.skeleton.provider.security.ProviderSecurityConfig; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.core.CoreSystem; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderMain.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java similarity index 93% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderMain.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java index e85cf60..f96f95e 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/ProviderMain.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider; +package eu.arrowhead.application.skeleton.provider; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ConfigConstants.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ConfigConstants.java similarity index 89% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ConfigConstants.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ConfigConstants.java index f70dbe7..ff1520b 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ConfigConstants.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ConfigConstants.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.configuration; +package eu.arrowhead.application.skeleton.provider.configuration; public class ConfigConstants { diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfProperties.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ContainerConfProperties.java similarity index 94% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfProperties.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ContainerConfProperties.java index c4cbce8..8e87a74 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfProperties.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ContainerConfProperties.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.configuration; +package eu.arrowhead.application.skeleton.provider.configuration; import javax.validation.constraints.Max; import javax.validation.constraints.Min; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ContainerConfiguration.java similarity index 97% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ContainerConfiguration.java index 7cc7e67..bd51cee 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/configuration/ContainerConfiguration.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/configuration/ContainerConfiguration.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.configuration; +package eu.arrowhead.application.skeleton.provider.configuration; import org.apache.coyote.http11.AbstractHttp11Protocol; import org.apache.logging.log4j.LogManager; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/controller/ProviderController.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/controller/ProviderController.java similarity index 93% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/controller/ProviderController.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/controller/ProviderController.java index 95c9a7a..bf0edb2 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/controller/ProviderController.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/controller/ProviderController.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.controller; +package eu.arrowhead.application.skeleton.provider.controller; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderAccessControlFilter.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderAccessControlFilter.java similarity index 93% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderAccessControlFilter.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderAccessControlFilter.java index 0a0575a..28832f9 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderAccessControlFilter.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderAccessControlFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.security; +package eu.arrowhead.application.skeleton.provider.security; import java.util.Map; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderSecurityConfig.java similarity index 96% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderSecurityConfig.java index e004a22..2ae8edb 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderSecurityConfig.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderSecurityConfig.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.security; +package eu.arrowhead.application.skeleton.provider.security; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Configuration; diff --git a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderTokenSecurityFilter.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderTokenSecurityFilter.java similarity index 95% rename from client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderTokenSecurityFilter.java rename to application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderTokenSecurityFilter.java index 3dce009..316077b 100644 --- a/client-skeleton-provider/src/main/java/eu/arrowhead/client/skeleton/provider/security/ProviderTokenSecurityFilter.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/security/ProviderTokenSecurityFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.provider.security; +package eu.arrowhead.application.skeleton.provider.security; import java.security.PrivateKey; import java.security.PublicKey; diff --git a/client-skeleton-provider/src/main/resources/META-INF/additional-spring-configuration-metadata.json b/application-skeleton-provider/src/main/resources/META-INF/additional-spring-configuration-metadata.json similarity index 100% rename from client-skeleton-provider/src/main/resources/META-INF/additional-spring-configuration-metadata.json rename to application-skeleton-provider/src/main/resources/META-INF/additional-spring-configuration-metadata.json diff --git a/client-skeleton-provider/src/main/resources/application.properties b/application-skeleton-provider/src/main/resources/application.properties similarity index 96% rename from client-skeleton-provider/src/main/resources/application.properties rename to application-skeleton-provider/src/main/resources/application.properties index 82bf337..e59a4e2 100644 --- a/client-skeleton-provider/src/main/resources/application.properties +++ b/application-skeleton-provider/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=PROVIDERSKELETON +application_system_name=PROVIDERSKELETON # Client web-server parameters server.address=127.0.0.1 diff --git a/client-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 b/application-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 similarity index 100% rename from client-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 rename to application-skeleton-provider/src/main/resources/certificates/providerskeleton.p12 diff --git a/client-skeleton-provider/src/main/resources/certificates/truststore.p12 b/application-skeleton-provider/src/main/resources/certificates/truststore.p12 similarity index 100% rename from client-skeleton-provider/src/main/resources/certificates/truststore.p12 rename to application-skeleton-provider/src/main/resources/certificates/truststore.p12 diff --git a/client-skeleton-publisher/.classpath b/application-skeleton-publisher/.classpath similarity index 100% rename from client-skeleton-publisher/.classpath rename to application-skeleton-publisher/.classpath diff --git a/client-skeleton-publisher/.project b/application-skeleton-publisher/.project similarity index 95% rename from client-skeleton-publisher/.project rename to application-skeleton-publisher/.project index 26bd190..fca9ad2 100644 --- a/client-skeleton-publisher/.project +++ b/application-skeleton-publisher/.project @@ -1,6 +1,6 @@ - client-skeleton-provider + arrowhead-application-skeleton-publisher diff --git a/client-skeleton-publisher/.settings/org.eclipse.wst.common.project.facet.core.xml b/application-skeleton-publisher/.settings/org.eclipse.wst.common.project.facet.core.xml similarity index 100% rename from client-skeleton-publisher/.settings/org.eclipse.wst.common.project.facet.core.xml rename to application-skeleton-publisher/.settings/org.eclipse.wst.common.project.facet.core.xml diff --git a/client-skeleton-publisher/.springBeans b/application-skeleton-publisher/.springBeans similarity index 100% rename from client-skeleton-publisher/.springBeans rename to application-skeleton-publisher/.springBeans diff --git a/client-skeleton-publisher/pom.xml b/application-skeleton-publisher/pom.xml similarity index 96% rename from client-skeleton-publisher/pom.xml rename to application-skeleton-publisher/pom.xml index e27bb35..5542c25 100644 --- a/client-skeleton-publisher/pom.xml +++ b/application-skeleton-publisher/pom.xml @@ -7,7 +7,7 @@ 4.4.0.0 - arrowhead-client-skeleton-publisher + arrowhead-application-skeleton-publisher Arrowhead Publisher Skeleton diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java similarity index 90% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java index 43727c7..e1ca8f3 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherApplicationInitListener.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher; +package eu.arrowhead.application.skeleton.publisher; import java.io.IOException; import java.security.KeyStore; @@ -21,9 +21,9 @@ import ai.aitia.arrowhead.application.library.ArrowheadService; import ai.aitia.arrowhead.application.library.config.ApplicationInitListener; import ai.aitia.arrowhead.application.library.util.ApplicationCommonConstants; -import eu.arrowhead.client.skeleton.publisher.constants.PublisherConstants; -import eu.arrowhead.client.skeleton.publisher.event.PresetEventType; -import eu.arrowhead.client.skeleton.publisher.security.PublisherSecurityConfig; +import eu.arrowhead.application.skeleton.publisher.constants.PublisherConstants; +import eu.arrowhead.application.skeleton.publisher.event.PresetEventType; +import eu.arrowhead.application.skeleton.publisher.security.PublisherSecurityConfig; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.core.CoreSystem; @@ -50,13 +50,13 @@ public class PublisherApplicationInitListener extends ApplicationInitListener { private boolean sslEnabled; @Value(ApplicationCommonConstants.$APPLICATION_SYSTEM_NAME) - private String clientSystemName; + private String applicationSystemName; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_ADDRESS_WD) - private String clientSystemAddress; + private String applicationSystemAddress; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_PORT_WD) - private int clientSystemPort; + private int applicationSystemPort; private final Logger logger = LogManager.getLogger(PublisherApplicationInitListener.class); @@ -129,9 +129,9 @@ private void publishInitStartedEvent() { final String eventType = PresetEventType.START_INIT.getEventTypeName(); final SystemRequestDTO source = new SystemRequestDTO(); - source.setSystemName(clientSystemName); - source.setAddress(clientSystemAddress); - source.setPort(clientSystemPort); + source.setSystemName(applicationSystemName); + source.setAddress(applicationSystemAddress); + source.setPort(applicationSystemPort); if (sslEnabled) { source.setAuthenticationInfo( Base64.getEncoder().encodeToString(arrowheadService.getMyPublicKey().getEncoded())); } diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherMain.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java similarity index 87% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherMain.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java index 5f46f4a..71b7cce 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/PublisherMain.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher; +package eu.arrowhead.application.skeleton.publisher; import java.time.ZonedDateTime; import java.util.Base64; @@ -16,8 +16,8 @@ import ai.aitia.arrowhead.application.library.ArrowheadService; import ai.aitia.arrowhead.application.library.util.ApplicationCommonConstants; -import eu.arrowhead.client.skeleton.publisher.constants.PublisherConstants; -import eu.arrowhead.client.skeleton.publisher.event.PresetEventType; +import eu.arrowhead.application.skeleton.publisher.constants.PublisherConstants; +import eu.arrowhead.application.skeleton.publisher.event.PresetEventType; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.dto.shared.EventPublishRequestDTO; @@ -31,13 +31,13 @@ public class PublisherMain implements ApplicationRunner { // members @Value(ApplicationCommonConstants.$APPLICATION_SYSTEM_NAME) - private String clientSystemName; + private String applicationSystemName; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_ADDRESS_WD) - private String clientSystemAddress; + private String applicationSystemAddress; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_PORT_WD) - private int clientSystemPort; + private int applicationSystemPort; @Value(CommonConstants.$SERVER_SSL_ENABLED_WD) private boolean sslEnabled; @@ -72,9 +72,9 @@ private void publishRunStartedEvent() { final String eventType = PresetEventType.START_RUN.getEventTypeName(); final SystemRequestDTO source = new SystemRequestDTO(); - source.setSystemName(clientSystemName); - source.setAddress(clientSystemAddress); - source.setPort(clientSystemPort); + source.setSystemName(applicationSystemName); + source.setAddress(applicationSystemAddress); + source.setPort(applicationSystemPort); if (sslEnabled) { source.setAuthenticationInfo(Base64.getEncoder().encodeToString( arrowheadService.getMyPublicKey().getEncoded())); } diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ConfigConstants.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ConfigConstants.java similarity index 89% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ConfigConstants.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ConfigConstants.java index 38c70cd..bfdd82e 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ConfigConstants.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ConfigConstants.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.configuration; +package eu.arrowhead.application.skeleton.publisher.configuration; public class ConfigConstants { diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfProperties.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ContainerConfProperties.java similarity index 94% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfProperties.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ContainerConfProperties.java index fd2dc48..4d0b73b 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfProperties.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ContainerConfProperties.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.configuration; +package eu.arrowhead.application.skeleton.publisher.configuration; import javax.validation.constraints.Max; import javax.validation.constraints.Min; diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ContainerConfiguration.java similarity index 97% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ContainerConfiguration.java index 35fd5a6..4773f56 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/configuration/ContainerConfiguration.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/configuration/ContainerConfiguration.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.configuration; +package eu.arrowhead.application.skeleton.publisher.configuration; import org.apache.coyote.http11.AbstractHttp11Protocol; import org.apache.logging.log4j.LogManager; diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/constants/PublisherConstants.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/constants/PublisherConstants.java similarity index 90% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/constants/PublisherConstants.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/constants/PublisherConstants.java index 5e459a7..7a2c403 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/constants/PublisherConstants.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/constants/PublisherConstants.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.constants; +package eu.arrowhead.application.skeleton.publisher.constants; public class PublisherConstants { //================================================================================================= diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/controller/PublisherController.java similarity index 82% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/controller/PublisherController.java index 5593fb6..e36f61c 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/controller/PublisherController.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/controller/PublisherController.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.controller; +package eu.arrowhead.application.skeleton.publisher.controller; import java.util.Map; @@ -9,9 +9,9 @@ import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; -import eu.arrowhead.client.skeleton.publisher.event.EventTypeConstants; -import eu.arrowhead.client.skeleton.publisher.event.PresetEventType; -import eu.arrowhead.client.skeleton.publisher.service.PublisherService; +import eu.arrowhead.application.skeleton.publisher.event.EventTypeConstants; +import eu.arrowhead.application.skeleton.publisher.event.PresetEventType; +import eu.arrowhead.application.skeleton.publisher.service.PublisherService; import eu.arrowhead.common.CommonConstants; @RestController diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/event/EventTypeConstants.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/event/EventTypeConstants.java similarity index 92% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/event/EventTypeConstants.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/event/EventTypeConstants.java index 87e56a1..4fe15fc 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/event/EventTypeConstants.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/event/EventTypeConstants.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.event; +package eu.arrowhead.application.skeleton.publisher.event; public class EventTypeConstants { diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/event/PresetEventType.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/event/PresetEventType.java similarity index 96% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/event/PresetEventType.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/event/PresetEventType.java index e35b0cd..4155641 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/event/PresetEventType.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/event/PresetEventType.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.event; +package eu.arrowhead.application.skeleton.publisher.event; import java.util.Collections; import java.util.List; diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherAccessControlFilter.java similarity index 93% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherAccessControlFilter.java index 150719d..5c2ede4 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherAccessControlFilter.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherAccessControlFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.security; +package eu.arrowhead.application.skeleton.publisher.security; import java.util.Map; diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherSecurityConfig.java similarity index 96% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherSecurityConfig.java index 7cb8b28..4d9da42 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherSecurityConfig.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherSecurityConfig.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.security; +package eu.arrowhead.application.skeleton.publisher.security; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Configuration; diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherTokenSecurityFilter.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherTokenSecurityFilter.java similarity index 95% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherTokenSecurityFilter.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherTokenSecurityFilter.java index 1b2757c..94043ef 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/security/PublisherTokenSecurityFilter.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/security/PublisherTokenSecurityFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.security; +package eu.arrowhead.application.skeleton.publisher.security; import java.security.PrivateKey; import java.security.PublicKey; diff --git a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/service/PublisherService.java similarity index 86% rename from client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java rename to application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/service/PublisherService.java index ca18b68..ea4de25 100644 --- a/client-skeleton-publisher/src/main/java/eu/arrowhead/client/skeleton/publisher/service/PublisherService.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/service/PublisherService.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.publisher.service; +package eu.arrowhead.application.skeleton.publisher.service; import java.time.ZonedDateTime; import java.util.Base64; @@ -12,8 +12,8 @@ import ai.aitia.arrowhead.application.library.ArrowheadService; import ai.aitia.arrowhead.application.library.util.ApplicationCommonConstants; -import eu.arrowhead.client.skeleton.publisher.PublisherApplicationInitListener; -import eu.arrowhead.client.skeleton.publisher.event.PresetEventType; +import eu.arrowhead.application.skeleton.publisher.PublisherApplicationInitListener; +import eu.arrowhead.application.skeleton.publisher.event.PresetEventType; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.dto.shared.EventPublishRequestDTO; @@ -25,13 +25,13 @@ public class PublisherService { // members @Value(ApplicationCommonConstants.$APPLICATION_SYSTEM_NAME) - private String clientSystemName; + private String applicationSystemName; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_ADDRESS_WD) - private String clientSystemAddress; + private String applicationSystemAddress; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_PORT_WD) - private int clientSystemPort; + private int applicationSystemPort; @Value(CommonConstants.$SERVER_SSL_ENABLED_WD) private boolean sslEnabled; @@ -68,9 +68,9 @@ private SystemRequestDTO getSource() { logger.debug("getSource started..."); final SystemRequestDTO source = new SystemRequestDTO(); - source.setSystemName(clientSystemName); - source.setAddress(clientSystemAddress); - source.setPort(clientSystemPort); + source.setSystemName(applicationSystemName); + source.setAddress(applicationSystemAddress); + source.setPort(applicationSystemPort); if (sslEnabled) { source.setAuthenticationInfo( Base64.getEncoder().encodeToString(arrowheadService.getMyPublicKey().getEncoded())); } diff --git a/client-skeleton-publisher/src/main/resources/META-INF/additional-spring-configuration-metadata.json b/application-skeleton-publisher/src/main/resources/META-INF/additional-spring-configuration-metadata.json similarity index 100% rename from client-skeleton-publisher/src/main/resources/META-INF/additional-spring-configuration-metadata.json rename to application-skeleton-publisher/src/main/resources/META-INF/additional-spring-configuration-metadata.json diff --git a/client-skeleton-publisher/src/main/resources/application.properties b/application-skeleton-publisher/src/main/resources/application.properties similarity index 96% rename from client-skeleton-publisher/src/main/resources/application.properties rename to application-skeleton-publisher/src/main/resources/application.properties index ddbdfd8..e8baf75 100644 --- a/client-skeleton-publisher/src/main/resources/application.properties +++ b/application-skeleton-publisher/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=PUBLISHERSKELETON +application_system_name=PUBLISHERSKELETON # Client web-server parameters server.address=127.0.0.1 diff --git a/client-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 b/application-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 similarity index 100% rename from client-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 rename to application-skeleton-publisher/src/main/resources/certificates/publisherskeleton.p12 diff --git a/client-skeleton-publisher/src/main/resources/certificates/truststore.p12 b/application-skeleton-publisher/src/main/resources/certificates/truststore.p12 similarity index 100% rename from client-skeleton-publisher/src/main/resources/certificates/truststore.p12 rename to application-skeleton-publisher/src/main/resources/certificates/truststore.p12 diff --git a/client-skeleton-subscriber/.classpath b/application-skeleton-subscriber/.classpath similarity index 100% rename from client-skeleton-subscriber/.classpath rename to application-skeleton-subscriber/.classpath diff --git a/client-skeleton-subscriber/.project b/application-skeleton-subscriber/.project similarity index 95% rename from client-skeleton-subscriber/.project rename to application-skeleton-subscriber/.project index 26bd190..899af96 100644 --- a/client-skeleton-subscriber/.project +++ b/application-skeleton-subscriber/.project @@ -1,6 +1,6 @@ - client-skeleton-provider + arrowhead-application-skeleton-subscriber diff --git a/client-skeleton-subscriber/.settings/org.eclipse.wst.common.project.facet.core.xml b/application-skeleton-subscriber/.settings/org.eclipse.wst.common.project.facet.core.xml similarity index 100% rename from client-skeleton-subscriber/.settings/org.eclipse.wst.common.project.facet.core.xml rename to application-skeleton-subscriber/.settings/org.eclipse.wst.common.project.facet.core.xml diff --git a/client-skeleton-subscriber/.springBeans b/application-skeleton-subscriber/.springBeans similarity index 100% rename from client-skeleton-subscriber/.springBeans rename to application-skeleton-subscriber/.springBeans diff --git a/client-skeleton-subscriber/pom.xml b/application-skeleton-subscriber/pom.xml similarity index 96% rename from client-skeleton-subscriber/pom.xml rename to application-skeleton-subscriber/pom.xml index 38635f2..cf28210 100644 --- a/client-skeleton-subscriber/pom.xml +++ b/application-skeleton-subscriber/pom.xml @@ -7,7 +7,7 @@ 4.4.0.0 - arrowhead-client-skeleton-subscriber + arrowhead-application-skeleton-subscriber Arrowhead Subscriber Skeleton diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/ConfigEventProperites.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/ConfigEventProperites.java similarity index 94% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/ConfigEventProperites.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/ConfigEventProperites.java index 7fac17a..3e9bd83 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/ConfigEventProperites.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/ConfigEventProperites.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber; +package eu.arrowhead.application.skeleton.subscriber; import java.util.Map; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java similarity index 90% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java index 39f5c9c..493a71f 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberApplicationInitListener.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber; +package eu.arrowhead.application.skeleton.subscriber; import java.io.IOException; import java.security.KeyStore; @@ -20,7 +20,7 @@ import ai.aitia.arrowhead.application.library.ArrowheadService; import ai.aitia.arrowhead.application.library.config.ApplicationInitListener; import ai.aitia.arrowhead.application.library.util.ApplicationCommonConstants; -import eu.arrowhead.client.skeleton.subscriber.security.SubscriberSecurityConfig; +import eu.arrowhead.application.skeleton.subscriber.security.SubscriberSecurityConfig; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.core.CoreSystem; @@ -47,13 +47,13 @@ public class SubscriberApplicationInitListener extends ApplicationInitListener { private boolean sslEnabled; @Value(ApplicationCommonConstants.$APPLICATION_SYSTEM_NAME) - private String clientSystemName; + private String applicationSystemName; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_ADDRESS_WD) - private String clientSystemAddress; + private String applicationSystemAddress; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_PORT_WD) - private int clientSystemPort; + private int applicationSystemPort; private final Logger logger = LogManager.getLogger(SubscriberApplicationInitListener.class); @@ -109,7 +109,7 @@ public void customDestroy() { logger.info("No preset events to unsubscribe."); } else { for (final String eventType : eventTypeMap.keySet()) { - arrowheadService.unsubscribeFromEventHandler(eventType, clientSystemName, clientSystemAddress, clientSystemPort); + arrowheadService.unsubscribeFromEventHandler(eventType, applicationSystemName, applicationSystemAddress, applicationSystemPort); } } } @@ -151,16 +151,16 @@ private void subscribeToPresetEvents() { logger.info("No preset events to subscribe."); } else { final SystemRequestDTO subscriber = new SystemRequestDTO(); - subscriber.setSystemName(clientSystemName); - subscriber.setAddress(clientSystemAddress); - subscriber.setPort(clientSystemPort); + subscriber.setSystemName(applicationSystemName); + subscriber.setAddress(applicationSystemAddress); + subscriber.setPort(applicationSystemPort); if (sslEnabled) { subscriber.setAuthenticationInfo(Base64.getEncoder().encodeToString(arrowheadService.getMyPublicKey().getEncoded())); } for (final String eventType : eventTypeMap.keySet()) { try { - arrowheadService.unsubscribeFromEventHandler(eventType, clientSystemName, clientSystemAddress, clientSystemPort); + arrowheadService.unsubscribeFromEventHandler(eventType, applicationSystemName, applicationSystemAddress, applicationSystemPort); } catch (final Exception ex) { logger.debug("Exception happend in subscription initalization " + ex); } diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberMain.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java similarity index 87% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberMain.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java index 2435b5a..ac64b43 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberMain.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber; +package eu.arrowhead.application.skeleton.subscriber; import java.util.Base64; import java.util.Map; @@ -16,7 +16,7 @@ import ai.aitia.arrowhead.application.library.ArrowheadService; import ai.aitia.arrowhead.application.library.util.ApplicationCommonConstants; -import eu.arrowhead.client.skeleton.subscriber.constants.SubscriberConstants; +import eu.arrowhead.application.skeleton.subscriber.constants.SubscriberConstants; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.dto.shared.SystemRequestDTO; import eu.arrowhead.common.exception.InvalidParameterException; @@ -33,13 +33,13 @@ public class SubscriberMain implements ApplicationRunner { private String presetEvents; @Value(ApplicationCommonConstants.$APPLICATION_SYSTEM_NAME) - private String clientSystemName; + private String applicationSystemName; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_ADDRESS_WD) - private String clientSystemAddress; + private String applicationSystemAddress; @Value(ApplicationCommonConstants.$APPLICATION_SERVER_PORT_WD) - private int clientSystemPort; + private int applicationSystemPort; @Value(CommonConstants.$SERVER_SSL_ENABLED_WD) private boolean sslEnabled; @@ -80,9 +80,9 @@ private void subscribeToPresetEvents() { } else { final SystemRequestDTO subscriber = new SystemRequestDTO(); - subscriber.setSystemName(clientSystemName); - subscriber.setAddress(clientSystemAddress); - subscriber.setPort(clientSystemPort); + subscriber.setSystemName(applicationSystemName); + subscriber.setAddress(applicationSystemAddress); + subscriber.setPort(applicationSystemPort); if (sslEnabled) { subscriber.setAuthenticationInfo( Base64.getEncoder().encodeToString(arrowheadService.getMyPublicKey().getEncoded())); @@ -90,7 +90,7 @@ private void subscribeToPresetEvents() { for (final String eventType : eventTypeMap.keySet()) { try { - arrowheadService.unsubscribeFromEventHandler(eventType, clientSystemName, clientSystemAddress, clientSystemPort); + arrowheadService.unsubscribeFromEventHandler(eventType, applicationSystemName, applicationSystemAddress, applicationSystemPort); } catch (final Exception ex) { logger.debug("Could not unsubscribe from EventType: " + eventType); } diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberUtilities.java similarity index 87% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberUtilities.java index ebe75e1..ec756fb 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/SubscriberUtilities.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberUtilities.java @@ -1,6 +1,6 @@ -package eu.arrowhead.client.skeleton.subscriber; +package eu.arrowhead.application.skeleton.subscriber; -import eu.arrowhead.client.skeleton.subscriber.constants.SubscriberDefaults; +import eu.arrowhead.application.skeleton.subscriber.constants.SubscriberDefaults; import eu.arrowhead.common.dto.shared.SubscriptionRequestDTO; import eu.arrowhead.common.dto.shared.SystemRequestDTO; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ConfigConstants.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ConfigConstants.java similarity index 89% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ConfigConstants.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ConfigConstants.java index c51fead..5d661b4 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ConfigConstants.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ConfigConstants.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.configuration; +package eu.arrowhead.application.skeleton.subscriber.configuration; public class ConfigConstants { diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfProperties.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ContainerConfProperties.java similarity index 94% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfProperties.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ContainerConfProperties.java index ea57c14..3bd5a08 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfProperties.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ContainerConfProperties.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.configuration; +package eu.arrowhead.application.skeleton.subscriber.configuration; import javax.validation.constraints.Max; import javax.validation.constraints.Min; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ContainerConfiguration.java similarity index 96% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ContainerConfiguration.java index 662ecfb..ed6750c 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/configuration/ContainerConfiguration.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/configuration/ContainerConfiguration.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.configuration; +package eu.arrowhead.application.skeleton.subscriber.configuration; import org.apache.coyote.http11.AbstractHttp11Protocol; import org.apache.logging.log4j.LogManager; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/constants/SubscriberConstants.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/constants/SubscriberConstants.java similarity index 93% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/constants/SubscriberConstants.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/constants/SubscriberConstants.java index 11faf70..a666292 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/constants/SubscriberConstants.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/constants/SubscriberConstants.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.constants; +package eu.arrowhead.application.skeleton.subscriber.constants; public class SubscriberConstants { //================================================================================================= diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/constants/SubscriberDefaults.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/constants/SubscriberDefaults.java similarity index 89% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/constants/SubscriberDefaults.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/constants/SubscriberDefaults.java index a658728..98b8490 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/constants/SubscriberDefaults.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/constants/SubscriberDefaults.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.constants; +package eu.arrowhead.application.skeleton.subscriber.constants; public class SubscriberDefaults { diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/controller/SubscriberController.java similarity index 92% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/controller/SubscriberController.java index bfc01de..5c0e906 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/controller/SubscriberController.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/controller/SubscriberController.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.controller; +package eu.arrowhead.application.skeleton.subscriber.controller; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; @@ -8,8 +8,8 @@ import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; -import eu.arrowhead.client.skeleton.subscriber.constants.SubscriberConstants; -import eu.arrowhead.client.skeleton.subscriber.constants.SubscriberDefaults; +import eu.arrowhead.application.skeleton.subscriber.constants.SubscriberConstants; +import eu.arrowhead.application.skeleton.subscriber.constants.SubscriberDefaults; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.dto.shared.EventDTO; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberAccessControlFilter.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberAccessControlFilter.java similarity index 93% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberAccessControlFilter.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberAccessControlFilter.java index 7e8ee0f..a526a5e 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberAccessControlFilter.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberAccessControlFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.security; +package eu.arrowhead.application.skeleton.subscriber.security; import java.util.Map; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java similarity index 97% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java index 762b437..7797698 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberNotificationAccessControlFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.security; +package eu.arrowhead.application.skeleton.subscriber.security; import java.io.IOException; import java.security.cert.X509Certificate; @@ -13,7 +13,7 @@ import org.springframework.lang.Nullable; import org.springframework.util.Assert; -import eu.arrowhead.client.skeleton.subscriber.constants.SubscriberDefaults; +import eu.arrowhead.application.skeleton.subscriber.constants.SubscriberDefaults; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.core.CoreSystem; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberSecurityConfig.java similarity index 97% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberSecurityConfig.java index a3fc4ab..edce22c 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberSecurityConfig.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberSecurityConfig.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.security; +package eu.arrowhead.application.skeleton.subscriber.security; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Configuration; diff --git a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java similarity index 96% rename from client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java rename to application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java index ea1d46a..d0ae1b3 100644 --- a/client-skeleton-subscriber/src/main/java/eu/arrowhead/client/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/security/SubscriberTokenSecurityFilter.java @@ -1,4 +1,4 @@ -package eu.arrowhead.client.skeleton.subscriber.security; +package eu.arrowhead.application.skeleton.subscriber.security; import java.io.IOException; import java.security.PrivateKey; @@ -14,7 +14,7 @@ import org.springframework.lang.Nullable; -import eu.arrowhead.client.skeleton.subscriber.constants.SubscriberDefaults; +import eu.arrowhead.application.skeleton.subscriber.constants.SubscriberDefaults; import eu.arrowhead.common.CommonConstants; import eu.arrowhead.common.Utilities; import eu.arrowhead.common.exception.ArrowheadException; diff --git a/client-skeleton-subscriber/src/main/resources/META-INF/additional-spring-configuration-metadata.json b/application-skeleton-subscriber/src/main/resources/META-INF/additional-spring-configuration-metadata.json similarity index 100% rename from client-skeleton-subscriber/src/main/resources/META-INF/additional-spring-configuration-metadata.json rename to application-skeleton-subscriber/src/main/resources/META-INF/additional-spring-configuration-metadata.json diff --git a/client-skeleton-subscriber/src/main/resources/application.properties b/application-skeleton-subscriber/src/main/resources/application.properties similarity index 97% rename from client-skeleton-subscriber/src/main/resources/application.properties rename to application-skeleton-subscriber/src/main/resources/application.properties index 9aa1587..40eee24 100644 --- a/client-skeleton-subscriber/src/main/resources/application.properties +++ b/application-skeleton-subscriber/src/main/resources/application.properties @@ -3,7 +3,7 @@ ############################################ # Name of the client system -client_system_name=SUBSCRIBERSKELETON +application_system_name=SUBSCRIBERSKELETON # Client web-server parameters server.address=127.0.0.1 diff --git a/client-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 b/application-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 similarity index 100% rename from client-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 rename to application-skeleton-subscriber/src/main/resources/certificates/subscriberskeleton.p12 diff --git a/client-skeleton-subscriber/src/main/resources/certificates/truststore.p12 b/application-skeleton-subscriber/src/main/resources/certificates/truststore.p12 similarity index 100% rename from client-skeleton-subscriber/src/main/resources/certificates/truststore.p12 rename to application-skeleton-subscriber/src/main/resources/certificates/truststore.p12 diff --git a/pom.xml b/pom.xml index 11ad742..8bc805d 100644 --- a/pom.xml +++ b/pom.xml @@ -24,16 +24,16 @@ - client-skeleton-consumer - client-skeleton-provider - client-skeleton-subscriber - client-skeleton-publisher + application-skeleton-consumer + application-skeleton-provider + application-skeleton-subscriber + application-skeleton-publisher ossrh - https://s01.oss.sonatype.org/content/repositories/aiaitia-1016 + https://s01.oss.sonatype.org/content/repositories/aiaitia-1017 From 77c1a7939b1aef3530fe484d410dc74c6d0c9876 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bordi=20Tam=C3=A1s?= Date: Wed, 21 Jul 2021 15:02:23 +0200 Subject: [PATCH 07/11] Update README.md --- README.md | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index bfd0910..93c2eeb 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ -# Arrowhead Client Skeletons (Java Spring-Boot) -##### The project provides client skeletons for the Arrowhead Framework 4.1.3 +# Arrowhead Application Skeletons (Java Spring-Boot) +##### The project provides application skeletons for the Arrowhead Framework -### How to use client skeletons? +### How to use application skeletons? Fork this repo and extend the skeletons with your own application code. ([check the best practice recommendations](https://github.com/arrowhead-f/client-skeleton-java-spring/blob/master/README.md#best-practices-to-start-with-the-skeletons)) @@ -17,17 +17,17 @@ This is a multi-module maven project relying on the [parent `pom.xml`](https://g ##### Modules: -* **client-skeleton-consumer**: client skeleton module with the purpose of initiating an orchestration request and consume the service from the chosen provider. This consumer project also contains a simple example of how to orchestrate and consume the service afterward. +* **application-skeleton-consumer**: application skeleton module with the purpose of initiating an orchestration request and consume the service from the chosen provider. This consumer project also contains a simple example of how to orchestrate and consume the service afterward. -* **client-skeleton-provider**: client skeleton module with the purpose of registering a specific service into the Service Registry and running a web server where the service is available. +* **application-skeleton-provider**: application skeleton module with the purpose of registering a specific service into the Service Registry and running a web server where the service is available. -* **client-skeleton-subscriber**: client skeleton module with the purpose of registering subscriptions into the Event Handler and running a web server where it waits for notifications. +* **application-skeleton-subscriber**: application skeleton module with the purpose of registering subscriptions into the Event Handler and running a web server where it waits for notifications. -* **client-skeleton-publisher**: client publisher module with the purpose of publishing events into the Event Handler. +* **application-skeleton-publisher**: application publisher module with the purpose of publishing events into the Event Handler. -Skeletons are built on the [`Arrowhead Client Library`](https://github.com/arrowhead-f/client-library-java-spring) which is also imported to this project as a Maven dependency. The client library provides the `ArrowheadService.class` which is a singleton spring managed bean and designed with the purpose of interacting with Arrowhead Framework. Use its methods by [autowiring](https://www.baeldung.com/spring-autowire) into your spring managed custom classes or use `ArrowheadBeans.getArrowheadService()` if your custom class is not spring managed. *(**Look for the java docs** attached for each method within this class.)* +Skeletons are built on the [`Arrowhead Application Library`](https://github.com/arrowhead-f/application-library-java-spring) which is also imported to this project as a Maven dependency. The application library provides the `ArrowheadService.class` which is a singleton spring managed bean and designed with the purpose of interacting with Arrowhead Framework. Use its methods by [autowiring](https://www.baeldung.com/spring-autowire) into your spring managed custom classes or use `ArrowheadBeans.getArrowheadService()` if your custom class is not spring managed. *(**Look for the java docs** attached for each method within this class.)* -Each client skeleton has a default 'ApplicationInitListener' and a default 'SecurityConfig' what you can change or extend. The essential configuration has to be managed by customizing the `application.properties` file, located in `src/main/resources` folder. +Each application skeleton has a default 'ApplicationInitListener' and a default 'SecurityConfig' what you can change or extend. The essential configuration has to be managed by customizing the `application.properties` file, located in `src/main/resources` folder. ### Best practices to start with the skeletons @@ -36,7 +36,7 @@ Location: `src/main/resources` * Decide the required security level and set the `server.ssl.enabled` and `token.security.filter.enabled` properties accordingly. * If `token.security.filter.enabled` is true, `server.ssl.enabled` also has to be true !!! * [Create](https://github.com/arrowhead-f/core-java-spring#certificates) your own client certificate (or for demo purpose use the provided one) and update the further `server.ssl...` properties accordingly. *(**Note** that `server.ssl.key-store-password` and `server.ssl.key-password` must be the same.)* -* Change the `client_system_name` property to your system name. *(**Note** that it should be in line with your certificate common name e.g.: when your certificate common name is `my-awesome-client.my-cloud.my-company.arrowhed.eu`, then your system name is  `my-awesome-client`)* +* Change the `application_system_name` property to your system name. *(**Note** that it should be in line with your certificate common name e.g.: when your certificate common name is `my-awesome-client.my-cloud.my-company.arrowhed.eu`, then your system name is  `my-awesome-client`)* * Adjust the Service Registry Core System location by the `sr_address` and `sr_port` properties. * In case of a provider you have to set its web-server parameters by the `server.address` and `server.port` properties. * In case of a consumer decide whether it should act as a web-server or not. If yes, then set the `spring.main.web-application-type` to 'servlet' and set further server parameters like in the provider case. If not, just leave these properties unchanged. @@ -51,9 +51,9 @@ All the provided skeleton classes are located in the child packages of the `eu.a * You can create your own packages like `com.my_company.my_awesome_project` to organize the skeleton and the application code separated. In the latter case if you wish to use Spring Beans at your custom packages, then you have to let the Spring Framework to known about your base package(s). This can be managed by adding the base package name(s) as a string value(s) in the `@ComponentScan` annotation of the application's `Main.class` *(**Look for the 'TODO' mark** within the main class)*. ##### (3rd) security configuration -The skeletons provide a built-in arrowhed framework compatible security configuration located in `eu.arrowhead.client.skeleton.consumer|provider.security` package. -* The `ConsumerSecurityConfig.class`, the `ProviderSecurityConfig.class`, the `SubscriberSecurityConfig.class` and the `PublisherSecurityConfig.class` extends the `DefaultSecurityConfig.class` which is imported by the client-library dependency and responsible for setting the `server.ssl.enabled` property declared in the `application.properties`. *(**Note:** The `ConsumerSecurityConfig.class` is became effective only when your consumer is a web-server.)* -* The `ConsumerAccessControlFilter.class` the `ProviderSecurityConfig.class`, the `SubscriberSecurityConfig.class` and the `PublisherSecurityConfig.class` extends the `AccessControlFilter.class` which is imported by the client-library dependency and responsible for setting the security level based on the `application.properties`. +The skeletons provide a built-in arrowhed framework compatible security configuration located in `eu.arrowhead.application.skeleton.consumer|provider.security` package. +* The `ConsumerSecurityConfig.class`, the `ProviderSecurityConfig.class`, the `SubscriberSecurityConfig.class` and the `PublisherSecurityConfig.class` extends the `DefaultSecurityConfig.class` which is imported by the application-library dependency and responsible for setting the `server.ssl.enabled` property declared in the `application.properties`. *(**Note:** The `ConsumerSecurityConfig.class` is became effective only when your consumer is a web-server.)* +* The `ConsumerAccessControlFilter.class` the `ProviderSecurityConfig.class`, the `SubscriberSecurityConfig.class` and the `PublisherSecurityConfig.class` extends the `AccessControlFilter.class` which is imported by the application-library dependency and responsible for setting the security level based on the `application.properties`.   -  `ConsumerAccessControlFilter.class` is effective only when your consumer is a web-server and `server.ssl.enabled` property is set to true. This filter is responsible for validating whether the received HTTPS request is coming from one of the local cloud's clients based on its certificate. *(**Look for the 'TODO' mark** within this class if you want to implement additional access rules.)*   -  `ProviderAccessControlFilter.class` is doing the same as described in the consumer case, but is effective only when `server.ssl.enabled` property is set to true and `token.security.filter.enabled` property is set to false. When `token.security.filter.enabled` property is set to true, then `ProviderTokenSecurityFilter.class` is effective which is validating whether a token is received within the HTTPS request and whether it is a valid one ore not. *(**Note** that the token is created by the Authorization Core System during the orchestration process and the consumer have to put it into its HTTPS request as a query parameter.)*   -  `PublisherAccessControlFilter.class` is doing the same as described in the provider case, but when `token.security.filter.enabled` property is set to true, then `PublisherTokenSecurityFilter.class` is effective and is doing the same as described in the provider case. @@ -62,7 +62,7 @@ The skeletons provide a built-in arrowhed framework compatible security configur * The `SubscriberNotificationAccessControlFilter.class` is checking the requested target URI and if it is registered in the application.properties as notification URI then validating whether the requester is an allowed Core System. If the requester is not allowed, it throws an AuthExeption with `" is unauthorized to access "` text in the message body. *(**Note:** By default only the `EVENT HANDLER CORE SYSTEM` is allowed.)* ##### (4th) start-up & shutdown configuration -The skeletons provide a built-in application start-up and shutdown configuration located in `eu.arrowhead.client.skeleton.consumer|provider` package. +The skeletons provide a built-in application start-up and shutdown configuration located in `eu.arrowhead.application.skeleton.consumer|provider` package. The `ConsumerApplicationInitListener.class`, the `ProviderApplicationInitListener.class`, `PublisherApplicationInitListener.class` and the `SubscriberApplicationInitListener.class` contains the `customInit()` method which is executed automatically right after the application start-up and also the `customDestroy()` method which is executed automatically right after triggering the application shutdown, but still before the final stop. *(**Look for the 'TODO' marks** within these classes if you want to implement additional logic.)* ###### Already implemented Consumer start-up logic: @@ -108,4 +108,4 @@ The `ConsumerApplicationInitListener.class`, the `ProviderApplicationInitListene ###### Already implemented Subscriber shutdown logics: * Unsubscribing from the event types defined in apllication.properties. -##### Check [`sos-examples-spring`](https://github.com/arrowhead-f/sos-examples-spring) repository for full demo client implementations. +##### Check [`sos-examples-spring`](https://github.com/arrowhead-f/sos-examples-spring) repository for full demo application implementations. From 04caef4a0a6b14288ea7de1aaf3be55b2b05283d Mon Sep 17 00:00:00 2001 From: Tamas Bordi Date: Wed, 1 Sep 2021 13:13:49 +0200 Subject: [PATCH 08/11] check configuration (cherry picked from commit 02d55234ce67cf0f4a5f1db64e83b1726af82578) --- .../provider/ProviderApplicationInitListener.java | 11 ++++++++++- .../publisher/PublisherApplicationInitListener.java | 11 ++++++++++- .../subscriber/SubscriberApplicationInitListener.java | 11 ++++++++++- 3 files changed, 30 insertions(+), 3 deletions(-) diff --git a/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java index 1f5e0f5..e6cd326 100644 --- a/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java @@ -50,7 +50,8 @@ public class ProviderApplicationInitListener extends ApplicationInitListener { //------------------------------------------------------------------------------------------------- @Override protected void customInit(final ContextRefreshedEvent event) { - + checkConfiguration(); + //Checking the availability of necessary core systems checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); if (sslEnabled && tokenSecurityFilterEnabled) { @@ -76,6 +77,14 @@ public void customDestroy() { //================================================================================================= // assistant methods + + //------------------------------------------------------------------------------------------------- + private void checkConfiguration() { + if (!sslEnabled && tokenSecurityFilterEnabled) { + logger.info("Contradictory configuration:"); + logger.info("token.security.filter.enabled=true while server.ssl.enabled=false"); + } + } //------------------------------------------------------------------------------------------------- private void setTokenSecurityFilter() { diff --git a/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java index e1ca8f3..f77e795 100644 --- a/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java @@ -66,7 +66,8 @@ public class PublisherApplicationInitListener extends ApplicationInitListener { //------------------------------------------------------------------------------------------------- @Override protected void customInit(final ContextRefreshedEvent event) { - + checkConfiguration(); + //Checking the availability of necessary core systems checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); @@ -99,6 +100,14 @@ public void customDestroy() { //================================================================================================= // assistant methods + + //------------------------------------------------------------------------------------------------- + private void checkConfiguration() { + if (!sslEnabled && tokenSecurityFilterEnabled) { + logger.info("Contradictory configuration:"); + logger.info("token.security.filter.enabled=true while server.ssl.enabled=false"); + } + } //------------------------------------------------------------------------------------------------- private void setTokenSecurityFilter() { diff --git a/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java index 493a71f..aa7a533 100644 --- a/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java @@ -66,7 +66,8 @@ public class SubscriberApplicationInitListener extends ApplicationInitListener { //------------------------------------------------------------------------------------------------- @Override protected void customInit(final ContextRefreshedEvent event) { - + checkConfiguration(); + //Checking the availability of necessary core systems checkCoreSystemReachability(CoreSystem.SERVICEREGISTRY); @@ -116,6 +117,14 @@ public void customDestroy() { //================================================================================================= // assistant methods + + //------------------------------------------------------------------------------------------------- + private void checkConfiguration() { + if (!sslEnabled && tokenSecurityFilterEnabled) { + logger.info("Contradictory configuration:"); + logger.info("token.security.filter.enabled=true while server.ssl.enabled=false"); + } + } //------------------------------------------------------------------------------------------------- private void setTokenSecurityFilter() { From b9b3893a71071860956eec84f1f1256fa17efe3a Mon Sep 17 00:00:00 2001 From: Tamas Bordi Date: Wed, 1 Sep 2021 13:31:18 +0200 Subject: [PATCH 09/11] check configuration change log level to warn --- .../skeleton/provider/ProviderApplicationInitListener.java | 4 ++-- .../skeleton/publisher/PublisherApplicationInitListener.java | 4 ++-- .../subscriber/SubscriberApplicationInitListener.java | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java index e6cd326..3ebf2d0 100644 --- a/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderApplicationInitListener.java @@ -81,8 +81,8 @@ public void customDestroy() { //------------------------------------------------------------------------------------------------- private void checkConfiguration() { if (!sslEnabled && tokenSecurityFilterEnabled) { - logger.info("Contradictory configuration:"); - logger.info("token.security.filter.enabled=true while server.ssl.enabled=false"); + logger.warn("Contradictory configuration:"); + logger.warn("token.security.filter.enabled=true while server.ssl.enabled=false"); } } diff --git a/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java index f77e795..e8b0de3 100644 --- a/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherApplicationInitListener.java @@ -104,8 +104,8 @@ public void customDestroy() { //------------------------------------------------------------------------------------------------- private void checkConfiguration() { if (!sslEnabled && tokenSecurityFilterEnabled) { - logger.info("Contradictory configuration:"); - logger.info("token.security.filter.enabled=true while server.ssl.enabled=false"); + logger.warn("Contradictory configuration:"); + logger.warn("token.security.filter.enabled=true while server.ssl.enabled=false"); } } diff --git a/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java index aa7a533..b2a3f8a 100644 --- a/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberApplicationInitListener.java @@ -121,8 +121,8 @@ public void customDestroy() { //------------------------------------------------------------------------------------------------- private void checkConfiguration() { if (!sslEnabled && tokenSecurityFilterEnabled) { - logger.info("Contradictory configuration:"); - logger.info("token.security.filter.enabled=true while server.ssl.enabled=false"); + logger.warn("Contradictory configuration:"); + logger.warn("token.security.filter.enabled=true while server.ssl.enabled=false"); } } From 65bccbc91ce7e510af342e0e466099d12f404d76 Mon Sep 17 00:00:00 2001 From: Tamas Bordi Date: Tue, 9 Nov 2021 10:54:53 +0100 Subject: [PATCH 10/11] add missing base package to component scan --- .../arrowhead/application/skeleton/consumer/ConsumerMain.java | 2 +- .../arrowhead/application/skeleton/provider/ProviderMain.java | 2 +- .../arrowhead/application/skeleton/publisher/PublisherMain.java | 2 +- .../application/skeleton/subscriber/SubscriberMain.java | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java index 37bb986..4623955 100644 --- a/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java +++ b/application-skeleton-consumer/src/main/java/eu/arrowhead/application/skeleton/consumer/ConsumerMain.java @@ -21,7 +21,7 @@ import eu.arrowhead.common.exception.ArrowheadException; @SpringBootApplication -@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE}) //TODO: add custom packages if any +@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE, "ai.aitia"}) //TODO: add custom packages if any public class ConsumerMain implements ApplicationRunner { //================================================================================================= diff --git a/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java index f96f95e..5ef7484 100644 --- a/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java +++ b/application-skeleton-provider/src/main/java/eu/arrowhead/application/skeleton/provider/ProviderMain.java @@ -7,7 +7,7 @@ import eu.arrowhead.common.CommonConstants; @SpringBootApplication -@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE}) //TODO: add custom packages if any +@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE, "ai.aitia"}) //TODO: add custom packages if any public class ProviderMain { //================================================================================================= diff --git a/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java index 71b7cce..836dd64 100644 --- a/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java +++ b/application-skeleton-publisher/src/main/java/eu/arrowhead/application/skeleton/publisher/PublisherMain.java @@ -24,7 +24,7 @@ import eu.arrowhead.common.dto.shared.SystemRequestDTO; @SpringBootApplication -@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE}) //TODO: add custom packages if any +@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE, "ai.aitia"}) //TODO: add custom packages if any public class PublisherMain implements ApplicationRunner { //================================================================================================= diff --git a/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java index ac64b43..6fefaf9 100644 --- a/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java +++ b/application-skeleton-subscriber/src/main/java/eu/arrowhead/application/skeleton/subscriber/SubscriberMain.java @@ -23,7 +23,7 @@ @SpringBootApplication @EnableConfigurationProperties(ConfigEventProperites.class) -@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE}) //TODO: add custom packages if any +@ComponentScan(basePackages = {CommonConstants.BASE_PACKAGE, "ai.aitia"}) //TODO: add custom packages if any public class SubscriberMain implements ApplicationRunner { //================================================================================================= From c2619d9298632750cb3b3562e3cc7dbb64ddc3b8 Mon Sep 17 00:00:00 2001 From: Tamas Bordi Date: Wed, 10 Nov 2021 14:30:37 +0100 Subject: [PATCH 11/11] change to arrowhead-application-library-java-spring v4.4.0.0 release --- pom.xml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/pom.xml b/pom.xml index 8bc805d..01304cb 100644 --- a/pom.xml +++ b/pom.xml @@ -30,13 +30,6 @@ application-skeleton-publisher - - - ossrh - https://s01.oss.sonatype.org/content/repositories/aiaitia-1017 - - - ai.aitia