Skip to content

Commit

Permalink
Add UpdateTimestamp API
Browse files Browse the repository at this point in the history
fix
style: format code with Gofumpt and Prettier

Signed-off-by: kpango <[email protected]>
  • Loading branch information
kpango committed Sep 2, 2024
1 parent b17cc73 commit 07fe2ed
Show file tree
Hide file tree
Showing 159 changed files with 6,832 additions and 3,077 deletions.
2,698 changes: 2,608 additions & 90 deletions .cspell.json

Large diffs are not rendered by default.

9 changes: 7 additions & 2 deletions .gitfiles
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ Makefile
Makefile.d/actions.mk
Makefile.d/bench.mk
Makefile.d/build.mk
Makefile.d/client.mk
Makefile.d/dependencies.mk
Makefile.d/docker.mk
Makefile.d/e2e.mk
Expand Down Expand Up @@ -511,6 +510,7 @@ cmd/tools/cli/loadtest/main_test.go
cmd/tools/cli/loadtest/sample.yaml
cmd/tools/cli/vdctl/main.go
cmd/tools/cli/vdctl/main_test.go
codecov.yml
design/Vald Architecture Assets.drawio
design/Vald Architecture Dataflow.drawio
design/Vald Architecture Overview.drawio
Expand Down Expand Up @@ -698,6 +698,7 @@ hack/benchmark/internal/starter/gateway/vald/vald_test.go
hack/benchmark/internal/starter/starter.go
hack/benchmark/metrics/metrics.go
hack/benchmark/src/singleflight/singleflight_bench_test.go
hack/cspell/main.go
hack/docker/gen/main.go
hack/git/hooks/pre-commit
hack/go.mod.default
Expand Down Expand Up @@ -1904,6 +1905,11 @@ rust/libs/ngt-rs/src/input.h
rust/libs/ngt-rs/src/lib.rs
rust/libs/ngt/Cargo.toml
rust/libs/ngt/src/lib.rs
rust/libs/observability/Cargo.toml
rust/libs/observability/src/config.rs
rust/libs/observability/src/lib.rs
rust/libs/observability/src/macros.rs
rust/libs/observability/src/observability.rs
rust/libs/proto/Cargo.toml
rust/libs/proto/src/core.v1.tonic.rs
rust/libs/proto/src/discoverer.v1.tonic.rs
Expand Down Expand Up @@ -1965,7 +1971,6 @@ versions/PROTOBUF_VERSION
versions/REVIEWDOG_VERSION
versions/RUST_VERSION
versions/TELEPRESENCE_VERSION
versions/VALDCLI_VERSION
versions/VALD_VERSION
versions/YQ_VERSION
versions/ZLIB_VERSION
Expand Down
6 changes: 3 additions & 3 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ assignees: ""
- Vald Version: v1.7.13
- Go Version: v1.23.0
- Rust Version: v1.80.0
- Docker Version: v27.1.1
- Kubernetes Version: v1.30.3
- Helm Version: v3.15.3
- Docker Version: v27.2.0
- Kubernetes Version: v1.31.0
- Helm Version: v3.15.4
- NGT Version: v2.2.4
- Faiss Version: v1.8.0
6 changes: 3 additions & 3 deletions .github/ISSUE_TEMPLATE/security_issue_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ assignees: ""
- Vald Version: v1.7.13
- Go Version: v1.23.0
- Rust Version: v1.80.0
- Docker Version: v27.1.1
- Kubernetes Version: v1.30.3
- Helm Version: v3.15.3
- Docker Version: v27.2.0
- Kubernetes Version: v1.31.0
- Helm Version: v3.15.4
- NGT Version: v2.2.4
- Faiss Version: v1.8.0
6 changes: 3 additions & 3 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
- Vald Version: v1.7.13
- Go Version: v1.23.0
- Rust Version: v1.80.0
- Docker Version: v27.1.1
- Kubernetes Version: v1.30.3
- Helm Version: v3.15.3
- Docker Version: v27.2.0
- Kubernetes Version: v1.31.0
- Helm Version: v3.15.4
- NGT Version: v2.2.4
- Faiss Version: v1.8.0

