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

@alicloud/pop-core

Package Overview
Dependencies
Maintainers
3
Versions
44
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@alicloud/pop-core - npm Package Compare versions

Comparing version 1.2.4 to 1.3.0

15

lib/roa.js

@@ -30,2 +30,8 @@ 'use strict';

this.host = url.parse(this.endpoint).hostname;
var httpModule = this.host.startsWith('https://') ? require('https') : require('http');
this.keepAliveAgent = new httpModule.Agent({
keepAlive: true,
keepAliveMsecs: 3000
});
}

@@ -110,3 +116,3 @@

request(method, uriPattern, query = {}, body = '', headers = {}) {
request(method, uriPattern, query = {}, body = '', headers = {}, opts) {
var postBody = null;

@@ -130,7 +136,10 @@

return httpx.request(url, {
const options = Object.assign({
method,
agent: this.keepAliveAgent,
headers: mixHeaders,
data: postBody
}).then((response) => {
}, opts);
return httpx.request(url, options).then((response) => {
return httpx.read(response, 'utf8').then((body) => {

@@ -137,0 +146,0 @@ const contentType = response.headers['content-type'] || '';

2

package.json
{
"name": "@alicloud/pop-core",
"version": "1.2.4",
"version": "1.3.0",
"description": "AliCloud POP SDK core",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -49,3 +49,4 @@ # @alicloud/pop-core

// => returns Promise
// request(HTTPMethod, uriPath, queries, body, headers);
// request(HTTPMethod, uriPath, queries, body, headers, options);
// options => {timeout}
client.request('GET', '/regions');

@@ -52,0 +53,0 @@ // co/yield, async/await

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