refact: to use go-dbw CreateItems, DeleteItems (#4974)

* refact: to use go-dbw CreateItems, DeleteItems

Latest version of go-dbw updated the signature of
CreateItems(...) and DeleteItems(...) on a happy
note this latest version of go-dbw actually does
batch inserts and updates for this functions.

* all: regenerate protos with new protoc-gen-go version
This commit is contained in:
Jim authored and GitHub committed 2024-08-01 11:18:53 -04:00
1 parent b24f6dcee8
commit 28b465e4b8
167 files changed
+2254 -2248

No files matched your search

+2 -2
View File
@@ -75,7 +75,7 @@ func (w *changeSafeDbwWriter) Create(ctx context.Context, i any, opt ...dbw.Opti
return dbw.New(w.db.underlying.wrapped.Load()).Create(ctx, i, opt...)
}
func (w *changeSafeDbwWriter) CreateItems(ctx context.Context, createItems []any, opt ...dbw.Option) error {
func (w *changeSafeDbwWriter) CreateItems(ctx context.Context, createItems any, opt ...dbw.Option) error {
return dbw.New(w.db.underlying.wrapped.Load()).CreateItems(ctx, createItems, opt...)
}
@@ -83,7 +83,7 @@ func (w *changeSafeDbwWriter) Delete(ctx context.Context, i any, opt ...dbw.Opti
return dbw.New(w.db.underlying.wrapped.Load()).Delete(ctx, i, opt...)
}
func (w *changeSafeDbwWriter) DeleteItems(ctx context.Context, deleteItems []any, opt ...dbw.Option) (int, error) {
func (w *changeSafeDbwWriter) DeleteItems(ctx context.Context, deleteItems any, opt ...dbw.Option) (int, error) {
return dbw.New(w.db.underlying.wrapped.Load()).DeleteItems(ctx, deleteItems, opt...)
}