pkuwm commented on a change in pull request #1190:
URL: https://github.com/apache/helix/pull/1190#discussion_r463471112
##########
File path:
helix-rest/src/main/java/org/apache/helix/rest/server/resources/zookeeper/ZooKeeperAccessor.java
##########
@@ -101,6 +100,26 @@ public Response get(@PathParam("path") String path,
@QueryParam("command") Strin
}
}
+ @DELETE
+ @Path("{path: .+}")
+ public Response delete(@PathParam("path") String path) {
+ // Lazily initialize ZkBaseDataAccessor
+ ServerContext _serverContext =
+ (ServerContext)
_application.getProperties().get(ContextPropertyKeys.SERVER_CONTEXT.name());
+ _zkBaseDataAccessor = _serverContext.getByteArrayZkBaseDataAccessor();
+
+ path = prependPath(path);
Review comment:
Actually if we set the root path as below, we don't need to prepend the
root slash, which is not that clean.
```
@Path("/zookeeper{path: /.+}")
public class ZooKeeperAccessor extends AbstractResource {
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]