ANN: DelphiMVCFramework 3.0 beta

In the last months some of the great 9 DelphiMVCFramework contributors from all over the world, have worked hard to release the version 3.0. Now it is ready to be tested!


DelphiMVCFramework is one of the most popular RESTful framework for Delphi, so any change has been accurately considered and also its impact on the current 2.x projects has been take in consideration. There are a lot of new core features that will make even more easy to work on (and with) your beloved RESTful framework. Also, all these changes will make the framework even more flexible regarding the serializators even for custom types (yes, now you can register your custom serializer for your data types). Also, JSON is no more the only “built-in” supported format. Well, now JSON is the only format, but now is really easy to add to the serializers registry a brand new serializer which serialize in XML, YAML, BSON, CSV etc. The serializers are recicled between requests to get the maximum performances.

Considering that some often-used methods have been removed or refactored, we tracked all the breacking changes in a document, so that you can evaluate the impact that the new version may have on your projects.

Here the content of the document as it is today (the latest version is available here).

DelphiMVCFramework 3.0.0 breaking changes

  • RenderListAsProperty has been removed from TMVCController. You can set such kind of specialized serializations in your custom base controller.
  • RenderJSONArrayAsProperty has been removed from TMVCController. You can set such kind of specialized serializations in your custom base controller.
  • Render has been removed from TMVCController (was deprecated).
  • Render(TJSONValue) has been removed from TMVCController (use Render(TObject)).
  • Trying to deserialize a TJSONNull the target instance will not be freed anymore (consistency with serialize).
  • Context.Request.BodyAsJSONObject dosen’t exist any more. Use BodyAs or the following pattern to migrate.
JSON := TJSONObject.ParseJSONValue(Context.Request.Body) as TJSONObject;
  if not Assigned(JSON) then
    raise EMVCException.Create('Invalid JSON');
  // do something here
  • TMVCConfigKey moved to unit MVCFramework.Commons.
  • TMVCMimeType was renamed to TMVCMediaType.
  • TMVCController.Render (no parameter method) do not exist anymore. If the return is a ResponseStream, use the RenderResponseStream.
  • TMVCController.PushJSONToView was renamed to PushToView and Removed SystemJSON dependency, use the ToJSON method if necessary.

As you can see, the breaking changes are very few and there are very low probabilities that will require you more than 10 minutes to fix them even in a big DelphiMVCFramework 2.x project. I did it for our biggest projects, and 10 minutes are largely over-estimated.

Beta Tests

For the next weeks/months the 3.0 beta version will be available for testing. If no major bugs will be found, the 3.0 will be merged in the main branch.

To test the 3.0 beta version you have to checkout the “pluggable_mapper” branch (clone the repo if you didn’t already, and then checkout the “pluggable_mapper” branch).

You can go back to the 2.1.6 (carbon) when you finished the test. There is no reason to be afraid about the changes. They are really in the deep layers and should not affect the “normal” services.

Happy testing!


Considering all the help requests coming from the users (and the fact that facebook is not permitted in some companies) we at bit Time Professionals (the company which lead the development of DelphiMVCFramework and other open source Delphi projects) decided to create a specific community and leave the facebook group only for announces and polls.

Some of bit Time Professionals Open Source Projects
Some of bit Time Professionals Open Source Projects

So, if you need help about DelphiMVCFramework, LoggerPro, Delphi Redis Client, columbusegg4delphi, Delphi Event Bus, Delphi STOMP client, you can go to the bit Time Professionals Community and ask there. If you want to support the projects or you need fast responses, you can also subscribe to the “professional support” group (with a very low fee) and your requests will get priority upon the other by our engineers (which likely wrote 80% of the framework code). When possibile, the support team will send you a specific sample written specifically to show you how to solve your problem. The “professional” groups will be available soon. If you are interested about prices or other things related to the professional support, ask to professionals(at)bittime(dot)it.

Currently is just started, go to subscribe now!



Echoes From The Past: Message Master For Delphi a.k.a. MM4D

