@@ -73,7 +73,7 @@ |
||
73 | 73 | } |
74 | 74 | } |
75 | 75 | if (!in_array($this->options['backend'], $this->supportedBackends)) { |
76 | - throw new \InvalidArgumentException("Unsupported backend '" . $this->options['backend'] . "'"); |
|
76 | + throw new \InvalidArgumentException("Unsupported backend '".$this->options['backend']."'"); |
|
77 | 77 | } |
78 | 78 | } |
79 | 79 |
@@ -279,7 +279,7 @@ |
||
279 | 279 | $classpath = implode(':', $jars); |
280 | 280 | $threads = $this->config->getThreads(); |
281 | 281 | |
282 | - $directives = ' -D' . implode(' -D', [ |
|
282 | + $directives = ' -D'.implode(' -D', [ |
|
283 | 283 | 'php.java.bridge.daemon="false"', |
284 | 284 | "php.java.bridge.threads=$threads" |
285 | 285 | ]); |
@@ -24,11 +24,11 @@ |
||
24 | 24 | */ |
25 | 25 | public function logServerConfig(ConsoleLogger $logger, Config $config) |
26 | 26 | { |
27 | - $logger->info('* config port :' . $config->getPort()); |
|
28 | - $logger->info('* config log_file :' . $config->getLogFile()); |
|
29 | - $logger->info('* config pid_file :' . $config->getPidFile()); |
|
30 | - $logger->info('* config classpaths :' . implode(',', $config->getClasspaths())); |
|
31 | - $logger->info('* config java_bin :' . $config->getJavaBin()); |
|
32 | - $logger->info('* config server_jar :' . $config->getServerJar()); |
|
27 | + $logger->info('* config port :'.$config->getPort()); |
|
28 | + $logger->info('* config log_file :'.$config->getLogFile()); |
|
29 | + $logger->info('* config pid_file :'.$config->getPidFile()); |
|
30 | + $logger->info('* config classpaths :'.implode(',', $config->getClasspaths())); |
|
31 | + $logger->info('* config java_bin :'.$config->getJavaBin()); |
|
32 | + $logger->info('* config server_jar :'.$config->getServerJar()); |
|
33 | 33 | } |
34 | 34 | } |
@@ -223,7 +223,7 @@ discard block |
||
223 | 223 | { |
224 | 224 | // Four levels back. |
225 | 225 | $ds = DIRECTORY_SEPARATOR; |
226 | - $dir = __DIR__ . "$ds..$ds..$ds..$ds..$ds"; |
|
226 | + $dir = __DIR__."$ds..$ds..$ds..$ds..$ds"; |
|
227 | 227 | $base_dir = realpath($dir); |
228 | 228 | if (!$base_dir) { |
229 | 229 | $message = 'Cannot resolve project base directory.'; |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | |
253 | 253 | // Step 2: server_jar file must exists |
254 | 254 | if (!is_file($config['server_jar']) || !is_readable($config['server_jar'])) { |
255 | - throw new Exception\InvalidArgumentException("Server jar file not exists or unreadable. server-jar: '" . $config['server_jar'] . "'"); |
|
255 | + throw new Exception\InvalidArgumentException("Server jar file not exists or unreadable. server-jar: '".$config['server_jar']."'"); |
|
256 | 256 | } |
257 | 257 | |
258 | 258 | // Step 3: log and pid file should be creatable |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | public function isRunning($pid) |
40 | 40 | { |
41 | 41 | $cmd = sprintf('kill -0 %d 2>&1', $pid); |
42 | - $this->logger->debug(__METHOD__ . ": Exec command: $cmd"); |
|
42 | + $this->logger->debug(__METHOD__.": Exec command: $cmd"); |
|
43 | 43 | exec($cmd, $output, $return_var); |
44 | 44 | $running = ($return_var === 0); |
45 | 45 | |
@@ -63,13 +63,13 @@ discard block |
||
63 | 63 | if ($wait) { |
64 | 64 | $sleep_time = '0.2'; |
65 | 65 | $cmd = sprintf('kill %d; while ps -p %d; do sleep %s;done;', $pid, $pid, $sleep_time); |
66 | - $this->logger->debug(__METHOD__ . " Exec command: $cmd"); |
|
66 | + $this->logger->debug(__METHOD__." Exec command: $cmd"); |
|
67 | 67 | exec($cmd, $output, $return_var); |
68 | 68 | $killed = ($return_var === 0); |
69 | 69 | if ($killed) { |
70 | - $this->logger->debug(__METHOD__ . " Successfully killed process {$pid}"); |
|
70 | + $this->logger->debug(__METHOD__." Successfully killed process {$pid}"); |
|
71 | 71 | } else { |
72 | - $this->logger->notice(__METHOD__ . " Cannot kill process {$pid}, $output"); |
|
72 | + $this->logger->notice(__METHOD__." Cannot kill process {$pid}, $output"); |
|
73 | 73 | } |
74 | 74 | } else { |
75 | 75 | //@todo |
@@ -58,7 +58,7 @@ |
||
58 | 58 | $this->server = new StandaloneServer($config, $logger); |
59 | 59 | $this->server->restart(); |
60 | 60 | |
61 | - $logger->debug("Server output: \n" . $this->server->getOutput()); |
|
61 | + $logger->debug("Server output: \n".$this->server->getOutput()); |
|
62 | 62 | |
63 | 63 | $output->writeln("Server successfully restarted on port $port"); |
64 | 64 |
@@ -52,7 +52,7 @@ |
||
52 | 52 | $process = new Linux\LinuxProcess($logger); |
53 | 53 | break; |
54 | 54 | default: |
55 | - $msg = "System style '" . $style . "' is not supported"; |
|
55 | + $msg = "System style '".$style."' is not supported"; |
|
56 | 56 | throw new UnsupportedSystemException($msg); |
57 | 57 | } |
58 | 58 |