Skip to content

Commit

Permalink
Uplaod thread hangs if no files uploaded
Browse files Browse the repository at this point in the history
  • Loading branch information
datasetutil committed Jan 26, 2015
1 parent 0dc4dc7 commit baa24ad
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<description>Analytics Cloud Datatset Utils</description>
<artifactId>datasetutils</artifactId>
<packaging>jar</packaging>
<version>32.0.12-SNAPSHOT</version>
<version>32.0.13-SNAPSHOT</version>
<url>https://github.com/forcedotcom/Analytics-Cloud-Dataset-Utils</url>
<organization>
<name>salesforce.com</name>
Expand Down
3 changes: 2 additions & 1 deletion src/main/java/com/sforce/dataset/loader/DatasetLoader.java
Original file line number Diff line number Diff line change
Expand Up @@ -662,6 +662,7 @@ public static boolean uploadEM(File dataFile, String dataFormat, byte[] metadata
MAX_NUM_UPLOAD_THREADS = 1;
while(retryCount<3)
{
q.clear(); //clear the queue otherwise thread will die before it starts because of previous empty messages
LinkedList<FilePartsUploaderThread> upThreads = new LinkedList<FilePartsUploaderThread>();
for(int i = 1;i<=MAX_NUM_UPLOAD_THREADS;i++)
{
Expand Down Expand Up @@ -734,7 +735,7 @@ public static boolean uploadEM(File dataFile, String dataFormat, byte[] metadata
if(allPartsUploaded)
break;
else
logger.println("Not all file parts uplaoded trying again");
logger.println("Not all file parts uploaded trying again");
retryCount++;
}

Expand Down

0 comments on commit baa24ad

Please sign in to comment.