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

@aws-sdk/endpoint-cache

Package Overview
Dependencies
Maintainers
7
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-sdk/endpoint-cache - npm Package Compare versions

Comparing version 3.32.0 to 3.34.0

tsconfig.types.json

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

# [3.34.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.33.0...v3.34.0) (2021-09-24)
### Features
* **non-clients:** remove comments from transpiled JS files ([#2813](https://github.com/aws/aws-sdk-js-v3/issues/2813)) ([e6fc7f3](https://github.com/aws/aws-sdk-js-v3/commit/e6fc7f3e0fa74785590ac19e7ed143c916bb9b6e))
# [3.32.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.31.0...v3.32.0) (2021-09-17)

@@ -8,0 +19,0 @@

42

dist/cjs/EndpointCache.js

@@ -10,8 +10,2 @@ "use strict";

}
/**
* Returns an un-expired endpoint for the given key.
*
* @param endpointsWithExpiry
* @returns
*/
getEndpoint(key) {

@@ -25,8 +19,2 @@ const endpointsWithExpiry = this.get(key);

}
/**
* Returns un-expired endpoints for the given key.
*
* @param key
* @returns
*/
get(key) {

@@ -48,12 +36,2 @@ if (!this.has(key)) {

}
/**
* Stores the endpoints passed for the key in cache.
* If not defined, uses empty string for the Address in endpoint.
* If not defined, uses one minute for CachePeriodInMinutes in endpoint.
* Stores milliseconds elapsed since the UNIX epoch in Expires param based
* on value provided in CachePeriodInMinutes.
*
* @param key
* @param endpoints
*/
set(key, endpoints) {

@@ -66,18 +44,5 @@ const now = Date.now();

}
/**
* Deletes the value for the given key in the cache.
*
* @param {string} key
*/
delete(key) {
// Replace with remove/delete call once support is added upstream
// Refs: https://github.com/Yomguithereal/mnemonist/issues/143
this.cache.set(key, []);
}
/**
* Checks whether the key exists in cache.
*
* @param {string} key
* @returns {boolean}
*/
has(key) {

@@ -87,4 +52,2 @@ if (!this.cache.has(key)) {

}
// Remove call for peek, once remove/delete support is added upstream
// Refs: https://github.com/Yomguithereal/mnemonist/issues/143
const endpoints = this.cache.peek(key);

@@ -96,5 +59,2 @@ if (!endpoints) {

}
/**
* Clears the cache.
*/
clear() {

@@ -105,2 +65,2 @@ this.cache.clear();

exports.EndpointCache = EndpointCache;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiRW5kcG9pbnRDYWNoZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9FbmRwb2ludENhY2hlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7QUFBQSw0RUFBMkM7QUFRM0MsTUFBYSxhQUFhO0lBR3hCLFlBQVksUUFBZ0I7UUFDMUIsSUFBSSxDQUFDLEtBQUssR0FBRyxJQUFJLG1CQUFRLENBQUMsUUFBUSxDQUFDLENBQUM7SUFDdEMsQ0FBQztJQUVEOzs7OztPQUtHO0lBQ0gsV0FBVyxDQUFDLEdBQVc7UUFDckIsTUFBTSxtQkFBbUIsR0FBRyxJQUFJLENBQUMsR0FBRyxDQUFDLEdBQUcsQ0FBQyxDQUFDO1FBQzFDLElBQUksQ0FBQyxtQkFBbUIsSUFBSSxtQkFBbUIsQ0FBQyxNQUFNLEtBQUssQ0FBQyxFQUFFO1lBQzVELE9BQU8sU0FBUyxDQUFDO1NBQ2xCO1FBQ0QsTUFBTSxTQUFTLEdBQUcsbUJBQW1CLENBQUMsR0FBRyxDQUFDLENBQUMsUUFBUSxFQUFFLEVBQUUsQ0FBQyxRQUFRLENBQUMsT0FBTyxDQUFDLENBQUM7UUFDMUUsT0FBTyxTQUFTLENBQUMsSUFBSSxDQUFDLEtBQUssQ0FBQyxJQUFJLENBQUMsTUFBTSxFQUFFLEdBQUcsU0FBUyxDQUFDLE1BQU0sQ0FBQyxDQUFDLENBQUM7SUFDakUsQ0FBQztJQUVEOz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CFlbmRwb2ludHMpIHtcbiAgICAgIHJldHVybiBmYWxzZTtcbiAgICB9XG4gICAgcmV0dXJuIGVuZHBvaW50cy5sZW5ndGggPiAwO1xuICB9XG5cbiAgLyoqXG4gICAqIENsZWFycyB0aGUgY2FjaGUuXG4gICAqL1xuICBjbGVhcigpIHtcbiAgICB0aGlzLmNhY2hlLmNsZWFyKCk7XG4gIH1cbn1cbiJdfQ==
{
"name": "@aws-sdk/endpoint-cache",
"version": "3.32.0",
"version": "3.34.0",
"scripts": {
"build": "yarn build:cjs && yarn build:es && yarn build:types",
"build:cjs": "tsc -p tsconfig.cjs.json",
"build:es": "tsc -p tsconfig.es.json",
"build": "yarn build:es && yarn build:cjs",
"build:types": "tsc -p tsconfig.types.json",
"downlevel-dts": "downlevel-dts dist/types dist/types/ts3.4",

@@ -9,0 +10,0 @@ "test": "jest --passWithNoTests"

{
"compilerOptions": {
"declarationDir": "./dist/types",
"rootDir": "./src",
"outDir": "./dist/cjs",
"baseUrl": "."
"baseUrl": ".",
"outDir": "dist/cjs",
"rootDir": "src"
},

@@ -8,0 +7,0 @@ "extends": "../../tsconfig.cjs.json",

{
"compilerOptions": {
"baseUrl": ".",
"lib": ["es5", "es2015.promise", "es2015.iterable"],
"declarationDir": "./dist/types",
"rootDir": "./src",
"outDir": "./dist/es",
"baseUrl": "."
"outDir": "dist/es",
"rootDir": "src"
},

@@ -9,0 +8,0 @@ "extends": "../../tsconfig.es.json",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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