Welcome Guest! You need to login or register to make posts.

Notification

Icon
Error

Options
Go to last post Go to first unread
Alex.Navarro@filogix.com  
#1 Posted : Friday, February 12, 2016 11:18:39 AM(UTC)
Alex.Navarro@filogix.com

Rank: Member

Groups: Member
Joined: 6/25/2013(UTC)
Posts: 10

We have been using the uploader in our software for years. Recently, we changed the thumbnailWidth of our largest converter from 640 to 1024

99% of the time, our server side logs show the thumbnails uploading as:
Quote:
photoname.jpg_Thumbnail0.jpg
photoname.jpg_Thumbnail1.jpg
photoname.jpg_Thumbnail2.jpg


However, we have been having cases lately in which our upload log shows:
Quote:
photoname.jpg_Thumbnail2.jpg
photoname.jpg_Thumbnail1.jpg
photoname.jpg_Thumbnail0.jpg

or

Quote:
photoname.jpg_Thumbnail1.jpg
photoname.jpg_Thumbnail0.jpg
photoname.jpg_Thumbnail2.jpg


What would cause these to be uploaded out of order like this? Is there anyway to insist that the converted thumbnails always upload in the same order?
Our converters code is below:

Code:


                converters: [
                        {
                                mode: "*.*=Thumbnail",
                                thumbnailFitMode: "Width",
                                thumbnailWidth: 1024,
                                thumbnailJpegQuality: 90,
                                thumbnailWatermark: "Text='watermark';Position=BottomCenter;Size=4px;OffsetY=4;Style=Bold;Opacity=50;Outline=false;FillColor=#000000;",
                                thumbnailCompressOversizedOnly: true
                        },
                        {
                                mode: "*.*=Thumbnail",
                                thumbnailFitMode: "Width",
                                thumbnailWidth: 320,
                                thumbnailJpegQuality: 90,
                                thumbnailWatermark: "Text='watermark';Position=BottomCenter;Size=4px;OffsetY=4;Style=Bold;Opacity=50;Outline=false;FillColor=#000000;",
                                thumbnailCompressOversizedOnly: true
                        },
                        {
                                mode: "*.*=Thumbnail",
                                thumbnailFitMode: "Width",
                                thumbnailWidth: 107,
                                thumbnailJpegQuality: 90,
                                thumbnailWatermark: "Text='watermark';Position=BottomCenter;Size=4px;OffsetY=4;Style=Bold;Opacity=50;Outline=false;FillColor=#000000;",
                                thumbnailCompressOversizedOnly: true
                        }
                ],

Andrew  
#2 Posted : Thursday, February 18, 2016 4:55:44 AM(UTC)
Andrew

Rank: Advanced Member

Groups: Member, Administration
Joined: 8/2/2003(UTC)
Posts: 876

Thanks: 2 times
Was thanked: 27 time(s) in 27 post(s)
Alex,

What version you are using? Is it the latest one?

Also, what are the remaining settings? Do you use parallel upload feature?
Alex.Navarro@filogix.com  
#3 Posted : Thursday, February 25, 2016 5:17:35 AM(UTC)
Alex.Navarro@filogix.com

Rank: Member

Groups: Member
Joined: 6/25/2013(UTC)
Posts: 10

We are using version 8.5.33.0. Not the latest, but very close.
We actually updated to 8.5.33 because of this issue, wondering if that would fix the problem, but it didn't. At the time of our update, that was the latest. In the weeks since, 8.5.49 has been released.

Here are our remaining settings.

Code:

