You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2020/06/03 04:19:43 UTC

[GitHub] [incubator-doris] morningman opened a new pull request #3755: [Plugin] Add timeout of connection when downloading the plugins from URL

morningman opened a new pull request #3755:
URL: https://github.com/apache/incubator-doris/pull/3755


   Fix #3754
   
   If no timeout is set, the download process may be blocked forever.


----------------------------------------------------------------
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:
users@infra.apache.org



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


[GitHub] [incubator-doris] morningman commented on a change in pull request #3755: [Plugin] Add timeout of connection when downloading the plugins from URL

Posted by GitBox <gi...@apache.org>.
morningman commented on a change in pull request #3755:
URL: https://github.com/apache/incubator-doris/pull/3755#discussion_r434325324



##########
File path: fe/src/main/java/org/apache/doris/plugin/PluginZip.java
##########
@@ -113,13 +113,13 @@ Path downloadRemoteZip(Path targetPath) throws IOException, UserException {
         cleanPathList.add(zip);
 
         // download zip
-        try (InputStream in = openUrlInputStream(source)) {
+        try (InputStream in = Util.getInputStreamFromUrl(source, null, 5000, 5000)) {

Review comment:
       I change it to a config




----------------------------------------------------------------
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:
users@infra.apache.org



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


[GitHub] [incubator-doris] kangkaisen commented on a change in pull request #3755: [Plugin] Add timeout of connection when downloading the plugins from URL

Posted by GitBox <gi...@apache.org>.
kangkaisen commented on a change in pull request #3755:
URL: https://github.com/apache/incubator-doris/pull/3755#discussion_r434305139



##########
File path: fe/src/main/java/org/apache/doris/plugin/PluginZip.java
##########
@@ -113,13 +113,13 @@ Path downloadRemoteZip(Path targetPath) throws IOException, UserException {
         cleanPathList.add(zip);
 
         // download zip
-        try (InputStream in = openUrlInputStream(source)) {
+        try (InputStream in = Util.getInputStreamFromUrl(source, null, 5000, 5000)) {

Review comment:
       Should be static const value.
   If the timeout isn't a config, I think set a larger value maybe better when the plugin resource is big and network is poor.




----------------------------------------------------------------
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:
users@infra.apache.org



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


[GitHub] [incubator-doris] morningman merged pull request #3755: [Plugin] Add timeout of connection when downloading the plugins from URL

Posted by GitBox <gi...@apache.org>.
morningman merged pull request #3755:
URL: https://github.com/apache/incubator-doris/pull/3755


   


----------------------------------------------------------------
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:
users@infra.apache.org



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