Catches exception on get Configuration
This commit is contained in:
parent
096afda31c
commit
2465ed3741
|
@ -28,16 +28,21 @@ public class SDI {
|
||||||
|
|
||||||
@GET
|
@GET
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
// @JacksonFeatures(serializationEnable = { SerializationFeature.INDENT_OUTPUT })
|
|
||||||
public ScopeConfiguration getConfiguration(){
|
public ScopeConfiguration getConfiguration(){
|
||||||
|
try {
|
||||||
|
ScopeConfiguration config=sdiManager.getContextConfiguration();
|
||||||
|
log.debug("Served Configuration");
|
||||||
|
return config;
|
||||||
|
}catch(Throwable t) {
|
||||||
|
log.error("Unable to serve get configuration");
|
||||||
|
throw new WebApplicationException("Unable to get configuration. Contact administrator.",t);
|
||||||
|
}
|
||||||
|
|
||||||
return sdiManager.getContextConfiguration();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@GET
|
@GET
|
||||||
@Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
|
@Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
|
||||||
// @JacksonFeatures(serializationEnable = { SerializationFeature.INDENT_OUTPUT })
|
|
||||||
@Path("status")
|
@Path("status")
|
||||||
public HealthReport getReport() {
|
public HealthReport getReport() {
|
||||||
try{
|
try{
|
||||||
|
|
Loading…
Reference in New Issue