-
Notifications
You must be signed in to change notification settings - Fork 216
Infra: Refactor TwoDomainLoadBalancer class #2611
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
Conversation
anpanigr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we avoid the Ordering of the tests in the class.
|
I'd not recommend removing the ordering because if we do so, we need to move installation of three LBers to BeforeAll. Then we go back to where we have this change -- when one installation of LBer failed, entire tests fail |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the LoadBalancer tests ( 3 to 15) depends on Test(2) i.e.
testTwoDomainsManagedByOneOperatorSharingPV because Test(1) creates TwoDomains and shutdown both.
How the NGINX tests depends on Traefik if you consider Ordering in needed.
Why testTraefikHostRoutingAdminServer(#5) depend on testNginxTLSPathRoutingAcrossDomains(#4)
|
You are right that all LBers related tests have to be done after order(1) and order(2). However, in order to remove the ordering, we have to install all three LBers before all tests (except 1 & 2) start, that strategy bring back the issue of one LBer failed to install, no test will run. It doesn't matter whether 5 depends on 4, I just didn't touch the original ordering. If you don't like it, I can re-order to group same LBer test together. |
anpanigr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The other option is create separate class for each LB. Move the Test(1) and Test(2) to a separate class. For each LoadBalancer class beforeAll() create two domains and install the LoadBalancer, then all tests are independent.
We need a separate JIRA to accomplish this. Can you try to fails the Ngix LoadBalancer installation and make sure that Traefik and Apache test works fine.
anpanigr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
I changed NGINX namespace to force installing NGINX fail, nginxHelmParams = installAndVerifyNginx(nginxNamespace + "123", 0, 0); The results are expected, only NIGNX related tests failed all other tests passed [INFO] |
vanajamukkara
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LG
Currently TwoDomainLoadBalancer test class has method testDeployAppAndInstallIngressControllers() which install all three lb ingress and deploy the clusterView application.
When one of the loadbalancers fails to install, all the test fail, as each test uses the cluster view application to verify inter-server communication. If ngnix installation fails, traefik and apache tests also fails.
So we need to de associate each test methods to be independent of all type of lb igrress installation.
Jenkin Run(s)
https://build.weblogick8s.org:8443/job/weblogic-kubernetes-operator-kind-new/7137/
https://build.weblogick8s.org:8443/job/weblogic-kubernetes-operator-kind-new/71334