Some years ago, at the Delphi 6/7 timeframe I was working on a client/server program with c.a. 400 forms and 200 units. At that time I needed a simple way to localize in Italian (in primis) and in other languages, all the  standard dialogs (ShowMessage, InputBox, InputQuery etc.). Moreover, I would have liked to give a unique style to them. In addition, I needed to localize that dialogs. Moreover I needed a simple way to show a program of a background operation using a not modal dialog with a simple pattern like the following:

  ShowStatusPos(STATUS_CAPTION, Point(50, 50), True);
    for i := 1 to 100 do
      SetupQuery(LMyDataset, i);
      while not LMyDataset.Eof do
        //do something
        UpdateStatus(i, Format(STATUS_CAPTION + ' %2d%%', [i]));

So, after some tests I wrote Message Master for Delphi. MM4D is a smal library which supports all of these features, or at least these features were supported at that time. Indeed, since then I saw many (really many) 3rd-party Delphi/C++Builder written programs which actually use MM4D. However, since then I didn’t supported that library anymore. Now, more or less, 15 years after, a user wrote to my about MM4D support in Delphi 10 Seattle. So, I decided to update the code to let it compile on Delphi 10 Seattle. So, now it is currently supported (even if I dont plan to improve it in any way in the short term). However if someone use it or want to use it and update/upgrade/improve, here’s the github reporitories. I hope I have done something good for all the old time users.

Message Master For Delphi

In the repositories there is a demo to show all the features of MM4D and there is also a small tool called UnitsAdded.exe which can be used to add the MM4D features to a project automatically (search for Dialogs.pas and, if exists, add MessDlgs after it).
MM4Delphi uses the good XiControls (included). So, still thank you to Eugene Genev for his XiControls.

DelphiMVCFramework at the 10° Delphi Meetup in Dresden , Germany

Mathias Pannier did a nice talk at the 10° Delphi Meetup in Dresden, Germany. You can find his review with the slide (both in english) in his blog.

Mathias contacted me about some specific questions the audience did.

Here’s my replies.

  • Is it possible to have a [MapperJSONSer(‘first_name’)] attribute for DataSet fields?
    • Not currently. It quite simple to implement but now this feature is available only for objects using RTTI attributes. Maybe in the near future this will be extended also to dataset serialition.
  • Is it possible to implement a custom renderer for example for xml output?
    • Sure! DMVCFramework is really opened to extensions. You can implement renders for every format you like, you are not tied to the built in.
  • Which Delphi edition is required? Starter, Professional, Enterprise, Ultimate?
    • DMVCFramework requires Professional version, because WebBroker is available from that version upwards.
  • Did You have any performance comparison?
    • Yes, it is not a complete test, is just a rough test between DMVCFramework and nodejs. DMVCFramework is not running into Apache or IIS, but is using its INDY default web server so the actual performance using a real webserver are far better.


I’m planning to do more tests and as sson I’ll do them, will be published here and in the facebook group.

  • What about documentation?
    • The framework is quite intuitive, so after read this presentation (ITDevCon2013) you can go though all the samples (which covers all the features) and you will be up&running in in an hour or so.
    • However, some volenterous users, are starting to work on a more structured documentation. There will be a markdown generated site which will provide tutorial and devguide.


Still thank you to all the people which actively partecipating in this project.


Stay tuned.



Migration to github for all my open source projects… done!

Since when Google announced that Google Code will be closed I did start to plan the migration of all my open source projects. Now, the migration is terminated.

In the next days, I’ll add all the contributors too, so that the development can go forward as usual.

These are the projects

  • DelphiMVCFramework
    • if you are reading my Delphi Cookbook, please use this new repository instead of the old SVN one, reported in the book.
  • DORM, the Delphi ORM
  • DelphiRedisClient
  • DelphiDIContainer
  • DelphiSTOMPClient

All the repositories are available on my personal github page and, as usual all contributions are welcome.



ITDevCon 2014, Call4Papers

ITDevCon 2014
ITDevCon 2014

Dear potential ITDevCon speaker,

As every year, I’m building the agenda for next ITDevCon that will be held next october 23th, 24th in Milan (Italy), in a new location.

This will be the 6th edition ( we’re getting conference experts J )

The call for papers are officially open right now, so if you want to propose some speeches, I’ll be glad to see it.

