Skip to content

Commit

Permalink
chore: improvements to SEO setup for modified pages
Browse files Browse the repository at this point in the history
  • Loading branch information
cprice404 committed Jan 18, 2024
1 parent 8f62f1b commit 5b7bc75
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 11 deletions.
24 changes: 17 additions & 7 deletions docs/cache/develop/sdks/nodejs/config-and-error-handling.mdx
Original file line number Diff line number Diff line change
@@ -1,18 +1,28 @@
---
sidebar_position: 2
sidebar_label: Config and Error Handling
title: Observability for TypeScript and Node.js
description: Instrument your Momento-enabled Node.js code with Logs, Metrics, and Traces

This comment has been minimized.

Copy link
@cprice404

cprice404 Jan 18, 2024

Author Contributor

@allenheltondev when you posted suggestions for these two fields I realized I had copypasta'd them from the observability page, so I attempted to come up with phrases actually related to config / error handling that matched the style you were suggesting.

title: Manage Momento Configuration and Error Handling in TypeScript and Node.js
description: Learn how to configure your Momento CacheClient and write production-ready error handling code in TypeScript and Node.js
keywords:
- momento
- cache
- configuration
- error handling
- exceptions
- sdk
- production ready
- typescript
- node.js
- nodejs
- javascript
---

import { SdkExampleCodeBlock } from "@site/src/components/SdkExampleCodeBlock";
// This import is necessary even though it looks like it's un-used; The inject-example-code-snippet
// plugin will transform instances of SdkExampleCodeBlock to SdkExampleCodeBlockImpl
import { SdkExampleCodeBlockImpl } from "@site/src/components/SdkExampleCodeBlockImpl";

# Configuration and Error Handling in the Momento node.js SDK

## Configuration
# How to Manage Configuration and Error Handling in the Momento Node.js SDK

The code below illustrates the simplest way to construct a `CacheClient`:

Expand All @@ -26,13 +36,13 @@ and `Lambda` (which is tuned for use in AWS Lambda environments). Here is how yo

<SdkExampleCodeBlock language={'javascript'} snippetId={'configuration_ConstructWithLambdaConfig'} />

:::tip
If you omit the configuration, Momento will use the `Laptop` configuration by default. This configuration has relaxed
timeouts, suitable for development or in high-latency environments. (It is not recommended for production, server-side use.)
:::

For more information about `Configuration` objects see [SDK Configuration Objects](/cache/develop/basics/client-configuration-objects.md).

## Error Handling

By default, `CacheClient` errors are surfaced to developers as part of the return values of the calls, as opposed to throwing
exceptions. This makes errors more visible when you're writing your code, and allows your IDE to be more helpful in ensuring
you've handled the errors you care about.
Expand Down
25 changes: 23 additions & 2 deletions docs/cache/develop/sdks/nodejs/observability.mdx
Original file line number Diff line number Diff line change
@@ -1,8 +1,29 @@
---
sidebar_position: 3
sidebar_label: Observability
title: Observability for TypeScript and Node.js
description: Instrument your Momento-enabled Node.js code with Logs, Metrics, and Traces
title: Observe your Momento Cache client metrics in TypeScript and Node.js
description: Learn how to improve observability of your Momento Cache client by configuring logging, client-side metrics, and traces.
- momento
- cache
- client
- observability
- logging
- metrics
- traces
- opentelemetry
- prometheus
- cloudwatch
- grafana
- zipkin
- pino
- winston
- bunyan
- morgan
- node.js
- nodejs
- typescript
- javascript
- sdk
---

import { SdkExampleCodeBlock } from "@site/src/components/SdkExampleCodeBlock";
Expand Down
15 changes: 13 additions & 2 deletions docs/topics/develop/sdks/nodejs/index.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
---
sidebar_position: 1
title: Momento Node.js SDK
title: Momento Node.js SDK | Topics
pagination_prev: null
sidebar_label: Node.js
description: Information about the Momento Node.js SDK
description: Get started using the Momento Node.js SDK for Topics Today. Discover system requirements, explore our cheat sheets, and learn about cool integrations with one-click installs.
keywords:
- momento
- topics
- event-driven architecture
- eda
- websockets
- node.js
- nodejs
- javascript
- sdk
- typescript
---

# Momento Node.js SDK - Topic Client
Expand Down

0 comments on commit 5b7bc75

Please sign in to comment.