Skip to content

Commit da43c55

Browse files
committed
Rename to Instasent
1 parent 6555cfa commit da43c55

16 files changed

+72
-72
lines changed

BCCResqueBundle.php

Lines changed: 0 additions & 9 deletions
This file was deleted.

Command/ClearQueueCommand.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\Command;
3+
namespace Instasent\ResqueBundle\Command;
44

55
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
66
use Symfony\Component\Console\Input\InputArgument;
@@ -12,15 +12,15 @@ class ClearQueueCommand extends ContainerAwareCommand
1212
protected function configure()
1313
{
1414
$this
15-
->setName('bcc:resque:clear-queue')
16-
->setDescription('Clear a BCC queue')
15+
->setName('instasent:resque:clear-queue')
16+
->setDescription('Clear a Instasent queue')
1717
->addArgument('queue', InputArgument::REQUIRED, 'Queue name')
1818
;
1919
}
2020

2121
protected function execute(InputInterface $input, OutputInterface $output)
2222
{
23-
$resque = $this->getContainer()->get('bcc_resque.resque');
23+
$resque = $this->getContainer()->get('instasent_resque.resque');
2424

2525
$queue = $input->getArgument('queue');
2626
$count = $resque->clearQueue($queue);

Command/StartScheduledWorkerCommand.php

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\Command;
3+
namespace Instasent\ResqueBundle\Command;
44

55
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
66
use Symfony\Component\Process\Process;
@@ -13,8 +13,8 @@ class StartScheduledWorkerCommand extends ContainerAwareCommand
1313
protected function configure()
1414
{
1515
$this
16-
->setName('bcc:resque:scheduledworker-start')
17-
->setDescription('Start a bcc scheduled resque worker')
16+
->setName('instasent:resque:scheduledworker-start')
17+
->setDescription('Start a instasent scheduled resque worker')
1818
->addOption('foreground', 'f', InputOption::VALUE_NONE, 'Should the worker run in foreground')
1919
->addOption('force', null, InputOption::VALUE_NONE, 'Force creation of a new worker if the PID file exists')
2020
->addOption('interval', 'i', InputOption::VALUE_REQUIRED, 'How often to check for new jobs across the queues', 5)
@@ -23,7 +23,7 @@ protected function configure()
2323

2424
protected function execute(InputInterface $input, OutputInterface $output)
2525
{
26-
$pidFile = $this->getContainer()->get('kernel')->getCacheDir().'/bcc_resque_scheduledworker.pid';
26+
$pidFile = $this->getContainer()->get('kernel')->getCacheDir().'/instasent_resque_scheduledworker.pid';
2727
if (file_exists($pidFile) && !$input->getOption('force')) {
2828
throw new \Exception('PID file exists - use --force to override');
2929
}
@@ -35,18 +35,18 @@ protected function execute(InputInterface $input, OutputInterface $output)
3535
$env = array(
3636
'APP_INCLUDE' => $this->getContainer()->getParameter('kernel.root_dir').'/bootstrap.php.cache',
3737
'VVERBOSE' => 1,
38-
'RESQUE_PHP' => $this->getContainer()->getParameter('bcc_resque.resque.vendor_dir').'/chrisboulton/php-resque/lib/Resque.php',
38+
'RESQUE_PHP' => $this->getContainer()->getParameter('instasent_resque.resque.vendor_dir').'/chrisboulton/php-resque/lib/Resque.php',
3939
'INTERVAL' => $input->getOption('interval'),
4040
);
4141

42-
$prefix = $this->getContainer()->getParameter('bcc_resque.prefix');
42+
$prefix = $this->getContainer()->getParameter('instasent_resque.prefix');
4343
if (!empty($prefix)) {
44-
$env['PREFIX'] = $this->getContainer()->getParameter('bcc_resque.prefix');
44+
$env['PREFIX'] = $this->getContainer()->getParameter('instasent_resque.prefix');
4545
}
4646

47-
$redisHost = $this->getContainer()->getParameter('bcc_resque.resque.redis.host');
48-
$redisPort = $this->getContainer()->getParameter('bcc_resque.resque.redis.port');
49-
$redisDatabase = $this->getContainer()->getParameter('bcc_resque.resque.redis.database');
47+
$redisHost = $this->getContainer()->getParameter('instasent_resque.resque.redis.host');
48+
$redisPort = $this->getContainer()->getParameter('instasent_resque.resque.redis.port');
49+
$redisDatabase = $this->getContainer()->getParameter('instasent_resque.resque.redis.database');
5050
if ($redisHost != null && $redisPort != null) {
5151
$env['REDIS_BACKEND'] = $redisHost.':'.$redisPort;
5252
}

Command/StartWorkerCommand.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\Command;
3+
namespace Instasent\ResqueBundle\Command;
44

55
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
66
use Symfony\Component\Process\Process;
@@ -14,8 +14,8 @@ class StartWorkerCommand extends ContainerAwareCommand
1414
protected function configure()
1515
{
1616
$this
17-
->setName('bcc:resque:worker-start')
18-
->setDescription('Start a bcc resque worker')
17+
->setName('instasent:resque:worker-start')
18+
->setDescription('Start a instasent resque worker')
1919
->addArgument('queues', InputArgument::REQUIRED, 'Queue names (separate using comma)')
2020
->addOption('count', 'c', InputOption::VALUE_REQUIRED, 'How many workers to fork', 1)
2121
->addOption('interval', 'i', InputOption::VALUE_REQUIRED, 'How often to check for new jobs across the queues', 5)
@@ -47,9 +47,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
4747
$env['QUEUE'] = $input->getArgument('queues');
4848
$env['VERBOSE'] = 1;
4949

50-
$prefix = $this->getContainer()->getParameter('bcc_resque.prefix');
50+
$prefix = $this->getContainer()->getParameter('instasent_resque.prefix');
5151
if (!empty($prefix)) {
52-
$env['PREFIX'] = $this->getContainer()->getParameter('bcc_resque.prefix');
52+
$env['PREFIX'] = $this->getContainer()->getParameter('instasent_resque.prefix');
5353
}
5454

5555
if ($input->getOption('verbose')) {
@@ -60,9 +60,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
6060
unset($env['VERBOSE']);
6161
}
6262

63-
$redisHost = $this->getContainer()->getParameter('bcc_resque.resque.redis.host');
64-
$redisPort = $this->getContainer()->getParameter('bcc_resque.resque.redis.port');
65-
$redisDatabase = $this->getContainer()->getParameter('bcc_resque.resque.redis.database');
63+
$redisHost = $this->getContainer()->getParameter('instasent_resque.resque.redis.host');
64+
$redisPort = $this->getContainer()->getParameter('instasent_resque.resque.redis.port');
65+
$redisDatabase = $this->getContainer()->getParameter('instasent_resque.resque.redis.database');
6666

6767
if ($redisHost != null && $redisPort != null) {
6868
$env['REDIS_BACKEND'] = $redisHost.':'.$redisPort;

Command/StopScheduledWorkerCommand.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\Command;
3+
namespace Instasent\ResqueBundle\Command;
44

55
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
66
use Symfony\Component\Console\Input\InputInterface;
@@ -15,14 +15,14 @@ class StopScheduledWorkerCommand extends ContainerAwareCommand
1515
protected function configure()
1616
{
1717
$this
18-
->setName('bcc:resque:scheduledworker-stop')
19-
->setDescription('Stop a bcc resque scheduled worker')
18+
->setName('instasent:resque:scheduledworker-stop')
19+
->setDescription('Stop a instasent resque scheduled worker')
2020
;
2121
}
2222

2323
protected function execute(InputInterface $input, OutputInterface $output)
2424
{
25-
$pidFile = $this->getContainer()->get('kernel')->getCacheDir().'/bcc_resque_scheduledworker.pid';
25+
$pidFile = $this->getContainer()->get('kernel')->getCacheDir().'/instasent_resque_scheduledworker.pid';
2626
if (!file_exists($pidFile)) {
2727
$output->writeln('No PID file found');
2828

Command/StopWorkerCommand.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\Command;
3+
namespace Instasent\ResqueBundle\Command;
44

55
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
66
use Symfony\Component\Console\Input\InputArgument;
@@ -13,16 +13,16 @@ class StopWorkerCommand extends ContainerAwareCommand
1313
protected function configure()
1414
{
1515
$this
16-
->setName('bcc:resque:worker-stop')
17-
->setDescription('Stop a bcc resque worker')
16+
->setName('instasent:resque:worker-stop')
17+
->setDescription('Stop a instasent resque worker')
1818
->addArgument('id', InputArgument::OPTIONAL, 'Worker id')
1919
->addOption('all', 'a', InputOption::VALUE_NONE, 'Should kill all workers')
2020
;
2121
}
2222

2323
protected function execute(InputInterface $input, OutputInterface $output)
2424
{
25-
$resque = $this->getContainer()->get('bcc_resque.resque');
25+
$resque = $this->getContainer()->get('instasent_resque.resque');
2626

2727
if ($input->getOption('all')) {
2828
$workers = $resque->getWorkers();

ContainerAwareJob.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle;
3+
namespace Instasent\ResqueBundle;
44

55
use Symfony\Component\Finder\Finder;
66
use Symfony\Component\HttpKernel\KernelInterface;

Controller/DefaultController.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\Controller;
3+
namespace Instasent\ResqueBundle\Controller;
44

55
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
66

@@ -11,7 +11,7 @@ public function indexAction()
1111
$this->getResque()->pruneDeadWorkers();
1212

1313
return $this->render(
14-
'BCCResqueBundle:Default:index.html.twig',
14+
'InstasentResqueBundle:Default:index.html.twig',
1515
array(
1616
'resque' => $this->getResque(),
1717
)
@@ -30,7 +30,7 @@ public function showQueueAction($queue)
3030
}
3131

3232
return $this->render(
33-
'BCCResqueBundle:Default:queue_show.html.twig',
33+
'InstasentResqueBundle:Default:queue_show.html.twig',
3434
array(
3535
'queue' => $queue,
3636
'jobs' => $jobs,
@@ -50,7 +50,7 @@ public function listFailedAction()
5050
}
5151

5252
return $this->render(
53-
'BCCResqueBundle:Default:failed_list.html.twig',
53+
'InstasentResqueBundle:Default:failed_list.html.twig',
5454
array(
5555
'jobs' => $jobs,
5656
'showingAll' => $showingAll,
@@ -61,7 +61,7 @@ public function listFailedAction()
6161
public function listScheduledAction()
6262
{
6363
return $this->render(
64-
'BCCResqueBundle:Default:scheduled_list.html.twig',
64+
'InstasentResqueBundle:Default:scheduled_list.html.twig',
6565
array(
6666
'timestamps' => $this->getResque()->getDelayedJobTimestamps(),
6767
)
@@ -78,7 +78,7 @@ public function showTimestampAction($timestamp)
7878
}
7979

8080
return $this->render(
81-
'BCCResqueBundle:Default:scheduled_timestamp.html.twig',
81+
'InstasentResqueBundle:Default:scheduled_timestamp.html.twig',
8282
array(
8383
'timestamp' => $timestamp,
8484
'jobs' => $jobs,
@@ -87,11 +87,11 @@ public function showTimestampAction($timestamp)
8787
}
8888

8989
/**
90-
* @return \BCC\ResqueBundle\Resque
90+
* @return \Instasent\ResqueBundle\Resque
9191
*/
9292
protected function getResque()
9393
{
94-
return $this->get('bcc_resque.resque');
94+
return $this->get('instasent_resque.resque');
9595
}
9696

9797
/**

DependencyInjection/BCCResqueExtension.php

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\DependencyInjection;
3+
namespace Instasent\ResqueBundle\DependencyInjection;
44

55
use Symfony\Component\DependencyInjection\ContainerBuilder;
66
use Symfony\Component\Config\FileLocator;
@@ -12,7 +12,7 @@
1212
*
1313
* To learn more see {@link http://symfony.com/doc/current/cookbook/bundles/extension.html}
1414
*/
15-
class BCCResqueExtension extends Extension
15+
class InstasentResqueExtension extends Extension
1616
{
1717
/**
1818
* {@inheritdoc}
@@ -25,30 +25,30 @@ public function load(array $configs, ContainerBuilder $container)
2525
$loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
2626
$loader->load('services.xml');
2727

28-
$container->setParameter('bcc_resque.resque.vendor_dir', $config['vendor_dir']);
29-
$container->setParameter('bcc_resque.resque.class', $config['class']);
30-
$container->setParameter('bcc_resque.resque.redis.host', $config['redis']['host']);
31-
$container->setParameter('bcc_resque.resque.redis.port', $config['redis']['port']);
32-
$container->setParameter('bcc_resque.resque.redis.database', $config['redis']['database']);
28+
$container->setParameter('instasent_resque.resque.vendor_dir', $config['vendor_dir']);
29+
$container->setParameter('instasent_resque.resque.class', $config['class']);
30+
$container->setParameter('instasent_resque.resque.redis.host', $config['redis']['host']);
31+
$container->setParameter('instasent_resque.resque.redis.port', $config['redis']['port']);
32+
$container->setParameter('instasent_resque.resque.redis.database', $config['redis']['database']);
3333

3434
if (!empty($config['prefix'])) {
35-
$container->setParameter('bcc_resque.prefix', $config['prefix']);
36-
$container->getDefinition('bcc_resque.resque')->addMethodCall('setPrefix', array($config['prefix']));
35+
$container->setParameter('instasent_resque.prefix', $config['prefix']);
36+
$container->getDefinition('instasent_resque.resque')->addMethodCall('setPrefix', array($config['prefix']));
3737
}
3838

3939
if (!empty($config['worker']['root_dir'])) {
40-
$container->setParameter('bcc_resque.worker.root_dir', $config['worker']['root_dir']);
40+
$container->setParameter('instasent_resque.worker.root_dir', $config['worker']['root_dir']);
4141
}
4242

4343
if (!empty($config['auto_retry'])) {
4444
if (isset($config['auto_retry'][0])) {
45-
$container->getDefinition('bcc_resque.resque')->addMethodCall('setGlobalRetryStrategy', array($config['auto_retry'][0]));
45+
$container->getDefinition('instasent_resque.resque')->addMethodCall('setGlobalRetryStrategy', array($config['auto_retry'][0]));
4646
} else {
4747
if (isset($config['auto_retry']['default'])) {
48-
$container->getDefinition('bcc_resque.resque')->addMethodCall('setGlobalRetryStrategy', array($config['auto_retry']['default']));
48+
$container->getDefinition('instasent_resque.resque')->addMethodCall('setGlobalRetryStrategy', array($config['auto_retry']['default']));
4949
unset($config['auto_retry']['default']);
5050
}
51-
$container->getDefinition('bcc_resque.resque')->addMethodCall('setJobRetryStrategy', array($config['auto_retry']));
51+
$container->getDefinition('instasent_resque.resque')->addMethodCall('setJobRetryStrategy', array($config['auto_retry']));
5252
}
5353
}
5454
}

DependencyInjection/Configuration.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace BCC\ResqueBundle\DependencyInjection;
3+
namespace Instasent\ResqueBundle\DependencyInjection;
44

55
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
66
use Symfony\Component\Config\Definition\ConfigurationInterface;
@@ -18,7 +18,7 @@ class Configuration implements ConfigurationInterface
1818
public function getConfigTreeBuilder()
1919
{
2020
$treeBuilder = new TreeBuilder();
21-
$rootNode = $treeBuilder->root('bcc_resque');
21+
$rootNode = $treeBuilder->root('instasent_resque');
2222

2323
$rootNode
2424
->addDefaultsIfNotSet()
@@ -32,7 +32,7 @@ public function getConfigTreeBuilder()
3232
->defaultNull()
3333
->end()
3434
->scalarNode('class')
35-
->defaultValue('BCC\ResqueBundle\Resque')
35+
->defaultValue('Instasent\ResqueBundle\Resque')
3636
->cannotBeEmpty()
3737
->info('Set the resque class dir')
3838
->end()

0 commit comments

Comments
 (0)