I see no timer_read() in the module and wonder how the module controls it's run time to make sure it exits itself clean once global timeout is reached. I also tried running link checks in linkchecker without global_timeout specified (and with background process disabled) and got a Fatal error: Maximum execution time of 240 seconds exceeded.. Something that should never happen as the default timeout is 120 seconds only.

Fatal error: Maximum execution time of 240 seconds exceeded in drupal7\sites\all\modules\httprl\httprl.module on line 1289

      $options += array(
        'global_connections' => $linkchecker_check_connections_max,
        //'global_timeout' => $max_execution_time - 30,
        'domain_connections' => linkchecker_check_domain_connections,
        'callback' => array(
          array(
            'function' => '_linkchecker_status_handling',
          ),
          $link, // This need to be passed or it's not send back to _linkchecker_status_handling()
        )
      );

It looks like the global_timeout has no effect and this also explains why the named lock do not get removed and the watchdog messages are not written.

Comments

hass’s picture

It exits cleanly if the links in the queue have been completed within the timeframe. If there are still links in the queue it errors out.

hass’s picture

Aside defining a timeout of 120.0 without looking into ini_get('max_execution_time') must also be a bug. I remember some people who have only a 60 seconds limit on their cheap host.

hass’s picture

I see there are some microseconds calls, but something goes wrong for sure.

hass’s picture

Priority: Major » Normal

Ups, missed #1870850: Global Timeout not working as expected. and I'm currently running DEV from 18. December. Trying again if this is a duplicate.

hass’s picture

Status: Active » Closed (duplicate)