arina-ielchiieva commented on a change in pull request #1788: DRILL-7204: Add
proper validation when creating plugin
URL: https://github.com/apache/drill/pull/1788#discussion_r285189528
##########
File path:
exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/StorageResources.java
##########
@@ -204,6 +204,10 @@ public JsonResult
createOrUpdatePluginJSON(PluginConfigWrapper plugin) {
@Consumes(MediaType.APPLICATION_FORM_URLENCODED)
@Produces(MediaType.APPLICATION_JSON)
public JsonResult createOrUpdatePlugin(@FormParam("name") String name,
@FormParam("config") String storagePluginConfig) {
+ name = name.trim();
Review comment:
Can name be null? Just checking to ensure we won't get NPE here.
----------------------------------------------------------------
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