Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[KYUUBI #5606][REST] Handle engine listing request properly for users…
… who have not created engine ### _Why are the changes needed?_ Close #5606 ``` 2023-11-03 19:30:13.215 ERROR KyuubiRestFrontendService-57 org.apache.kyuubi.server.api.v1.AdminResource: No such engine for user: anonymous, engine type: SPARK_SQL, share level: USER, subdomain: null org.apache.kyuubi.shaded.zookeeper.KeeperException$NoNodeException: KeeperErrorCode = NoNode for /kyuubi_1.8.1-SNAPSHOT_USER_SPARK_SQL/anonymous at org.apache.kyuubi.shaded.zookeeper.KeeperException.create(KeeperException.java:114) at org.apache.kyuubi.shaded.zookeeper.KeeperException.create(KeeperException.java:54) at org.apache.kyuubi.shaded.zookeeper.ZooKeeper.getChildren(ZooKeeper.java:1659) at org.apache.kyuubi.shaded.curator.framework.imps.GetChildrenBuilderImpl$3.call(GetChildrenBuilderImpl.java:230) at org.apache.kyuubi.shaded.curator.framework.imps.GetChildrenBuilderImpl$3.call(GetChildrenBuilderImpl.java:219) at org.apache.kyuubi.shaded.curator.RetryLoop.callWithRetry(RetryLoop.java:109) at org.apache.kyuubi.shaded.curator.framework.imps.GetChildrenBuilderImpl.pathInForeground(GetChildrenBuilderImpl.java:216) at org.apache.kyuubi.shaded.curator.framework.imps.GetChildrenBuilderImpl.forPath(GetChildrenBuilderImpl.java:207) at org.apache.kyuubi.shaded.curator.framework.imps.GetChildrenBuilderImpl.forPath(GetChildrenBuilderImpl.java:40) at org.apache.kyuubi.ha.client.zookeeper.ZookeeperDiscoveryClient.getChildren(ZookeeperDiscoveryClient.scala:82) at org.apache.kyuubi.server.api.v1.AdminResource.$anonfun$listEngines$5(AdminResource.scala:306) at org.apache.kyuubi.ha.client.DiscoveryClientProvider$.withDiscoveryClient(DiscoveryClientProvider.scala:36) at org.apache.kyuubi.server.api.v1.AdminResource.listEngines(AdminResource.scala:304) ``` ### _How was this patch tested?_ - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible - [ ] Add screenshots for manual tests if appropriate - [x] [Run test](https://kyuubi.readthedocs.io/en/master/contributing/code/testing.html#running-tests) locally before make a pull request ### _Was this patch authored or co-authored using generative AI tooling?_ No Closes #5619 from pan3793/list-engine. Closes #5606 783894b [Cheng Pan] nit 52eb538 [Cheng Pan] nit 8d8097f [Cheng Pan] [KYUUBI #5606][REST] Handle engine listing request properly for users who have not created engine Authored-by: Cheng Pan <chengpan@apache.org> Signed-off-by: Cheng Pan <chengpan@apache.org> (cherry picked from commit 7926cc6) Signed-off-by: Cheng Pan <chengpan@apache.org>
- Loading branch information