mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-03-13 12:40:17 +00:00
dispatch examples update
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16923 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
f32d1b1534
commit
ed2ef13eac
@ -17,11 +17,16 @@ sub heartbeat {
|
|||||||
print Dumper $event;
|
print Dumper $event;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub channel_hangup {
|
||||||
|
my $self = shift;
|
||||||
|
my $event = $self->{event_hash};
|
||||||
|
print "DO SQL GOODIES HERE!\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
$0 = "ESL::Dispatch rocks!";
|
||||||
|
|
||||||
$daemon->set_worker(\&worker, 2000);
|
$daemon->set_worker(\&worker, 2000);
|
||||||
$daemon->set_callback("heartbeat", \&heartbeat);
|
$daemon->set_callback("heartbeat", \&heartbeat);
|
||||||
$daemon->set_callback("channel_hangup", \&heartbeat);
|
$daemon->set_callback("channel_hangup", \&channel_hangup);
|
||||||
|
|
||||||
|
|
||||||
$daemon->run;
|
$daemon->run;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user