use of org.olat.restapi.system.vo.IndexerStatus in project OpenOLAT by OpenOLAT.
the class IndexerWebService method getStatus.
/**
* Return the status of the indexer: running, stopped
* @response.representation.200.mediaType application/xml, application/json
* @response.representation.200.doc The status of the indexer
* @response.representation.401.doc The roles of the authenticated user are not sufficient
* @return The status of the indexer
*/
@GET
@Path("status")
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
public Response getStatus() {
String status;
SearchServiceStatus serviceStatus = SearchServiceFactory.getService().getStatus();
if (serviceStatus instanceof SearchServiceStatusImpl) {
status = serviceStatus.getStatus();
} else {
status = "disabled";
}
return Response.ok(new IndexerStatus(status)).build();
}
use of org.olat.restapi.system.vo.IndexerStatus in project openolat by klemens.
the class IndexerWebService method getStatus.
/**
* Return the status of the indexer: running, stopped
* @response.representation.200.mediaType application/xml, application/json
* @response.representation.200.doc The status of the indexer
* @response.representation.401.doc The roles of the authenticated user are not sufficient
* @return The status of the indexer
*/
@GET
@Path("status")
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
public Response getStatus() {
String status;
SearchServiceStatus serviceStatus = SearchServiceFactory.getService().getStatus();
if (serviceStatus instanceof SearchServiceStatusImpl) {
status = serviceStatus.getStatus();
} else {
status = "disabled";
}
return Response.ok(new IndexerStatus(status)).build();
}
Aggregations