Skip to content

Releases: dereuromark/cakephp-queue

6.7.2

10 Sep 08:43

Choose a tag to compare

Improvements

  • Expose kill signal parameter in controller

6.7.1

19 Jun 12:27
0657b84

Choose a tag to compare

Fixes

  • Fixed TaskFinder failing to find tasks if app directory is not src/.

6.7.0

23 Apr 23:08

Choose a tag to compare

Improvements

Allow creating tasks in sub folders/namespaces.
So far it was only possible to have tasks on one single level.
You can now use My/Sub/MyTaskNameTask to create tasks in sub-namespace Task\My\Sub\.

E.g. src/Queue/Task/My/Sub/{YourNameForIt}Task.php would be found and used as My/Sub/{YourNameForIt}.

6.6.2

27 Mar 14:39

Choose a tag to compare

Improvements

  • Added shim to transform serialized data for object to JSON switch as button in backend.
  • Use add() method for AddFromBackendInterface interface functionality for backend button.

Before

x

After

y

6.6.1

12 Mar 15:03

Choose a tag to compare

Improvements

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

6.6.0

04 Jan 17:22

Choose a tag to compare

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).

6.5.0

14 Oct 22:04
3c18f31

Choose a tag to compare

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.

6.4.4

13 Oct 10:31

Choose a tag to compare

Fixes

Fixed Migration OldTaskFinder for upgrading from v5 to v6.

6.4.3

19 Aug 11:49
d16535e

Choose a tag to compare

Fixes

Removed deprecation introduced in 6.4.2

6.4.2

18 Aug 20:22

Choose a tag to compare

Fixes

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