Skip to content

Commit cfa9b93

Browse files
author
ramanan-ravi
committed
Cache inventory to minimize cloud api calls
Use postgresql cache
1 parent c10c7bd commit cfa9b93

File tree

3 files changed

+81
-135
lines changed

3 files changed

+81
-135
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,6 @@
1515
# vendor/
1616

1717
# Ignore file types
18-
.vscode/
18+
.vscode/
19+
20+
.idea

go.mod

Lines changed: 26 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ go 1.21.0
44

55
toolchain go1.21.4
66

7+
replace github.com/turbot/steampipe-plugin-sdk/v5 v5.10.1 => github.com/deepfence/steampipe-plugin-sdk/v5 v5.10.1
8+
79
require (
810
github.com/Azure/azure-sdk-for-go v68.0.0+incompatible
911
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.11.0
@@ -49,14 +51,15 @@ require (
4951
github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect
5052
github.com/btubbs/datetime v0.1.1 // indirect
5153
github.com/cenkalti/backoff/v4 v4.3.0 // indirect
52-
github.com/cespare/xxhash/v2 v2.2.0 // indirect
54+
github.com/cespare/xxhash/v2 v2.3.0 // indirect
5355
github.com/danwakefield/fnmatch v0.0.0-20160403171240-cbb64ac3d964 // indirect
56+
github.com/deepfence/gocache/lib/v4 v4.1.40 // indirect
57+
github.com/deepfence/gocache/store/bigcache/v4 v4.1.41 // indirect
58+
github.com/deepfence/gocache/store/postgresqlcache/v4 v4.1.41 // indirect
59+
github.com/deepfence/gocache/store/ristretto/v4 v4.1.41 // indirect
5460
github.com/dgraph-io/ristretto v0.1.1 // indirect
5561
github.com/dimchansky/utfbom v1.1.1 // indirect
5662
github.com/dustin/go-humanize v1.0.0 // indirect
57-
github.com/eko/gocache/lib/v4 v4.1.5 // indirect
58-
github.com/eko/gocache/store/bigcache/v4 v4.2.1 // indirect
59-
github.com/eko/gocache/store/ristretto/v4 v4.2.1 // indirect
6063
github.com/fatih/color v1.15.0 // indirect
6164
github.com/felixge/httpsnoop v1.0.4 // indirect
6265
github.com/form3tech-oss/jwt-go v3.2.2+incompatible // indirect
@@ -69,7 +72,6 @@ require (
6972
github.com/golang-jwt/jwt/v5 v5.2.1 // indirect
7073
github.com/golang/glog v1.2.0 // indirect
7174
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
72-
github.com/golang/mock v1.6.0 // indirect
7375
github.com/golang/protobuf v1.5.4 // indirect
7476
github.com/google/go-cmp v0.6.0 // indirect
7577
github.com/google/s2a-go v0.1.7 // indirect
@@ -86,14 +88,18 @@ require (
8688
github.com/hashicorp/hcl/v2 v2.20.1 // indirect
8789
github.com/hashicorp/yamux v0.1.1 // indirect
8890
github.com/iancoleman/strcase v0.3.0 // indirect
91+
github.com/jackc/pgpassfile v1.0.0 // indirect
92+
github.com/jackc/pgservicefile v0.0.0-20221227161230-091c0ba34f0a // indirect
93+
github.com/jackc/pgx/v5 v5.6.0 // indirect
94+
github.com/jackc/puddle/v2 v2.2.1 // indirect
8995
github.com/jmespath/go-jmespath v0.4.0 // indirect
90-
github.com/klauspost/compress v1.15.11 // indirect
96+
github.com/klauspost/compress v1.17.9 // indirect
9197
github.com/kylelemons/godebug v1.1.0 // indirect
98+
github.com/lib/pq v1.10.9 // indirect
9299
github.com/mattn/go-colorable v0.1.13 // indirect
93100
github.com/mattn/go-ieproxy v0.0.1 // indirect
94101
github.com/mattn/go-isatty v0.0.19 // indirect
95102
github.com/mattn/go-runewidth v0.0.13 // indirect
96-
github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect
97103
github.com/mitchellh/go-homedir v1.1.0 // indirect
98104
github.com/mitchellh/go-testing-interface v1.14.1 // indirect
99105
github.com/mitchellh/go-wordwrap v1.0.0 // indirect
@@ -102,13 +108,14 @@ require (
102108
github.com/olekukonko/tablewriter v0.0.5 // indirect
103109
github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c // indirect
104110
github.com/pkg/errors v0.9.1 // indirect
105-
github.com/prometheus/client_golang v1.14.0 // indirect
106-
github.com/prometheus/client_model v0.3.0 // indirect
107-
github.com/prometheus/common v0.37.0 // indirect
108-
github.com/prometheus/procfs v0.8.0 // indirect
111+
github.com/prometheus/client_golang v1.19.0 // indirect
112+
github.com/prometheus/client_model v0.6.1 // indirect
113+
github.com/prometheus/common v0.52.3 // indirect
114+
github.com/prometheus/procfs v0.13.0 // indirect
109115
github.com/rivo/uniseg v0.2.0 // indirect
110116
github.com/sethvargo/go-retry v0.2.4 // indirect
111117
github.com/shopspring/decimal v1.3.1 // indirect
118+
github.com/spf13/cast v1.5.1 // indirect
112119
github.com/stevenle/topsort v0.2.0 // indirect
113120
github.com/tkrajina/go-reflector v0.5.6 // indirect
114121
github.com/ulikunitz/xz v0.5.10 // indirect
@@ -125,16 +132,17 @@ require (
125132
go.opentelemetry.io/otel/sdk/metric v1.26.0 // indirect
126133
go.opentelemetry.io/otel/trace v1.26.0 // indirect
127134
go.opentelemetry.io/proto/otlp v1.2.0 // indirect
128-
golang.org/x/crypto v0.21.0 // indirect
129-
golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1 // indirect
130-
golang.org/x/mod v0.8.0 // indirect
131-
golang.org/x/net v0.23.0 // indirect
132-
golang.org/x/oauth2 v0.17.0 // indirect
133-
golang.org/x/sync v0.6.0 // indirect
135+
go.uber.org/mock v0.4.0 // indirect
136+
golang.org/x/crypto v0.22.0 // indirect
137+
golang.org/x/exp v0.0.0-20240416160154-fe59bbe5cc7f // indirect
138+
golang.org/x/mod v0.17.0 // indirect
139+
golang.org/x/net v0.24.0 // indirect
140+
golang.org/x/oauth2 v0.18.0 // indirect
141+
golang.org/x/sync v0.7.0 // indirect
134142
golang.org/x/sys v0.19.0 // indirect
135143
golang.org/x/text v0.14.0 // indirect
136144
golang.org/x/time v0.5.0 // indirect
137-
golang.org/x/tools v0.6.0 // indirect
145+
golang.org/x/tools v0.20.0 // indirect
138146
google.golang.org/api v0.162.0 // indirect
139147
google.golang.org/appengine v1.6.8 // indirect
140148
google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de // indirect

0 commit comments

Comments
 (0)