Merged in feature/ecr (pull request #161)

Feature/ecr

* nosave

* repo

* awscli

* unzip

* ignore

* moreram

* 14k

* ref

* deployment

* 12k

* uselocal

* go

* dockercomd

* reorder

* iamgename

* installs

* tart

* cli

* clideps

* y

* dockerce

* nodock

* multi

* rmecr

* dev
This commit is contained in:
Michael McGuinness
2025-06-03 13:52:10 +00:00
parent ae4b456399
commit 7ce7c9df4d
73 changed files with 295 additions and 326 deletions
+1 -2
View File
@@ -1,7 +1,6 @@
package database
import (
"context"
"testing"
"queryorchestration/internal/serviceconfig/database"
@@ -10,7 +9,7 @@ import (
)
func TestCreateDB(t *testing.T) {
ctx := context.Background()
ctx := t.Context()
cfg := &database.DBConfig{
DBHost: "invalid_value",
}
+1 -2
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"queryorchestration/internal/database/repository"
@@ -17,7 +16,7 @@ func TestClean(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
+1 -2
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"queryorchestration/internal/database/repository"
@@ -17,7 +16,7 @@ func TestClientQueries(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"fmt"
"testing"
@@ -19,7 +18,7 @@ func TestCollector(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -221,7 +220,7 @@ func TestCollector(t *testing.T) {
}
func BenchmarkListCollectorQueries(b *testing.B) {
ctx := context.Background()
ctx := b.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(b, cfg)
@@ -243,7 +242,7 @@ func BenchmarkListCollectorQueries(b *testing.B) {
}
func BenchmarkGetCollectorByClientID(b *testing.B) {
ctx := context.Background()
ctx := b.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(b, cfg)
+1 -2
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"queryorchestration/internal/database/repository"
@@ -21,7 +20,7 @@ func TestQueriesNew(t *testing.T) {
}
func TestQueriesWithTx(t *testing.T) {
ctx := context.Background()
ctx := t.Context()
pool, err := pgxmock.NewPool()
require.NoError(t, err)
+9 -10
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"queryorchestration/internal/database/repository"
@@ -18,7 +17,7 @@ func TestDocument(t *testing.T) {
}
t.Run("List docs for a client", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -38,7 +37,7 @@ func TestDocument(t *testing.T) {
})
t.Run("Create document", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -68,7 +67,7 @@ func TestDocument(t *testing.T) {
t.Run("Create two documents", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -103,7 +102,7 @@ func TestDocument(t *testing.T) {
})
t.Run("Two clients", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -149,7 +148,7 @@ func TestDocument(t *testing.T) {
})
t.Run("document summary", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -181,7 +180,7 @@ func TestDocument(t *testing.T) {
})
t.Run("document external", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -214,7 +213,7 @@ func TestDocument(t *testing.T) {
})
t.Run("doc id by hash", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -245,7 +244,7 @@ func TestDocument(t *testing.T) {
})
t.Run("doc entry", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -286,7 +285,7 @@ func TestDocument(t *testing.T) {
})
t.Run("doc latest entry", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
+5 -6
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"queryorchestration/internal/database/repository"
@@ -18,7 +17,7 @@ func TestQueries(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -227,7 +226,7 @@ func TestQueryDependencyTree(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -445,7 +444,7 @@ func TestQueriesList(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -500,7 +499,7 @@ func TestListQueryClients(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -588,7 +587,7 @@ func TestListQueryClients(t *testing.T) {
}
func BenchmarkListQueryDirectDependentsByDocId(b *testing.B) {
ctx := context.Background()
ctx := b.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(b, cfg)
+5 -6
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"time"
@@ -20,7 +19,7 @@ func TestResults(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -47,7 +46,7 @@ func TestResultValues(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -376,7 +375,7 @@ func TestUnsyncedNoDepsQueries(t *testing.T) {
t.Run("two files", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -472,7 +471,7 @@ func TestUnsyncedNoDepsQueries(t *testing.T) {
t.Run("update query", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -499,7 +498,7 @@ func TestUnsyncedNoDepsQueries(t *testing.T) {
}
func BenchmarkListUnsynced(b *testing.B) {
ctx := context.Background()
ctx := b.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(b, cfg)
+24 -24
View File
@@ -20,7 +20,7 @@ func TestListClientDocumentIDs(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -197,7 +197,7 @@ func TestClientSync(t *testing.T) {
t.Run("no collector", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -218,7 +218,7 @@ func TestClientSync(t *testing.T) {
t.Run("no documents", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -247,7 +247,7 @@ func TestClientSync(t *testing.T) {
t.Run("create document", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -282,7 +282,7 @@ func TestClientSync(t *testing.T) {
t.Run("document fail clean", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -318,7 +318,7 @@ func TestClientSync(t *testing.T) {
t.Run("clean document", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -360,7 +360,7 @@ func TestClientSync(t *testing.T) {
t.Run("extracted text", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -400,7 +400,7 @@ func TestClientSync(t *testing.T) {
t.Run("single query", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -430,7 +430,7 @@ func TestClientSync(t *testing.T) {
t.Run("change super query", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -460,7 +460,7 @@ func TestClientSync(t *testing.T) {
})
t.Run("upstream query update result", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -504,7 +504,7 @@ func TestClientSync(t *testing.T) {
t.Run("update upstream query", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -564,7 +564,7 @@ func TestClientSync(t *testing.T) {
t.Run("update text entry", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -602,7 +602,7 @@ func TestClientSync(t *testing.T) {
})
t.Run("update text entry result", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -648,7 +648,7 @@ func TestClientSync(t *testing.T) {
})
t.Run("update clean entry", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -689,7 +689,7 @@ func TestClientSync(t *testing.T) {
})
t.Run("update clean entry with result", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -756,7 +756,7 @@ func TestClientSync(t *testing.T) {
t.Run("add new collector version", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -781,7 +781,7 @@ func TestClientSync(t *testing.T) {
t.Run("add new active collector version", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -812,7 +812,7 @@ func TestClientSync(t *testing.T) {
t.Run("remove query from new collector version", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -843,7 +843,7 @@ func TestClientSync(t *testing.T) {
})
t.Run("remove query and update collector version", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -881,7 +881,7 @@ func TestClientSync(t *testing.T) {
t.Run("add existing query", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -911,7 +911,7 @@ func TestClientSync(t *testing.T) {
t.Run("add super query", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -940,7 +940,7 @@ func TestClientSync(t *testing.T) {
})
t.Run("add super query with result", func(t *testing.T) {
t.Parallel()
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -1102,7 +1102,7 @@ func createDocumentWithCollectorAndResults(t testing.TB, queries *repository.Que
}
func BenchmarkIsClientSynced(b *testing.B) {
ctx := context.Background()
ctx := b.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(b, cfg)
@@ -1121,7 +1121,7 @@ func BenchmarkIsClientSynced(b *testing.B) {
}
func BenchmarkGetDocumentExternal(b *testing.B) {
ctx := context.Background()
ctx := b.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(b, cfg)
+3 -4
View File
@@ -1,7 +1,6 @@
package repository_test
import (
"context"
"testing"
"time"
@@ -20,7 +19,7 @@ func TestTextExtraction(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -127,7 +126,7 @@ func TestTextTextractPart(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)
@@ -256,7 +255,7 @@ func TestTextOutPart(t *testing.T) {
if testing.Short() {
t.SkipNow()
}
ctx := context.Background()
ctx := t.Context()
cfg := &serviceconfig.BaseConfig{}
test.CreateDB(t, cfg)