You are not logged in.
BTW, isn't two weeks a quite short period of time for porting a project with 600,000 lines of code? ![]()
BTW2, don't neglect the little virus, safety and health are much more important than the economics. I'm from China and I know a little about it.
mORMot is awesome! I genuinely recommend it to people everywhere when appropriate ![]()
I agree, I suggest continue using github if possible. "Everyone has an account and is familiar with" makes a lot of differences!
I've not used gitlab before, but the majority of the World is using github, it must for a good reason.
I agree with the smooth transition.
This way it looks like a preparatory version for 2.x. Something like 1.19.x
I disagree. ab is trying to achieve the migration path as smooth as possible, and that's the key for people to follow.
It's not like 1.19.x, while ab already planed to make changes like splitting TSQLRest into smaller pieces such as 'orm', 'rest', and so on, into different units. It'll already be API breaking changes, but just very logical, reasonable and easy to follow. And I appreciate ab's plan.
With github I can contribute changes very easily and I believe many are familiar with the process. How the gitlab's process compared to github's Fork-Clone-Edit-Commit-CreatePR process?
Problem solved!!! What a obscure compiler message!
Solution:
Go to "Project Objects > Delphi Compiler > Output - C/C++ > C/C++ Output file generation", change the value to "Generate DCUs Only " from the default value "Generate all C++Builder files (including package libs)"
@ab,
I filled and submitted the survey form. The most important thing is: Please keep the current forum, it contains a lot of value-able contents!!!
Several source file of my package (*.dpk) references SynCommons.pas and some other units of the mORMot library, when trying to compile/install it, I got the following error:
[dcc32 Error] SynTests.pas(1): E1025 Unsupported language feature: 'Object'
Anyone can give me some tips as to resolving the issue?
I already {$define USEPACKAGES} in the 'Conditional Defines' project options.
Thanks.
@macfly, Lazarus supports extensions, of course.
@ab,
No problem at all! I can contribute for the XE4 compatibilities ![]()
If you plan to keep Delphi 7 compatibility, I guess my XE4 is safe then ![]()
While I myself enjoyed using vs code for other editing tasks, but out of curiosity, can you explain for fpc/mORMot coding why you don't like Lazarus? Does vscode for FPC provide the same code-complete experience as Lazarus?
I think @johnnysynop is just worried that we're going to take unnecessary litigation risks.
Why is that? I don't think so. If you want to compile sqlite.c with XE7 and you don't have one, then buy one. If you want to compile it with a free compiler, the way I see it you have three options:
#1 - Make changes yourself.
#2 - Pay someone else capable to make the changes.
#3 - Ask others help for free.
Obviously the OP is taking approach #3 but somehow @ab couldn't respond to him for some reason, and the OP then posted this thread which doesn't seem very friendly nor very polite, not even consist with the facts.
@johnnysynop,
Sure, mORMot is a 100% percent open source project with an extremely permissive (MIT) license, it's a godsend to the Delphi/Object Pascal community.
I have nothing to say but "thanks" for the work done by @ab and other contributors.
Please note that the world is not a perfect world where everything is completely as you expected. Frankly, maybe you're having some kind of issue using mORMot, but what you are asking now is like someone has given you 10K dollars **for free* and you ask for another $100 for free. If he do that, you are lucky; If he don't, you have to understand the other people - no one is responsible to serve you in all situations for free.
Or at least, if you want to be a little more kind, be a little more polite when asking for help for free.
3 days after Erick's post, WINE 5.0's released: https://www.winehq.org/news/2020012101
no, no requirements yet, but the SynNode module is really really impressive!
Alternatives:
https://github.com/Coldzer0/QuickJS-Pascal (based on a famous lightweight engine by a famous open source rockstar)
and
https://github.com/tondrej/chakracore-delphi (based on chakracore which Microsoft no longer enhances)
Hey Erick, thank you again for the very insightful and helpful info!
So in order for this kind of web server programs to run under WINE, all you need is a Delphi-compiled console mORMot program that that doesn't have a VCL GUI.
Hey Erick,
The result is very much impressive! Do you have a link to any good article that you can suggest, mostly about two things:
- Install WINE from Linux console that's hosted in a remote VPS
- Get a mORMot app run by WINE.
Thanks Erick ![]()
@erick,
Thanks for keep sharing, it's very helpful!
Re the msvcr100.dll issue, is it a license one? I mean, MS doesn't allow installing msvcr100.dll on non-MS OSes, right?
BTW, I assume Linux is much much more popular then FreeBSD nowadays, I'm just out of curiosity - why do you prefer the latter?
One question - I guess if you use WINE to deploy your Delphi program, you won't be able to debug on the target platform (FreeBSD or Linux)?
@ab, Yes, agreed! That'll be great if mORMot can include necessary changes, if any, in order to adapt to the WINE layer on Linux etc.
@ab,
It's perfect if one can port their apps to FPC which supports a lot of compilers, but as Erick has mentioned, with the WINE you can continue using Delphi and your 3rd party libraries, that's a huge benefit if you have time and resource constraints.
Hey erick, thanks for sharing, it's a very interesting and useful finding!
Over 2 years ago I had a similar experiment (https://synopse.info/forum/viewtopic.php?id=4263), and I've noticed significant improvements over the years from the media.
What I tried was on the Linux GUI, do you mean you can just install WINE from the FreeBSD command line and then run the Delphi-compiled, mORMot-powered console program from the FreeBSD console?
If anyone is willing to find out what is wrong with Delphi XE4 linking bug, and provide a fix, you are welcome!
I guess your last line was intended to reply "Delphi 64bit sqlite compilation" ( https://synopse.info/forum/viewtopic.php?id=5127) ![]()
You can use wxsqlite3 with mORMot with the dynamic linking mode. Search 'wxsqlite' in https://synopse.info/files/html/Synopse … 01.18.html
Thank you, ab.
I downloaded sqlite3-64.dll from http://synopse.info/files/SQLite3-64.7z, and found it's 600+KB smaller than the official one from sqlite.org, not sure why. I assume it has all the FTS4/5 and json1, right?
I think you'll have to disable those mORMot's built-in collations, I can't tell the details so please check the document.
In this case I don't need to encrypt the sqlite db file, I guess I don't lose any other features aside from slightly slower performance, right?
BTW, for dynamic linking I should download the sqlite3.dll from sqlite.org but not from somewhere on synopse.info, right?
@ab,
No problem, I'll use dynamic linking for now.
Hello ab,
I'm getting a "[dcc64 Fatal Error] F2084 Internal Error: AV0858E903-R343E15EC-0" error when trying to compile with XE4/Win64.
I'm wondering if there is a any workaround, I'm currently using dynamic linking (.dll)? I'm using the latest github repository committed on Jan 14, 2020.
Thanks.
Not by me, I'm the discoverer ![]()
https://github.com/krkodil/mORMot
Example usage:
SynClient client = new SynClient("127.0.0.1", 8080, "service", false);
if (client.login("User", "synopse")) {
JSONArray params = new JSONArray().put(2).put(3); // Add(2, 3)
JSONObject response = client.call("Calculator.Add", params);
System.out.println("Summ: " + response);
client.logout();
}Happy holidays to all mORMot authors and users!
mORMot is the most powerful web framework for the Pascal/Delphi community, it's been becoming more and more powerful and mature over the past years and I believe it will become better in the future.
Delphi's been the best desktop development tool, and now with mORMot, Delphi/Lazarus has also become a very good server-side development tool as well, and this is not possible without ab and other contributor's good work!
I confirm it's fixed now! Happy holidays!
Thanks for the new implementation, ab, I actually didn't take into account nested JSON objects.
I tested the new version and found an issue that's also exist with my implementation (which I didn't notice until now).
The issue is with tags with 3 brackets, in that case the result will include an extra unwanted '}' at the end of the rendering result.
I guess the following test can reveal the issue.
helpers := mustache.HelpersGetStandardList(['jsonhelper'], [MustacheHelper]);
mustache := TSynMustache.Parse('{{{jsonhelper {a:"a",b:10}}}}');
html := mustache.RenderJSON('', nil, helpers);
Check(html='a=a,b=10');Thank you ab! I think you can write the tests better, and I'll check them once you are done, so that maybe next time my PR will also include some tests.
@ab,
the gihtub PR is here: https://github.com/synopse/mORMot/pull/260
Please review and make changes as needed. Thanks.
I fixed the issue, a github PR is coming
Hello ab,
The helper being used in this form:
{{{helperA {src: "folder1/file1.jpeg", alt: "some text"}}}}If I understand the document correctly, this part, the JSON string will be passed to helperA by the engine:
{src: "folder1/file1.jpeg", alt: "some text"}is supposed to be passed into the TMyClass.HelperA method below:
The helper function registered with TSynMustache.HelperAdd is defined as something like:
procedure TMyClass.HelperA(const Value: variant; out result: variant);
begin
// here I expect the "Value" parameter contains the JSON string passed to the helper,
// but the Delphi debugger shows that the "Value" parameter is null
end;However, the debugger shows that the "Value" parameter is null.
Any hint? Thanks.
@Eugene, it's very useful, I shall study the source code, thanks!
If you do so, be sure to use TSQLRawBlob as the field type.
For your concerns about the performance of sqlite itself, read:
SQLite small blob storage: 35% Faster Than the Filesystem:
Great project! What if one want to use another css/html framework such as Bootstrap?
Hey!
I didn't know about that, even after using mORMot for such a long time!
Well done and thanks, ab!
Just sharing a thought concluded from real-life projects:
We all know that there are two kinds of services you can define with mORMot:
- Method-based
- Interface-based (the "interface" here is the interface in Delphi/FPC)
A advantage of method-based services over the interface-based ones, is that the **compatibility** to new/old versions of clients.
If you use interface-based services, if you need to add a new parameter - oops! all clients need to be updated **otherwise the call will fail**.
But with method-based services, new versions of clients can submit new parameters while the old clients can keep working, and the server handle it according to what the incoming parameters are.
Just my 2 cents.
not sure, sorry. actually I don't quite understand Swagger
Sure you can access the mORMot server from a client written in other languages - mORMot talks in HTTP/WebSocks/REST standards.
Why not assign cross-node unique IDs using TSynUniqueIdentifierGenerator on the client side?
Agree with @idSDS
@ab, FYI,
In my view, for me to adopt a new methodology, I need to answer ALL of the following questions
- What are the **disadvantages** of using directly TSQLRecord?
- What are the **advantages** of using KDD/DDD?
- Are these disadvantages/advantages **significant** without significant side effects/penalties like class explosion?