This is an automated email from the ASF dual-hosted git repository.

zhaoc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-doris.git


The following commit(s) were added to refs/heads/master by this push:
     new edbeaf8  Throw a UserException when miss plugin's md5 file (#3542)
edbeaf8 is described below

commit edbeaf8e305cff41dfcaba0ffa97f2a10114858f
Author: WingC <1018957...@qq.com>
AuthorDate: Mon May 11 02:33:35 2020 -0500

    Throw a UserException when miss plugin's md5 file (#3542)
---
 fe/src/main/java/org/apache/doris/plugin/PluginZip.java | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/fe/src/main/java/org/apache/doris/plugin/PluginZip.java 
b/fe/src/main/java/org/apache/doris/plugin/PluginZip.java
index 2120bb3..a43dc0e 100644
--- a/fe/src/main/java/org/apache/doris/plugin/PluginZip.java
+++ b/fe/src/main/java/org/apache/doris/plugin/PluginZip.java
@@ -118,10 +118,12 @@ class PluginZip {
         }
 
         // .md5 check
-        String expectedChecksum = "";
+        String expectedChecksum;
         try (InputStream in = openUrlInputStream(source + ".md5")) {
             BufferedReader br = new BufferedReader(new InputStreamReader(in));
             expectedChecksum = br.readLine();
+        } catch (IOException e) {
+            throw new UserException(e.getMessage() + ". you should provide a 
md5 URI to check plugin file");
         }
 
         DigestUtils.md5Hex(Files.readAllBytes(zip));


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to