-
Notifications
You must be signed in to change notification settings - Fork 228
SUMO-254678: Doc update Database apps migration V1 to V2 #5009
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
Merged
sumoanema
merged 44 commits into
SumoLogic:main
from
chetanchoudhary-sumo:v1v2migration-db-apps-doc-updates
May 2, 2025
Merged
Changes from 5 commits
Commits
Show all changes
44 commits
Select commit
Hold shift + click to select a range
e4233c0
SUMO-254678: Doc update Database apps migration V1 to V2
chetanchoudhary-sumo 6643ff6
Updating monitor part
chetanchoudhary-sumo a44f0ee
updating fields section
chetanchoudhary-sumo 4d9206f
updating FER section
chetanchoudhary-sumo a6d64e0
Merge branch 'main' into v1v2migration-db-apps-doc-updates
kimsauce 1e67c7c
Fixing Fields section
chetanchoudhary-sumo d3f313d
Merge remote-tracking branch 'refs/remotes/origin/v1v2migration-db-ap…
chetanchoudhary-sumo dde2b09
Addressing review comments from PR #5017
chetanchoudhary-sumo 5e56bf6
Update sql-server.md
amee-sumo 35947f8
Update docs/integrations/amazon-aws/dynamodb.md
chetanchoudhary-sumo 11df94a
Update docs/integrations/amazon-aws/dynamodb.md
chetanchoudhary-sumo c025cb1
Update docs/integrations/amazon-aws/dynamodb.md
chetanchoudhary-sumo 21f2c0c
Update docs/integrations/databases/cassandra.md
chetanchoudhary-sumo d2b2779
Update docs/integrations/databases/cassandra.md
chetanchoudhary-sumo 87390a5
Update docs/integrations/databases/cassandra.md
chetanchoudhary-sumo 51d7c7e
Update docs/integrations/databases/couchbase.md
chetanchoudhary-sumo 8332e5e
Update docs/integrations/databases/couchbase.md
chetanchoudhary-sumo c02a514
Update docs/integrations/databases/couchbase.md
chetanchoudhary-sumo 871dc6d
Update docs/integrations/databases/mariadb.md
chetanchoudhary-sumo 3b6ae78
Update docs/integrations/microsoft-azure/sql-server.md
chetanchoudhary-sumo 6d71bdd
Update docs/observability/application-components.md
chetanchoudhary-sumo 50fb40c
Update docs/integrations/databases/mysql.md
chetanchoudhary-sumo cf2dcbc
Update docs/integrations/databases/redis.md
chetanchoudhary-sumo 75aeeb8
Update docs/integrations/databases/oracle.md
chetanchoudhary-sumo b10a1cf
Update docs/integrations/databases/mariadb.md
chetanchoudhary-sumo a5052b0
Update docs/integrations/databases/mariadb.md
chetanchoudhary-sumo aec6c18
Update docs/integrations/databases/memcached.md
chetanchoudhary-sumo 593c49f
Update docs/integrations/databases/memcached.md
chetanchoudhary-sumo 6d149e1
Update docs/integrations/databases/memcached.md
chetanchoudhary-sumo ead4389
Update docs/integrations/databases/mongodb.md
chetanchoudhary-sumo 534d2ac
Update docs/integrations/databases/mongodb.md
chetanchoudhary-sumo fbccf2a
Update docs/integrations/databases/mongodb.md
chetanchoudhary-sumo 59911bb
Update docs/integrations/databases/mongodb.md
chetanchoudhary-sumo efc20dd
Apply suggestions from code review
chetanchoudhary-sumo 0cb57e2
Apply suggestions from code review
chetanchoudhary-sumo 80d83ab
Merge branch 'main' into v1v2migration-db-apps-doc-updates
chetanchoudhary-sumo 0062af6
Reverting DynamoDB documentation
chetanchoudhary-sumo 156e6b1
Merge branch 'main' into v1v2migration-db-apps-doc-updates
chetanchoudhary-sumo 4b32c89
Updating Cassandra Doc
chetanchoudhary-sumo e9b4d39
Updating V2 Migrated Database apps docs to standard pattern
chetanchoudhary-sumo 379e857
removing commented alert install section
chetanchoudhary-sumo 1a3fc31
Merge branch 'main' into v1v2migration-db-apps-doc-updates
chetanchoudhary-sumo 05f02c2
reverting application-components
chetanchoudhary-sumo 9b94d14
Merge branch 'main' into v1v2migration-db-apps-doc-updates
sumoanema File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -41,7 +41,7 @@ Create the following Fields in Sumo Logic prior to configuring collection. This | |
|
|
||
| <TabItem value="k8s"> | ||
|
|
||
| If you're using Cassandra in a Kubernetes environment, create the fields: | ||
| If you're using Cassandra in a Kubernetes environment, then these fields will be created: | ||
| * `pod_labels_component` | ||
| * `pod_labels_environment` | ||
| * `pod_labels_db_system` | ||
|
|
@@ -53,7 +53,7 @@ If you're using Cassandra in a Kubernetes environment, create the fields: | |
| </TabItem> | ||
| <TabItem value="non-k8s"> | ||
|
|
||
| If you're using Cassandra in a non-Kubernetes environment, create the fields: | ||
| If you're using Cassandra in a non-Kubernetes environment, then these fields will be created: | ||
| * `component` | ||
| * `environment` | ||
| * `db_system` | ||
|
|
@@ -263,26 +263,7 @@ Pivoting to Tracing data from Entity Inspector is possible only for “Cassandra | |
| 5. Sumo Logic Kubernetes collection will automatically start collecting logs from the pods having the annotations defined above. | ||
| 6. Verify logs in Sumo Logic. | ||
|
|
||
| 3. Add an FER to normalize the fields in Kubernetes environments. Labels created in Kubernetes environments automatically are prefixed with pod_labels. To normalize these for our app to work, we need to create a Field Extraction Rule if not already created for Proxy Application Components. This step is not needed if one is using application components solution terraform script. To do so: | ||
| 1. [**Classic UI**](/docs/get-started/sumo-logic-ui-classic). In the main Sumo Logic menu, select **Manage Data > Logs > Field Extraction Rules**. <br/>[**New UI**](/docs/get-started/sumo-logic-ui). In the top menu select **Configuration**, and then under **Logs** select **Field Extraction Rules**. You can also click the **Go To...** menu at the top of the screen and select **Field Extraction Rules**. | ||
| 2. Click the **+ Add** button on the top right of the table. | ||
| 3. The **Add Field Extraction Rule** form will appear: | ||
| 4. Enter the following options: | ||
| * **Rule Name**. Enter the name as **App Observability - Database**. | ||
| * **Applied At.** Choose **Ingest Time** | ||
| * **Scope**. Select **Specific Data** | ||
| * **Scope**: Enter the following keyword search expression: | ||
| ```sql | ||
| pod_labels_environment=* pod_labels_component=database pod_labels_db_system=* pod_labels_db_cluster=* | ||
| ``` | ||
| * **Parse Expression**. Enter the following parse expression: | ||
| ```sql | ||
| if (!isEmpty(pod_labels_environment), pod_labels_environment, "") as environment | ||
| | pod_labels_component as component | ||
| | pod_labels_db_system as db_system | ||
| | if (!isEmpty(pod_labels_db_cluster), pod_labels_db_cluster, null) as db_cluster | ||
| ``` | ||
| 5. Click **Save** to create the rule. | ||
| 3. **FER to normalize the fields in Kubernetes environments.** Labels created in Kubernetes environments automatically are prefixed with pod_labels. To normalize these for our app to work, we will have Field Extraction Rule automatically created for Database Application Components named as **AppObservabilityCassandraDatabaseFER**. | ||
|
|
||
| </TabItem> | ||
| <TabItem value="non-k8s"> | ||
|
|
@@ -522,91 +503,7 @@ At this point, Cassandra metrics and logs should start flowing into Sumo Logic. | |
| </TabItem> | ||
| </Tabs> | ||
|
|
||
| ## Installing Cassandra Monitors | ||
|
|
||
| :::note | ||
| This step is not needed if you are using the [Application Components Solution](/docs/observability/application-components) Terraform script. | ||
| ::: | ||
|
|
||
| To install these monitors, you must have the **Manage Monitors** role capability. You can install monitors by importing a JSON file or using a Terraform script. | ||
|
|
||
| Sumo Logic has provided pre-packaged alerts available through [Sumo Logic monitors](/docs/alerts/monitors) to help you proactively determine if a Cassandra cluster is available and performing as expected. These monitors are based on metric and log data and include pre-set thresholds that reflect industry best practices and recommendations. For more information about individual alerts, see [Cassandra Alerts](#cassandra-alerts). | ||
|
|
||
| There are limits to how many alerts can be enabled. For more information, see [Monitors](/docs/alerts/monitors/create-monitor) for details. | ||
|
|
||
| ### Method A: Importing a JSON file | ||
|
|
||
| 1. Download the [JSON file](https://github.com/SumoLogic/terraform-sumologic-sumo-logic-monitor/blob/main/monitor_packages/Memcached/Memcached.json) that describes the monitors. | ||
| 2. The [JSON](https://github.com/SumoLogic/terraform-sumologic-sumo-logic-monitor/blob/main/monitor_packages/Memcached/Memcached.json) contains the alerts that are based on Sumo Logic searches that do not have any scope filters and therefore will be applicable to all Cassandra clusters, the data for which has been collected via the instructions in the previous sections. | ||
|
|
||
| However, if you would like to restrict these alerts to specific clusters or environments, update the JSON file by replacing the text `db_cluster=*` with `<Your Custom Filter>`. Custom filter examples: | ||
| * For alerts applicable only to a specific cluster, your custom filter would be: `db_cluster=dev-cassandra-01`. | ||
| * For alerts applicable to all clusters that start with `cassandra-prod`, your custom filter would be: `db_cluster=cassandra-prod*`. | ||
| * For alerts applicable to specific clusters, within a production environment, your custom filter would be:`db_cluster=dev-cassandra-01` AND `environment=prod`. This assumes you have set the optional environment tag while configuring collection. | ||
| 3. [**Classic UI**](/docs/get-started/sumo-logic-ui-classic). In the main Sumo Logic menu, select **Manage Data > Monitoring > Monitors**. <br/>[**New UI**](/docs/get-started/sumo-logic-ui). In the main Sumo Logic menu, select **Alerts > Monitors**. You can also click the **Go To...** menu at the top of the screen and select **Monitors**. | ||
| 4. Click **Add**. | ||
| 5. Click **Import**. | ||
| 6. On the **Import Content popup**, enter **Cassandra** in the Name field, paste the JSON into the popup, and click **Import**. | ||
| 7. The monitors are created in a "Cassandra" folder. The monitors are disabled by default. See the [Monitors](/docs/alerts/monitors) topic for information about enabling monitors and configuring notifications or connections. | ||
|
|
||
| ### Method B: Using a Terraform script | ||
|
|
||
| 1. Generate an access key and access ID for a user that has the **Manage Monitors** role capability. For instructions, see [Access Keys](/docs/manage/security/access-keys). | ||
| 2. Download [Terraform 0.13](https://www.terraform.io/downloads.html) or later and install it. | ||
| 3. Download the Sumo Logic Terraform package for Cassandra monitors. The alerts package is available in the Sumo Logic GitHub [repository](https://github.com/SumoLogic/terraform-sumologic-sumo-logic-monitor/tree/main/monitor_packages/Memcached). You can either download it using the git clone command or as a zip file. | ||
| 4. Alert Configuration. After extracting the package, navigate to the `terraform-sumologic-sumo-logic-monitor/monitor_packages/Cassandra/` directory. | ||
| 5. Edit the Cassandra.auto.tfvars file and add the Sumo Logic Access Key and Access ID from Step 1 and your Sumo Logic deployment. If you're not sure of your deployment, see [Sumo Logic Endpoints and Firewall Security](/docs/api/getting-started#sumo-logic-endpoints-by-deployment-and-firewall-security). | ||
| ```bash | ||
| access_id = "<SUMOLOGIC ACCESS ID>" | ||
| access_key = "<SUMOLOGIC ACCESS KEY>" | ||
| environment = "<SUMOLOGIC DEPLOYMENT>" | ||
| ``` | ||
| 6. The Terraform script installs the alerts without any scope filters, if you would like to restrict the alerts to specific clusters or environments, update the `cassandra_data_source` variable. For example: | ||
| * To configure alerts for a specific cluster, set `cassandra_data_source` to something like `db_cluster=cassandra.prod.01` | ||
| * To configure alerts for all clusters in an environment, set `cassandra_data_source` to something like `environment=prod` | ||
| * To configure alerts for multiple clusters using a wildcard, set `cassandra_data_source` to something like `db_cluster=cassandra-prod*` | ||
| * To configure alerts for...A specific clusters within a specific environment, set `cassandra_data_source` to something like `db_cluster=cassandra-1` and `environment=prod`. This assumes you have configured and applied Fields as described [Configure Fields in Sumo Logic](#step-1-configure-fields-in-sumo-logic) step. | ||
|
|
||
| All monitors are disabled by default on installation. To enable all of the monitors, set the `monitors_disabled` parameter to `false`. By default, the monitors will be located in a "Cassandra" folder on the **Monitors** page. To change the name of the folder, update the monitor folder name in the folder variable in the `Cassandra.auto.tfvars` file. | ||
|
|
||
| 7. If you want your alerts to send email or connection notifications, edit the `Cassandra_notifications.auto.tfvars` file to populate the `connection_notifications` and `email_notifications` sections. Examples are provided below. | ||
|
|
||
| In the variable definition below, replace `<CONNECTION_ID>` with the connection ID of the Webhook connection. You can obtain the Webhook connection ID by calling the [Monitors API](https://api.sumologic.com/docs/#operation/listConnections). | ||
|
|
||
| ```bash title="Pagerduty connection example" | ||
| connection_notifications = [ | ||
| { | ||
| connection_type = "PagerDuty", | ||
| connection_id = "<CONNECTION_ID>", | ||
| payload_override = "{\"service_key\": \"your_pagerduty_api_integration_key\",\"event_type\": \"trigger\",\"description\": \"Alert: Triggered {{TriggerType}} for Monitor {{Name}}\",\"client\": \"Sumo Logic\",\"client_url\": \"{{QueryUrl}}\"}", | ||
| run_for_trigger_types = ["Critical", "ResolvedCritical"] | ||
| }, | ||
| { | ||
| connection_type = "Webhook", | ||
| connection_id = "<CONNECTION_ID>", | ||
| payload_override = "", | ||
| run_for_trigger_types = ["Critical", "ResolvedCritical"] | ||
| } | ||
| ] | ||
| ``` | ||
|
|
||
| For information about overriding the payload for different connection types, see [Set Up Webhook Connections](/docs/alerts/webhook-connections/set-up-webhook-connections). | ||
| ```bash title="Email notifications example" | ||
| email_notifications = [ | ||
| { | ||
| connection_type = "Email", | ||
| recipients = ["[email protected]"], | ||
| subject = "Monitor Alert: {{TriggerType}} on {{Name}}", | ||
| time_zone = "PST", | ||
| message_body = "Triggered {{TriggerType}} Alert on {{Name}}: {{QueryURL}}", | ||
| run_for_trigger_types = ["Critical", "ResolvedCritical"] | ||
| } | ||
| ] | ||
| ``` | ||
|
|
||
| 8. To install the Monitors, navigate to the `terraform-sumologic-sumo-logic-monitor/monitor_packages/Cassandra/` directory and run `terraform init`. This will initialize Terraform and download the required components. | ||
| 9. Run `terraform plan` to view the monitors that Terraform will create or modify. | ||
| 10. Run `terraform apply`. | ||
|
|
||
| ## Installing the Cassandra app | ||
|
|
||
|
|
@@ -739,7 +636,13 @@ Use this dashboard to: | |
|
|
||
| <img src={useBaseUrl('img/integrations/databases/Cassandra-Write-Path.png')} alt="Cassandra dashboards" /> | ||
|
|
||
| ## Cassandra Alerts | ||
| ## Create monitors for Cassandra app | ||
|
|
||
| import CreateMonitors from '../../reuse/apps/create-monitors.md'; | ||
|
|
||
| <CreateMonitors/> | ||
|
|
||
| ### Cassandra Alerts | ||
|
|
||
| Sumo Logic has provided out-of-the-box alerts available via [Sumo Logic monitors](/docs/alerts/monitors) to help you quickly determine if the Cassandra cluster is available and performing as expected. | ||
|
|
||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.