⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

Best way to support amazon s3



thecrazycodr

thecrazycodr
  • profile picture
  • Member

Posted 04 March 2019 - 16:55 PM

Hey all,

 

So i inherited this project that uses GroceryCRUD. Can't say i'm particularly fond of these technologies but i have to use it and so i'll do.

 

My first task is to make the app scalable which means no uploads/file management on the machine hosting the app (Or as little as possible). To this end, i need to understand a little bit how file uploads work.

 

The version this project uses is: 1.5.7

 

I see that there are a lot of file_exists, move_uploaded_file, is_uploaded_files used and i don't see any kind of filesystem abstraction for GroceryCrud such as League/FlySystem. Is there an easy way for me rewire all file management to use an abstraction? I'd really need this right now.

 

If it isn't possible, i need to ensure that uploads are done in an atomic way, all of the upload is called on the same machine at once and never in multiple XHR requests. Is this something we can configure? If so, then i could simply hook into most callbacks and just move uploaded files to S3.

 

The last problem i see is that GroceryCrud seems to be checking for file existence... If i can't easily overcome that, i'll have to hack away the code and this is something i definitely DONT WANT TO DO...

 

My guess is not many people will be able to help me with this apart from John himself.

 

Thanks anyway