From 7c373900ac2e3fbc1da332cfd94a55f912f0f071 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Tue, 22 Oct 2019 10:56:28 -0500 Subject: [PATCH 01/11] Updated best practices and deployment info - Clarified that smart wizard checks to ensure Cloud configuration follows best practices for SCD strategy - Added step to validate Elasticsearch service version compatibility with Elasticsearch PHP client --- guides/v2.2/cloud/reference/discover-deploy.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/guides/v2.2/cloud/reference/discover-deploy.md b/guides/v2.2/cloud/reference/discover-deploy.md index f3f1fc371ef..83cde94c9f6 100644 --- a/guides/v2.2/cloud/reference/discover-deploy.md +++ b/guides/v2.2/cloud/reference/discover-deploy.md @@ -23,7 +23,7 @@ You can track build and deploy actions in real-time using the terminal or the Pr If you are using external GitHub repositories, the log of operations does not display in the GitHub session. However, you can still follow activity in the interface for the external repository and the Project Web Interface. See [Integrations]({{ page.baseurl }}/cloud/integrations/cloud-integrations.html). {:.bs-callout-info} -In Integration environments, you cannot view the deploy logs from the Project Web Interface. This feature is available only for Production and Staging environments. However, you can view logs for every phase of the deployment in any environment using the Magento [build and deploy]({{ page.baseurl }}/cloud/project/log-locations.html#build-and-deploy-logs). +In Integration environments, you cannot view the deploy logs from the Project Web Interface. This feature is available only for Production and Staging environments. However, you can view logs for every phase of the deployment in any environment using the Magento [build and deploy]({{ page.baseurl }}/cloud/project/log-locations.html#build-and-deploy-logs) logs. ## Project configuration {#cloud-deploy-conf} @@ -72,7 +72,7 @@ We highly recommend the following best practices and considerations for your dep - Use the `magento-cloud local:build` command to test the build in your local environment. Identify and fix any issues related to composer dependencies and environment and application configuration before deploying to a remote environment. See [Test build your code locally before deployment]({{ page.baseurl }}/cloud/live/live-sanity-check.html#test-build). - - Run the {{ site.data.var.ece }} smart wizard to ensure that your Cloud project configuration follows best practices for build and deployment. See [Smart wizard]({{ page.baseurl }}/cloud/deploy/smart-wizards.html). + - Run the {{ site.data.var.ece }} smart wizard to ensure that your Cloud project configuration follows best practices for build and deployment including static content deployment (SCD) strategy. See [Smart wizard]({{ page.baseurl }}/cloud/deploy/smart-wizards.html). - **After completing testing in local and Integration environments, deploy and test in the Staging environment**–See [Deploy code to Staging and Production]({{ page.baseurl }}/cloud/live/stage-prod-migrate.html#code). @@ -105,6 +105,8 @@ Follow best practices for builds and deployment, and use the [Upgrades and patch - Test your database to address any issues introduced by the updates to the Magento version and extensions. - Make any required updates to environment-specific settings before deploying to the remote environment. + + - Ensure that the Elasticsearch service version is compatible with the Elasticsearch PHP client version. See [Set up Elasticsearch]({{ page.baseurl }}/cloud/project/project-conf-files_services-elastic.html). - **Check database connectivity and available storage in remote environments**– From 239be0db7f41e0140d9e63b105fc22a877e6d728 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Wed, 23 Oct 2019 17:54:24 -0500 Subject: [PATCH 02/11] Added elasticsearch compatibility check --- ...loud-elasticsearch-client-compatibility.md | 7 ++ .../project-conf-files_services-elastic.md | 107 ++++++++++++++++++ .../project/project-conf-files_services.md | 4 +- 3 files changed, 117 insertions(+), 1 deletion(-) create mode 100644 _includes/cloud/cloud-elasticsearch-client-compatibility.md diff --git a/_includes/cloud/cloud-elasticsearch-client-compatibility.md b/_includes/cloud/cloud-elasticsearch-client-compatibility.md new file mode 100644 index 00000000000..3005bcb2963 --- /dev/null +++ b/_includes/cloud/cloud-elasticsearch-client-compatibility.md @@ -0,0 +1,7 @@ +The following table lists compatible versions of the Elasticsearch software supported by {{ site.data.var.ee }}. + +Elasticsearch service | Elasticsearch composer package | Status +--------- | ------------- | ------------------------- +1.7 – 2.4.x| 2.x.x | deprecated +5.2.x | 5.x.x | default versions for {{ site.data.var.ee }} versions 2.2.x - 2.2.7 and 2.3.0 +6.x | 6.x | recommended, default versions for {{ site.data.var.ee }} versions 2.2.8 and 2.3.1 and later. diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index d40e113f754..b2b30ef7ee9 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -30,6 +30,9 @@ To enable Elasticsearch: disk: 1024 ``` + {:.bs-callout-info} + For details on determining the correct version to install, see [Elasticsearch software compatibility](#elasticsearch-software-compatibility) + 1. Set the `relationships` property in the `.magento.app.yaml` file. ```yaml @@ -59,6 +62,110 @@ To enable Elasticsearch: bin/magento cache:clean ``` + {.bs-callout-tip} + You can use the `SEARCH_CONFIGURATION` deploy variable to retain customized search service settings between deployments. + +## Elasticsearch software compatibility + +When you install or upgrade your {{ site.data.var.ece }} project, ensure that the Elasticsearch service version you specify in the `services.yaml` file is compatible with the [Elasticsearch PHP](https://github.com/elastic/elasticsearch-php) client for {{ site.data.var.ee }}. + +- **First time setup**–Confirm that the Elasticsearch version specified in the `services.yaml` file is compatible with the Elasticsearch PHP client configured for {{ site.data.var.ee }}. + +- **Project upgrade**–Verify that the Elasticsearch PHP client in the new Magento version is compatible with the Elasticsearch service version installed on the Cloud infrastructure. + +{% include cloud/cloud-elasticsearch-client-compatibility.md %} + +{:.procedure} +To check Elasticsearch software compatibility: + +1. Use SSH to log in to the remote environment. + +1. Check the Composer package version for `elasticsearch/elasticsearch`. + + ```bash + composer show elasticsearch/elasticsearch + ``` + + In the response, check the installed version in the `versions` property. + + ```terminal + name : elasticsearch/elasticsearch + descrip. : PHP Client for Elasticsearch + keywords : client, elasticsearch, search + versions : * v6.7.1 + type : library + license : Apache License 2.0 (Apache-2.0) (OSI approved) https://spdx.org licensesApache-2.0.html#licenseText + source : [git] https://github.com/elastic elasticsearch-php.git7be453dd36d1b141b779f2cb956715f8e04ac2f4 + dist : [zip] https://api.github.com/repos/elastic/elasticsearch-php/zipball/ 7be453dd36d1b141b779f2cb956715f8e04ac2f4 7be453dd36d1b141b779f2cb956715f8e04ac2f4 + path : /app/vendor/elasticsearch/elasticsearch + names : elasticsearch/elasticsearch + ``` + + You can also find the Elasticsearch PHP client version in the `composer.lock` file in the environment root directory. + +1. From the command line, retrieve the Elasticsearch service connection details. + + ```bash + echo $MAGENTO_CLOUD_RELATIONSHIPS | base64 -d | json_pp + ``` + + In the response, find the IP address for the Elasticsearch service endpoint: + + ```terminal + "elasticsearch" : [ + { + "cluster" : "fo3qdoxtla4j4-master-7rqtwti", + "public" : false, + "service" : "elasticsearch", + "port" : 9200, + "query" : {}, + "scheme" : "http", + "fragment" : null, + "host" : "elasticsearch.internal", + "username" : null, + "rel" : "elasticsearch", + "password" : null, + "ip" : "169.254.220.11", + "path" : null, + "hostname" "dzggu33f75wi3sd24lgwtoupxm.elasticsearch.service._.magentosite.cloud", + "type" : "elasticsearch:6.5" + } + ``` + +1. Retrieve the installed Elasticsearch service `version:number` from the service endpoint. + + ```bash + curl -XGET :9200/ + ``` + + ```terminal + { + "name" : "-AqGi9D", + "cluster_name" : "elasticsearch", + "cluster_uuid" : "_yze6-ywSEW1MaAF8ZPWyQ", + "version" : { + "number" : "6.5.4", + "build_flavor" : "default", + "build_type" : "deb", + "build_hash" : "82a8aa7", + "build_date" : "2019-01-23T12:07:18.760675Z", + "build_snapshot" : false, + "lucene_version" : "7.5.0", + "minimum_wire_compatibility_version" : "5.6.0", + "minimum_index_compatibility_version" : "5.0.0" + }, + " tagline" : "You Know, for Search" + } + ``` + +1. Check version compatibility between the Elasticsearch service and the PHP client. + + If the versions are incompatible, make one of the following updates to your environment configuration: + + - Change the Elasticsearch service version in the `services.yaml` file to a version that is compatible with the Elasticsearch PHP client. On Pro Staging and Production environments, you must submit a support ticket to change the Elasticsearch service version. + + - [Change the Elasticsearch PHP client]({{ page.baseurl }}/config-guide/elasticsearch/es-downgrade.html) to a version that is compatible with the Elasticsearch service version. + ## Restart the Elasticsearch service If you need to restart the [Elasticsearch](https://www.elastic.co) service, you must contact Magento support. diff --git a/guides/v2.2/cloud/project/project-conf-files_services.md b/guides/v2.2/cloud/project/project-conf-files_services.md index be334dbec78..937b5861c1c 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services.md +++ b/guides/v2.2/cloud/project/project-conf-files_services.md @@ -135,7 +135,6 @@ To verify relationships in local environment: type: 'mysql:10.0' port: 3306 ``` - {:.no-copy} {:.procedure} To verify relationships in remote environments: @@ -170,3 +169,6 @@ Service | Magento 2.3 | Magento 2.2 `rabbitmq`| 3.5, 3.7 | 3.5 `redis` | 3.2, 4.0, 5.0 | 3.2, 4.0, 5.0 `varnish` | Magento 2.3.3 and later—4.0, 5.0, 6.2
Magento 2.3.0 to 2.3.2—4.0, 5.0 | 4.0, 5.0 + +{:.bs-callout-info} +When you set up the Elasticsearch service, check to ensure that you use a version that is compatible with the installed [Elasticsearch PHP](https://github.com/elastic/elasticsearch-php) client. See [Check Elasticsearch software compatibility]({{ page.baseurl }}/cloud/project/project-conf-files_services-elastic.html#elasticsearch-software-compatibility). \ No newline at end of file From c99133fb3c259b438446207a78a0502598076896 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Wed, 23 Oct 2019 20:16:25 -0500 Subject: [PATCH 03/11] Fixed linting error and minor editorial updates --- .../project-conf-files_services-elastic.md | 16 +++++++++++----- guides/v2.2/cloud/reference/discover-deploy.md | 2 +- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index b2b30ef7ee9..5c3d71636e6 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -16,8 +16,8 @@ functional_areas: {% include cloud/service-config-integration-starter.md %} -{: .bs-callout-warning} -Staging and Production environments that are in the same cluster share a single Elasticsearch instance, so you must specify a unique Elasticsearch prefix for each of these environments. +{:.bs-callout-tip} +Magento recommends that you always set up Elasticsearch for your {{ site.data.var.ece }} project even if you plan to configure a third-party search tool for your {{ site.data.var.ee }} application. Setting up Elasticsearch provides a fallback option in the event that the third-party search tool fails. {:.procedure} To enable Elasticsearch: @@ -63,11 +63,11 @@ To enable Elasticsearch: ``` {.bs-callout-tip} - You can use the `SEARCH_CONFIGURATION` deploy variable to retain customized search service settings between deployments. + By default, the search configuration is regenerated each time you deploy to a remote environment. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search). ## Elasticsearch software compatibility -When you install or upgrade your {{ site.data.var.ece }} project, ensure that the Elasticsearch service version you specify in the `services.yaml` file is compatible with the [Elasticsearch PHP](https://github.com/elastic/elasticsearch-php) client for {{ site.data.var.ee }}. +When you install or upgrade your {{ site.data.var.ece }} project, always check for compatibility between the Elasticsearch service version and the [Elasticsearch PHP](https://github.com/elastic/elasticsearch-php) client for {{ site.data.var.ee }}. - **First time setup**–Confirm that the Elasticsearch version specified in the `services.yaml` file is compatible with the Elasticsearch PHP client configured for {{ site.data.var.ee }}. @@ -170,7 +170,13 @@ To check Elasticsearch software compatibility: If you need to restart the [Elasticsearch](https://www.elastic.co) service, you must contact Magento support. -## Elasticsearch plugins +## Additional search configuration + +By default, the search configuration is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search_configuration). + +{{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. + +### Elasticsearch plugins Optionally, you can add Elasticsearch plugins by adding the `configuration:plugins` section to the `.magento/services.yaml` file. For example, the following code enables the ICU analysis plugin and Python script support plugins. diff --git a/guides/v2.2/cloud/reference/discover-deploy.md b/guides/v2.2/cloud/reference/discover-deploy.md index 83cde94c9f6..7744c48d75f 100644 --- a/guides/v2.2/cloud/reference/discover-deploy.md +++ b/guides/v2.2/cloud/reference/discover-deploy.md @@ -105,7 +105,7 @@ Follow best practices for builds and deployment, and use the [Upgrades and patch - Test your database to address any issues introduced by the updates to the Magento version and extensions. - Make any required updates to environment-specific settings before deploying to the remote environment. - + - Ensure that the Elasticsearch service version is compatible with the Elasticsearch PHP client version. See [Set up Elasticsearch]({{ page.baseurl }}/cloud/project/project-conf-files_services-elastic.html). - **Check database connectivity and available storage in remote environments**– From 285dfd17ea3f367e51118217878726b39f1e283b Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Wed, 23 Oct 2019 20:29:55 -0500 Subject: [PATCH 04/11] Updated the Additional search configuration section --- .../cloud/project/project-conf-files_services-elastic.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index 5c3d71636e6..a4430fa20da 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -172,9 +172,11 @@ If you need to restart the [Elasticsearch](https://www.elastic.co) service, you ## Additional search configuration -By default, the search configuration is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search_configuration). +- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search_configuration). -{{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. +- {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. + +- After you set up the Elasticsearch service for your project, use the Magento Admin UI to test the Elasticsearch connection and customize Elasticsearch settings for {{ site.data.var.ee }}. ### Elasticsearch plugins From 1d9c94352bcfe3b12dddb25f29b763202306b397 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Wed, 23 Oct 2019 20:33:25 -0500 Subject: [PATCH 05/11] Fixed linting errors --- .../cloud/project/project-conf-files_services-elastic.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index a4430fa20da..d09e5705102 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -172,11 +172,11 @@ If you need to restart the [Elasticsearch](https://www.elastic.co) service, you ## Additional search configuration -- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search_configuration). +- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search_configuration). -- {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. +- {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. -- After you set up the Elasticsearch service for your project, use the Magento Admin UI to test the Elasticsearch connection and customize Elasticsearch settings for {{ site.data.var.ee }}. +- After you set up the Elasticsearch service for your project, use the Magento Admin UI to test the Elasticsearch connection and customize Elasticsearch settings for {{ site.data.var.ee }}. ### Elasticsearch plugins From 4effbb88c1972ca75891e14247db42c753c9c7de Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Thu, 24 Oct 2019 04:39:33 -0500 Subject: [PATCH 06/11] Update guides/v2.2/cloud/project/project-conf-files_services-elastic.md --- .../v2.2/cloud/project/project-conf-files_services-elastic.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index d09e5705102..7113d3351dc 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -172,7 +172,7 @@ If you need to restart the [Elasticsearch](https://www.elastic.co) service, you ## Additional search configuration -- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search_configuration). +- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/deploy-variables.html#search_configuration). - {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. @@ -192,4 +192,4 @@ elasticsearch: - lang-python ``` -If you use the ElasticSuite third-party plugin, you must [update the `{{site.data.var.ct}}` package]({{page.baseurl}}/cloud/project/ece-tools-update.html) to version 2002.0.19 or later. \ No newline at end of file +If you use the ElasticSuite third-party plugin, you must [update the `{{site.data.var.ct}}` package]({{page.baseurl}}/cloud/project/ece-tools-update.html) to version 2002.0.19 or later. From 0a179f42964530f16615764330f9ccdbfa055d46 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Thu, 24 Oct 2019 06:40:35 -0500 Subject: [PATCH 07/11] Update guides/v2.2/cloud/project/project-conf-files_services-elastic.md --- .../v2.2/cloud/project/project-conf-files_services-elastic.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index 7113d3351dc..1e59cab6276 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -172,7 +172,7 @@ If you need to restart the [Elasticsearch](https://www.elastic.co) service, you ## Additional search configuration -- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/deploy-variables.html#search_configuration). +- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/variables-deploy.html#search_configuration). - {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. From ea9de5980f94be9c1f7f9df2fdafbaa865dc2b47 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Thu, 24 Oct 2019 07:00:55 -0500 Subject: [PATCH 08/11] Removed duplicate information --- .../v2.2/cloud/project/project-conf-files_services-elastic.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index 1e59cab6276..7708a6697bc 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -62,9 +62,6 @@ To enable Elasticsearch: bin/magento cache:clean ``` - {.bs-callout-tip} - By default, the search configuration is regenerated each time you deploy to a remote environment. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/working-with-variables.html#search). - ## Elasticsearch software compatibility When you install or upgrade your {{ site.data.var.ece }} project, always check for compatibility between the Elasticsearch service version and the [Elasticsearch PHP](https://github.com/elastic/elasticsearch-php) client for {{ site.data.var.ee }}. From a5219f17204479858bba5b4e0c99ee27720087f7 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Thu, 24 Oct 2019 11:22:14 -0500 Subject: [PATCH 09/11] Apply suggestions from code review Co-Authored-By: hguthrie --- .../project/project-conf-files_services-elastic.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index 7708a6697bc..451ab2535da 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -31,7 +31,7 @@ To enable Elasticsearch: ``` {:.bs-callout-info} - For details on determining the correct version to install, see [Elasticsearch software compatibility](#elasticsearch-software-compatibility) + For details on determining the correct version to install, see [Elasticsearch software compatibility](#elasticsearch-software-compatibility). 1. Set the `relationships` property in the `.magento.app.yaml` file. @@ -98,12 +98,12 @@ To check Elasticsearch software compatibility: names : elasticsearch/elasticsearch ``` - You can also find the Elasticsearch PHP client version in the `composer.lock` file in the environment root directory. + Also, you can find the Elasticsearch PHP client version in the `composer.lock` file in the environment root directory. 1. From the command line, retrieve the Elasticsearch service connection details. ```bash - echo $MAGENTO_CLOUD_RELATIONSHIPS | base64 -d | json_pp + magento-cloud relationships -P elasticsearch ``` In the response, find the IP address for the Elasticsearch service endpoint: @@ -169,9 +169,9 @@ If you need to restart the [Elasticsearch](https://www.elastic.co) service, you ## Additional search configuration -- By default, the search configuration for Cloud environments is regenerated each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/variables-deploy.html#search_configuration). +- By default, the search configuration for Cloud environments regenerates each time you deploy. You can use the `SEARCH_CONFIGURATION` deploy variable to retain custom search settings between deployments. See [Deploy variables]({{ page.baseurl }}/cloud/env/variables-deploy.html#search_configuration). -- {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment share a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. +- {{ site.data.var.ece }} projects provisioned with a shared Production and Staging environment use a single Elasticsearch instance, so you must specify a unique _Elasticsearch Index prefix_ for each of these environments. See [Configure Magento to use Elasticsearch]({{ page.baseurl}}/config-guide/elasticsearch/configure-magento.html) in the _Configuration Guide_. - After you set up the Elasticsearch service for your project, use the Magento Admin UI to test the Elasticsearch connection and customize Elasticsearch settings for {{ site.data.var.ee }}. From ae4fee33124f3787816dfe9d5a6ca68c31666d57 Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Fri, 25 Oct 2019 13:14:41 -0500 Subject: [PATCH 10/11] Replaced command for retrieving elasticsearch info --- .../project-conf-files_services-elastic.md | 40 +++++++++---------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index 451ab2535da..d829dd6e255 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -103,30 +103,30 @@ To check Elasticsearch software compatibility: 1. From the command line, retrieve the Elasticsearch service connection details. ```bash - magento-cloud relationships -P elasticsearch + vendor/bin/ece-tools env:config:show services ``` - + In the response, find the IP address for the Elasticsearch service endpoint: ```terminal - "elasticsearch" : [ - { - "cluster" : "fo3qdoxtla4j4-master-7rqtwti", - "public" : false, - "service" : "elasticsearch", - "port" : 9200, - "query" : {}, - "scheme" : "http", - "fragment" : null, - "host" : "elasticsearch.internal", - "username" : null, - "rel" : "elasticsearch", - "password" : null, - "ip" : "169.254.220.11", - "path" : null, - "hostname" "dzggu33f75wi3sd24lgwtoupxm.elasticsearch.service._.magentosite.cloud", - "type" : "elasticsearch:6.5" - } + | elasticsearch: | + +------------------------------------------+----------------------------------------------------------------------+ + | username | null | + | scheme | http | + | service | elasticsearch | + | fragment | null | + | ip | 169.254.220.11 | + | hostname | dzggu33f75wi3sd24lgwtoupxm.elasticsearch.service._.magentosite.cloud | + | public | false | + | cluster | fo3qdoxtla4j4-master-7rqtwti | + | host | elasticsearch.internal | + | rel | elasticsearch | + | query | | + | path | null | + | password | null | + | type | elasticsearch:6.5 | + | port | 9200 | + +------------------------------------------+----------------------------------------------------------------------+ ``` 1. Retrieve the installed Elasticsearch service `version:number` from the service endpoint. From c6266b1481b71dbba4db59010a1fdb33708503dc Mon Sep 17 00:00:00 2001 From: Margaret Eker Date: Fri, 25 Oct 2019 13:53:54 -0500 Subject: [PATCH 11/11] Removed trailing spaces --- .../v2.2/cloud/project/project-conf-files_services-elastic.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md index d829dd6e255..d12e086694a 100644 --- a/guides/v2.2/cloud/project/project-conf-files_services-elastic.md +++ b/guides/v2.2/cloud/project/project-conf-files_services-elastic.md @@ -105,7 +105,7 @@ To check Elasticsearch software compatibility: ```bash vendor/bin/ece-tools env:config:show services ``` - + In the response, find the IP address for the Elasticsearch service endpoint: ```terminal