Fixed runtime error related to XML marshaling
This commit is contained in:
parent
b39cecbfbc
commit
c2fe1c8240
@ -78,12 +78,11 @@ public class EnvoyClient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Send message
|
// Send message
|
||||||
String url = String.format("%s:%s/envoy-server/rest/message/send",
|
|
||||||
serverProps.getProperty("server"),
|
|
||||||
serverProps.getProperty("port"));
|
|
||||||
Client client = ClientBuilder.newClient();
|
Client client = ClientBuilder.newClient();
|
||||||
WebTarget target = client.target(url);
|
WebTarget target = client.target(String.format("%s:%s/envoy-server/rest/message/send",
|
||||||
Response response = target.request().post(Entity.entity(message, "application/xml"));
|
serverProps.getProperty("server"),
|
||||||
|
serverProps.getProperty("port")));
|
||||||
|
Response response = target.request().post(Entity.entity(messages, "application/xml"));
|
||||||
System.out.println("Response code: " + response.getStatus());
|
System.out.println("Response code: " + response.getStatus());
|
||||||
response.close();
|
response.close();
|
||||||
client.close();
|
client.close();
|
||||||
|
Reference in New Issue
Block a user