Re: [PR] upgrade: etcd-adapter and add e2e test [apisix-ingress-controller]
Revolyssup merged PR #2369: URL: https://github.com/apache/apisix-ingress-controller/pull/2369 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] upgrade: etcd-adapter and add e2e test [apisix-ingress-controller]
Revolyssup commented on code in PR #2369: URL: https://github.com/apache/apisix-ingress-controller/pull/2369#discussion_r1993017733 ## test/e2e/suite-chore/etcd_consistency.go: ## @@ -0,0 +1,87 @@ +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You 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 +// +// http://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. +package chore + +import ( + "fmt" + "net/http" + + "github.com/onsi/ginkgo/v2" + "github.com/stretchr/testify/assert" + + "github.com/apache/apisix-ingress-controller/test/e2e/scaffold" +) + +var _ = ginkgo.Describe("suite-chore: etcd revision", func() { + s := scaffold.NewScaffold(&scaffold.Options{ + EnableEtcdServer: true, + }) + ginkgo.It("etcd revision", func() { + ginkgo.By("apply route", func() { + backendSvc, backendSvcPort := s.DefaultHTTPBackend() + ar := fmt.Sprintf(` +apiVersion: apisix.apache.org/v2 +kind: ApisixRoute +metadata: + name: httpbin-route +spec: + http: + - name: rule1 +match: + hosts: + - httpbin.org + paths: + - /ip +backends: +- serviceName: %s + servicePort: %d +`, backendSvc, backendSvcPort[0]) + assert.Nil(ginkgo.GinkgoT(), s.CreateVersionedApisixResource(ar)) + assert.Nil(ginkgo.GinkgoT(), s.EnsureNumApisixRoutesCreated(1), "checking number of routes") + assert.Nil(ginkgo.GinkgoT(), s.EnsureNumApisixUpstreamsCreated(1), "checking number of upstreams") + Review Comment: done -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] upgrade: etcd-adapter and add e2e test [apisix-ingress-controller]
nic-chen commented on code in PR #2369: URL: https://github.com/apache/apisix-ingress-controller/pull/2369#discussion_r1992972775 ## test/e2e/suite-chore/etcd_consistency.go: ## @@ -0,0 +1,87 @@ +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You 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 +// +// http://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. +package chore + +import ( + "fmt" + "net/http" + + "github.com/onsi/ginkgo/v2" + "github.com/stretchr/testify/assert" + + "github.com/apache/apisix-ingress-controller/test/e2e/scaffold" +) + +var _ = ginkgo.Describe("suite-chore: etcd revision", func() { + s := scaffold.NewScaffold(&scaffold.Options{ + EnableEtcdServer: true, + }) + ginkgo.It("etcd revision", func() { + ginkgo.By("apply route", func() { + backendSvc, backendSvcPort := s.DefaultHTTPBackend() + ar := fmt.Sprintf(` +apiVersion: apisix.apache.org/v2 +kind: ApisixRoute +metadata: + name: httpbin-route +spec: + http: + - name: rule1 +match: + hosts: + - httpbin.org + paths: + - /ip +backends: +- serviceName: %s + servicePort: %d +`, backendSvc, backendSvcPort[0]) + assert.Nil(ginkgo.GinkgoT(), s.CreateVersionedApisixResource(ar)) + assert.Nil(ginkgo.GinkgoT(), s.EnsureNumApisixRoutesCreated(1), "checking number of routes") + assert.Nil(ginkgo.GinkgoT(), s.EnsureNumApisixUpstreamsCreated(1), "checking number of upstreams") + Review Comment: please apply more APISIX CRD to increase revision before restarting ingress controller -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[PR] upgrade: etcd-adapter and add e2e test [apisix-ingress-controller]
Revolyssup opened a new pull request, #2369: URL: https://github.com/apache/apisix-ingress-controller/pull/2369 ### Type of change: After the etcd=adapter upgrade, the bug which caused newer updates to be not seen after ingress restarts in etcd.enabled mode has been fixed. This PR upgrades to newer adapter and adds e2e case. - [ ] Bugfix - [ ] New feature provided - [ ] Improve performance - [ ] Backport patches - [ ] Documentation - [ ] Refactor - [ ] Chore - [ ] CI/CD or Tests ### What this PR does / why we need it: ### Pre-submission checklist: - [ ] Did you explain what problem does this PR solve? Or what new features have been added? - [ ] Have you added corresponding test cases? - [ ] Have you modified the corresponding document? - [ ] Is this PR backward compatible? **If it is not backward compatible, please discuss on the [mailing list](https://github.com/apache/apisix-ingress-controller#community) first** -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org