Click or drag to resize

Activsoft's engine is in constant development and evolution since 1999, starting as a simple web framework - though with great ambitions - to being a cross platform application development framework. This topic tells you the story behind its creation and development.

Genesis (1999-2001)

When we started making websites back in 1999, there was no tool to cleanly separate the data management layer and the presentation layer; jsp didn't exist, ASP was a happy mix of calls to ActiveX objects - mainly ADO - and HTML tags, as was PHP (PHP mostly still is, but this is another story). It seemed particularly important to us since we were a developer-only shop with very little skills in the presentation layer.

Luckily, we stumbled upon the first version of Microsoft's XSLT implementation (MSXML 2.5) which was based on a release candidate of the first XSLT version. The choice was set: XML as a data format and XSLT as a transformation tool to generate HTML content, and the first version would be based on IIS / ASP.

Then, we wondered how we would generate the XML; since most of the work to create of dynamic web pages was to extract data from a database, we created an ActiveX that read SQL requests from a configuration table stored in the database, executed them, and outputted the content in XML with a fixed format based on column names and a tag name for each request. We included a way to make references in these SQL requests to parameters sent to the server by the user's web browser, and a pagination system to return only the data needed to display a fixed length page of a search result.

To store new data in the database, we added a similar system for INSERT / UPDATE / DELETE SQL requests with the same parameter injection format. We rounded up the first version with an ActiveX to track sessions and viewed pages, to create web sites statistics. The whole library was created while programming a fully featured website for a french television network, Voyage, with around 80 different templates, in three months. There were lots of very shorts nights during that span, but we realized it had been worth it when we were able to create our second website, though considerably simpler, in no more than two weeks, using the exact same tools.

Consolidation (2001-2006)

In the following years, we could validate that our technical choices were the right ones, by creating different kind of websites with the same model: e commerce, back offices, content, etc. We were also able to adapt the same programming model to the Java world, on the request of a client who wanted to be eventually able to have its teams maintain the application in case he didn't want to work with us anymore. Once the engine was translated, a 30 template website was migrated from IIS / ASP / SQL Server to Apache Tomcat / Java / Oracle in less than one day. The PHP version followed shortly. Eventually, we created a first .NET version, which marked the fourth version of the engine. We added several features to the core model:

  • base interfaces for easy extensibility (IExtractor, IAction, etc.)

  • new output formats: PDF using FOP from the command line, CSV, Excel, etc.

  • a web service tool set based on ASMX web services, outputting the XML using XML / XSLT combination

XSLT extension model (2007-2013)

As we were making more and more web applications and back offices, we recognized the need to add a component system akin to facelets or ASP.NET user controls. We first tried a template based approach, but it was very cumbersome for developers and not very efficient performance wise.

To avoid these two pitfalls, ideally, we wanted to create tag libraries integrated in XSLT, but at first we shunned this idea since we didn't see how these tags could be interpreted except by the XSLT engine itself, and it seemed too complicated to create or extend an existing XSLT engine.

The right idea was to preprocess the XSLT files to transform our tags into standard XSLT / XHTML / Javascript code to be executed by the standard XSLT engine; this approach could be integrated into any platform with almost no change (be it ASP.NET, J2EE or PHP), produced optimized code that could be cached by the XSLT engine, and was the easiest to use for the developers.

This approach considerably accelerated the development of our web applications, and was successfully applied to other tasks: UI internationalization using the standard xml:lang attribute, authorization, etc.

Mobile development

We began programming mobile applications by the end of the 2000s, for the older Windows Mobile versions, and then for Android. Quickly, we came to realize that the mobile OS war was here to last, and we didn't want to be one of its collateral damages. Since we were able to create a common programming model on the server side, we wondered whether we could use a variation of this model for mobile development.

The idea was to create some kind of server inside the tablet or smart phone that could work locally as IIS or Apache worked remotely through sockets. To do this, we needed for each platform:

  • a working XSLT engine

  • a common configuration system

  • an extension mechanism to create custom actions and extractors

  • an SQL database

  • a way to redirect web requests made from the local web browser control towards our server - including AJAX requests

The first three were provided to us by the Xamarin tools; we could use the same code base in C# for each target platform. The fourth is for better or worse SQLite. The fifth is heavily dependent on the platform, but once we could set it for each, we never had to look back. Creating a disconnected mobile application is now as easy as creating a web application and a synchronization web service client in C#.