I'm currently trying to to get the JSON-Response from the following URL using Apache Camel with its Jetty Component:
At this point, I have the following snippet:
public void configure() {
from("direct:dwd")
.setHeader(Exchange.HTTP_PATH, simple("/geoserver/dwd/ows"))
.setHeader(Exchange.HTTP_QUERY, simple("service=WFS&version=2.11.0&request=GetFeature&typeName=dwd:RBSN_RR&outputFormat=application%2Fjson"))
.setHeader(Exchange.HTTP_PATH, simple("GET"))
.to("jetty:https://maps.dwd.de")
.log("${body}");
}
What should I do to get the JSON-Response?
GET
. UseExchange.HTTP_METHOD, simple("GET")
instead. – Bedlatimer
to call route once after context started. Egfrom("timer://testDwd?repeatCount=1").to("direct:dwd");
– Bedla