New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@acuris/eventstore-postgresql

Package Overview
Dependencies
Maintainers
4
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@acuris/eventstore-postgresql - npm Package Compare versions

Comparing version 1.1.2 to 1.1.4

1

dist/PgEventSource.d.ts

@@ -8,2 +8,3 @@ import * as Pg from "pg";

export declare function pgConfigForAWSAsync(region: string, hostname: string, port: number, database: string, username: string): Promise<Pg.ClientConfig>;
export declare function pgAsyncConfigForAWS(region: string, hostname: string, port: number, database: string, username: string): Pg.ClientConfig;
export declare function pgConfigForRDS(region: string, clusterIdentifier: string, username: string, readonly?: boolean): Promise<Pg.ClientConfig>;

@@ -10,0 +11,0 @@ export declare class PgEventSource implements EventSource {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.PgEventSource = exports.pgConfigForRDS = exports.pgConfigForAWSAsync = exports.pgConfigForAWS = void 0;
exports.PgEventSource = exports.pgConfigForRDS = exports.pgAsyncConfigForAWS = exports.pgConfigForAWSAsync = exports.pgConfigForAWS = void 0;
const PgSchemaManager_1 = require("./PgSchemaManager");

@@ -31,2 +31,20 @@ const eventstore_api_1 = require("@acuris/eventstore-api");

exports.pgConfigForAWSAsync = pgConfigForAWSAsync;
function pgAsyncConfigForAWS(region, hostname, port, database, username) {
const AWS = require("aws-sdk");
const signer = new AWS.RDS.Signer({ hostname, username, port, region });
return {
host: hostname, user: username, port, database, ssl: { rejectUnauthorized: false },
password() {
return new Promise((resolve, reject) => {
signer.getAuthToken({}, (err, token) => {
if (err)
reject(err);
else
resolve(token);
});
});
}
};
}
exports.pgAsyncConfigForAWS = pgAsyncConfigForAWS;
async function pgConfigForRDS(region, clusterIdentifier, username, readonly = false) {

@@ -39,3 +57,3 @@ const AWS = require("aws-sdk");

throw new Error(`Cluster "${clusterIdentifier}" not found`);
return pgConfigForAWSAsync(region, readonly ? clusterInfo.ReaderEndpoint : clusterInfo.Endpoint, clusterInfo.Port, clusterInfo.DatabaseName, username);
return pgAsyncConfigForAWS(region, readonly ? clusterInfo.ReaderEndpoint : clusterInfo.Endpoint, clusterInfo.Port, clusterInfo.DatabaseName, username);
}

@@ -42,0 +60,0 @@ exports.pgConfigForRDS = pgConfigForRDS;

2

package.json
{
"name": "@acuris/eventstore-postgresql",
"private": false,
"version": "1.1.2",
"version": "1.1.4",
"description": "Eventstore implementation storing events in Postgresql",

@@ -6,0 +6,0 @@ "keywords": [

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