Automate uploads

vozzibaer

Joined: 2012-07-26
Posts: 5
Posted: Thu, 2012-08-02 13:36

I have spend a lot of time with searching for a method to schedule the upload of pictures, but nothing found :-(
The only solution which should help is gal3uploader, a application written in "Go". I have compiled this for my 32-Bit Ubuntu Server
and it runs in a cron-job. But the problem here is, that after many file (one time about 50, another time about 90) it crashes without
any messages.
The only way for me is now that I use the serveradd module, select my picture folder with thousands of picture and wait, wait, wait....
...and hope that I have not selected a folder always in my gallery - than I have hunderds of duplicated pictures.

I think, it where a good feature, if the serveradd module can controlled via command line. Maybe in this way

serveradd -s sourcedir -d destinationdir -h http://www.mygallery/index.php -r (recursiv) and check if pictures are
duplicate, and maybe with an option to delete pictures are not in the sourcedir.

Regards,
vozzibaer

 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Thu, 2012-08-02 16:34

+1 to this suggestion. But g3remote should work in the meantime, yeah?

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Thu, 2012-08-02 17:55
 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Thu, 2012-08-02 18:21

Yes, that appears to be the client mentioned in the original post.

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Thu, 2012-08-02 19:26
Quote:
But the problem here is, that after many file (one time about 50, another time about 90) it crashes without
any messages.

I bet the server add method dies as well on occasion.
Just to be clear I have never used this client.

So the client works as a cron, so that fills the requirement of 'schedule the upload of pictures'
the docs say: (if a matching image doesn't already exist in the gallery). so that should fill the requirement of the duplicated pictures.

So now I guess it meets all the requirements except that like other upload methods it stops without warning. Perhaps it just needs some error checking in the code or some delays to check if the server is still responsive.

I would like to have this feature as well, but don't have the skills the write it.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Thu, 2012-08-02 19:44
floridave wrote:
I bet the server add method dies as well on occasion.

Really? Why?

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Thu, 2012-08-02 20:14

Because the other method does. Most likely.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Thu, 2012-08-02 20:20

Maybe I misunderstood the comment. Gallery should be pretty mature software at this point and I wouldn't expect it to be expected that core functionality like uploading photos might just die sometimes. Is that what you're saying?

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Fri, 2012-08-03 02:49

Depending on the resources available as well as the Internet connection I would expect to see some., especially on some overloaded hosts and multi megapixel images.

Dave
___________________________________________
Blog & G2 || floridave - Gallery Team

 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Fri, 2012-08-03 03:00
floridave wrote:
Depending on the resources available as well as the Internet connection I would expect to see some., especially on some overloaded hosts and multi megapixel images.

Even with Server Add?

I understand if one has a really terrible internet connection, but even so, tcp is a reliable protocol, and it's a bit surprising for any modern application to exhibit random failure without at least logging an error which can be traced back to the problem.

 
vozzibaer

Joined: 2012-07-26
Posts: 5
Posted: Fri, 2012-08-03 11:33

Hi, I'm back. I'm from Germany, so in the last night I have used the server add method to upload of 953 Picture on my server in my intranet at home.
As first - dosn't die :-), but I wondering, because the size of autoratated picture are reduced obout 75% (p.e. from 5MB to 1MB)
As second, I have also try the g3remote, but I in Windows I become an error and on my linux box, if I run "python G3remote.py" also ("Module wx not found").
Also I cannot found, where I put my key and url in the "config.py".

Regards

vozzibaer

 
mattdm

Joined: 2005-07-22
Posts: 181
Posted: Fri, 2012-08-03 12:08
vozzibaer wrote:
box, if I run "python G3remote.py" also ("Module wx not found").

This part is easily solved. You just need the wxPython package. On Fedora, `sudo yum install wxPython`.

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Fri, 2012-08-03 17:37
mattdm wrote:

Even with Server Add?

Yes we see it all the time on hosts that overload the servers and put some very restrictions on DB queries (query count) & process time & disk access limitations among others.
Some hosts just kill the process and any application can't test for this or log it.

Yes there is additional debugging and other coding that could go into making it more robust and we are making strides to get there.
Remember, we are using a 3rd party framework (Kohana) and we don't have the resources to do what we did in G2 (develop our own framework).
If you have any patches that will make it happen faster please let us know by creating a fork on the github so we can merge those into the product faster.

Dave

_____________________________________________
Blog & G2 || floridave - Gallery Team