Change record status: 
Project: 
Introduced in branch: 
8.x
Description: 

In prior versions of Drupal 8, if you had the Node and Search modules enabled, and had at least one NodeSearch search page enabled, each time you ran cron and indexed nodes for searching, the NodeSearch plugin would set the state variable "node.cron_last" to the changed time of the newest node that was indexed during that cron run, with a call to:

$this->state->set('node.cron_last', $node->getChangedTime());

In Drupal 7, this was accomplished with a variable_set() to the variable 'node_cron_last' under the equivalent conditions (Search module enabled and Node search page enabled, during node search indexing in cron):

variable_set('node_cron_last', $node->changed);

This state variable is no longer being set and has been removed from the code base.

Background

This state variable was being used to calculate search rankings for nodes for the "Most recent content" ranking choice. However, the calculation in Drupal 7 and prior versions of Drupal 8 was not really working -- it basically only prioritized the one most recently updated node and set the priority for all others to nearly zero, making it useless in practice.

In Drupal 8 the ranking calculation was changed to an algorithm that actually ranked nodes by their updated time, and the node.cron_last/node_cron_last state variable was no longer needed for this calculation. So, it was removed from the code base.

The state variable "system.cron_last" is not affected.

Impacts: 
Module developers
Updates Done (doc team, etc.)
Online documentation: 
Not done
Theming guide: 
Not done
Module developer documentation: 
Not done
Examples project: 
Not done
Coder Review: 
Not done
Coder Upgrade: 
Not done
Other: 
Other updates done