Local storage options

53 views
Skip to first unread message

Quentin Harley

unread,
Feb 9, 2014, 12:17:47 PM2/9/14
to botq...@googlegroups.com
We started a discussion about having a local storage option for botqueue.  This would be important to
  1. Increase performance.  Some of us don't have the best internet connections, making sending files up and down to and from Amazon a waste of time. 
  2. Bandwidth savings.  The current solution makes a lot of sense for the BotQueue.com website, but not for a internally hosted instance of botqueue
  3. For labs making items that are not open.  Many companies would feel uncomfortable having their proprietary designs floating on the internet out of their control
IF this is to be done, it still needs to be 
  • accessable from the internet if required
  • secure - no passive downloadable links to stl files for instance
What would be an acceptable incentive to get it done...

Cheers,
Q

graphmastur

unread,
Feb 9, 2014, 1:44:54 PM2/9/14
to botq...@googlegroups.com

The main problem is the ridiculous amount of things based on s3. Mainly S3, S3File, and S3Request.

The main way to do this would be this:

1. Make a class that had functions like getFile, getRequest, etc. I don't know what you'd use for S3. I've written down every use of the functions on each of the S3 classes, and I'm working on extracting an interface.
2. After you create the interface for the files, have it figure out which one to use based on a configuration file define or dependency injection.
3. Modify the passthru function to read the local file instead of the remote file.
4. Make things like the job upload function which links directly to S3 upload somewhere else.
5. Make sure all Urls are now correct and don't point to S3.

Basically, that's about it. I'm working on refactoring BotQueue to make it more testable so I'm not going to just slap a solution on there to say it's done.

I will say, however, that it is currently in progress.

Justin Nesselrotte

--
You received this message because you are subscribed to the Google Groups "BotQueue" group.
To unsubscribe from this group and stop receiving emails from it, send an email to botqueue+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Message has been deleted

Justin Nesselrotte

unread,
Dec 16, 2014, 6:42:32 PM12/16/14
to botq...@googlegroups.com, graph...@gmail.com
Oh yes, there is. It's been available since the end of this summer. I forgot I posted about it here, so I didn't update it.

To use it, add you need two options in extensions/config.php: STORAGE_METHOD and STORAGE_PATH. This is what I use for local file storage:
define("STORAGE_METHOD", "LocalFile");
define("STORAGE_PATH", "/var/www/storage");

Make sure that the directory specified in STORAGE_PATH exists, and is readable/writable by the Apache server process, in my case, that's www-data.

On Tuesday, December 16, 2014 5:38:53 PM UTC-6, Manuel Beltran wrote:
Justin,
Has there been any progress on this feature?  Is there a local storage (non S3) solution available?  Is there something I can do to help?

Manuel Beltran

Manuel Beltran

unread,
Dec 16, 2014, 11:30:32 PM12/16/14
to botq...@googlegroups.com, graph...@gmail.com
Thanks!  I saw the other post so I deleted this one.  It looks like it’s now in the latest Master branch for 0.5.  I will load it and let you know in the other post if I have any issues with it.

Manuel

You received this message because you are subscribed to a topic in the Google Groups "BotQueue" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/botqueue/ibRSMPKoccM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to botqueue+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages