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

Can not get plugin list #2910

Open
cataglyphis opened this issue Jan 19, 2024 · 15 comments
Open

Can not get plugin list #2910

cataglyphis opened this issue Jan 19, 2024 · 15 comments
Labels
bug Something isn't working

Comments

@cataglyphis
Copy link

Issue description

  1. Can not get plugin list when visit: https://xxx.com/plugin/list

Expected behavior

  1. list all enabled plugins

How to Reproduce

  1. click Plugin in apisix dashboard homepage

Screenshots

image

Environment

  • apisix version (cmd: apisix version): 3.2.2
  • OS (cmd: uname -a):
  • OpenResty / Nginx version (cmd: nginx -V or openresty -V):
  • etcd version, if have (cmd: run etcd --version): 3.5.0
  • apisix-dashboard version, if have: 3.0.1
  • Browser version, if have:

Additional context

No response

@cataglyphis cataglyphis added the bug Something isn't working label Jan 19, 2024
@hanqingwu
Copy link

can you check whether etcd is healthy or check dashboard logs ?
docker logs docker-apisix-apisix-dashboard-1
docker exec -it docker-apisix-apisix-dashboard-1 cat /usr/local/apisix-dashboard/logs/access.log
docker exec -it docker-apisix-apisix-dashboard-1 cat /usr/local/apisix-dashboard/logs/error.log

@cataglyphis
Copy link
Author

cataglyphis commented Jan 23, 2024

apisix dashboard log

