Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add mirror gateway definitions and Implementations #2262

Merged
merged 117 commits into from
Jan 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
117 commits
Select commit Hold shift + click to select a range
0fc1949
add mirror definition and update proto dependencies
hlts2 Feb 9, 2023
e0472c2
Add mirror gateway component (#1949)
hlts2 Apr 25, 2023
b0aef58
Rename ip to host of proto payload field for mirror gateway (#2031)
hlts2 May 18, 2023
c3f987a
make proto/add & make format
hlts2 Jun 16, 2023
6347736
fix docker build for mirror
hlts2 Jun 19, 2023
2c0d146
Revert "fix docker build for mirror"
hlts2 Jun 19, 2023
e905008
fix docker build error for mirror gateway
hlts2 Jun 19, 2023
48ad760
Add Custom Resource for mirror target (#2023)
hlts2 Jul 4, 2023
1f24460
fix mirror image tag
hlts2 Jul 4, 2023
8bbe931
Add mirror gateway document (#2105)
hlts2 Jul 25, 2023
9d40824
merge ingress configuration for lb and filter
hlts2 Aug 15, 2023
7e4c2c7
fix duplicate definition error
hlts2 Aug 15, 2023
bd35400
make proto/all & make schema update & make format
hlts2 Aug 15, 2023
9fd7fa2
fix test execution error for mirror handler
hlts2 Aug 15, 2023
91ea275
make proto/all format and update schema and fails build error
hlts2 Sep 21, 2023
c26ac88
use resuable workflow to build mirror image
hlts2 Sep 21, 2023
8a172d9
use internal sync package and refactor
hlts2 Sep 21, 2023
65af965
fix error handling
hlts2 Sep 21, 2023
19558ab
add network policy settings and update deploy command
hlts2 Sep 21, 2023
3924e8f
add default setting logic
hlts2 Sep 21, 2023
8fabca9
add new fileld to crd schema and update crd
hlts2 Sep 25, 2023
00b9e01
fix make command to deploy vald with mirror components
hlts2 Sep 25, 2023
6eaba03
add e2e test for mirror
hlts2 Sep 26, 2023
4fea273
add debug command to get pod status
hlts2 Sep 26, 2023
b32c705
bugfix command
hlts2 Sep 26, 2023
37923f3
disable sidecar e2e and add mirror e2e command
hlts2 Sep 26, 2023
b410364
update cluster role
hlts2 Sep 26, 2023
7ece16f
add cluster-info dump command
hlts2 Sep 26, 2023
2ed49ca
Revert "add cluster-info dump command"
hlts2 Sep 26, 2023
454eaf3
debug: add logs command
hlts2 Sep 27, 2023
388f8ef
Revert "debug: add logs command"
hlts2 Sep 27, 2023
91deb87
add RemoveByTimestamp for mirror
hlts2 Sep 27, 2023
0b96823
fix: update sleep time for operator deploy
hlts2 Sep 28, 2023
86f4211
update wait time for vmt
hlts2 Sep 28, 2023
5ea8d4f
Returns all connection information in the registration rpc (#2199)
hlts2 Oct 2, 2023
192ae24
Add handler logic to continue processing (#2204)
hlts2 Oct 11, 2023
9661fc3
Update Mirror Gateway document (#2207)
hlts2 Nov 8, 2023
746e01c
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Nov 16, 2023
08c44fb
feat: schema and protobuf update
hlts2 Nov 16, 2023
7d7a690
fix: reviewdog warning and add comment
hlts2 Nov 16, 2023
c9007ed
style: format code with Gofumpt and Prettier
deepsource-autofix[bot] Nov 16, 2023
78734df
fix: reviewdog warning
hlts2 Nov 16, 2023
88dad2e
fix: reviewdog warning
hlts2 Nov 16, 2023
ee0f48a
fix: move mirror client mock definition to internal package
hlts2 Nov 16, 2023
374dc57
feat: add new handler base logic
hlts2 Nov 21, 2023
9e87530
fix: refactor stream list object rpc
hlts2 Nov 21, 2023
e62a657
fix: divide logic to other function
hlts2 Nov 22, 2023
6c6b744
style: format code with Gofumpt and Prettier
deepsource-autofix[bot] Nov 22, 2023
c825ad8
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Nov 29, 2023
104c22b
make proto/all format
hlts2 Nov 29, 2023
a36f1a8
fix: return grpc error
hlts2 Nov 29, 2023
1512b78
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 4, 2023
23b1f72
fix: make proto/all format
hlts2 Dec 4, 2023
68a8072
feat: add mirror service test
hlts2 Dec 4, 2023
d6580ec
fix: add mock definition code
hlts2 Dec 4, 2023
2b1cac5
style: format code with Gofumpt and Prettier
deepsource-autofix[bot] Dec 4, 2023
19ee272
fix: use internal method
hlts2 Dec 5, 2023
f5afe4c
fix: delete Exist method because it is not needed
hlts2 Dec 5, 2023
6c2789c
fix: use address cache insted of connectedAddr method
hlts2 Dec 5, 2023
70e2e17
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 5, 2023
b032917
fix: make format
hlts2 Dec 5, 2023
f34b142
feat: improve connection management and add new test
hlts2 Dec 5, 2023
7c502f0
fix: make format
hlts2 Dec 5, 2023
1cb6662
fix: lint warnning
hlts2 Dec 5, 2023
ffa4eb6
fix: refactor error handling
hlts2 Dec 6, 2023
21b781f
feat: add test for syncronizee based on address and small refactor
hlts2 Dec 6, 2023
1aef5da
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 6, 2023
08a6bc1
fix: improve error handling and example image tag
hlts2 Dec 7, 2023
5bee190
fix: schema update and format
hlts2 Dec 7, 2023
8192f11
Update charts/vald/values/multi-vald/dev-vald-with-mirror.yaml
hlts2 Dec 7, 2023
4c11568
fix: lint warnning
hlts2 Dec 7, 2023
6e786f2
style: format code with Gofumpt and Prettier
deepsource-autofix[bot] Dec 7, 2023
af35bef
fix: reviewdog warning and deepsource warning
hlts2 Dec 7, 2023
1b4eb27
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 7, 2023
42b1175
feat: use new command to docker build
hlts2 Dec 7, 2023
4dede1c
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 7, 2023
08f79da
fix: make format
hlts2 Dec 7, 2023
2e99bc7
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 7, 2023
b57c5f6
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 7, 2023
8de1bac
fix: update schema and format
hlts2 Dec 7, 2023
2de16f6
fix: deleted unnecessary RPCs due to failure of previous rebasing
hlts2 Dec 7, 2023
c5e4ef3
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 7, 2023
76309fd
fix: proto and execute make proto/all format
hlts2 Dec 7, 2023
b9ae28c
fix: revert unnecessary changes
hlts2 Dec 7, 2023
389673e
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 11, 2023
7c4fa6b
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 12, 2023
3921932
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 12, 2023
e06ef8f
fix: make proto/all format
hlts2 Dec 12, 2023
628008b
fix: deepsource warning
hlts2 Dec 14, 2023
8a6ac6e
fix: deleted unnecessary code
hlts2 Dec 14, 2023
385cee5
fix: deepsource warning
hlts2 Dec 14, 2023
41f54f8
fix: deepsource warning
hlts2 Dec 14, 2023
c266728
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 21, 2023
515441b
fix: make proto/all format
hlts2 Dec 21, 2023
6232600
fix: apply feedback for comment
hlts2 Dec 21, 2023
596d4cb
feat: add internal hash package to generate hash value
hlts2 Dec 26, 2023
6cbf407
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Dec 26, 2023
2491ec9
fix: ignore deepsource warning
hlts2 Dec 26, 2023
0679362
feat: add function and method comment
hlts2 Dec 26, 2023
d69dddb
Update pkg/gateway/mirror/handler/grpc/handler.go
hlts2 Dec 26, 2023
7eb59bd
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 9, 2024
e7a6ab9
fix: schema and proto update and format
hlts2 Jan 9, 2024
8d3143c
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 9, 2024
f55617c
feat: add ingress rule for lb and filter
hlts2 Jan 9, 2024
e7cba07
fix: deleted wildcard path
hlts2 Jan 9, 2024
052b112
fix: ingress unified into one manifest
hlts2 Jan 10, 2024
4812983
fix: make format
hlts2 Jan 10, 2024
48f32b6
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 10, 2024
41d7740
fix: lb ingress port settings and small refactor
hlts2 Jan 10, 2024
c4b1f7a
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 10, 2024
0a5d335
feat: add cluster wide ingress resource name
hlts2 Jan 10, 2024
21d8cac
fix: add deploy ingress resource using make command
hlts2 Jan 10, 2024
350a2a5
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 11, 2024
1027b47
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 11, 2024
c5e43ca
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 11, 2024
6ba9f57
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 16, 2024
dd370c2
Merge branch 'main' into feature/mirror-gateway-definition
hlts2 Jan 19, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/actions/detect-docker-image-tags/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ runs:
["vdaas/vald-agent-sidecar"]="agent.sidecar.image.tag"
["vdaas/vald-discoverer-k8s"]="discoverer.image.tag"
["vdaas/vald-lb-gateway"]="gateway.lb.image.tag"
["vdaas/vald-mirror-gateway"]="gateway.mirror.image.tag"
["vdaas/vald-manager-index"]="manager.index.image.tag"
["vdaas/vald-index-creation"]="manager.index.creator.image.tag"
["vdaas/vald-index-save"]="manager.index.saver.image.tag"
Expand Down
4 changes: 2 additions & 2 deletions .github/actions/e2e-deploy-vald-helm-operator/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ runs:
${HELM_EXTRA_OPTIONS} \
charts/vald-helm-operator/.

sleep 3
sleep 6
env:
DEFAULT_IMAGE_TAG: ${{ inputs.default_image_tag }}
HELM_EXTRA_OPTIONS: ${{ inputs.helm_extra_options }}
Expand All @@ -97,7 +97,7 @@ runs:
run: |
kubectl apply -f ${VALDRELEASE}

sleep 3
sleep 6

kubectl wait --for=condition=ready pod -l ${WAIT_FOR_SELECTOR} --timeout=${WAIT_FOR_TIMEOUT}

Expand Down
11 changes: 11 additions & 0 deletions .github/actions/e2e-deploy-vald/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ inputs:
description: "Path to the values.yaml that passed to Helm command."
required: false
default: "false"
namespace:
description: "Namespace to deploy."
required: false
wait_for_selector:
description: "Label selector used for specifying a pod waited for"
required: false
Expand Down Expand Up @@ -65,6 +68,14 @@ runs:
run: |
cat ${{ inputs.values }}

- name: Change namespace
if: ${{ inputs.namespace != '' }}
shell: bash
run: |
kubectl create ns ${NAMESPACE} ; kubectl config set-context --current --namespace=${NAMESPACE}
env:
NAMESPACE: ${{ inputs.namespace }}

- name: Deploy vald from remote charts
shell: bash
id: deploy_vald_remote
Expand Down
24 changes: 24 additions & 0 deletions .github/helm/values/vald-mirror-target.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#
# Copyright (C) 2019-2024 vdaas.org vald team <vald@vdaas.org>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# You may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
apiVersion: vald.vdaas.org/v1
kind: ValdMirrorTarget
metadata:
name: mirror-target-02
spec:
colocation: dc1
target:
host: vald-mirror-gateway.vald-02.svc.cluster.local
port: 8081
81 changes: 81 additions & 0 deletions .github/helm/values/values-mirror-01.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
#
# Copyright (C) 2019-2024 vdaas.org vald team <vald@vdaas.org>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# You may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

defaults:
logging:
level: info
networkPolicy:
enabled: false

gateway:
mirror:
enabled: true
clusterRoleBinding:
name: vald-mirror-01
serviceAccount:
name: vald-mirror-01
lb:
enabled: true
minReplicas: 1
hpa:
enabled: false
resources:
requests:
cpu: 100m
memory: 50Mi
gateway_config:
index_replica: 3

agent:
minReplicas: 3
maxReplicas: 10
podManagementPolicy: Parallel
hpa:
enabled: false
resources:
requests:
cpu: 100m
memory: 50Mi
ngt:
auto_index_duration_limit: 2m
auto_index_check_duration: 30s
auto_index_length: 1000
dimension: 784

discoverer:
minReplicas: 1
hpa:
enabled: false
resources:
requests:
cpu: 100m
memory: 50Mi
clusterRoleBinding:
name: vald-01
serviceAccount:
name: vald-01

manager:
index:
replicas: 1
resources:
requests:
cpu: 100m
memory: 30Mi
indexer:
auto_index_duration_limit: 2m
auto_index_check_duration: 30s
auto_index_length: 1000
85 changes: 85 additions & 0 deletions .github/helm/values/values-mirror-02.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
#
# Copyright (C) 2019-2024 vdaas.org vald team <vald@vdaas.org>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# You may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

defaults:
logging:
level: info
networkPolicy:
enabled: false

gateway:
mirror:
enabled: true
clusterRole:
enabled: false
clusterRoleBinding:
name: vald-mirror-02
serviceAccount:
name: vald-mirror-02
lb:
enabled: true
minReplicas: 1
hpa:
enabled: false
resources:
requests:
cpu: 100m
memory: 50Mi
gateway_config:
index_replica: 3

agent:
minReplicas: 3
maxReplicas: 10
podManagementPolicy: Parallel
hpa:
enabled: false
resources:
requests:
cpu: 100m
memory: 50Mi
ngt:
auto_index_duration_limit: 2m
auto_index_check_duration: 30s
auto_index_length: 1000
dimension: 784

discoverer:
minReplicas: 1
hpa:
enabled: false
resources:
requests:
cpu: 100m
memory: 50Mi
clusterRole:
enabled: false
clusterRoleBinding:
name: vald-02
serviceAccount:
name: vald-02

manager:
index:
replicas: 1
resources:
requests:
cpu: 100m
memory: 30Mi
indexer:
auto_index_duration_limit: 2m
auto_index_check_duration: 30s
auto_index_length: 1000
82 changes: 82 additions & 0 deletions .github/workflows/dockers-gateway-mirror-image.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
#
# Copyright (C) 2019-2024 vdaas.org vald team <vald@vdaas.org>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# You may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
name: "Build docker image: gateway-mirror"
on:
push:
branches:
- main
tags:
- "*.*.*"
- "v*.*.*"
- "*.*.*-*"
- "v*.*.*-*"
paths:
- ".github/actions/docker-build/actions.yaml"
- ".github/workflows/dockers-gateway-mirror-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
- "!internal/**/*_test.go"
- "!internal/**/*_mock.go"
- "!internal/db/**"
- "!internal/k8s/**"
- "apis/grpc/**"
- "pkg/gateway/mirror/**"
- "cmd/gateway/mirror/**"
- "pkg/gateway/internal/**"
- "dockers/gateway/mirror/Dockerfile"
- "versions/GO_VERSION"
pull_request:
paths:
- ".github/actions/docker-build/actions.yaml"
- ".github/workflows/dockers-gateway-mirror-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
- "!internal/**/*_test.go"
- "!internal/**/*_mock.go"
- "!internal/db/**"
- "!internal/k8s/**"
- "apis/grpc/**"
- "pkg/gateway/mirror/**"
- "cmd/gateway/mirror/**"
- "pkg/gateway/internal/**"
- "dockers/gateway/mirror/Dockerfile"
- "versions/GO_VERSION"
pull_request_target:
paths:
- ".github/actions/docker-build/actions.yaml"
- ".github/workflows/dockers-gateway-mirror-image.yml"
- "go.mod"
- "go.sum"
- "internal/**"
- "!internal/**/*_test.go"
- "!internal/**/*_mock.go"
- "!internal/db/**"
- "!internal/k8s/**"
- "apis/grpc/**"
- "pkg/gateway/mirror/**"
- "cmd/gateway/nirror/**"
- "pkg/gateway/internal/**"
- "dockers/gateway/mirror/Dockerfile"
- "versions/GO_VERSION"

jobs:
build:
uses: ./.github/workflows/_docker-image.yaml
with:
target: gateway-mirror
secrets: inherit
Loading
Loading