Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@aws-sdk/eventstream-serde-config-resolver

Package Overview
Dependencies
Maintainers
4
Versions
107
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-sdk/eventstream-serde-config-resolver

[![NPM version](https://img.shields.io/npm/v/@aws-sdk/@aws-sdk/eventstream-serde-config-resolver/alpha.svg)](https://www.npmjs.com/package/@aws-sdk/@aws-sdk/eventstream-serde-config-resolver) [![NPM downloads](https://img.shields.io/npm/dm/@aws-sdk/@aws-s

  • 1.0.0-gamma.1
  • Source
  • npm
  • Socket score

Version published
Maintainers
4
Created

What is @aws-sdk/eventstream-serde-config-resolver?

@aws-sdk/eventstream-serde-config-resolver is a package within the AWS SDK for JavaScript that provides utilities for resolving configuration related to event stream serialization and deserialization. This is particularly useful when working with AWS services that use event streams, such as AWS Transcribe or Kinesis.

What are @aws-sdk/eventstream-serde-config-resolver's main functionalities?

Event Stream Serialization

This feature allows you to resolve the configuration for event stream serialization. The `resolveEventStreamSerdeConfig` function takes an object with an `eventStreamSerdeProvider` property, which provides the serialization and deserialization logic.

const { resolveEventStreamSerdeConfig } = require('@aws-sdk/eventstream-serde-config-resolver');

const config = resolveEventStreamSerdeConfig({
  eventStreamSerdeProvider: () => ({
    serialize: (input) => {/* serialization logic */},
    deserialize: (output) => {/* deserialization logic */}
  })
});

console.log(config);

Custom Serialization Logic

This feature demonstrates how to provide custom serialization and deserialization logic. The `customSerdeProvider` object defines how to serialize and deserialize event stream data, and this is passed to the `resolveEventStreamSerdeConfig` function.

const { resolveEventStreamSerdeConfig } = require('@aws-sdk/eventstream-serde-config-resolver');

const customSerdeProvider = {
  serialize: (input) => Buffer.from(JSON.stringify(input)),
  deserialize: (output) => JSON.parse(output.toString())
};

const config = resolveEventStreamSerdeConfig({
  eventStreamSerdeProvider: () => customSerdeProvider
});

console.log(config);

Other packages similar to @aws-sdk/eventstream-serde-config-resolver

FAQs

Package last updated on 21 May 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc