We’re nearing the end of the year but with 191 merged pull requests in the last two weeks of November, development was nowhere near slow. For this report we have pulled together activities from development mailing lists, blogs, coding work and everything else community members share with us. Tips are very much welcome! Ping Jos with your input.
This has been a very busy period for the ownCloud community. In the area of code, the biggest items during the last weeks of November were massive API work and refactoring in Core and the new QR share and Polls apps as well as big upcoming changes in Passman. And you should not have missed the big announcement of the open sourcing of the iOS app, a call for help to clean up bugs in ownCloud and the announcement of ownCloud event resources! Read on to learn more details on these and all other happenings in the ownCloud universe.
You can read a report on the first half of November here.
Core had a focus on API improvements and cleanups, while the Apps moved forward with a variety of features including a rewrite of the Bookmarks app, gif playing in the Gallery and much coming in the Passman app.
With 93 PR’s in core, a strong focus in this period was on cleaning up, refactoring and improving the API ownCloud offers to App developers. A few performance improvements and many bugfixes made it in as well. But let’s start with some feature, security and performance improvements.
- Previews are cleaned up deleted when a folder is removed
- Adam Williamson contributed an update of the Google Drive external storage app to the latest version of the google API PHP client library
- An improvement to SQLite handling can lead to up to three times better performance on small ownCloud instances
- LDAP got unified count filters and introduced display name attribute detection, improving compatibility with various LDAP setups
- By checking for XMLWriter class, a php module not installed on all systems, ownCloud can warn users. The documentation has also been adjusted to mention this
- For trusted domains, the port check has been removed, fixing lots of small issues. Testing of this issue is still ongoing to make sure it works properly and safely
- That the logic to show the right user the right shares can be complicated is shown in this PR, fixing the first half of this issue
- A change was introduced to make sure ownCloud wouldn’t try to rotate TIFF files in the thumbnail handling code. This would be needed for a performance improvement in thumbnail handling which got unfortunately orphaned. If you’re interested in further hacking on this to speed up showing files with thumbnails, checkout this pull request!
- Thanks to this fix user management can now properly search in groups as well as users
- Users will now get a warning about the dangers of password resetting when their files are encrypted and in the shared files list, the delete button is no longer visible to avoid the confusion with unsharing
- To improve security and privacy protection of ownCloud, this PR adds the OCS API header by default to all jQuery AJAX requests done from oC JS to prevent being the cookies re-used from another domain
- phpass was replaced with the new Hasher interface. Developers were notified by mail
- Improved session handling makes public sharing of files when using the encryption app more robust and more session handling improvements were merged here
- As another privacy improvement, this PR makes sure ownCloud doesn’t disclose the relative directory path for single shared files of users
Below a summary of the changes and improvements to the ownCloud API in the last weeks of November.
- Work on dependency handling for Apps is in progress. An xml parser was introduced (part two). This is loosely related to the improved app management merged earlier, and coming with ownCloud 8 as well
- The AppFramework gained the ability to modify and access cookies. The documentation was also taken care off
- Activities now can have priorities, making it possible for more apps to reuse them. Some needed cleanup followed. The activity manager was also modified to deal with the new reality
- It is now possible to override the route name generation, thanks to this PR. But with this discussion, Raydiation is opening «another Pandora’s box«, according to DeepDiver1975
- There is now a public interface for enabling/disabling apps, prompting a ticket to track progress on further refactoring of \OC_App
- The removal of name space permission constants, making all interfaces/classes autoloadable, autoloading preview providers and the move of constants from GET_TYPE to OC\Files finished the work started last year to turn all name space constants into class constants
Besides API improvements benefiting ownCloud App developers, there has been a lot of work done to clean up code and refactoring core ownCloud code to improve maintainability and stability and make room for further improvements.
- Deprecation of
\OC::$sessionresulted in work in a variety of areas but it has now been removed and cleaned up
- Several more old API wrappers and calls were deprecated and oparoz got rid of deprecated switches in the command line client
- In preparation of a cleanup of I*Config classes, Morris replaced all static calls to OC_Config and OC_Preferences with calls to OCP\IConfig
- More cleanup work related to handling configuration was done with dropping OC_Preferences::getUsers and getApps and OC_Preferences refactoring
- Some legacy code was let go, a notification was send to the mailing list about this last PR. Code related to upgrading from ownCloud 6 to 7 disappeared as well. So did this and a dependency of some commands on an old config object was cleaned up as well
- As part of an effort to refactor shared storage (which is made possible thanks to the removal of the Shared folder in ownCloud 7), Jail and PermissionsMask storage wrappers were merged. This PR was central to this work that once fully finished will bring improved performance and more robust shared folder behavior
- More refactoring took place when DatabaseSetupException handling was fixed and a good look at the storage handling code kicked of some changes like this one
One PR highlighted: Dependency Injection and Performance
A small change, caching the results of available languages, makes page loading slightly faster. In the comments, MorrisJobke pointed out that Dependency Injection could get us similar gains for all static functions in ownCloud, giving a noticeable performance increase all over.
He explained this further on IRC.
Dependency injection is a software pattern which helps a developer to not repeatedly call some globally available code parts, but instead request what he needs in advance. These are then registered at a Dependency Injection Container. For example, you tell the code that you need: a User instance, a Database connection and a config object. This is looked up in the container, where it is also noted how these objects themselves are constructed (what dependencies they require) and once the object is instantiated, the container holds it. For every additional request for this object, it isn’t recreated, but the previously generated one is used, saving time! As noted in the pull request about caching the available languages, the function providing them was called 8 times while a page was generated. You can imagine that avoiding this decreases overhead significantly and could speed up page loading in ownCloud all over.
As an example, see mailsettingscontroller.php: these are the required dependencies
then see application.php: they are passed in there!
This all allows a step by step transition away from the static code that is still in core and could cause some weird side effects. From time to time I drop static classes and add instances to the dependency container.
If you find this interesting and would like to help speed up ownCloud, Morris and Lukas would be more than happy to help you get going. Ping them on IRC under ‘MorrisJobke’ and ‘AnybodyElse’ or mail the ownCloud devel mailing list and note you’d like to take on this challenge!
If you want to get involved in coding on ownCloud in this or other areas – check out this page!
The design of ownCloud is such that the apps are where most of the ‘cool stuff’ happens! The apps maintained in the ownCloud repository had over 60 pull requests merged. Some of the most interesting merges included:
- The Bookmarks app was rewritten and refactored for the App Framework thanks to the hard work of ganomi, who is now maintainer of the app
- Thanks to oparoz, the gallery now plays gifs when viewing them fullscreen
- morsik contributed to the Music app, adding info about authentication so users know that Ampache needs an APIkey rather than the ownCloud password and made sure the app returns the correct album count while wakeup removed obsolete languages
- The chat app added presence and synchronize roster with the contacts app so you connect to your Facebook account, your friends are listed in the side bar to chat with. Both changes where done by LEDfan
- nickel-chrome contributed automatic account creation to the Mozilla Sync app
- The contacts app progressed thanks to jbtbnl who fixed the trash can and hamburger icon size and ockham who made it possible to share contact groups
- The news app improved its dealing with some more websites
- In the Activity app, some cleanup work was done and a bug was fixed and code tests were added. The app now follows the users’ timezone
- The Android app mostly had small fixes and improvements
On apps.owncloud.com, we welcomed the QR share and Polls apps as well as updates to several existing entries. We also have an update on what is going on with the Passman app for you!
- The brand new QR Share allows you to generate a QR code for share links
- Also new is Polls, which lets you create a wide variety of public polls. Find the app on github – it already has had contributions from 5 different people and is moving fast!
- Imprint updated to 0.2.2, fixing a crash, cleaning up some code and introducing markdown support to complement the existing html and plain text
- The user_sql app, which lets you authenticate against an arbitrary SQL database, added support for Joomla 2.5.18+ encryption and a bugfix
- The youtube downloader updated to 0.4, improving performance and fixing some bugs
- Version 1.3 of the Large File Upload app removed dependencies for the App Framework and included some CSS fixes but the author notes that there is more work to be done there
- Old Menu bugfixed up to 0.2.1
- The files_clipboard app offers a minimal clipboard to move files between folders in the files app and was updated with some bug fixes
Passman author brantje mailed about the Passman password manager app he’s working on. A big update is coming «when it is ready», version 2.0.
This new release uses AngluarJS besides jQuery and introduces a series of improvements:
- Password Sharing
The idea behind this feature is to share passwords with other users or even groups and public links, with expiration based on either date or how many times the link was opened (making it suitable for sharing of one-time passwords). This is build with help from animalillo!
- OTP Generator
This can load a two-factor authentication QR code in passman and save this; and generates the OTP codes for login when needed. Brantje noted that this is useful when your phone battery is empty and you need to log in your Google account with 2-factor authentication – no need for a backup code thanks to Passman!
- A new and improved password generator
- Password strength indicator which gives an estimate for how long it takes to crack a password
- Password strength scanner can show you all weak passwords
- Support for removing custom fields and using custom icons
- Permanent removal
- Fast search
- support for the Activity app, showing
When an item expires; is shared; soft or hard deleted; and recovered
As you see, the new Passman brings large improvements. If you’re interested in helping out with coding or testing, check out the github repo!
Besides the emails referenced already, some interesting conversations from the development mailing list include:
- an email about the ownCloud release schedule and versioning changes
- A note from a contributor interested in developing client side encryption
- and a notification that a team of 5 developers is working on a Ubuntu Touch ownCloud app, code for which you can find on launchpad
You can join the discussions on the mailing list here.
Other ownCloud happenings
On Planet ownCloud, ownCloud contributor blogs are gathered. Blogs in this period include the big announcement of the open sourcing of the iOS app, a call for help to clean up bugs in ownCloud and the announcement of ownCloud event resources.
- The ownCloud iOS app source code is now available under the GPLv3
- Some ownCloud developers gave a very successful workshop at CERN
- The ownCloud developers asked for help with triaging and cleaning up bug reports and while December 5 is long gone, if you’re still willing to help, there is no reason not to!
- Jos asked what’s holding ownCloud back?
- If you want to organize meetups or go to events to represent ownCloud, we now got you covered with online and physical materials including presentation slides, flyers and posters. Find a calendar of ownCloud events on owncloud.org/events.
- Stathis wrote an informative blog about organizing a local community
Please note that if you’re an ownCloud contributor, you should get your blog aggregated on owncloud.org/news! Ping Jos with your RSS feed. And if you want to become part of the action but aren’t yet, check out our contribute page on owncloud.org to find out how to get involved and become part of the awesome that is ownCloud!