Skip to content

Commit

Permalink
BRMO-374: opruimen van BRK 1 referenties
Browse files Browse the repository at this point in the history
  • Loading branch information
mprins committed Nov 26, 2024
1 parent acb5dbe commit 1909e11
Show file tree
Hide file tree
Showing 14 changed files with 28 additions and 72 deletions.
4 changes: 2 additions & 2 deletions brmo-loader/src/main/java/nl/b3p/brmo/loader/RsgbProxy.java
Original file line number Diff line number Diff line change
Expand Up @@ -986,7 +986,7 @@ private StringBuilder parseOldData(
* formatting. De fallback optie voor formatting is {@code yyyy-MM-dd}, ondersteunde opties zijn:
*
* <ul>
* <li>{@code yyyy-MM-dd} (BRK / BRK2)
* <li>{@code yyyy-MM-dd} (BRK2)
* <li>{@code yyyyMMddHHmmssSSS0} (BAG)
* </ul>
*
Expand All @@ -995,7 +995,7 @@ private StringBuilder parseOldData(
* @return formatted datum, indien mogelijk in de vorm van {@code otherDate}
*/
private String formatDateLikeOtherDate(Date newDate, String otherDate) {
// 2010-06-29 (BRK/BRK2)
// 2010-06-29 (BRK2)
SimpleDateFormat dfltFmt = new SimpleDateFormat("yyyy-MM-dd");
// 201006291200000000 (BAG)
SimpleDateFormat f2 = new SimpleDateFormat("yyyyMMddHHmmssSSS0");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@
* Endpoint servlet welke geposte bestanden opslaat in een directory conform de configuratie. Deze
* servlet ondersteund gzip compressie. Voorbeeld:<br>
* {@code curl -X POST -H "Content-Type: application/xml"
* http://localhost:8037/brmo-proxyservice/post/brk -d @'pom.xml'} <br>
* http://localhost:8037/brmo-proxyservice/post/brk2 -d @'pom.xml'} <br>
* of met gzip compressie:<br>
* {@code curl -v -s --trace-ascii http_trace.log --data-binary @src/test/resources/web.xml.gz -H
* "Content-Type: text/xml" -H "Content-Encoding: gzip" -X POST
* http://localhost:8037/brmo-proxyservice/post/brk} <br>
* http://localhost:8037/brmo-proxyservice/post/brk2} <br>
* of met certificaat authenticatie en wget:<br>
* {@code wget --post-file="test.xml" --append-output=logs/wget.log --ca-cert=./ca.pem
* --certificate=./client.pem --private-key=./key.pem https://somehost.nl/brmo-proxyservice/post/brk
* -O - >> output.log}
* --certificate=./client.pem --private-key=./key.pem
* https://somehost.nl/brmo-proxyservice/post/brk2 -O - >> output.log}
*
* @author mprins
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

/**
* Endpoint servlet welke geposte bestanden doorstuurt naar de BRMO. Voorbeeld: {@code curl -X POST
* -H "Content-Type: application/xml" http://localhost:8084/brmo-proxyservice/post/brk
* -H "Content-Type: application/xml" http://localhost:8084/brmo-proxyservice/post/brk2
* -d @'/testbestanden/BRK_KLEIN_SNAPSHOT.xml'}
*
* @author mprins
Expand Down
23 changes: 0 additions & 23 deletions brmo-proxyservice/src/main/webapp/WEB-INF/web.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,6 @@
version="3.1"
metadata-complete="true">
<display-name>brmo-proxyservices</display-name>
<servlet>
<servlet-name>BRK_file</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointFileServlet</servlet-class>
<init-param>
<description>directory waar bestanden terecht komen</description>
<param-name>save_dir</param-name>
<param-value>/var/opt/brmo/brk/</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>BRK2_file</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointFileServlet</servlet-class>
Expand All @@ -32,15 +23,6 @@
<param-value>/var/opt/brmo/woz</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>BRK_proxy</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointProxyServlet</servlet-class>
<init-param>
<description>BRMO endpoint waarnaartoe door-gepost wordt</description>
<param-name>proxy_for_url</param-name>
<param-value>http://localhost:8037/brmo-service/post/brk</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>BRK2_proxy</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointProxyServlet</servlet-class>
Expand All @@ -59,11 +41,6 @@
<param-value>http://localhost:8037/brmo-service/post/woz</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>BRK_file</servlet-name>
<!--<servlet-name>BRK_proxy</servlet-name>-->
<url-pattern>/post/brk</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>BRK2_file</servlet-name>
<!--<servlet-name>BRK_proxy</servlet-name>-->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ void testPostBRK() throws Exception {
new File(BerichtEndpointFileServletTest.class.getResource("/test.xml").getFile());
assertNotNull(expected, "Expected file not found");
// servlet schrijft naar saveDir,
// /tmp/brk/post-op_<yyyy-MM-dd_HH-mm-ss-SSS>_<randomuniek>.xml
File actual =
Files.newDirectoryStream(new File(saveDir).toPath(), "*.{xml}").iterator().next().toFile();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,9 +194,6 @@ public void setAdvancedFunctionProcessName(String advancedFunctionProcessName) {

@Before(stages = LifecycleStage.BindingAndValidation)
public void populateAdvancedFunctionProcesses() {
String brkExportDir = this.getContext().getServletContext().getInitParameter("exportDir.brk");
LOG.warn("Instellen BRK export directory op niet-default waarde: " + brkExportDir);

// bij een nieuw proces ook de wiki bijwerken:
// https://github.com/B3Partners/brmo/wiki/Geavanceerde-functies
advancedFunctionProcesses =
Expand Down
8 changes: 1 addition & 7 deletions brmo-service/src/main/webapp/WEB-INF/web.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<context-param>
<description>Gebruik (true) multithreaded XSL transformatie/GML parse pipeline of niet (false). Om op correcte wijze WOZ en BRP
berichten te kunnen verwerken dient deze op false te worden ingesteld - omdat deze geen was/wordt leveren, maar een (onvolledige) toestandmutatie.
Voor BRK/nHR berichten kan deze op true worden ingesteld. Eventueel kan dan ook de onderstaande pipelining.capacity worden aangepast.</description>
Voor BRK2/nHR berichten kan deze op true worden ingesteld. Eventueel kan dan ook de onderstaande pipelining.capacity worden aangepast.</description>
<param-name>pipelining.enabled</param-name>
<param-value>false</param-value>
</context-param>
Expand Down Expand Up @@ -38,12 +38,6 @@
<param-name>stand.transform.max</param-name>
<param-value>1000000</param-value>
</context-param>
<context-param>
<description>BRK export locatie, een bestaande directory waar de servlet container mag schrijven.
Default waarde is /tmp/brkmutaties</description>
<param-name>exportDir.brk</param-name>
<param-value>/tmp/brkmutaties</param-value>
</context-param>
<context-param>
<description>Aantal uitvoerende threads voor ingeplande taken. Default waarde is 1, bij hogere waarden dient de
gebruiker er voor te zorgen dat er geen in de tijd overlappende transformatie of GDS2 processen van
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,15 +151,6 @@ public void endTest(TestInfo testInfo) {
@AfterAll
public static void closeConnections() throws SQLException {
// JNDI connectie pools niet sluiten!
// if (dsStaging != null) {
// dsStaging.close();
// }
// if (dsRsgb != null) {
// dsRsgb.close();
// }
// if (dsRsgbBrk != null) {
// dsRsgbBrk.close();
// }
try {
InitialContext ic = new InitialContext();
ic.unbind("java:comp/env/jdbc/brmo/rsgb");
Expand Down
8 changes: 4 additions & 4 deletions brmo-test-util/src/test/resources/web-invalid-jee6.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@
metadata-complete="true">
<display-name>brmo-proxyservices</display-name>
<servlet>
<servlet-name>BRK_file</servlet-name>
<servlet-name>BRK2_file</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointFileServlet</servlet-class>
<init-param>
<param-name>save_dir</param-name>
<param-value>/var/opt/brmo/brk/</param-value>
<param-value>/var/opt/brmo/brk2/</param-value>
<description>expres ongeldig</description>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>BRK_file</servlet-name>
<url-pattern>/post/brk</url-pattern>
<servlet-name>BRK2_file</servlet-name>
<url-pattern>/post/brk2</url-pattern>
</servlet-mapping>

</web-app>
12 changes: 6 additions & 6 deletions brmo-test-util/src/test/resources/web-valid-jee6.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
metadata-complete="true">
<display-name>brmo-proxyservices</display-name>
<servlet>
<servlet-name>BRK_file</servlet-name>
<servlet-name>BRK2_file</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointFileServlet</servlet-class>
<init-param>
<description>directory waar bestanden terecht komen</description>
<param-name>save_dir</param-name>
<param-value>/var/opt/brmo/brk/</param-value>
<param-value>/var/opt/brmo/brk2/</param-value>
</init-param>
</servlet>
<servlet>
Expand All @@ -24,7 +24,7 @@
</init-param>
</servlet>
<servlet>
<servlet-name>BRK_proxy</servlet-name>
<servlet-name>BRK2_proxy</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointProxyServlet</servlet-class>
<init-param>
<description>BRMO endpoint waarnaartoe door-gepost wordt</description>
Expand All @@ -42,9 +42,9 @@
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>BRK_file</servlet-name>
<!--<servlet-name>BRK_proxy</servlet-name>-->
<url-pattern>/post/brk</url-pattern>
<servlet-name>BRK2_file</servlet-name>
<!--<servlet-name>BRK2_proxy</servlet-name>-->
<url-pattern>/post/brk2</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>BAG_file</servlet-name>
Expand Down
12 changes: 6 additions & 6 deletions brmo-test-util/src/test/resources/web-valid-jee7.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
version="3.1">
<display-name>brmo-proxyservices</display-name>
<servlet>
<servlet-name>BRK_file</servlet-name>
<servlet-name>BRK2_file</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointFileServlet</servlet-class>
<init-param>
<description>directory waar bestanden terecht komen</description>
<param-name>save_dir</param-name>
<param-value>/var/opt/brmo/brk/</param-value>
<param-value>/var/opt/brmo/brk2/</param-value>
</init-param>
</servlet>
<servlet>
Expand All @@ -23,12 +23,12 @@
</init-param>
</servlet>
<servlet>
<servlet-name>BRK_proxy</servlet-name>
<servlet-name>BRK2_proxy</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointProxyServlet</servlet-class>
<init-param>
<description>BRMO endpoint waarnaartoe door-gepost wordt</description>
<param-name>proxy_for_url</param-name>
<param-value>http://localhost:8037/brmo-service/post/brk</param-value>
<param-value>http://localhost:8037/brmo-service/post/brk2</param-value>
</init-param>
</servlet>
<servlet>
Expand All @@ -41,9 +41,9 @@
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>BRK_file</servlet-name>
<servlet-name>BRK2_file</servlet-name>
<!--<servlet-name>BRK_proxy</servlet-name>-->
<url-pattern>/post/brk</url-pattern>
<url-pattern>/post/brk2</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>BAG_file</servlet-name>
Expand Down
8 changes: 4 additions & 4 deletions brmo-test-util/src/test/resources/web-valid-jee8.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
version="4.0">
<display-name>brmo-proxyservices</display-name>
<servlet>
<servlet-name>BRK_file</servlet-name>
<servlet-name>BRK2_file</servlet-name>
<servlet-class>nl.b3p.brmo.service.proxy.BerichtEndpointFileServlet</servlet-class>
<init-param>
<description>directory waar bestanden terecht komen</description>
<param-name>save_dir</param-name>
<param-value>/var/opt/brmo/brk/</param-value>
<param-value>/var/opt/brmo/brk2/</param-value>
</init-param>
</servlet>
<servlet>
Expand All @@ -23,8 +23,8 @@
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>BRK_file</servlet-name>
<url-pattern>/post/brk</url-pattern>
<servlet-name>BRK2_file</servlet-name>
<url-pattern>/post/brk2</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>BAG_file</servlet-name>
Expand Down
1 change: 0 additions & 1 deletion docker/src/main/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ SHELL ["/bin/bash", "-eux", "-o", "pipefail", "-c"]
RUN set -eux;ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone \
&& mkdir -p /opt/brmo-data/BGT/ \
&& mkdir -p /opt/brmo-data/NHR/certificaten/ \
&& mkdir -p /opt/brmo-data/BRK/berichtendump \
&& mkdir -p /opt/brmo-data/TOPNL/Top10NL/ \
&& mkdir -p /opt/brmo-data/TOPNL/Top50NL/ \
&& mkdir -p /opt/brmo-data/TOPNL/Top100NL/ \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,4 @@
</Realm>
<Parameter name="stand.transform.max.size" value="-1" override="false"/>
<Parameter name="pipelining.enabled" value="true" override="false"/>
<Parameter name="exportDir.brk" value="true" override="/opt/brmo-data/BRK/berichtendump"/>
</Context>

0 comments on commit 1909e11

Please sign in to comment.