public static void main(String[] args) throws Exception {
SCAContribution notificationContribution = locate("notification");
SCAContribution notificationJMSContribution = locate("notification-jms");
SCANode node =
SCANodeFactory.newInstance().createSCANode("notification-jms.composite",
notificationContribution,
notificationJMSContribution);
try {
node.start();
System.out.println("Quick notification test");
Notification notification = ((SCAClient)node).getService(Notification.class, "Notification");
String accountID = "1234";
String subject = "Holiday payment taken";
String message = "Payment of £102.37 accepted...";
notification.notify(accountID, subject, message);
System.out.println("Notification sent");
} finally {
node.stop();
}
}