diff options
author | hclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-31 19:23:14 +0000 |
---|---|---|
committer | hclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-31 19:23:14 +0000 |
commit | 1e1fd49cfd5b770a7bdba08bfbba321748325f31 (patch) | |
tree | a7ff5c758fd389beaac2c7ac8ffc4b96635a383f /chrome/common/service_process_util.h | |
parent | b21d691e4e486071ac8601fee7867c29729faca6 (diff) | |
download | chromium_src-1e1fd49cfd5b770a7bdba08bfbba321748325f31.zip chromium_src-1e1fd49cfd5b770a7bdba08bfbba321748325f31.tar.gz chromium_src-1e1fd49cfd5b770a7bdba08bfbba321748325f31.tar.bz2 |
Use named events instead of lock files for service process
Use named events to signal that a service process is running.
BUG=52891
TEST=browser_tests --gtest_filter=ServiceProcess*
Review URL: http://codereview.chromium.org/3268003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@58041 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/service_process_util.h')
-rw-r--r-- | chrome/common/service_process_util.h | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/chrome/common/service_process_util.h b/chrome/common/service_process_util.h index 9894b1e..4ea6106 100644 --- a/chrome/common/service_process_util.h +++ b/chrome/common/service_process_util.h @@ -20,24 +20,14 @@ std::string GetServiceProcessChannelName(ServiceProcessType type); // The following methods are used as a mechanism to signal a service process // is running properly and all initialized. // -// The way it works is that we will create a file on the file system to indicate -// that service process is running. This way the browser process will know that -// it can connect to it without problem. -// -// When the service process this lock file is deleted. - +// Signal that the service process is running. // This method is called when the service process is running and initialized. -// Return true if lock file was created. -bool CreateServiceProcessLockFile(ServiceProcessType type); +void SignalServiceProcessRunning(ServiceProcessType type); -// This method deletes the lock file created by this above method. -// Return true if lock file was deleted. -bool DeleteServiceProcessLockFile(ServiceProcessType type); +// Signal that the service process is stopped. +void SignalServiceProcessStopped(ServiceProcessType type); -// This method checks that if the service process lock file exists. This means -// that the service process is running. -// TODO(hclam): We should use a better mechanism to detect that a service -// process is running. +// This method checks that if the service process is running. bool CheckServiceProcessRunning(ServiceProcessType type); #endif // CHROME_COMMON_SERVICE_PROCESS_UTIL_H_ |