From 83d150c90820f54d113ea6848b9b9b209da48807 Mon Sep 17 00:00:00 2001 From: Lindsey Moore Date: Wed, 10 Jul 2024 22:00:47 -0400 Subject: [PATCH 1/6] DOCSP-37067 Remove old mentions of realm_config.json --- .../test/integration/materializeTotalSales.test.js | 2 +- source/apps/copy-app-copy-config-files.rst | 4 ++-- source/apps/environment.txt | 4 ++-- ...izeTotalSales.test.snippet.materialize-total-sales-test.js | 2 +- source/reference/config.txt | 2 +- source/security/network.txt | 2 +- source/tutorial/react-native.txt | 4 ++-- 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/examples/functions/functions_tester/test/integration/materializeTotalSales.test.js b/examples/functions/functions_tester/test/integration/materializeTotalSales.test.js index 8511181fd..55a7d8eeb 100644 --- a/examples/functions/functions_tester/test/integration/materializeTotalSales.test.js +++ b/examples/functions/functions_tester/test/integration/materializeTotalSales.test.js @@ -1,5 +1,5 @@ // :snippet-start: materialize-total-sales-test -const { app_id } = require("../../realm_config.json"); +const { app_id } = require("../../root_config.json"); const Realm = require("realm"); const { BSON } = require("realm"); diff --git a/source/apps/copy-app-copy-config-files.rst b/source/apps/copy-app-copy-config-files.rst index c5e966b58..6e50fd9d8 100644 --- a/source/apps/copy-app-copy-config-files.rst +++ b/source/apps/copy-app-copy-config-files.rst @@ -1,6 +1,6 @@ Copy all configuration files from your original App, except for -``realm_config.json``, to the new App's configuration directory. You -should use the new App's ``realm_config.json`` and overwrite any other +``root_config.json``, to the new App's configuration directory. You +should use the new App's ``root_config.json`` and overwrite any other configuration files. .. example:: diff --git a/source/apps/environment.txt b/source/apps/environment.txt index c7502f017..13a0b50a3 100644 --- a/source/apps/environment.txt +++ b/source/apps/environment.txt @@ -215,10 +215,10 @@ Procedure Your app always runs in a specific environment, which affects the value of all environment values. You can specify the current environment for your app in - ``realm_config.json``: + ``root_config.json``: .. code-block:: json - :caption: realm_config.json + :caption: root_config.json { ..., diff --git a/source/examples/generated/functions/materializeTotalSales.test.snippet.materialize-total-sales-test.js b/source/examples/generated/functions/materializeTotalSales.test.snippet.materialize-total-sales-test.js index a901105be..563977a48 100644 --- a/source/examples/generated/functions/materializeTotalSales.test.snippet.materialize-total-sales-test.js +++ b/source/examples/generated/functions/materializeTotalSales.test.snippet.materialize-total-sales-test.js @@ -1,4 +1,4 @@ -const { app_id } = require("../../realm_config.json"); +const { app_id } = require("../../root_config.json"); const Realm = require("realm"); const { BSON } = require("realm"); diff --git a/source/reference/config.txt b/source/reference/config.txt index 5b2841a9d..86f88b5f6 100644 --- a/source/reference/config.txt +++ b/source/reference/config.txt @@ -47,7 +47,7 @@ using structured JSON configuration and JavaScript source code files. You can include arbitrarily named files in your realm app config, with a few exceptions. The following filenames are used to define and configure components in your App: - ``stitch.json``, ``config.json``, ``realm_config.json``, and ``app_config.json``. + ``stitch.json``, ``config.json``, ``root_config.json``, and ``app_config.json``. Files with these names must conform to a specific schema for their component type. Using these file names when the file's content fails to conform to that schema throws an error when you import the app using the CLI. diff --git a/source/security/network.txt b/source/security/network.txt index 232d62001..59a3f3cfc 100644 --- a/source/security/network.txt +++ b/source/security/network.txt @@ -225,7 +225,7 @@ Allowed Request Origins ----------------------- You can define this :ref:`configuration option ` in the -app-level ``realm_config.json`` file. This field accepts an array of +app-level ``root_config.json`` file. This field accepts an array of URLs that incoming requests may originate from. If you define any allowed request origins, then App Services blocks any incoming request from an origin that is not listed. diff --git a/source/tutorial/react-native.txt b/source/tutorial/react-native.txt index 2e44d1654..86d7b2623 100644 --- a/source/tutorial/react-native.txt +++ b/source/tutorial/react-native.txt @@ -251,8 +251,8 @@ Atlas App Services App ~~~~~~~~~~~~~~~~~~~~~~ The template app includes a fully configured App Services App in the -``backend`` directory. It has a unique ``app_id`` value in -``realm_config.json`` that client applications use to connect. +``backend`` directory. It has a unique ``appId`` value in +``atlasConfig.json`` that client applications use to connect. It also includes the following pre-defined configurations: From f15dd4394e036d472bd907fa6b04394ae1fd47ba Mon Sep 17 00:00:00 2001 From: Lindsey Moore Date: Thu, 11 Jul 2024 12:03:25 -0400 Subject: [PATCH 2/6] change functions tester file name to root_config --- .../functions_tester/{realm_config.json => root_config.json} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename examples/functions/functions_tester/{realm_config.json => root_config.json} (100%) diff --git a/examples/functions/functions_tester/realm_config.json b/examples/functions/functions_tester/root_config.json similarity index 100% rename from examples/functions/functions_tester/realm_config.json rename to examples/functions/functions_tester/root_config.json From c3d3b061ff598b402bafbdd8f031185c5ebbb574 Mon Sep 17 00:00:00 2001 From: Lindsey Moore Date: Thu, 11 Jul 2024 12:09:34 -0400 Subject: [PATCH 3/6] update other tester files --- .../functions_tester/test/integration/retryHandlers.test.js | 2 +- .../functions_tester/test/integration/triggerMessage.test.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/functions/functions_tester/test/integration/retryHandlers.test.js b/examples/functions/functions_tester/test/integration/retryHandlers.test.js index 04f817854..f65491b5c 100644 --- a/examples/functions/functions_tester/test/integration/retryHandlers.test.js +++ b/examples/functions/functions_tester/test/integration/retryHandlers.test.js @@ -1,4 +1,4 @@ -const { app_id } = require("../../realm_config.json"); +const { app_id } = require("../../root_config.json"); const Realm = require("realm"); const app = new Realm.App(app_id); diff --git a/examples/functions/functions_tester/test/integration/triggerMessage.test.js b/examples/functions/functions_tester/test/integration/triggerMessage.test.js index c8f900203..76fed1ea6 100644 --- a/examples/functions/functions_tester/test/integration/triggerMessage.test.js +++ b/examples/functions/functions_tester/test/integration/triggerMessage.test.js @@ -1,4 +1,4 @@ -const { app_id } = require("../../realm_config.json"); +const { app_id } = require("../../root_config.json"); const Realm = require("realm"); const { BSON } = require("realm"); From 05297bb555520d6c14cc2ea70f07bbc2dc68f4b4 Mon Sep 17 00:00:00 2001 From: Lindsey Moore Date: Thu, 11 Jul 2024 12:18:56 -0400 Subject: [PATCH 4/6] remove remaining references --- examples/data-api/utils.sh | 2 +- examples/functions/functions_tester/nodemon.json | 2 +- source/apps/copy-app-copy-config-files.rst | 4 ++-- source/includes/realm-application-file-schema.rst | 2 +- source/openapi-admin-v3.yaml | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/examples/data-api/utils.sh b/examples/data-api/utils.sh index 7e86998f0..f133f37fc 100644 --- a/examples/data-api/utils.sh +++ b/examples/data-api/utils.sh @@ -127,7 +127,7 @@ create_data_api_app () { ## Copy the template App config files that we use for this test. cp -r ./backend "$app_name" ## Replace the App & Cluster configs with the values from the new App. - mv "$app_name-tmp/realm_config.json" "$app_name/realm_config.json" + mv "$app_name-tmp/root_config.json" "$app_name/root_config.json" mv "$app_name-tmp/data_sources/mongodb-atlas/config.json" "$app_name/data_sources/mongodb-atlas/config.json" ## Throw away the rest of the base App config files. rm -rf "$app_name-tmp" diff --git a/examples/functions/functions_tester/nodemon.json b/examples/functions/functions_tester/nodemon.json index 41c4639e9..19a3ea2a6 100644 --- a/examples/functions/functions_tester/nodemon.json +++ b/examples/functions/functions_tester/nodemon.json @@ -1,6 +1,6 @@ { "watch": [ - "realm_config.json", + "root_config.json", "auth", "data_sources", "environments", diff --git a/source/apps/copy-app-copy-config-files.rst b/source/apps/copy-app-copy-config-files.rst index 6e50fd9d8..ea3f6ea1e 100644 --- a/source/apps/copy-app-copy-config-files.rst +++ b/source/apps/copy-app-copy-config-files.rst @@ -7,8 +7,8 @@ configuration files. .. code-block:: bash - # Copy all configuration files except for realm_config.json + # Copy all configuration files except for root_config.json cp -r myapp myapp-temp - rm myapp-temp/realm_config.json + rm myapp-temp/root_config.json cp -r myapp-temp/* myapp-copy rm -rf myapp-temp diff --git a/source/includes/realm-application-file-schema.rst b/source/includes/realm-application-file-schema.rst index 3f7112259..c99b9070f 100644 --- a/source/includes/realm-application-file-schema.rst +++ b/source/includes/realm-application-file-schema.rst @@ -1,7 +1,7 @@ .. code-block:: none app/ - ├── realm_config.json + ├── root_config.json ├── auth/ │ ├── providers.json │ └── custom_user_data.json diff --git a/source/openapi-admin-v3.yaml b/source/openapi-admin-v3.yaml index 271b0aa22..f37f4ef68 100644 --- a/source/openapi-admin-v3.yaml +++ b/source/openapi-admin-v3.yaml @@ -481,7 +481,7 @@ paths: required: false description: |- The configuration file schema version to export. This value - corresponds to `config_version` in `realm_config.json`. + corresponds to `config_version` in `root_config.json`. example: 20210101 schema: type: string From 6c722a66ea944ec0417cb61df1d30ae8f9bbce29 Mon Sep 17 00:00:00 2001 From: Lindsey Moore Date: Thu, 11 Jul 2024 12:25:19 -0400 Subject: [PATCH 5/6] revert changes for data api --- examples/data-api/utils.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/data-api/utils.sh b/examples/data-api/utils.sh index f133f37fc..7e86998f0 100644 --- a/examples/data-api/utils.sh +++ b/examples/data-api/utils.sh @@ -127,7 +127,7 @@ create_data_api_app () { ## Copy the template App config files that we use for this test. cp -r ./backend "$app_name" ## Replace the App & Cluster configs with the values from the new App. - mv "$app_name-tmp/root_config.json" "$app_name/root_config.json" + mv "$app_name-tmp/realm_config.json" "$app_name/realm_config.json" mv "$app_name-tmp/data_sources/mongodb-atlas/config.json" "$app_name/data_sources/mongodb-atlas/config.json" ## Throw away the rest of the base App config files. rm -rf "$app_name-tmp" From e18df8845c0231ba255ef997dafeff3b06188bac Mon Sep 17 00:00:00 2001 From: Lindsey Moore Date: Thu, 11 Jul 2024 16:29:26 -0400 Subject: [PATCH 6/6] forgotten file --- source/reference/config/template-expansions.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/reference/config/template-expansions.txt b/source/reference/config/template-expansions.txt index 9cc3bc11d..95bafea03 100644 --- a/source/reference/config/template-expansions.txt +++ b/source/reference/config/template-expansions.txt @@ -130,7 +130,7 @@ Define a Template app configuration with the environment name: .. code-block:: - :caption: realm_config.json + :caption: root_config.json :emphasize-lines: 3 {