cakephp-queue

Queue plugin for CakePHP - simple, pure PHP and without dependencies.

MIT License

Downloads
633.9K
Stars
301
Committers
64
cakephp-queue - 6.6.1

Published by dereuromark over 1 year ago

Improvements

  • Display duration of each job in the job overview.
  • Allow adding helpers to view builder of Email tasks
cakephp-queue - 6.6.0

Published by dereuromark almost 2 years ago

Improvements

Allow configuration of serializing strategy:

  • Object (default for BC) using legacy serialize()
  • JSON using json_encode()
  • Any custom one implementing the SerializerInterface
'Queue' => [
    ...
    'serializerClass' => \Queue\Utility\JsonSerializer::class,
    'serializerConfig' => [...],
],

Added new MailerTask specifically for sending reusable emails using Mailer objects, but without passing through actual objects.
Instead, the class string (FQCN) is passed only together with config.
This allows it to work with JSON strategy and even in between updates of the server (as passed objects could fail to be "unserialized").

$data = [
    'class' => TestMailer::class,
    'action' => 'testAction',
    'vars' => [...],
];
$queuedJobsTable->createJob('Queue.Mailer', $data);

Added same JSON safe strategy for EmailTask and deprecated the object ways here only to be used with legacy ObjectSerializer.

$data = [
    'class' => Message::class,
    'settings' => $settings,
];
$queuedJobsTable->createJob('Queue.Email', $data);

The benefit of JSON serializing is:

  • Less payload (data vs full object).
  • More resilient after updates for non finished tasks: object can fail to unserialize if different, data can be handled with migration if needed.
  • Easier to debug and modify (e.g. for local dev/testing).
cakephp-queue - 4.4.1

Published by dereuromark almost 2 years ago

Fixes

Small CakePHP 3 fixes

cakephp-queue - 6.5.0

Published by dereuromark about 2 years ago

Improvements

Added AddFromBackendInterface to allow listing only possible tasks in GUI.
Some tasks that can be added (implementing AddInterface) require arguments and can as such only be executed from CLI.
With the new interface, this can now be differentiated.

cakephp-queue - 6.4.4

Published by dereuromark about 2 years ago

Fixes

Fixed Migration OldTaskFinder for upgrading from v5 to v6.

cakephp-queue - 6.4.3

Published by dereuromark about 2 years ago

Fixes

Removed deprecation introduced in 6.4.2

cakephp-queue - 6.4.2

Published by dereuromark about 2 years ago

Fixes

Fixed markJobDone() to add valid 1 (100%) value and added validation for expected 0...1 range.

cakephp-queue - 6.4.1

Published by dereuromark over 2 years ago

Fixes

Reverted BC breaks.

cakephp-queue - 6.4.0

Published by dereuromark over 2 years ago

Improvements

Full Changelog: https://github.com/dereuromark/cakephp-queue/compare/6.3.2...6.4.0

cakephp-queue - 6.3.2

Published by dereuromark over 2 years ago

Fixes

Full Changelog: https://github.com/dereuromark/cakephp-queue/compare/6.3.1...6.3.2

cakephp-queue - 6.3.1

Published by dereuromark over 2 years ago

cakephp-queue - 6.3.0

Published by dereuromark over 2 years ago

Improvements

Full Changelog: https://github.com/dereuromark/cakephp-queue/compare/6.2.2...6.3.0

cakephp-queue - 6.2.2

Published by dereuromark almost 3 years ago

Fixes

Fixed EmailTask to work with Cake\Mailer\Message object as expected, alongside the other ways it already supports.

cakephp-queue - 6.2.1

Published by dereuromark almost 3 years ago

Fixes

Fix up deprecation of helper/engine.

cakephp-queue - 6.2.0

Published by dereuromark almost 3 years ago

Improvements

  • Removed deprecations

Note: CakePHP 4.2+ and PHP 7.3+ now, also requires Tools 2.4+ if backend is used

cakephp-queue - 6.1.0

Published by dereuromark about 3 years ago

Improvements

Added TaskFinder::getClass() to resolve a name to a task class.

cakephp-queue - 6.0.2

Published by dereuromark about 3 years ago

Fixes

Fixed small notice.

cakephp-queue - 6.0.1

Published by dereuromark over 3 years ago

Fixes

  • Relaxed check for task existence when calling createJob().
    An option can now disable this if needed.
  • Fixed some remaining return types.
cakephp-queue - 6.0.0

Published by dereuromark over 3 years ago

Stable Release for CakePHP 4

Main improvements

  • Decoupled from old Shell/Task system as well as proxied to ConsoleIo using Io adapter class to avoid direct coupling
  • Now plugin and app tasks can coexist with the same name (MyTask vs MyPlugin.MyTask)
  • Allow adding command also by FQCN::class usage via QueuedJobsTable::createJob()
  • Includes migrating command to quickly make your existing tasks compatible.
  • Added "Reusable emails support" for Email task using action key
  • Added currently active job to worker processes view
  • Added "flush" functionality to remove failed jobs from the queue

BC breaking changes

  • job_type field of queued_jobs table has been renamed to job_task
  • Tasks have been moved to new namespace (use migrating tool to migrate)
  • CLI commands have been renamed, see bin/cake overview for details.
cakephp-queue - 6.0.0-beta

Published by dereuromark over 3 years ago

Improvements

  • Added "Reusable emails support" for Email task using action key
  • Added currently active job to worker processes view

Please help to test and stabilize.