Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MAGECLOUD-1332: Add ability to configure cron_consumers_runner via an environment variable #102

Merged
merged 2 commits into from
Nov 29, 2017
Merged

Conversation

BaDos
Copy link
Contributor

@BaDos BaDos commented Nov 28, 2017

Description

Magento allows to configure cron_consummers_runner via app/etc/env.php
We added opportunity to configure cron job cron_consummers_runner via an environment variable CRON_CONSUMERS_RUNNER.

Fixed Issues (if relevant)

https://magento2.atlassian.net/browse/MAGECLOUD-1332

Zephyr Tests

https://jira.corp.magento.com/browse/MAGETWO-84602

Contribution checklist

  • Pull request has a meaningful description of its purpose
  • Pull request was approved by architect
  • Pull request was approved by QA member
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)

Copy link
Contributor

@NadiyaS NadiyaS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lack of descriptions especially for CronConsummerRunner

$config = $this->configReader->read();
$cronConsumersRunnerConfig = new Repository($this->environment->getCronConsumersRunner());

$config['cron_consumers_runner'] = [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what if env.php already has configurations for this section?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We set configuration only from ENV variable.

$cronConsumersRunnerConfig = new Repository($this->environment->getCronConsumersRunner());

$config['cron_consumers_runner'] = [
'cron_run' => $cronConsumersRunnerConfig->get('cron_run') === 'true',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if CRON_CONSUMERS_RUNNER variable does not exist you don't need to set these values, because in this case you need to use Magento default values (they can be changed)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We disable this consumers runner by default on the Cloud.

Copy link
Contributor

@NadiyaS NadiyaS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved. Descriptions should be added later

@andriyShevtsov
Copy link
Contributor

QA approved

@shiftedreality shiftedreality added Progress: accept PR/issue status and removed Progress: testing in progress PR/issue status labels Nov 29, 2017
@shiftedreality shiftedreality merged commit 7ab28d5 into magento:develop Nov 29, 2017
@shiftedreality shiftedreality deleted the MAGECLOUD-1332 branch November 29, 2017 14:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Progress: accept PR/issue status Release: 2002.0.5 ECE-Tools Release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants