mirror of
https://github.com/Unitech/pm2.git
synced 2025-12-08 20:35:53 +00:00
34 lines
660 B
JavaScript
34 lines
660 B
JavaScript
|
|
var axm = require('axm');
|
|
|
|
|
|
|
|
|
|
|
|
axm.action('refresh:db2', {comment : 'Refresh main database'}, function(reply) {
|
|
|
|
axm.emit('user:register', {
|
|
user : 'Alex registered',
|
|
email : 'thorustor@gmail.com'
|
|
});
|
|
|
|
reply({success : true});
|
|
});
|
|
|
|
|
|
|
|
axm.action('hello', {comment : 'Refresh main database'}, function(reply) {
|
|
console.log('Refreshing');
|
|
reply({success : true});
|
|
});
|
|
|
|
axm.action('refresh:db3', {comment : 'Comment'}, function(reply) {
|
|
throw new Error('asdadsadsasd');
|
|
reply({success : false});
|
|
});
|
|
|
|
axm.action('refresh:db', {comment : 'Refresh main database'}, function(reply) {
|
|
console.log('Refreshing');
|
|
reply({success : true});
|
|
});
|