As usual, for the Call4Paper I need:

  • Title (for every talk)
  • Abstract (for every talk)
  • Difficulty level (for every talk. Difficulty level is a scale from 1 to 3 with the following mean: introduction, intermediate, advanced)
  • Speaker’s photo
  • Speaker’s profile

I’m looking forward to your proposal. The call4papers ends at Aug 31st, 2014 but if you have *VERY* interesting topic to propose, propose it… I’ll try to arrange the schedule and fit it in the agenda.

Send your proposal to call4paper(at)

Proposals will be evaluated and the speakers will be contacted ASAP.

This year topics will be the following:


  • What’s new in the latest Delphi versions

  • FireMonkey platform

  • MacOSX development

  • Android development

  • iOS development

  • Windows development

  • Mobile development (Android+iOS)

  • Develop UIs for different devices (smartphones, tablets, TV, watch etc)

  • BaaS integrations

  • LiveBindings ®

  • Delphi best practices

  • Design Patterns

  • DataSnap

  • DelphiMVCFramework

  • Arduino e/o Raspberry Pi

  • Web Application with Delphi

  • TDD and Unit Tests

  • Agile methodologies

  • ORM and other data access patterns

  • Using NoSQL databases (even to speed up your VCL software)

  • FireDAC

  • UI, UX, optimization for mobile and desktop


  • Real use cases for extended RTTI, Generics e AnonMethods

  • RESTful interfaces design and development

  • Architectures

Target audience

  • Software architects
  • Software developers
  • Project managers
  • IT managers
  • Trainers

The conference web site is (2014 version is still under construction).

Do you want to see a particular topic or have a suggestion for ITDevCon2014? Let me know

Thanks and see you at ITDevCon 2014.

March 2014 news about “DelphiMVCFramework”

In the last months DMVCFramework has been used in many projects. Some fixes and some new features has been added.

Tomorrow will start the 4th training from the Jan 1st 2014 on DMVCFramework… WOW!

