Suggestions for Large SaaS Project

I have a large SaaS application to write. So I considering my options. Any suggestions welcome, especially if you have used that technology.

  • Delphi with TMS Webcore and FNC
  • Delphi with Thinfinity
  • Delphi with Unigui
  • Anything else out there ?

Large SaaS doesn’t really tell us much (single tenant, multi-tenant? number of users or size of the application).

Sad to say it, but I would not even consider delphi for something like that - for a number of reasons.

  1. Hosting - delphi is realy limited to windows, the linux compiler is very immature imho - I woudln’t use it in production. Windows hosting is prohibitively expensive to do at scale - whereas linux hosting is as cheap as it gets.

  2. Lack of frameworks and experience to draw on. The only framework that comes to mind is mormot - haven’t used it but have heard plenty of people say it has a steep learning curve.

Contrast that with .net or ruby or other eco systems - on which most saas software is built. There is plenty of information out there on how to go about creating saas systems. I’m sure you have already done this, but googling delphi saas etc doesn’t inspire a lot of confidence imho.

My preference would be .net (netcore) - but that’s because I’ve allready built several systems (including our ci server product) with it and am comfortable with it. These forums are build with ruby on rails - which is very common in large scale saas environments.

And then you still have to choose a db backend, front end framework, auth framework etc… good luck!

As many here know, I am the developer of TMS XData (backend framework for Delphi).

XData is really full-featured. Learning curve is smooth. And I eat my own dog food, I have two running SaaS applications in production using TMS XData in backend and TMS Web Core in frontend: https://www.validadortiss.com.br and https://www.nuvemfiscal.com.br (site under work, API doc is here: API Nuvem Fiscal).

Like an egg and chicken situation, I’ve chosen XData for both SaaS because it has the features I needed and of course I have full control over it, but also we’ve implemented features in XData because the SaaS needed it.

The SaaS are multi tenant (XData has builtin multi-tenancy mechanisms), and the authentication system is also 100% using the upcoming TMS XAuth framework, among other nice features (Swagger documentation, etc.)

For now using Windows on AWS due to reasons @vincent explained (still do not 100% trust Linux compiler) but as XData is imho very optimized to be lightweight in both CPU and memory usage, the costs are low. It doesn’t matter if Windows is double the price of Linux machine, if it costs me 30 bucks a month, Linux would save me 15 bucks. That’s irrelevant. And only XData uses Windows, all the other parts of the architecture (edge proxy, databases, additional services) are on Linux anyway.

I would say that currently, the main disadvantage of using Delphi instead of the other proposed solutions is the difficulty of finding developers. If you intend to have a big team and need many developers, it will be harder for you to find Delphi developers to help you in your journey, compared to developers for other platforms (namely C# or NodeJS). But if you already have a team with existing Delphi knowledge and you consider that team will stay with you and will be enough to maintain your application, I think it’s a choice as good as the other ones.

Hi Rohil.
As Vincent suggested earlier, mormot is indeed a non-trivial learning curve.
However, it’s an “Enterprise” grade open-source product (compiles for Windows or Linux hosts and supports Delph or Free Pascal), with excellent security and scalability (vastly in excess of any other Pascal product I’ve ever seen). So, depending on your application’s requirements it may be worth a look (security is of top most importance to me today and if you keep up to date with that topic you’ll find that solutions that used to be considered secure aren’t very secure any more in the web space).

Did a quick mormot search regarding SaaS and found this - might be worth a look.

https://synopse.info/forum/viewtopic.php?id=5496

For a pascal web front end development tooI use Elevate Web Builder and there’s a lot to like about it. It has a Delphi like form designer and code editor and lots of 3’rd party components (grids treeview, and edit controls etc).
You can see some 3’rd party EWB tools here :

https://erickengelke.com/nice/samples.html

You can find Elevate Web Builder here (there’s a trial version available on that page) :
https://www.elevatesoft.com/products?category=ewb&type=web
and demo’s on YouTube

Thanks Wagner. If I dont use XData, then I could use FMX to compile the backend to linux. I have always preferred linux servers (and desktop). But have been forced to use Windows. I have idiotic and endless dramas with Windows. I am now considering PWA. Then all the grunt is at the user end and they can still use it to a limited degree when internet is down. Am I correct in thinking that all the FNC stuff will convert to javascript/html/css ?

Hi Vincent,

The project is in its very early stages of negotiation so I don’t want to expose it. Its in the medical field - with the usual, patient records, medical data, integration to IOT.

I have used Unigui and Thinfinity, but I am not a fan of windows, especially for servers. And they have licenses per user, money that could be going in our pockets instead.

I have been using Delphi since Turbo pascal 3, so most of the stuff just works the first time. I am also fairly conversant with PHP, but that would be too slow.

In the end, reduced development time, and easy to bug-fix trumps other things. I am willing to learn other things. But I have learnt in the past that I cant rely on other peoples opinions about their tools.
Because its based on their experiences, which are different to mine.

One major incident comes to mind. We were using lansmart for networking and everyone kept telling me netware was the way to go. So, we convinced one of the clients to fork out for it. And installed our application. The client was very unhappy because invoice printing was taking 30 seconds instead of 2-3. When I asked my friends, why they hadnt told me this. The reply was. “Waiting for printing is not a problem”. Luckily the week after, Novell released an upgrade to speed it to 6-12 seconds, which was bearable.

I keep hearing a lot about React. But it seems to be just javascript, in which case I may as well use TMS Webcore. I have played with TMS Webcore. I wrote one of my websites in it and have a primitive PWA running.

Thanks Robert,

I had a look at the webpages. I will certainly have a deeper look at it. I think that components available may be the final voters, especially the calendar and graphing. And of course, you are correct about security.

I don’t see a relation between XData and FMX in Linux? XData does support Linux, via Indy or WebBroker. But as a side comment, even though Linux itself is considered “better” than Windows for server, it’s a very recent platform in Delphi ecosystem. The compiler, RTL, 3rd party tools, all that is more recent and has more issues that, imho, makes “Delphi on Linux” a much less reliable server platform then “Delphi on Windows” (and more specifically, “XData on Windows”).

Yes, FNC in Web Core translates to JS/HTML/CSS.

1 Like