Skip to content

Commit

Permalink
To disable index check in Read Replica
Browse files Browse the repository at this point in the history
  • Loading branch information
kmrmt committed Dec 25, 2024
1 parent 9ab90c2 commit 75d1062
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
1 change: 1 addition & 0 deletions .github/actions/e2e-deploy-vald-readreplica/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ runs:
run: |
make k8s/vald-readreplica/deploy HELM_VALUES=${VALUES} HELM_EXTRA_OPTIONS="${HELM_EXTRA_OPTIONS}"
stern vald-discoverer &
stern vald-lb-gateway &
stern vald-agent-readreplica &
sleep 3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/_detect-ci-container.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
- name: Get Docker image tag from detection result
id: get_tag_name
run: |
TAG=$(echo "$TAGS" | awk '{print $1}' | awk -F '=' '{print $2}')
TAG=$(echo "$TAGS" | awk '{print $1}' | awk -F '=' '{print $2}' | sed -e 's/"//g')
echo "TAG=${TAG}"
echo "TAG=${TAG}" >> $GITHUB_OUTPUT
env:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -335,12 +335,12 @@ jobs:
E2E_UPDATE_COUNT=100 \
E2E_UPSERT_COUNT=100 \
E2E_REMOVE_COUNT=100 \
E2E_WAIT_FOR_CREATE_INDEX_DURATION=3m \
E2E_WAIT_FOR_CREATE_INDEX_DURATION=10m \
E2E_TARGET_POD_NAME=${POD_NAME} \
E2E_TARGET_NAMESPACE=default \
e2e/readreplica
env:
POD_NAME: ${{ steps.deploy_vald.outputs.POD_NAME }}
POD_NAME: ${{ steps.deploy_vald_readreplica.outputs.POD_NAME }}
e2e-stream-crud-with-mirror:
name: "E2E test (Stream CRUD) with mirror"
needs: [detect-ci-container]
Expand Down
14 changes: 5 additions & 9 deletions Makefile.d/kind.mk
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,15 @@ SNAPSHOTTER_VERSION=v8.2.0
## install KinD
kind/install: $(BINDIR)/kind

$(BINDIR)/kind:
$(BINDIR)/kind: $(BINDIR)/docker
mkdir -p $(BINDIR)
$(eval DARCH := $(subst aarch64,arm64,$(ARCH)))
curl -fsSL https://github.com/kubernetes-sigs/kind/releases/download/v$(KIND_VERSION)/kind-$(OS)-$(subst x86_64,amd64,$(shell echo $(DARCH) | tr '[:upper:]' '[:lower:]')) -o $(BINDIR)/kind
chmod a+x $(BINDIR)/kind

.PHONY: kind/start
## start kind (kubernetes in docker) cluster
kind/start: \
$(BINDIR)/docker
kind/start:
kind create cluster --name $(NAME)
@make kind/login

Expand All @@ -40,8 +39,7 @@ kind/login:

.PHONY: kind/stop
## stop kind (kubernetes in docker) cluster
kind/stop: \
$(BINDIR)/docker
kind/stop:
kind delete cluster --name $(NAME)

.PHONY: kind/restart
Expand Down Expand Up @@ -76,8 +74,7 @@ kind/cluster/restart: \

.PHONY: kind/vs/start
## start kind (kubernetes in docker) cluster with volume snapshot
kind/vs/start: \
$(BINDIR)/docker
kind/vs/start:
sed -e 's/apiServerAddress: "127.0.0.1"/apiServerAddress: "$(shell grep host.docker.internal /etc/hosts | cut -f1)"/' $(ROOTDIR)/k8s/debug/kind/e2e.yaml | kind create cluster --name $(NAME)-vs --config -
@make kind/vs/login

Expand All @@ -101,8 +98,7 @@ kind/vs/start: \

.PHONY: kind/vs/stop
## stop kind (kubernetes in docker) cluster with volume snapshot
kind/vs/stop: \
$(BINDIR)/docker
kind/vs/stop:
kind delete cluster --name $(NAME)-vs

.PHONY: kind/vs/login
Expand Down
3 changes: 3 additions & 0 deletions pkg/agent/core/ngt/service/ngt.go
Original file line number Diff line number Diff line change
Expand Up @@ -887,6 +887,9 @@ func (n *ngt) Start(ctx context.Context) <-chan error {
if n.dcd {
return nil
}
if n.isReadReplica {
return nil
}

Check warning on line 892 in pkg/agent/core/ngt/service/ngt.go

View check run for this annotation

Codecov / codecov/patch

pkg/agent/core/ngt/service/ngt.go#L891-L892

Added lines #L891 - L892 were not covered by tests
n.removeInvalidIndex(ctx)
ech := make(chan error, 2)
n.eg.Go(safety.RecoverFunc(func() (err error) {
Expand Down

0 comments on commit 75d1062

Please sign in to comment.