You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/09/19 01:45:59 UTC
[GitHub] [apisix-ingress-controller] xiangtianyu opened a new issue, #1340: bug: unexpected result when ingress restarted
xiangtianyu opened a new issue, #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340
### Issue description
if we apply yaml quickly just after the ingress restarted, it will cause some unexpected appearance
### Environment
- your apisix-ingress-controller version (output of apisix-ingress-controller version --long): 1.5.0-rc1
- your Kubernetes cluster version (output of kubectl version): 1.24.3
- if you run apisix-ingress-controller in Bare-metal environment, also show your OS version (uname -a):
### Minimal test code / Steps to reproduce
I used this yaml to create apisix route:
```
apiVersion: apisix.apache.org/v2beta3
kind: ApisixRoute
metadata:
name: httpserver-route
spec:
http:
- name: rule3
match:
hosts:
- local.httpbin.org
paths:
- /*
backends:
- serviceName: httpbin
servicePort: 80
```
and then i restarted apisix ingress and changed this yaml to
```
apiVersion: apisix.apache.org/v2beta3
kind: ApisixRoute
metadata:
name: httpserver-route
spec:
http:
- name: rule1
match:
hosts:
- local.httpbin.org
paths:
- /*
backends:
- serviceName: httpbin
servicePort: 80
- name: rule2
match:
hosts:
- local.httpbin.org
paths:
- /*
backends:
- serviceName: httpbin
servicePort: 80
```
### Actual result
it returned like this
<img width="1155" alt="截屏2022-09-19 09 25 33" src="https://user-images.githubusercontent.com/10825900/190937936-f29c1ce5-7227-4244-80ec-bd25a8e7c08b.png">
### Error log
no err log
### Expected result
it should be like this
<img width="1192" alt="截屏2022-09-19 09 16 27" src="https://user-images.githubusercontent.com/10825900/190937952-223f0ac2-b473-40e4-81ae-943c88078d98.png">
--
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-unsubscribe@apisix.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] tao12345666333 commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
tao12345666333 commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250722669
> My idea is that at startup, the controller deletes all apisix objects. Or more granular deletion. For example, delete resource label is `managed-by: apisix-ingress-controller` or `crd: httpbin-route`.
No. This is too dangerous. and may lead to accidents
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] AlinsRan commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
AlinsRan commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250671051
> > > So, is there any suggestion to avoid this? Or it will be fixed in code?
> >
> >
> > My idea is that at startup, the controller deletes all apisix objects. Or more granular deletion. For example, delete resource label is `managed-by: apisix-ingress-controller` or `crd: ApisixRoute`.
>
> But if do deletions like this, the online applications will be effected. In a short time, some requests cannot trans in correct way
By comparing resources, only redundant objects can be deleted.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] xiangtianyu commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
xiangtianyu commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250496759
> Maybe you applied yaml before initialization.
yes, so if the ingress is stopped, and then it start again, it will not sync this data between the gap?
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] xiangtianyu commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
xiangtianyu commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250625390
So, is there any suggestion to avoid this? Or it will be fixed in code?
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] xiangtianyu commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
xiangtianyu commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250650114
> > So, is there any suggestion to avoid this? Or it will be fixed in code?
>
> My idea is that at startup, the controller deletes all apisix objects. Or more granular deletion. For example, delete resource label is `managed-by: apisix-ingress-controller` or `crd: ApisixRoute`.
But if do deletions like this, the online applications will be effected. In a short time, some requests cannot trans in correct way
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] AlinsRan commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
AlinsRan commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250489725
Maybe you applied yaml before initialization.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] AlinsRan commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
AlinsRan commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250485154
No matter how I reproduce it, it is normal.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] AlinsRan commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
AlinsRan commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250510535
> > Maybe you applied yaml before initialization.
>
> yes, so if the ingress is stopped, and then it start again, it will not sync this data between the gap?
Yes, when it is started, it only watches the latest data and does not compare versions. Therefore, operations during this period will be lost.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] xiangtianyu commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
xiangtianyu commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250517511
>
IMO, this is a bug, ingress controller unavailable is unavoidable online.So it will certainly cause dirty data. This is inacceptable to me.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] AlinsRan commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
AlinsRan commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250742873
> >
>
> Will it be added into the future version of apisix ingress controller?
It will be. I will fixes it as soon as possible.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] oyiadin commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
oyiadin commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1305162769
Sorry but is this PR related? https://github.com/apache/apisix-ingress-controller/pull/680
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] xiangtianyu commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
xiangtianyu commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250673142
>
Will it be added into the future version of apisix 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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] xiangtianyu commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
xiangtianyu commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250488743
> No matter how I reproduce it, it is normal.
>
> ![image](https://user-images.githubusercontent.com/79972061/190941688-0785f1e0-af82-4a9f-8e7d-e055c021d4d6.png)
>
> ![image](https://user-images.githubusercontent.com/79972061/190941615-a4d46178-474d-414d-b8f8-1c812226d45b.png)
I retried again and definitely reproduce it.
<img width="1149" alt="截屏2022-09-19 10 45 16" src="https://user-images.githubusercontent.com/10825900/190942163-86a9ada4-2fbf-47e9-95dc-b658b2ca4241.png">
this time i used the execute file built by the newest code
Or you can stop the ingress and apply yaml and start the ingress.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix-ingress-controller] AlinsRan commented on issue #1340: bug: unexpected result when ingress restarted
Posted by GitBox <gi...@apache.org>.
AlinsRan commented on issue #1340:
URL: https://github.com/apache/apisix-ingress-controller/issues/1340#issuecomment-1250645270
> So, is there any suggestion to avoid this? Or it will be fixed in code?
My idea is that at startup, the controller deletes all apisix objects. Or more granular deletion. For example, delete resource label is `managed-by: apisix-ingress-controller` or `crd: ApisixRoute`.
--
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-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org