39 |
|
|
40 |
CompositeNotifier notif = new CompositeNotifier(); |
CompositeNotifier notif = new CompositeNotifier(); |
41 |
notif.addNotifier( new JavaLogNotifier() ); |
notif.addNotifier( new JavaLogNotifier() ); |
42 |
notif.addNotifier( new MailNotifier("traininfo@t-hoerup.dk", "torben@t-hoerup.dk", "192.168.10.5") ); |
|
43 |
|
//only send mail on prod server |
44 |
|
if (sce.getServletContext().getRealPath("/").startsWith("/home/app/") ) { |
45 |
|
notif.addNotifier( new MailNotifier("traininfo@t-hoerup.dk", "torben@t-hoerup.dk", "192.168.10.5") ); |
46 |
|
} |
47 |
|
|
48 |
LoggingCircuitBreaker banedk = new LoggingCircuitBreaker("banedk", settings); |
LoggingCircuitBreaker banedk = new LoggingCircuitBreaker("banedk", settings); |
49 |
banedk.setNotifier(notif); |
banedk.setNotifier(notif); |