625626627628629630631632633634635
ServiceAlertsCollection collection = builder.build(); OutputStream out = null; try { out = new BufferedOutputStream(new FileOutputStream(path)); collection.writeTo(out); out.close(); } catch (Exception ex) { _log.error("error saving service alerts to path " + path, ex); } finally { if (out != null) {