Healt of the project
Written the .
It has been a long time since the last blog post and several things changed. In good.
2 millions downloads
First, the project has reached the noticeable milestone of 2 millions downloads. We can attach different meaning to it but the most important one is the progression over the time.
The progression is exponential!
When making open source softwares, this is hardly difficult to know if people are using it or not. Even worse, to know who is using it. If nobody knocks on the IRC door to tell us its company, for instance, is using Hoa, we have no way to deduce it. The number of downloads provides a partial answer: We know that more and more people are using it due to the exponential growth of the downloads. We still do not know who is behind these downloads though. Please, tell us 😄!
For the fun, here is the graph of the Github activity:
We are about to reach 1500 stargazers. Feel free to follow us!
Since many months, we are working hard on stabilizing all the existing libraries over creating new ones. This decision has been taken during the Hoa Apex 2nd edition (the community event) and renewed during the 3rd edition. “Stabilizing” means migrating test suites, enhancing test suites, writing documentation etc. The goal is to have an even better quality and safety. Performances are also targeted.
Hoa\Graph library has been finalized and
released under the 1.16.04.06 snapshot. The API is now stable and new
iterators have been introduced. Thus, the classical
iterators allow respectively to traverse a graph with a depth-first or
breadth-first strategy. They come together with the
iterators to traverse a graph backward.
Hoa\Acl library has been finalized too
and released under the 1.16.04.06 snapshot. The API is now stable. It is
possible to have thinner queries on an ACL instance because it has always
been based on the
Hoa\Graph library but it now takes advantage
of the new
Hoa\Graph iterators to save CPU and memory, and thus
to provide better performances. Thanks to the
interface, it is possible to define very thin queries, and even to use
Hoa\Ruler library to define your own ACL rules! Take a
look at the
file to get more information.
Hoa\Socket library has been also finalized
and released under the 1.16.01.15 snapshot but two major snapshots have
been released since then, respectively 1.16.02.10 and 1.16.02.17. The API is
now stable, the quality has been enhanced and the library is able to
handle many more connections at the same time. The safety regarding socket
disconnection errors is better in a high concurrency
context (i.e. more than 500 concurrent connections). New TLS
constants have been introduced too. Finally, a nice feature is the ability
to define socket wrappers, like
irc://, which let me transition to the next important
Hoa\Websocket library has a new feature based on the
socket wrapper. It is now possible to use
wss:// URLs, respectively for a non-secure and a secure
connection, as a socket URL. Thus, to start a secure WebSocket connection
over TLS, one might simply write:
$websocket = new Hoa\Websocket\Server( new Hoa\Socket\Server('wss://127.0.0.1:443') );
All the TLS configuration will be done automatically, which is pretty comfortable from the developer point of view.
Hoa\Database library has received new patches to
introduce iterators over result sets. It takes advantage of the database
cursor to only load the needed data in the application, mainly saving
memory. This is the result of almost 1 year of work (see
Pull Request #18
on Github). The API is pretty straighforward and very comprehensive at
the end: Given a result set, you define a direction
FROM_END) and a fetching style
etc.) and an iterator is automatically built for you. A simple
foreach loop will let you go through your database
result. This is not stable yet for all the database drivers, but the API is
stable and we are fixing bugs when they are found. Testing in progress.
As you might foresee, this work has required several deep thinking on
Hoa\Iterator library API.
That's all for the important releases.
Quality, tests and numbers!
We said we are focused on the quality. Only for the new finalized libraries, here are the numbers:
Hoa\Graph: 9 new test suites, which represent 66 test cases, be 157 assertions,
Hoa\Acl, 8 new test suites, which represent 82 test cases, be 369 assertions,
Hoa\Socket, 10 new test suites, which represent 157 test cases, be 975 assertions.
Total: 27 new test suites, 305 new test cases, be 1501 new assertions, only for the new finalized libraries. Not bad!
A special note about
Hoa\Socket test suites. We have been
able to test advanced and complicated
scenarios like unexpected disconnections, broken pipes, broadcast
over not completely connected sockets (for instance if a handshake is
required) etc. These extreme scenarios are where most of the bugs
hide and this is crucial to be able to represent and reproduce
them. This is especially possible thanks to
atoum, the test framework under
Board and tasks
In January, we got more than 90 issues and PR opened in Hoa's libraries repositories. We decided to lower this number to 40 before May. We are in the middle of May and we have 41 issues and PR opened (see Hoa's central board). This is not bad at all! Considering we have constantly new issues and PR, we have closed more than 200 issues and PR in 5 months!
We are going to start a new blog series called “This Week in Hoa”. Every week we have between 5 and 20 issues and PR closed and it would be good to communicate about it. Stay tuned for the first episode!
As always, this work would have not been possible without the dedication of an active community. The project is discreet and does not make the “buzz”, but after more than 5 active years, it is still here and widely used like never before. More and more projects are using it and we hope to get back to you with huge news soon.
Thank you all!