Skip to content

Commit d32eaa7

Browse files
Merge pull request #241 from RedisLabs/feat/subscriptions-aws-account-id
AWS account ID in subscriptions
2 parents a954eb2 + 6a65c27 commit d32eaa7

File tree

6 files changed

+43
-2
lines changed

6 files changed

+43
-2
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: CI
22

3-
on: [push]
3+
on: [push, pull_request]
44

55
jobs:
66
build:
@@ -15,6 +15,7 @@ jobs:
1515
uses: actions/[email protected]
1616
with:
1717
go-version-file: go.mod
18+
cache: true
1819

1920
- name: Build
2021
run: make
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Vulnerability Check
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
vulncheck:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Checkout
10+
uses: actions/[email protected]
11+
12+
- name: Install Go
13+
uses: actions/[email protected]
14+
with:
15+
go-version-file: go.mod
16+
cache: true
17+
18+
- name: Check for vulnerabilities
19+
run: go run golang.org/x/vuln/cmd/govulncheck@latest ./...

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,20 @@
22
All notable changes to this project will be documented in this file.
33
See updating [Changelog example here](https://keepachangelog.com/en/1.0.0/).
44

5+
## Unreleased
6+
7+
### Added:
8+
* Added `AWSAccountID` field to `CloudDetail` struct in subscriptions model for AWS account identification
9+
* Added `govulncheck` to CI pipeline for automated vulnerability detection
10+
* New `.github/workflows/vulnerability.yml` workflow for parallel vulnerability checking
11+
* Enabled Go module caching in GitHub Actions for improved build performance
12+
13+
### Updated:
14+
* Updated Go toolchain to 1.25.3 to address stdlib vulnerabilities (GO-2025-4007, GO-2025-3751, GO-2025-3750, GO-2025-3749, GO-2025-3563)
15+
16+
### Tests:
17+
* Added AWS account ID to subscription test fixtures (`TestSubscription_List`, `TestSubscription_Get`, `TestSubscription_Get_PublicEndpointAccess`)
18+
519
## 0.40.0 (31st October 2025)
620

721
### Added:

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module github.com/RedisLabs/rediscloud-go-api
22

33
go 1.24.0
44

5-
toolchain go1.24.1
5+
toolchain go1.25.3
66

77
require (
88
github.com/avast/retry-go/v4 v4.7.0

service/subscriptions/model.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,7 @@ func (o Subscription) String() string {
153153
type CloudDetail struct {
154154
Provider *string `json:"provider,omitempty"`
155155
CloudAccountID *int `json:"cloudAccountId,omitempty"`
156+
AWSAccountID *string `json:"awsAccountId,omitempty"`
156157
TotalSizeInGB *float64 `json:"totalSizeInGb,omitempty"`
157158
Regions []*Region `json:"regions,omitempty"`
158159
}

subscription_test.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -425,6 +425,7 @@ func TestSubscription_List(t *testing.T) {
425425
{
426426
"provider": "AWS",
427427
"cloudAccountId": 2,
428+
"awsAccountId": "123456789012",
428429
"totalSizeInGb": 0.0062,
429430
"regions": [
430431
{
@@ -509,6 +510,7 @@ func TestSubscription_List(t *testing.T) {
509510
{
510511
Provider: redis.String("AWS"),
511512
CloudAccountID: redis.Int(2),
513+
AWSAccountID: redis.String("123456789012"),
512514
TotalSizeInGB: redis.Float64(0.0062),
513515
Regions: []*subscriptions.Region{
514516
{
@@ -579,6 +581,7 @@ func TestSubscription_Get(t *testing.T) {
579581
{
580582
"provider": "AWS",
581583
"cloudAccountId": 3,
584+
"awsAccountId": "987654321098",
582585
"totalSizeInGb": 4,
583586
"regions": [
584587
{
@@ -624,6 +627,7 @@ func TestSubscription_Get(t *testing.T) {
624627
{
625628
Provider: redis.String("AWS"),
626629
CloudAccountID: redis.Int(3),
630+
AWSAccountID: redis.String("987654321098"),
627631
TotalSizeInGB: redis.Float64(4),
628632
Regions: []*subscriptions.Region{
629633
{
@@ -658,6 +662,7 @@ func TestSubscription_Get_PublicEndpointAccess(t *testing.T) {
658662
{
659663
"provider": "AWS",
660664
"cloudAccountId": 3,
665+
"awsAccountId": "111222333444",
661666
"totalSizeInGb": 4,
662667
"regions": [
663668
{
@@ -704,6 +709,7 @@ func TestSubscription_Get_PublicEndpointAccess(t *testing.T) {
704709
{
705710
Provider: redis.String("AWS"),
706711
CloudAccountID: redis.Int(3),
712+
AWSAccountID: redis.String("111222333444"),
707713
TotalSizeInGB: redis.Float64(4),
708714
Regions: []*subscriptions.Region{
709715
{

0 commit comments

Comments
 (0)