Happy Friday QuickBox, It’s time for another development update!
Framework
This week marked the completion of the system applications and the beginning of the software conversion. System script size and file count has been reduced significantly. We’ve gone from 82 files to only 8! We also have a timeframe for pushing v3 to our beta testers!
Script handling
82 files to 8 for handling the system commands seems a bit crazy – however, I’ve completely redesigned how the qb command runs scripts. Let’s quickly compare how v2 and v3 handle the qb install software
command:
QuickBox v2
qb
checks how it is invoked (via CLI or Web).qb
parses the positional parameters based on its invocation (Multiple if statements based on positional ordering).qb
passes the first positional (install) through a case statement.- The case statement then runs a specified function based on what it is matched against – (install_function) in this example.
install_function
then re-checks the positional parameters and re-orders them based on the requested software.install_function
loads a new script (qbAppHandler).qbAppHandler
re-orders the positionals based on software again.qbAppHanlder
invokes the requested software script.- The software script parses the positionals into variables.
- The software script begins!
As you can see there’s a lot of steps and files for a relatively straight forward command. This is mainly due to the requirement of positionals being in a specific order. While the processing time of the above is relatively small…it’s not exactly what we would call optimized.
QuickBox v3
qb
parses input via a mixture of positional parameters and flags.qb
passes the first positional (install) through a case statement.- The case statement then loads the requested software script – passing existing positional and flags via an array.
- The software script parses the array into the required variables.
- The software script begins!
The use of arrays allows the removing additional handlers and negates the need to order arguments in fixed locations.
Dashboard
@JMSolo 👑 has been busy working with the optimizations I mentioned in the last update, and even better he’s pushed the changes to QuickBox v2!
Ajax
Last week an issue was identified with some Ajax scripts locking the database. JM has gone through those this week and nuked a lot of those scripts. Previously multiple ajax scripts were running server checks and assigning variables every second. However, most of these have now been removed with variables being assigned on page load (As there wasn’t a real need for them to be dynamically set).
The Ajax scripts have also had their invocation time tuned to be a lot less aggressive. As a result, you should now notice a snappier dashboard.
File cleanup
JM has also cleaned up various deprecated files. Some of these were being loaded by the dashboard…but without doing anything. Those have also been removed!
As these changes were released without a version increase you can grab them via a qb fix version
command
Beta-testing
We’re currently aiming to push v3 to our @⚠️Beta Squad towards the end of April October 2021 (timeframe updated to reflect brief hold on development as many adjustments needed to be made to the current v2 iteration; application updates etc). While we imagine v3 will be finished before then, we want to release a product that works straight out of the box, so there’ll be more time testing this release than we’ve done before.
And that’s all folks! 💖