ext/common/ApplicationPool2/SpawnerFactory.h in passenger-4.0.48 vs ext/common/ApplicationPool2/SpawnerFactory.h in passenger-4.0.49
- old
+ new
@@ -42,11 +42,11 @@
private:
ServerInstanceDir::GenerationPtr generation;
boost::mutex syncher;
SpawnerConfigPtr config;
DummySpawnerPtr dummySpawner;
-
+
SpawnerPtr tryCreateSmartSpawner(const Options &options) {
string dir = config->resourceLocator.getHelperScriptsDir();
vector<string> preloaderCommand;
if (options.appType == "classic-rails") {
preloaderCommand.push_back(options.ruby);
@@ -58,19 +58,19 @@
return SpawnerPtr();
}
return boost::make_shared<SmartSpawner>(generation, preloaderCommand,
options, config);
}
-
+
public:
SpawnerFactory(const ServerInstanceDir::GenerationPtr &_generation,
const SpawnerConfigPtr &_config)
: generation(_generation),
config(_config)
{ }
-
+
virtual ~SpawnerFactory() { }
-
+
virtual SpawnerPtr create(const Options &options) {
if (options.spawnMethod == "smart" || options.spawnMethod == "smart-lv2") {
SpawnerPtr spawner = tryCreateSmartSpawner(options);
if (spawner == NULL) {
spawner = boost::make_shared<DirectSpawner>(generation, config);