Changes

Jump to: navigation, search

stoney cloud: Notification Architecture

1,084 bytes added, 08:29, 20 June 2014
/* Graphical Workflow */
You can modify/update these interactions by editing [[File:Notification-workflow.xmi]] (you may need [http://uml.sourceforge.net/ Umbrello UML Modeller] diagram programme for KDE to display the content properly).
 
= How to use the Notification.pm module =
Given the set up described in section [[#Requirements | requirements]]: <br/>
Suppose you have the <code><Service></code> "notification" and the <code><Problem></code> "test". The template referenced in the LDAP (<code>ou=test,ou=templates,uid=<RESELLER>,ou=reseller,ou=configuration,ou=notification,ou=services,dc=stoney-cloud,dc=org</code>) looks like:
<pre>
Hello {name}
 
This is a notification test from {hostname}
 
Cheers
Sysadm
</pre>
You can now write a very simple perl script which will inform the user and the reseller for the service "notification" and the problem "test". All you need to do is:
* Use the notification.pm module
* Create a new instance of the notification class with the following parameters
** service: "notification"
** problem: "test"
** product_uid: <UID>
<source lang="perl">
my $notification = Notification->new( service => "notification",
problem => "test",
product_uid => $uid,
);
<source>
= Source Code =
486
edits