var u = $au.uploader({
	
	//Specify the id of this Uploader instance
	id: 'Uploader',
	
	width: 950, height: 600,
	
	licenseKey: '#####-#####-#####-#####-#####',
	
	javaControl: {
		codeBase: '../js/photo_upload/Uploader8.jar', 
		version: '8.5.33' 
	},
	
   	activeXControl: {
   		codeBase: '../js/photo_upload/Uploader8.cab', 
   		version: '8.5.33' 
   	},
	
   	paneLayout: 'ThreePanes', 
   	
   	enableRotation: true,  
   	enableDescriptionEditor: false,  
   	enableContextMenu: true,  
   	
   	backgroundColor: "#ffffff",  
   	borderStyle: "Fixed3D", 
   	
   	cancelUploadButtonText: "Cancel",  
   	uploadButtonText: "Upload Images",  
   	
   	uploadPane: {
      		dropFilesHereText: "Drag Property Photos Here."
    	},
   	
	paneItem: {
		showFileNameInThumbnailsView: true
	},
	
   	folderPane: {
   		viewMode: "Thumbnails",  
      		height: 300,  
      		previewSize: 107  
   	},
   	
   	messages: {
      		fileSizeTooSmall: "File is too small.",
      		maxFileSizeExceeded: "File is too large.",
      		dimensionsTooSmall: "Image is too small.",
      		maxFileSizeExceeded: "Image is too large.",
      		uploadCompleted: ""
   	},
   	
   	uploadProgressDialog: {
      		titleText: "Uploading Images"  
   	},
   	
   	restrictions: {
      		fileMask: "*.jpg;*.jpeg;*.jpe",  
      		maxFileSize: 20000000, 
      		maxImageHeight: 100000, 
      		maxImageWidth: 100000,  
      		minImageHeight: 200, 
      		minImageWidth: 320, 
      		maxFileCount: sPhotoCount  
   	},
   	
   	converters: [
   		{ 
       		mode: "*.*=Thumbnail",
       		thumbnailFitMode: "Width",
      			thumbnailWidth: 1024,
      			thumbnailJpegQuality: 90,
       		thumbnailWatermark: "Text='watermark';Position=BottomCenter;Size=12;OffsetY=4;Style=Bold;Opacity=50;Outline=false;FillColor=#000000;",	
      			thumbnailCompressOversizedOnly: true
      		},
      		{ 
       		mode: "*.*=Thumbnail",
       		thumbnailFitMode: "Width",
      			thumbnailWidth: 321,
      			thumbnailJpegQuality: 90,
       		thumbnailWatermark: "Text='watermark';Position=BottomCenter;Size=8;OffsetY=4;Style=Bold;Opacity=50;Outline=false;FillColor=#000000;",	
      			thumbnailCompressOversizedOnly: true
      		},
      		{ 
       		mode: "*.*=Thumbnail",
       		thumbnailFitMode: "Width",
      			thumbnailWidth: 107,
      			thumbnailJpegQuality: 90,
       		thumbnailWatermark: "Text='watermark';Position=BottomCenter;Size=4;OffsetY=4;Style=Bold;Opacity=50;Outline=false;FillColor=#000000;",
      			thumbnailCompressOversizedOnly: true
      		}
   	],
   	
   	uploadSettings: {actionUrl: uploadhref},
   	
   	metadata: {
      		additionalFormName: "frmPhotoUpload"
   	},
   	
   	events: {
      		afterUpload: [ImageUploader_AfterUpload]
   	}
   	
})

u.writeHtml();
Andrew  
#4 Posted : Thursday, February 25, 2016 10:01:54 PM(UTC)
Andrew

Rank: Advanced Member

Groups: Member, Administration
Joined: 8/2/2003(UTC)
Posts: 876

Thanks: 2 times
Was thanked: 27 time(s) in 27 post(s)
Alex,

I had a talk with developers and it looks like the uploader generates thumbnails asynchronously. That's why the order in the POST request is not guarantied by design (at least in Java uploader).

What you can do about it?

1. You can increase probability that the first converter is calculated first, etc if you rearrange converters by increase of the thumbnail width:

Code:
    converters: [
        { 
            mode: "*.*=Thumbnail",
            thumbnailFitMode: "Width",
                thumbnailWidth: 107,
...
            },
            { 
            mode: "*.*=Thumbnail",
            thumbnailFitMode: "Width",
                thumbnailWidth: 321,
...
            },
            { 
            mode: "*.*=Thumbnail",
            thumbnailFitMode: "Width",
                thumbnailWidth: 1024,
...
            }
    ],


Although the probability that 321-width thumbnail is generated faster than 107-width one still exists (since it involve not just resizing, but also disk operations which are less predictable), I believe you won't encounter it on practice.

2. Change your server code to avoid relying on the order in the POST request. All server platforms allow refer the uploaded file collection items not only by a number, but also by a POST field name. The uploader would send these files as File0_0, File1_0, File2_0, etc (the first number is a number of converter, the second one is a number of a selected item in the POST request).

3. I would consider switching to HTML5-based uploader. Besides of other benefits, it does not have this problem. Although it may sound as an overkill to fix this very problem, I believe it is a good idea as it eliminates all installation issues.

Hope this makes sense.
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.