本文整理汇总了C++中SipxProcess类的典型用法代码示例。如果您正苦于以下问题:C++ SipxProcess类的具体用法?C++ SipxProcess怎么用?C++ SipxProcess使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了SipxProcess类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: evRestartProcess
void Testing::evRestartProcess( SipxProcess& impl ) const
{
Os::Logger::instance().log(FAC_SUPERVISOR, PRI_DEBUG,"'%s': aborting configtest in order to restart",
impl.name());
ChangeState( impl, impl.pStoppingConfigtestToRestart );
impl.killConfigTest();
}
示例2: evShutdown
void Testing::evShutdown( SipxProcess& impl ) const
{
Os::Logger::instance().log(FAC_SUPERVISOR, PRI_DEBUG,"'%s': aborting configtest in order to shutdown",
impl.name());
ChangeState( impl, impl.pShuttingDown );
impl.killConfigTest();
}
示例3: evStopProcess
void SipxProcessFsm::evStopProcess( SipxProcess& impl ) const
{
Os::Logger::instance().log(FAC_SUPERVISOR,PRI_INFO,"'%s': Received event evStopProcess while in state '%s'",
impl.name(), impl.GetCurrentState()->name() );
ChangeState( impl, impl.pStopping);
}
示例4: DoEntryAction
void Testing::DoEntryAction( SipxProcess& impl ) const
{
impl.checkThreadId();
impl.clearStatusMessages();
impl.startConfigTest();
}
示例5: evRestartProcess
void SipxProcessFsm::evRestartProcess( SipxProcess& impl ) const
{
OsSysLog::add(FAC_SUPERVISOR,PRI_INFO,"'%s': Received event evRestartProcess while in state '%s'",
impl.name(), impl.GetCurrentState()->name() );
ChangeState( impl, impl.pConfigurationMismatch );
}
示例6: evResyncProcess
void SipxProcessFsm::evResyncProcess( SipxProcess& impl ) const
{
Os::Logger::instance().log(FAC_SUPERVISOR,PRI_INFO,"'%s': Received event evResyncProcess while in state '%s'",
impl.name(), impl.GetCurrentState()->name() );
ChangeState( impl, impl.pConfigurationMismatch );
}
示例7: DoEntryAction
void Stopping::DoEntryAction( SipxProcess& impl ) const
{
impl.checkThreadId();
impl.notifyShutdown();
impl.startStopTimer();
impl.stopProcess();
}
示例8: evProcessStopped
void SipxProcessFsm::evProcessStopped( SipxProcess& impl ) const
{
Os::Logger::instance().log(FAC_SUPERVISOR,PRI_WARNING,"'%s': Received unexpected event evProcessStopped while in state '%s'",
impl.name(), impl.GetCurrentState()->name() );
ChangeState( impl, impl.pFailed);
}
示例9: evConfigurationVersionUpdated
void ConfigurationMismatch::evConfigurationVersionUpdated( SipxProcess& impl ) const
{
impl.clearStatusMessages();
if ( impl.configurationVersionMatches() )
{
ChangeState( impl, impl.pResourceRequired );
}
}
示例10: evProcessStarted
void Starting::evProcessStarted( SipxProcess& impl ) const
{
if (impl.hadProcessFailed())
{
Alarm::raiseAlarm("PROCESS_RESTARTED", impl.data());
}
else if (impl.hadProcessBlocked())
{
Alarm::raiseAlarm("PROCESS_STARTED", impl.data());
impl.clearProcessBlocked();
}
ChangeState( impl, impl.pRunning );
}
示例11: getProcess
// Whether or not the SipxProcessResource is ready for use by a SipxProcess.
bool SipxProcessResource::isReadyToStart(UtlString& missingResource)
{
SipxProcess* myProcess = getProcess();
bool bReady = (myProcess && myProcess->isRunning());
if ( !bReady )
{
missingResource = "";
appendDescription(missingResource);
OsSysLog::add(FAC_SUPERVISOR, PRI_WARNING,
"SipxProcessResource::isReadyToStart returns false; %s is not running ",
data());
}
return bReady;
}
示例12: processes
// Fill in a map of process names and states (as UtlStrings)
void SipxProcessManager::getProcessStateAll(UtlHashMap& processStates //< key->name, value->state string
)
{
processStates.destroyAll();
SipxProcess* process;
// the lock is not required with the Iterator
UtlHashBagIterator processes(mProcesses);
while ((process = dynamic_cast<SipxProcess*>(processes())))
{
if ( 0 != process->compareTo(SUPERVISOR_PROCESS_NAME) )
{
processStates.insertKeyAndValue(new UtlString(process->data()),
new UtlString(process->GetCurrentState()->name())
);
}
}
}
示例13: evProcessStopped
// We need both the actual process, and the script which stops it, to finish
// before we move on. These events can come in any order.
void Stopping::evProcessStopped( SipxProcess& impl ) const
{
impl.checkThreadId();
if (impl.isCompletelyStopped())
{
if (impl.isEnabled())
{
ChangeState( impl, impl.pConfigurationMismatch );
}
else
{
ChangeState( impl, impl.pDisabled );
}
}
else
{
OsSysLog::add(FAC_SUPERVISOR, PRI_DEBUG,"'%s': process stopped, now wait for stop script", impl.name());
}
}
示例14: evStopCompleted
void Stopping::evStopCompleted( SipxProcess& impl ) const
{
impl.checkThreadId();
if (impl.isCompletelyStopped())
{
if (impl.isEnabled())
{
ChangeState( impl, impl.pConfigurationMismatch );
}
else
{
ChangeState( impl, impl.pDisabled );
}
}
else
{
Os::Logger::instance().log(FAC_SUPERVISOR, PRI_DEBUG,"'%s': stop completed, now wait for process stopped", impl.name());
}
}
示例15: processResources
/// Some change has been made to this resource; notify any SipxProcesses that use it.
void SipxResource::modified()
{
UtlSListIterator processResources(mUsedBy);
SipxProcessResource* processResource;
while ((processResource = dynamic_cast<SipxProcessResource*>(processResources())))
{
SipxProcess* process;
if ((process=processResource->getProcess()))
{
process->configurationChange(*this);
}
else
{
/* there is no process for this process resource
* - can happen when a definition is invalid, and has already been logged.
*/
}
}
}