Expand Down
2 changes: 1 addition & 1 deletion .github/helm/values/values-correction.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

defaults:
logging:
level: info
level: debug
networkPolicy:
enabled: true
gateway:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/dockers-benchmark-job-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ on:
paths:
- ".github/actions/docker-build/action.yaml"
- ".github/workflows/_docker-image.yaml"
- ".github/workflows/dockers-benchmak-job-image.yml"
- ".github/workflows/dockers-benchmark-job-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
Expand All @@ -44,7 +44,7 @@ on:
paths:
- ".github/actions/docker-build/action.yaml"
- ".github/workflows/_docker-image.yaml"
- ".github/workflows/dockers-benchmak-job-image.yml"
- ".github/workflows/dockers-benchmark-job-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/dockers-benchmark-operator-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ on:
paths:
- ".github/actions/docker-build/action.yaml"
- ".github/workflows/_docker-image.yaml"
- ".github/workflows/dockers-benchmak-operator-image.yml"
- ".github/workflows/dockers-benchmark-operator-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
Expand All @@ -44,7 +44,7 @@ on:
paths:
- ".github/actions/docker-build/action.yaml"
- ".github/workflows/_docker-image.yaml"
- ".github/workflows/dockers-benchmak-operator-image.yml"
- ".github/workflows/dockers-benchmark-operator-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
Expand Down
13 changes: 3 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ PROTOBUF_VERSION := $(eval PROTOBUF_VERSION := $(shell cat versions/PRO
REVIEWDOG_VERSION := $(eval REVIEWDOG_VERSION := $(shell cat versions/REVIEWDOG_VERSION))$(REVIEWDOG_VERSION)
RUST_VERSION := $(eval RUST_VERSION := $(shell cat versions/RUST_VERSION))$(RUST_VERSION)
TELEPRESENCE_VERSION := $(eval TELEPRESENCE_VERSION := $(shell cat versions/TELEPRESENCE_VERSION))$(TELEPRESENCE_VERSION)
VALDCLI_VERSION := $(eval VALDCLI_VERSION := $(shell cat versions/VALDCLI_VERSION))$(VALDCLI_VERSION)
YQ_VERSION := $(eval YQ_VERSION := $(shell cat versions/YQ_VERSION))$(YQ_VERSION)
ZLIB_VERSION := $(eval ZLIB_VERSION := $(shell cat versions/ZLIB_VERSION))$(ZLIB_VERSION)

Expand Down Expand Up @@ -455,7 +454,6 @@ init: \
tools/install: \
helm/install \
kind/install \
valdcli/install \
telepresence/install \
textlint/install

Expand Down Expand Up @@ -620,10 +618,6 @@ version/helm:
version/yq:
@echo $(YQ_VERSION)

.PHONY: version/valdcli
version/valdcli:
@echo $(VALDCLI_VERSION)

.PHONY: version/telepresence
version/telepresence:
@echo $(TELEPRESENCE_VERSION)
Expand Down Expand Up @@ -737,14 +731,14 @@ files/textlint: \
## run cspell for document
docs/cspell:\
cspell/install
cspell-cli $(ROOTDIR)/docs/**/*.md --show-suggestions $(CSPELL_EXTRA_OPTIONS)
cspell $(ROOTDIR)/docs/**/*.md --show-suggestions $(CSPELL_EXTRA_OPTIONS)

.PHONY: files/cspell
## run cspell for document
files/cspell: \
files \
cspell/install
cspell-cli $(ROOTDIR)/.gitfiles --show-suggestions $(CSPELL_EXTRA_OPTIONS)
cspell $(ROOTDIR)/.gitfiles --show-suggestions $(CSPELL_EXTRA_OPTIONS)

.PHONY: changelog/update
## update changelog
Expand All @@ -766,7 +760,6 @@ changelog/next/print:
include Makefile.d/actions.mk
include Makefile.d/bench.mk
include Makefile.d/build.mk
include Makefile.d/client.mk
include Makefile.d/dependencies.mk
include Makefile.d/docker.mk
include Makefile.d/e2e.mk
Expand All @@ -775,7 +768,7 @@ include Makefile.d/helm.mk
include Makefile.d/k3d.mk
include Makefile.d/k8s.mk
include Makefile.d/kind.mk
include Makefile.d/minikube.mk
include Makefile.d/proto.mk
include Makefile.d/test.mk
include Makefile.d/tools.mk
include Makefile.d/minikube.mk
45 changes: 0 additions & 45 deletions Makefile.d/client.mk

This file was deleted.

6 changes: 0 additions & 6 deletions Makefile.d/dependencies.mk
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ update/libs: \
update/rust \
update/telepresence \
update/vald \
update/valdcli \
update/yq \
update/zlib

Expand Down Expand Up @@ -227,11 +226,6 @@ update/hdf5:
update/vald:
curl -fsSL https://api.github.com/repos/$(REPO)/releases/latest | grep -Po '"tag_name": "\K.*?(?=")' > $(ROOTDIR)/versions/VALD_VERSION

.PHONY: update/valdcli
## update vald client library made by clojure self version
update/valdcli:
curl -fsSL https://api.github.com/repos/$(REPO)-client-clj/releases/latest | grep -Po '"tag_name": "\K.*?(?=")' > $(ROOTDIR)/versions/VALDCLI_VERSION

.PHONY: update/template
## update PULL_REQUEST_TEMPLATE and ISSUE_TEMPLATE
update/template:
Expand Down
27 changes: 27 additions & 0 deletions Makefile.d/docker.mk
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,33 @@ docker/build: \
docker/build/operator/helm \
docker/build/readreplica-rotate

docker/xpanes/build:
@xpanes -s -c "make -f $(ROOTDIR)/Makefile {}" \
docker/build/agent \
docker/build/agent-faiss \
docker/build/agent-ngt \
docker/build/agent-sidecar \
docker/build/benchmark-job \
docker/build/benchmark-operator \
docker/build/binfmt \
docker/build/buildbase \
docker/build/buildkit \
docker/build/buildkit-syft-scanner \
docker/build/ci-container \
docker/build/dev-container \
docker/build/discoverer-k8s \
docker/build/gateway-filter \
docker/build/gateway-lb \
docker/build/gateway-mirror \
docker/build/index-correction \
docker/build/index-creation \
docker/build/index-operator \
docker/build/index-save \
docker/build/loadtest \
docker/build/manager-index \
docker/build/operator/helm \
docker/build/readreplica-rotate

.PHONY: docker/name/org
docker/name/org:
@echo "$(ORG)"
Expand Down
29 changes: 28 additions & 1 deletion Makefile.d/tools.mk
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,34 @@ textlint/ci/install:
cspell/install: $(NPM_GLOBAL_PREFIX)/bin/cspell

$(NPM_GLOBAL_PREFIX)/bin/cspell:
npm install -g cspell@latest
npm install -g cspell@latest \
@cspell/dict-cpp \
@cspell/dict-docker \
@cspell/dict-en_us \
@cspell/dict-fullstack \
@cspell/dict-git \
@cspell/dict-golang \
@cspell/dict-k8s \
@cspell/dict-makefile \
@cspell/dict-markdown \
@cspell/dict-npm \
@cspell/dict-public-licenses \
@cspell/dict-rust \
@cspell/dict-shell
cspell link add @cspell/dict-cpp
cspell link add @cspell/dict-docker
cspell link add @cspell/dict-en_us
cspell link add @cspell/dict-fullstack
cspell link add @cspell/dict-git
cspell link add @cspell/dict-golang
cspell link add @cspell/dict-k8s
cspell link add @cspell/dict-makefile
cspell link add @cspell/dict-markdown
cspell link add @cspell/dict-npm
cspell link add @cspell/dict-public-licenses
cspell link add @cspell/dict-rust
cspell link add @cspell/dict-shell


.PHONY: buf/install
buf/install: $(BINDIR)/buf
Expand Down
24 changes: 19 additions & 5 deletions apis/docs/v1/docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
- [Update.MultiRequest](#payload-v1-Update-MultiRequest)
- [Update.ObjectRequest](#payload-v1-Update-ObjectRequest)
- [Update.Request](#payload-v1-Update-Request)
- [Update.TimestampRequest](#payload-v1-Update-TimestampRequest)
- [Upsert](#payload-v1-Upsert)
- [Upsert.Config](#payload-v1-Upsert-Config)
- [Upsert.MultiObjectRequest](#payload-v1-Upsert-MultiObjectRequest)
Expand Down Expand Up @@ -1119,6 +1120,18 @@ Represent the update request.
| vector | [Object.Vector](#payload-v1-Object-Vector) | | The vector to be updated. |
| config | [Update.Config](#payload-v1-Update-Config) | | The configuration of the update request. |

<a name="payload-v1-Update-TimestampRequest"></a>

### Update.TimestampRequest

Represent a vector meta data.

| Field | Type | Label | Description |
| --------- | ----------------- | ----- | ------------------------------------------------- |
| id | [string](#string) | | The vector ID. |
| timestamp | [int64](#int64) | | timestamp represents when this vector inserted. |
| force | [bool](#bool) | | force represents forcefully update the timestamp. |

<a name="payload-v1-Upsert"></a>

### Upsert
Expand Down Expand Up @@ -1731,11 +1744,12 @@ Search service provides ways to search indexed vectors.

Update service provides ways to update indexed vectors.

| Method Name | Request Type | Response Type | Description |
| ------------ | ------------------------------------------------------------------ | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
| Update | [.payload.v1.Update.Request](#payload-v1-Update-Request) | [.payload.v1.Object.Location](#payload-v1-Object-Location) | A method to update an indexed vector. |
| StreamUpdate | [.payload.v1.Update.Request](#payload-v1-Update-Request) stream | [.payload.v1.Object.StreamLocation](#payload-v1-Object-StreamLocation) stream | A method to update multiple indexed vectors by bidirectional streaming. |
| MultiUpdate | [.payload.v1.Update.MultiRequest](#payload-v1-Update-MultiRequest) | [.payload.v1.Object.Locations](#payload-v1-Object-Locations) | A method to update multiple indexed vectors in a single request. |
| Method Name | Request Type | Response Type | Description |
| --------------- | -------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
| Update | [.payload.v1.Update.Request](#payload-v1-Update-Request) | [.payload.v1.Object.Location](#payload-v1-Object-Location) | A method to update an indexed vector. |
| StreamUpdate | [.payload.v1.Update.Request](#payload-v1-Update-Request) stream | [.payload.v1.Object.StreamLocation](#payload-v1-Object-StreamLocation) stream | A method to update multiple indexed vectors by bidirectional streaming. |
| MultiUpdate | [.payload.v1.Update.MultiRequest](#payload-v1-Update-MultiRequest) | [.payload.v1.Object.Locations](#payload-v1-Object-Locations) | A method to update multiple indexed vectors in a single request. |
| UpdateTimestamp | [.payload.v1.Update.TimestampRequest](#payload-v1-Update-TimestampRequest) | [.payload.v1.Object.Location](#payload-v1-Object-Location) | A method to update timestamp an indexed vector. |

<a name="v1_vald_upsert-proto"></a>

Expand Down
2 changes: 1 addition & 1 deletion apis/grpc/v1/agent/sidecar/sidecar_vtproto.pb.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const _ = grpc.SupportPackageIsVersion7
// SidecarClient is the client API for Sidecar service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type SidecarClient interface{}
type SidecarClient any

type sidecarClient struct {
cc grpc.ClientConnInterface
Expand Down
Loading

0 comments on commit 07fe2ed

Please sign in to comment.