cakephp-file-storage icon indicating copy to clipboard operation
cakephp-file-storage copied to clipboard

Version 4.0 (complete rewrite)

Open burzum opened this issue 4 years ago • 3 comments

⚠️ This is going to be a big BC breaker but it should be easy to write a migration for the existing data. ⚠️

The goal is to get rid of the thight coupling of the functionality of this plugin to the CakePHP framework. The internal coupling is bad and being tight bound to the framework causes more work than gaining a benefit from it. Then new version is going to use a framework agnostic library version of this plugin and is going to integrate it just very loose to Cake, so that future changes the framework is going to make wont' cause a lot work. However, I would recommend to use phauthentic/file-storage directly, you can already start to read the docs if you want. Experience has shown that all the plugins are just a PITA to maintain when CakePHP requires changes to the plugins, even inside minor releases.

The development work is done in the 4.0 branch https://github.com/burzum/cakephp-file-storage/tree/4.0

Todo:

  • [x] Drop Gaufrette🗑️
  • [x] Drop Imagine🗑️
  • [x] Use CakePHP 4 🥳
  • [x] Use php 7.4 🥳
  • [x] Use phauthentic/file-storage (using Intervention Image and Flysystem) 🥳
  • [x] Use phauthentic/file-storage-image-processor 🥳
  • [x] Drop all the event listeners 🗑️
  • [x] Total rewrite of the path builders (using phauthentic/file-storage)
  • [x] Refactor the behavior and simplify it a lot
  • [x] Refactor the helpers
  • [ ] Update the shells
  • [x] Update tests
  • [ ] Tag stable releases of the phauthentic libraries
  • [ ] Update documentation - HELP WANTED AND APPRECIATED 🍻

Looking back at the old code makes me regretting not doing this cut earlier... 😟

burzum avatar Jul 14 '20 23:07 burzum

Just an update on this: Looks like we're going to get closer to tag a first ~~stable~~ release of the libs and finishing the sheels within the next few weeks. 🥳

burzum avatar Nov 06 '20 12:11 burzum

I am curious how this rewrite is going and if I can somehow help

LordSimal avatar Mar 03 '21 18:03 LordSimal

@LordSimal you can give it a try it should work. Since I don't work with CakePHP anymore I can't say anything about how well it already works. I've also started in a new company and don't have time and mood for open source right now. It should work, there might be edge cases not being covered yet. @dereuromark is using it but I don't know about the current state.

burzum avatar Mar 03 '21 19:03 burzum