ac-sqs 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,23 @@
1
+ <a name="2.0.1"></a>
2
+
3
+ ## [2.0.1](https://github.com/admiralcloud/ac-sqs/compare/v2.0.0..v2.0.1) (2023-07-02 13:28:31)
4
+
5
+
6
+ ### Bug Fix
7
+
8
+ * **App:** Add option to retrieve all available lists | MP | [3f6633cfad4b17f444373ca098831bd78bff51cc](https://github.com/admiralcloud/ac-sqs/commit/3f6633cfad4b17f444373ca098831bd78bff51cc)
9
+ Add option to retrieve all available lists
10
+ Related issues: [/issues#undefined](https://github.com//issues/undefined)
11
+ ### Documentation
12
+
13
+ * **App:** Improved info about testing | MP | [d60cd85395e9a7cdd80fb31186913f5901c28daa](https://github.com/admiralcloud/ac-sqs/commit/d60cd85395e9a7cdd80fb31186913f5901c28daa)
14
+ Improved info about testing
15
+ Related issues: [admiralcloud/ac-sqs#1](https://github.com/admiralcloud/ac-sqs/issues/1) [admiralcloud/ac-api-server#340](https://github.com/admiralcloud/ac-api-server/issues/340)
16
+ ### Chores
17
+
18
+ * **App:** Updated packages | MP | [f2a69c23c58099ae460a6e1df0fc22356a1a2c52](https://github.com/admiralcloud/ac-sqs/commit/f2a69c23c58099ae460a6e1df0fc22356a1a2c52)
19
+ Updated packages
20
+ Related issues: [/issues#undefined](https://github.com//issues/undefined)
1
21
  <a name="2.0.0"></a>
2
22
 
3
23
  # [2.0.0](https://github.com/admiralcloud/ac-sqs/compare/v0.1.0..v2.0.0) (2023-04-29 06:19:35)
package/README.md CHANGED
@@ -120,6 +120,7 @@ Preparations you have to make before running the tests:
120
120
  + export the AWS account id using **export awsaccount=12345**
121
121
  + create a SQS list named "test_acsqs"
122
122
  + create a bucket and export the name using **export bucket=acsqs-test-bucket**
123
+ + export the node test environment using **export NODE_ENV=test**
123
124
 
124
125
  **ATTENTION**: Tests may fail when checking the SQS length. This is a by-design failure:
125
126
  "ApproximateNumberOfMessages metrics may not achieve consistency until at least 1 minute after the producers stop sending messages."
package/index.js CHANGED
@@ -39,6 +39,15 @@ class ACSQS {
39
39
  }
40
40
  }
41
41
 
42
+ async getAllLists() {
43
+ let response = []
44
+ for (const list of this.availableLists) {
45
+ const attr = await this.getQueueAttributes({ name: list?.name, attributes: ['QueueArn'] })
46
+ response.push({ name: list?.name, value: attr?.Attributes?.QueueArn })
47
+ }
48
+ return response
49
+ }
50
+
42
51
  async getQueueUrl({ name, fifo, localPrefix }) {
43
52
  let queueUrl = `https://sqs.${this.region}.amazonaws.com/${this.account}/`
44
53
  if (localPrefix) queueUrl += `local_${localPrefix}_`
package/package.json CHANGED
@@ -3,18 +3,18 @@
3
3
  "author": "Mark Poepping (https://www.admiralcloud.com)",
4
4
  "license": "MIT",
5
5
  "repository": "admiralcloud/ac-sqs",
6
- "version": "2.0.0",
6
+ "version": "2.0.1",
7
7
  "dependencies": {
8
- "@aws-sdk/client-s3": "^3.321.1",
9
- "@aws-sdk/client-sqs": "^3.321.1",
10
- "@aws-sdk/credential-providers": "^3.321.1",
8
+ "@aws-sdk/client-s3": "^3.363.0",
9
+ "@aws-sdk/client-sqs": "^3.363.0",
10
+ "@aws-sdk/credential-providers": "^3.363.0",
11
11
  "lodash": "^4.17.21",
12
12
  "uuid": "^9.0.0"
13
13
  },
14
14
  "devDependencies": {
15
15
  "ac-semantic-release": "^0.4.1",
16
16
  "chai": "^4.3.7",
17
- "eslint": "^8.39.0",
17
+ "eslint": "^8.44.0",
18
18
  "mocha": "^10.x"
19
19
  },
20
20
  "scripts": {