e.printStackTrace();
}
}
private void setupServer(Application application) {
ResourceConfig rc = new ApplicationAdapter(application);
Map<String, Object> properties = new HashMap<String, Object>();
properties.put(ResourceConfig.FEATURE_TRACE, "true");
rc.setPropertiesAndFeatures(properties);
Properties serverProperties = readProperties();
int port = Integer.parseInt(serverProperties.getProperty(PORT_PROPERTY));
URI serverUri = UriBuilder.fromPath(ROOT_RESOURCE_PATH).scheme("http").host("localhost").port(port).build();
try {