filestore add-on fixes, PSR-2, cleanup, DB schema etc.