You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug][org] All /plugins/org/* endpoints return 404 since v1.0.3-beta19 #9327
I had searched in the issues and found no similar issues.
What happened
After upgrading to v1.0.3-beta19, every /plugins/org/* endpoint returns 404 (teams.csv, users.csv, user_account_mapping.csv, ...). PUT /plugins/org/teams.csv worked on v1.0.3-beta18.
Root cause: #9288 added plugins/all, which registers compiled-in plugins by value (plugin.MustRegister(org.Org{})). org declares Init and ApiResources on *Org, so the registered value implements neither PluginInit nor PluginApi: the plugin is never initialised and no routes are mounted. org is the only plugin with a pointer-receiver ApiResources, so it is the only one visibly affected. The .so loader always registered a pointer (plugin.Lookup returns *T), which is why this worked before.
What do you expect to happen
/plugins/org/* endpoints work as in beta18.
How to reproduce
Run v1.0.3-beta19.
curl -X PUT -F file=@teams.csv http://<lake>:8080/plugins/org/teams.csv → 404.
Anything else
Fix: #9326 (generator emits plugin.MustRegister(&pkg.Type{}), plus a regression test).
Activity
fix(plugins): register compiled-in plugins as pointers