Advanced Customisations
Changing the Job Parameters
You can override the __construct() method if you need to accept different/additional parameters. However, the first parameter must be string $trigger, and you must call $this->recordArguments(func_get_args()); again in the child class.
For example:
public function __construct(string $trigger, bool $something, $recordId = null, string $recordName = null)
{
parent::__construct($trigger, $recordId, $recordName);
$this->something = $something;
$this->recordArguments(func_get_args());
}
You may want to override the displayName() method as well, if you want any additional parameters to be displayed in the job name.
Changing the Lock Key
By default, only one job of each type is allowed to run at once, to prevent conflicts. Override funnelKey() to change this.
Note: It will need careful testing, e.g. to prevent full syncs overlapping with partial sync, so this is not recommended. It only has an effect when there is more than one queue worker configured, or you manually run a job synchronously.
Cleaning the Logs
By default log cleanup is scheduled for 3:07am. It will remove debug log entries after 3 months, truncate logs after 6 months, and delete sync history after 2 years. These settings can be changed in config/nexus-sync.php.