2024-01-23T15:28:57.015631618+08:00 2024-01-23T07:28:57.015Z	filter/logging.go:45	/plugin/list	{"status": 304, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:57.696833305+08:00 2024-01-23T07:28:57.696Z	filter/logging.go:45	/apisix/admin/plugins	{"status": 200, "host": "apisix-xxx.bambu-lab.com", "query": "all=true", "requestId": "", "latency": 0.000000002, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:57.702280307+08:00 2024-01-23T07:28:57.702Z	filter/logging.go:45	/apisix/admin/global_rules/1	{"status": 200, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:57.718622691+08:00 2024-01-23T07:28:57.718Z	filter/logging.go:45	/apisix/admin/global_rules/1	{"status": 200, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:58.400529750+08:00 2024-01-23T07:28:58.400Z	filter/logging.go:45	/plugin/list	{"status": 304, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:58.629927059+08:00 2024-01-23T07:28:58.629Z	filter/logging.go:45	/apisix/admin/global_rules/1	{"status": 200, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:58.630160926+08:00 2024-01-23T07:28:58.630Z	filter/logging.go:45	/apisix/admin/plugins	{"status": 200, "host": "apisix-xxx.bambu-lab.com", "query": "all=true", "requestId": "", "latency": 0.000000001, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:28:58.679658176+08:00 2024-01-23T07:28:58.679Z	filter/logging.go:45	/apisix/admin/global_rules/1	{"status": 200, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

2024-01-23T15:29:02.228708893+08:00 2024-01-23T07:29:02.228Z	filter/logging.go:45	/ping	{"status": 200, "host": "10.110.133.132:9000", "query": "", "requestId": "", "latency": 0, "remoteIP": "10.110.18.155", "method": "GET", "errs": []}

2024-01-23T15:29:02.228727595+08:00 2024-01-23T07:29:02.228Z	filter/logging.go:45	/ping	{"status": 200, "host": "10.110.133.132:9000", "query": "", "requestId": "", "latency": 0, "remoteIP": "10.110.18.155", "method": "GET", "errs": []}

no access / error log

/usr/local/apisix-dashboard # cd logs
/usr/local/apisix-dashboard/logs # ls
/usr/local/apisix-dashboard/logs # pwd
/usr/local/apisix-dashboard/logs
/usr/local/apisix-dashboard/logs # ls -al
total 8
drwxr-xr-x    2 root     root          4096 Apr 12  2023 .
drwxr-xr-x    1 root     root          4096 Apr 12  2023 ..
/usr/local/apisix-dashboard/logs #

@hanqingwu
Copy link

2024-01-23T15:28:58.400529750+08:00 2024-01-23T07:28:58.400Z filter/logging.go:45 /plugin/list {"status": 304, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

It show 304 code when you get /plugin/list, so can you clear you cookie or other cache then try again ?
Or press Ctrl+F5 to force a refresh ?

@cataglyphis
Copy link
Author

2024-01-23T15:28:58.400529750+08:00 2024-01-23T07:28:58.400Z filter/logging.go:45 /plugin/list {"status": 304, "host": "apisix-xxx.bambu-lab.com", "query": "", "requestId": "", "latency": 0, "remoteIP": "61.169.76.178", "method": "GET", "errs": []}

It show 304 code when you get /plugin/list, so can you clear you cookie or other cache then try again ? Or press Ctrl+F5 to force a refresh ?

still not working, and get plugins?all=true api return value is:

{
    "code": 0,
    "message": "",
    "data": null,
    "request_id": "532de6e9-80a1-4614-ac96-3ad4cd634d59"
}

@cataglyphis
Copy link
Author

what 's your use apisix-dashboard version ? image version ? I will try to reproduce .

apache/apisix-dashboard:3.0.1-alpine

@cataglyphis
Copy link
Author

And can you cat apisix-dashbaord conf in /usr/local/apisix-dashboard/conf/conf.yaml ?

/usr/local/apisix-dashboard/conf # cat conf.yaml
conf:
  listen:
    host: 0.0.0.0
    port: 9000
  etcd:
    prefix: "/apisix"
    endpoints:
      - apisix-etcd:2379
  log:
    error_log:
      level: warn
      file_path: /dev/stderr
    access_log:
      file_path: /dev/stdout
authentication:
  secret: secret
  expire_time: 3600
  users:
    - username: admin
      password: xxxxx

@cataglyphis
Copy link
Author

https://github.com/apache/apisix-docker/blob/release/apisix-dashboard-3.0.1/example/dashboard_conf/conf.yaml Can you try to add plugins like this config.yaml ?

downgrade apisix dashboard to 3.0.0, all the plugins listed like below
image

@hanqingwu
Copy link

So when you upgrade 3.0.1 , these plugins disappear ?
I have tried apache/apisix-dashboard:3.0.1-alpine , but i can not reproduce empty plugin list .

@cataglyphis
Copy link
Author

So when you upgrade 3.0.1 , these plugins disappear ? I have tried apache/apisix-dashboard:3.0.1-alpine , but i can not reproduce empty plugin list .

yes, and when I downgrade dashboard to 3.0.0, all plugins listed...

@harsh-rajput-vats
Copy link

Hi @hanqingwu,
I am facing same issue of empty plugin list. I am running APISIX on local kubernetes cluster via Minikube on my Mac M1.
Here are the image tags I am using:

Dashboard: apache/apisix-dashboard:latest
APISIX: apache/apisix:3.7.0-debian
initContainer for wait-etcd: busybox:1.28
etcd: bitnami/etcd:3.5.1-debian-10-r31

I have a created a repo and pushed all code to reproduce env:
https://github.com/harsh-rajput-vats/apisix_bug

Screenshot 2024-01-25 at 5 43 48 PM Screenshot 2024-01-25 at 5 45 25 PM

@jialechan
Copy link

same issues, image: apache/apisix-dashboard:3.0.1-alpine,

apache/apisix-dashboard:3.0.0-alpine is ok

@harsh-rajput-vats
Copy link

@jialechan
Thanks,
Its working with apache/apisix-dashboard:3.0.0-alpine atleast.

@anjia0532
Copy link
Contributor

same to me. downgrade to 3.0.0 to fixit

@andytael
Copy link

andytael commented Feb 3, 2024

Same for me, downgrade to 3.0.0 solved the problem

@cataglyphis
Copy link
Author

Any updates on this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants