narendly commented on a change in pull request #788: Implement request
forwarding for ZkRoutingDataWriter
URL: https://github.com/apache/helix/pull/788#discussion_r384315332
##########
File path:
helix-rest/src/main/java/org/apache/helix/rest/server/resources/metadatastore/MetadataStoreDirectoryAccessor.java
##########
@@ -165,8 +173,13 @@ public Response addShardingKey(@PathParam("realm") String
realm,
@Path("/metadata-store-realms/{realm}/sharding-keys/{sharding-key: .+}")
public Response deleteShardingKey(@PathParam("realm") String realm,
@PathParam("sharding-key") String shardingKey) {
+ if (shardingKey.charAt(0) != '/') {
+ shardingKey = "/" + shardingKey;
+ }
Review comment:
Now this is duplicate code. Could you refactor this out to a private method?
You could explain the JAX-RS behavior around slashes there.
----------------------------------------------------------------
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]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]