File storage providers

General discussion of development ideas and the approaches taken in the 3.x branch of phpBB. The next feature release of phpBB 3 will be 3.3/Proteus.
Forum rules
Please do not post support questions regarding installing, updating, or upgrading phpBB 3.2.x. If you need support for phpBB 3.2.x please visit the 3.2.x Support Forum on phpbb.com.

If you have questions regarding writing extensions please post in Extension Writers Discussion to receive proper guidance from our staff and community.
Post Reply
Senky
Extension Customisations
Extension Customisations
Posts: 301
Joined: Thu Jul 16, 2009 4:41 pm

File storage providers

Post by Senky » Fri May 27, 2016 10:50 am

If I do not miss something, there is only one way of handling uploads in phpBB - plupload. Right?

I think we should, in a world of cloud computing and remote data storages, start to discuss on how to make phpBB handle different upload providers.

The idea is like this:
  • provide an abstraction over file uploads in phpBB
  • provide a default provider - plupload
  • enable extensions to add custom providers (Amazon S3, Dropbox, Azure, ...)
  • phpBB would only be a mediator between enduser and the provider - it would take a file from the user and forward it to the provider
  • provider class would be responsible for permanent file storage and permanent accessibility of the file, giving phpBB only unique identification of the image (that would be used to link file to post/avatar)
What are your ideas about this?
Last edited by Senky on Sat May 28, 2016 8:48 am, edited 1 time in total.

User avatar
Paul
Infrastructure Team Leader
Infrastructure Team Leader
Posts: 364
Joined: Thu Sep 16, 2004 9:02 am
Contact:

Re: Upload providers

Post by Paul » Fri May 27, 2016 11:09 am

S3/Dropbox are storage providerd, how is that related to how the file is uploaded? What you want is storage providers, not upload providers.

Rhino.Freak
Registered User
Posts: 48
Joined: Thu Dec 24, 2015 10:47 am

Re: Upload providers

Post by Rhino.Freak » Fri May 27, 2016 2:55 pm

I actually like the idea of cloud storage linking but how would that work?

CHItA
Development Team
Development Team
Posts: 152
Joined: Thu Mar 12, 2015 1:43 pm
Location: Budapest, Hungary

Re: Upload providers

Post by CHItA » Fri May 27, 2016 4:43 pm

Rhino.Freak wrote:
Fri May 27, 2016 2:55 pm
I actually like the idea of cloud storage linking but how would that work?
You implement the filesystem interface with the clouds API or with something like flysystem + swap out the basic PHP filesystem functions in the core to use the filesystem interface.

Senky
Extension Customisations
Extension Customisations
Posts: 301
Joined: Thu Jul 16, 2009 4:41 pm

Re: Upload providers

Post by Senky » Sat May 28, 2016 8:48 am

paulus wrote:
Fri May 27, 2016 11:09 am
S3/Dropbox are storage providerd, how is that related to how the file is uploaded? What you want is storage providers, not upload providers.
Sorry, I was maybe just confusing. CHItA explained it clearly. We would implement the filesystem interface and let various providers handle the files in their way. As I think of it now, it has nothing to do with uploading process :D

User avatar
david63
Registered User
Posts: 245
Joined: Mon Feb 07, 2005 7:23 am
Location: Lancashire, UK

Re: File storage providers

Post by david63 » Sat May 28, 2016 9:20 am

Is this not something that could/should be handled with one or more events with extensions customised for the various storage facilities?
David
Remember: You only know what you know -
and you do not know what you do not know!

Senky
Extension Customisations
Extension Customisations
Posts: 301
Joined: Thu Jul 16, 2009 4:41 pm

Re: File storage providers

Post by Senky » Sat May 28, 2016 5:22 pm

david63 wrote:
Sat May 28, 2016 9:20 am
Is this not something that could/should be handled with one or more events with extensions customised for the various storage facilities?
It's also the way, but the same can be told about cache providers, auth providers, avatar providers, etc.

User avatar
Marc
Development Team Leader
Development Team Leader
Posts: 133
Joined: Thu Sep 09, 2010 11:36 am
Location: Munich, Germany

Re: File storage providers

Post by Marc » Mon May 30, 2016 8:32 am

I'd like to point out that there is already a ticket for splitting the file storage in the classes used for uploading files:
https://tracker.phpbb.com/browse/PHPBB3-14169

User avatar
rubencm
Registered User
Posts: 21
Joined: Sun Mar 12, 2017 8:30 pm

Re: File storage providers

Post by rubencm » Sun Aug 05, 2018 11:33 pm

This is almost working now, you can test it and report bugs

Post Reply