The best selling training is “Developing Web Client applications using AngularJS and DelphiMVCFramework” (a slightly modified version of this classic training

Tomorrow the training will be in italian, however is very popular also the english version.

However, back to the project, there is a first attempt to add some documentations on the project.

So far there are a lot of samples and all the unit tests, however there was a lack on the “classic” documentations. So, I’m happy to say that in the SVN trunk you can find my presentation held at the last ITDevCon2013 in Verona, IT.

If you are using DMVC framework I’ll be glad to have 2 lines of description about your project (numbers not functionalities insights) to put a success case page on the project website.

Here’s the direct link to the documentations:

This is the main DelphiMVCFramework project website:

Stay tuned

DelphiMVCFramework is now Open Source!


Yes, just after 1 year of development, and a couple of big projects developed with it, the DelphiMVCFramework has been published as OpenSource.

The project is on google code svn

I’ll talk about it at ITDevCon2013 (

In the trunk there are many samples and I’m planning to put many others.

Main DMVCFramework features

  • RESTful (RMM Level 3) compliant
  • Server side generated pages using eLua (Embedded Lua)
  • Messaging extension using STOMP (tested with Apache Apollo and Apache ActiveMQ)
  • Can be used in load balanced environment using memcached (
  • Fancy URL with parameter mappings
  • Integrated RESTClient
  • Works with XE4 and XE5 (tested, but should works also on XE3 and XE2)
  • Experimental support for IOCP
  • Simple, but very very simple, to use…

It contains also a lot of indipendent code that can be used in other kind of projects.

These are the most notable:

  • Mapper (convert JSON <=> Object, ObjectList <=> JSONArray, ObjectLists <=> DataSets)
  • LuaBinding (integrate Lua script into Delphi native code)
  • LuaTextFilter (convert eLua into plain Lua executable script just like JSP)
Currently DMVCFramework use Embarcadero WebBroker framework, but is not tied to it. I’m working on a version that use IOCP (that is 10 times faster than plain WebBroker) and other web libraries for Delphi.
Code is enough stable and is already used in big production system.
There are a couple of bugs that affect WebBroker and so, DMVCFramework.
In our system, I’ve applied some patches to solve these problems. If you need those patches, ask me (I cannot publish the full code because it is Embarcadero licensed code).
The bugs are:
And another bug that affect also DataSnap and TIdHTTPWebBrokerBridge based projects.
Code is tested on XE4 and XE5 but should works also on XE3 and XE2.

#3 “dorm, the Delphi ORM” bullettin

A veeery log time after the last dorm bullettin. But, as usual, I was been very busy on some projects (not only dorm) and the time goes by…

However, dorm has been extended, polished and improved over the last few months. Has been used in a couple other projects in my compoany (

So, here’s a small list of improvements and some other tips:

– ObjStatus support (more to come)

– TdormSession non-visual component. Check “samplesDelphiXE3TdormSession_Sample01formSample1.dproj”

– dorm is now in Continuous Integration (not for all supported databases, but I’m improving that)

– I’m integrating a JSON/DataSet/ObjectList mapper into dorm to be used in RESTful DataSnap/WebBroker (or not) http servers. More to come.

– Delphi XE3 Support

– Removes SuperObject as external lib. Now dorm uses an internal patched version.

– More demos added (Most noticeably id under “samplesDelphiXE3TODOManagerTODOManager.dproj”)

– Added samples using the new Visual LiveBinding feature in Delphi XE3

About the ObjSupport it’s worth to spend some words about it.

Since the beginning, dorm is completely “perisstence ignorant”: In other words, you can persiste what you want, you dont need to inherit from a specific class or implement a specific interface. This is a very powerful feature but make some internal dorm mechanism very complex. But I really WANT to have this feature, so I’ve added another “mode” to work with dorm: ObjStatus.

If dorm engine finds a property nemed “ObjStatus” of a specific type, it’ll use that property to track the object status (Clean, Dirty, Deleted).

In this way, I gained a *LOT* of speed compared to the prior version regarding persistence of complex objects graph.


procedure DoSomethingOnPersonByID(ID: Integer);
  p: TPerson;
	p := Session.Load(ID);
	p.FirstName := 'Daniele';
	p.Car.Model := 'Civic';
	p.Phones.Add(TPhone.Create('555-555-33-22', 'Home'))
	Session.Persist(p); //generates insert, update, delete for related objects too

As Usual you can find the project code here

dorm, “The Delphi ORM” and Spring for Delphi Framework

Great news for all the dorm and Spring4D users!

As you probably know, finally has been announced the official Spring framework for Delphi.

There is a lot of good technology in Spring4D!

So, I’m glad to announce that in a future version (hopefully, the next one) dorm, “The Delphi ORM” will use Spring4D and will become the ORM part of Spring4D.

So, dorm will be part of the Spring4D framework.

More info to come, so stay tuned.

Delphi MVC Web Framework – “Hello World”

This is the first “Hello World” for my Delphi MVC Web Framework.

program DelphiMVCWebFramework;


  MVCEngine in 'MVCEngine.pas',
  BaseController in 'BaseController.pas';

  mvc: TWebMVCEngine;
  mvc := TWebMVCEngine.Create;
  mvc.AddRoute('/', procedure(Context: TWebContext)
      Context.Write('Hello World');

Features list (some of them are in the internal roadmap)

  • Completely MVC
  • Addressable with servername/controllername/actionname?par1&par2
  • Addressable with servername/controllername/actionname/par1/par2
  • Can also use anonymous methods as actions for very simple app (in the sample)
  • Really RESTful (Level 3 of the Richardson Maturity Model)
  • Fully integrable into WebBroker and DataSnap
  • Supports multiple resource rapresentations
  • Completely customizable routing using internal formatting or regex
  • Inspired to ASP.NET, Sinatra, Java Spring MVC, Java Restlet
  • Scriptable views support (Pascal, Razor, Lua)
  • Component based
  • Session support
  • ORM support using dorm
  • Classic TDataSet support
  • State server to support real loadbalancing using reverse proxy
  • Can be deployed as standalone (in the example), ISAPI dll and Windows Service
  • Fully support https
  • More to come…
  • This framework is still under development.

    Are you interested in? 🙂


    The project is open source and you can fint it here