
We are pleased to announce the release of mORMot 2.1.
The download link is available on github.
The mORMot family is growing up.
2023-08-24
2023-08-24. Open Source › mORMot Framework
We are pleased to announce the release of mORMot 2.1.
The download link is available on github.
The mORMot family is growing up.
2022-02-15
2022-02-15. Open Source › mORMot Framework
The official release of mORMot 2 is around the edge. It may be the occasion to show some data persistence performance numbers, in respect to mORMot 1.
For the version 2 of our framework, its ORM feature has been enhanced and tuned in several aspects: REST routing optimization, ORM/JSON serialization, and in-memory and SQL engines tuning.
Numbers are talking. You could compare with any other solution, and compile and run the tests by yourself for both framework, and see how it goes on your own computer or server.
In a nutshell, we almost reach 1 million inserts per second on SQLite3, and are above the million inserts in our in-memory engine. Reading speed is 1.2 million and 1.7 million respectively. From the object to the storage, and back. And forcing AES-CTR encryption on disk almost don't change anything. Now we are talking.
2021-08-17
2021-08-17. Open Source › mORMot Framework
Last weeks, we have enhanced mORMot support to one of the more powerful AARM64 CPU available: the Ampere Altra CPU, as made available on the Oracle Cloud Infrastructure.
Long story short, this is an amazing hardware to run on server side, with performance close to what Intel/AMD offers, but with almost linear multi-core scalability. The FPC compiler is able to run good code on it, and our mORMot 2 library is able to use the hardware accelerated opcodes for AES, SHA2, and crc32/crc32c.
2020-06-05
2020-06-05. Open Source › mORMot Framework
About latest SQlite3 3.32.xxx there is a big problem with codecs.
Critical changes to the public SQLite code were introduced on Feb 7, 2020: “Simplify the code by removing the unsupported and undocumented SQLITE_HAS_CODEC compile-time option”. With the release of SQLite version 3.32.0 on May 22, 2020 these changes finally took officially effect, although they weren't officially announced.
As a sad and unexpected consequence, we are NOT ANY MORE able to compile the new SQlite3 amalgamation with our encryption patch.
2020-03-03
2020-03-03. Open Source › mORMot Framework
The more I think of it, the more I am convinced it is time to change how the
framework is versioned.
We have version 1.18 since years... difficult to follow... time to upgrade!
I would like to upgrade mORMot to version 2 - with a major
refactoring.
2019-09-21
2019-09-21. Open Source › mORMot Framework
A long-awaited feature was the ability to create stand-alone mORMot Win64 applications via Delphi, with no external sqlite3-64.dll required.
It is now available, with proper integration, and encryption is working!
2018-03-12
2018-03-12. Open Source › mORMot Framework
We just committed a deep refactoring of the SynSQlite3Static.pas unit - and all units using static linking for FPC. It also includes a new encryption format for SQlite3, using AES, so much more secure than the previous one. This is a breaking change, so worth a blog article! Now all static .o .a […]
2018-02-07
2018-02-07. Open Source › mORMot Framework
In the last weeks/months, we worked a lot with FPC.
Delphi is still our main IDE, due to its better debugging experience under
Windows, but we target to have premium support of FPC, on all platforms,
especially Linux.
The new Delphi Linux compiler is out of scope, since it is heavily priced,
its performance is not so good, and ARC broke memory management so would need a
deep review/rewrite of our source code, which we can't afford - since we have
FPC which is, from our
opinion, a much better compiler for Linux.
Of course, you can create clients for Delphi Linux and FMX, as usual, using
the cross-platform
client parts of mORMot. But for server side, this compiler is not
supported, and will probably never be.
2015-12-11
2015-12-11. Open Source › mORMot Framework
We have seen previously how the ORM part of the framework is able to provide
an Audit
Trail for change tracking.
It is a very convenient way of storing the change of state of the data.
On the other side, in any modern SOA solution, data is not at the center any
more, but services.
Sometimes, the data is not stored within your server, but in a third-party
Service-Oriented Architecture (SOA).
Being able to monitor the service execution of the whole system becomes sooner
or later mandatory.
Our framework allows to create an Audit Trail of any incoming or outgoing service operation, in a secure, efficient and automated way.
2015-08-23
2015-08-23. Open Source › mORMot Framework
You know certainly that our mORMot Open Source framework is an ORM,
i.e. mapping objects to a relational / SQL database (Object
Relational Mapping).
You may have followed also that it is able to connect to a
NoSQL database, like MongoDB, and
that the objects are then mapped via an ODM (Object
Document Mapping) - the original SQL SELECT are even
translated on the fly to MongoDB queries.
But thanks to mORMot, it is not "SQL vs NoSQL" - but
"SQL and NoSQL".
You are not required to make an exclusive choice.
You can share best of both worlds, depending on your application needs.
In fact, the framework is able to add NoSQL features to a regular relational / SQL database, by storing JSON documents in TEXT columns.
In your end-user code, you just define a variant
field in
the ORM, and store a
TDocVariant document within.
We also added some dedicated functions at SQL level, so that
SQLite3 could be used as embedded fast engine, and provide
advanced WHERE clauses on this JSON content.
2015-04-06
2015-04-06. Open Source › mORMot Framework
When publishing SOA services, most of them are defined as
stateless, in a typical query/answer pattern - see
Service-Oriented Architecture (SOA).
This fits exactly with the RESTful approach of Client-Server
services via interfaces, as proposed by the framework.
But it may happen that a client application (or service) needs to know the state of a given service. In a pure stateless implementation, it will have to query the server for any state change, i.e. for any pending notification - this is called polling.
Polling may take place for instance:
It may therefore sounds preferred, and in some case necessary, to have the ability to let the server notify one or several clients without any prior query, nor having the requirement of a client-side timer:
Our mORMot framework is therefore able to easily implement
asynchronous callbacks over WebSockets,
defining the callbacks as interface
parameters in service method
definitions - see
Available types for methods parameters.
2015-04-06. Open Source › mORMot Framework
In a previous
article, we presented how Master/Slave replication may be easily
implemented in mORMot's RESTful ORM.
Do not forget to
visit the corresponding paragraphs of our online documentation, which has
been updated, and is more accurate!
Sometimes, the on-demand synchronization is not enough.
So we have just introduced real-time replication via WebSockets.
For instance, you may need to:
TTimer
is not an option;In this case, the framework is able to use WebSockets and
asynchronous callbacks to let the master/slave replication - see
Asynchronous callbacks - take place without the need to ask explicitly
for pending data.
You would need to use
TSQLRestServer.RecordVersionSynchronizeMasterStart
,
TSQLRestServer.RecordVersionSynchronizeSlaveStart
and
TSQLRestServer.RecordVersionSynchronizeSlaveStop
methods over the
proper kind of bidirectional connection.
2015-03-31
2015-03-31. Open Source › mORMot Framework
As stated during
TSQLRecord fields definition, the ORM is able to maintain a revision
number for any TSQLRecord
table, so that it the table may be
easily synchronized remotely by another TSQLRestServer
instance.
If you define a TRecordVersion
published property, the ORM core
will fill this field just before any write with a monotonically increasing
revision number, and will take care of any deletion, so that those
modifications may be replayed later on any other database.
This synchronization will work as a strict master/slave replication
scheme, as a one-way on demand refresh of a replicated table.
Each write operation on the master database on a given table may be easily
reflected on one or several slave databases, with almost no speed nor storage
size penalty.
2015-01-10
2015-01-10. Open Source › mORMot Framework
You can use the FreePascal Compiler (FPC) to compile the mORMot framework source code, targetting Windows and Linux.
Linux is a premium target for cheap and efficient server Hosting. Since mORMot has no dependency, installing a new mORMot server is as easy as copying its executable on a blank Linux host, then run it. No need to install any framework nor runtime. You could even use diverse operating systems (several Linux or Windows Server versions) in your mORMot servers farm, with minimal system requirements, and updates.
We will now see how to write your software with Linux-compiling in mind, and also give some notes about how to install a Linux Virtual Machine with Lazarus on your Windows computer, compiling both FPC and Lazarus from their SVN latest sources!
2014-11-14
2014-11-14. Open Source › mORMot Framework
Up to now, the TSQLRecord.ID
property was defined in
mORMot.pas
as a plain
PtrInt
/NativeInt
(i.e. Integer
under
Win32), since it was type-cast as pointer for TSQLRecord
published
properties.
We introduced a new TID
type, so that the ORM primary key would
now be defined as Int64
.
All the framework ORM process relies on the TSQLRecord
class.
This abstract TSQLRecord
class features a lot of built-in methods,
convenient to do most of the ORM process in a generic way, at record level.
It first defines a primary key field, defined as ID:
TID
, i.e. as Int64
in mORMot.pas
:
type TID = type Int64; ... TSQLRecord = class(TObject) ... property ID: TID read GetID write fID; ...
In fact, our ORM relies now on a Int64
primary key, matching
the SQLite3 ID
/RowID
primary key.
This primary key will be used as RESTful resource
identifier, for all CRUD operations.
2014-08-15
2014-08-15. Open Source › mORMot Framework
The primary purpose of any software Backup is to recover data after
its loss, be it by data deletion or corruption.
Data loss can be a common experience of computer users. A 2008 survey found
that 66% of respondents had lost files on their home PC, as Wikipedia quotes.
As a consequence, for any professional use of data, like in our mORMot server, a backup policy is mandatory.
We just introduced officially the SQLite3 Backup API to our low-level
SynSQLite3.pas
unit, and wrote dedicated methods to make
background backup of a running mORMot server easy and safe, without
any noticeable performance penalty.
2014-04-18
2014-04-18. Open Source › mORMot Framework
We have just released a set of slides introducing ORM, SOA, REST, JSON, MVC, MVVM, SOLID, Mocks/Stubs, Domain-Driven Design concepts with Delphi, and showing some sample code using our Open Source mORMot framework. You can follow the public link on Google Drive! This is a great opportunity to […]
2014-03-07
2014-03-07. Open Source › mORMot Framework
We just tested, benchmarked and validated Oracle MySQL, IBM DB2 and PostgreSQL support for our SynDB
database classes and the mORMot's ORM core.
This article will also show all updated results, including our newly introduced multi-value
INSERT statement generations, which speed up a lot BATCH insertion.
Stay tuned!
Purpose here is not to say that one library or database is better or faster than another, but publish a snapshot of mORMot persistence layer abilities, depending on each access library.
In this timing, we do not benchmark only the "pure" SQL/DB layer access
(SynDB
units), but the whole Client-Server ORM of our
framework.
Process below includes all aspects of our ORM:
TSQLRecord
instances, via optimized
RTTI;In those tests, we just bypassed the communication layer, since
TSQLRestClient
and TSQLRestServer
are run in-process,
in the same thread - as a TSQLRestServerDB
instance. So you have
here some raw performance testimony of our framework's ORM and RESTful core,
and may expect good scaling abilities when running on high-end hardware, over a
network.
On a recent notebook computer (Core i7 and SSD drive), depending on the back-end database interfaced, mORMot excels in speed, as will show the following benchmark:
DB.pas
based classes), speed is lower (even if comparable for DB2,
MS SQL, PostgreSQL, MySQL) but still enough for most work, due to some
optimizations in the mORMot code (e.g. caching of prepared statements,
SQL multi-values insertion, direct export to/from JSON, SQlite3
virtual mode design, avoid most temporary memory allocation...).Difficult to find a faster ORM, I suspect.
2014-03-03
2014-03-03. Open Source › mORMot Framework
We just committed some nice features to the ORM kernel, and SynDB* classes of our mORMot framework.
During BATCH
insertion, the ORM is able to generate some optimized SQL statements,
depending on the target database, to send several rows of data at once.
It induces a noticeable speed increase when saving several objects into an
external database.
This feature is available for SQlite3 (3.7.11 and later),
MySQL, PostgreSQL, MS SQL Server (2008
and up), Oracle, Firebird and NexusDB.
Since it is working at SQL level, it is available for all supported access
libraries, e.g. ODBC, OleDB, Zeos/ZDBC, UniDAC,
FireDAC.
It means that even properties not implementing array binding (like OleDB,
Zeos or UniDAC) are able to have a huge boost at data insertion,
ready to compete with the
(until now) more optimized libraries.
2013-11-04
2013-11-04. Open Source › mORMot Framework
On an recent notebook computer (Core i7 and SSD drive), depending on the back-end database interfaced, mORMot excels in speed:
DB.pas
based classes), speed is lower, but still enough for most
work.Difficult to find a faster ORM, I suspect.
The following tables try to sum up all available possibilities, and give some benchmark (average objects/second for writing or read).
In these tables:
Synchronous := smOff
and/or DB.LockingMode :=
lmExclusive
;TObjectList
' indicates a
TSQLRestServerStaticInMemory
instance, either static (with no SQL
support) or virtual (i.e. SQL featured via SQLite3 virtual table
mechanism) which may persist the data on disk as JSON or compressed
binary;SynDBOracle.pas
);This list of database providers is to be extended in the future. Any feedback is welcome!
Numbers are expressed in rows/second (or objects/second). This benchmark was compiled with Delphi 7, so newer compilers may give even better results, with in-lining and advanced optimizations.
Note that these tests are not about the relative speed of each database engine, but reflect the current status of the integration of several DB libraries within the mORMot database access.
Purpose here is not to say that one library or database is better or faster than another, but publish a snapshot of current mORMot persistence layer abilities.
In this timing, we do not benchmark only the "pure" SQL/DB layer access
(SynDB
units), but the whole Client-Server ORM of our framework:
process below includes read and write RTTI access of a TSQLRecord
,
JSON marshaling, CRUD/REST routing, virtual cross-database layer, SQL
on-the-fly translation. We just bypass the communication layer, since
TSQLRestClient
and TSQLRestServer
are run in-process,
in the same thread - as a TSQLRestServerDB
instance. So you have
here some raw performance testimony of our framework's ORM and RESTful
core.
You can compile the "15 - External DB performance
" supplied
sample code, and run the very same benchmark on your own configuration.
« previous entries - page 1 of 5