Problem/Motivation

Some sites may want to schedule the publishing of their storage entities. It appears that making this possible requires providing a small plugin with the necessary annotation data.

Proposed resolution

Implement a class that extends SchedulerPluginBase.

Issue fork storage-3387038

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

mandclu created an issue. See original summary.

mandclu’s picture

Status: Active » Needs review

The code provided in the merge requests worked for me.

noah’s picture

This patch was working well for us with Scheduler 2.0.*, but since updating to 2.1.0 we're seeing every cron run failing to complete, and this error appearing in the log:

Error: Class "Drupal\scheduler\Event\SchedulerStorageEvents" not found in constant() (line 177 of /path/to/drupal/web/modules/contrib/scheduler/src/SchedulerManager.php)

I had a look at the changelog for the Scheduler 2.1.0 release, and I don't see anything obvious:

https://www.drupal.org/project/scheduler/releases/2.1.0

For now I've made the problem go away by just removing scheduling from the storage type (I didn't have to uninstall Scheduler). I'll make some time to see what I can do to address this, but if anyone else wants to take a look it looks like the patch being developed for scheduling Paragraphs might point in the right direction:

https://www.drupal.org/project/scheduler/issues/3312200

pearls’s picture

Version: 1.3.x-dev » 1.4.x-dev
Status: Needs review » Needs work

MR!9 didn't work for me. Cron is not running, publishing is still not happening at scheduled time. It still shows unpublished.
I've been waiting for this to be resolved for a long time, I was hoping it would be fixed with version 1.4 but the same problem persists. Thanks

mandclu’s picture

Assigned: mandclu » Unassigned
mandclu’s picture

This may need a dedicated project, similar to Scheduler for ECK

pearls’s picture

There are revision issues in ECK module that have not been resolved.
Those who need this feature for storage entities can use either the Scheduled Publish or Scheduled Transitions modules..