24 |
import org.w3c.dom.Document; |
import org.w3c.dom.Document; |
25 |
import org.w3c.dom.Element; |
import org.w3c.dom.Element; |
26 |
|
|
27 |
|
import dk.thoerup.curcuitbreaker.CircuitBreakerException; |
28 |
import dk.thoerup.traininfoservice.DBConnection; |
import dk.thoerup.traininfoservice.DBConnection; |
29 |
|
|
30 |
/** |
/** |
54 |
logger.warning("Read timed out, station="+station); |
logger.warning("Read timed out, station="+station); |
55 |
resp.sendError(500); |
resp.sendError(500); |
56 |
return; |
return; |
57 |
} catch (Exception e) { |
} catch (CircuitBreakerException cbe) { |
58 |
|
logger.warning("Circuitbreaker - failing fast"); |
59 |
|
resp.sendError(500); |
60 |
|
return; |
61 |
|
} catch (Throwable e) { |
62 |
logger.log(Level.WARNING, "Unknown exception, station=" +station, e); |
logger.log(Level.WARNING, "Unknown exception, station=" +station, e); |
63 |
resp.sendError(500); |
resp.sendError(500); |
64 |
return; |
return; |