#52 Re: mORMot 1 » 2nd Edition of mORMot book » 2017-02-03 22:29:33

Junior/RO wrote:

@erick, which tools are you using for Latex?


TexShop on a Mac.
Latex as my engine

My first few lines are:
%\documentclass{tufte-book}
\documentclass{book}

I didn't have luck with tufts-book, so I went with classic {book}

For conversion to Ebook I've been trying calibre.

#53 Re: mORMot 1 » 2nd Edition of mORMot book » 2017-02-03 14:41:36

jbroussia wrote:

Can I login into createspace with my Amazon credentials or do I need to create a new account ?

EDIT: tried with my Amazon credentials, didn't work, so new account needed...

EDIT2: finally ordered from Amazon instead ! Book not available right now, need to wait for restocking. Got it from Amazon.fr as Amazon.de and Amazon.co.uk don't list the book.

Sorry it didn't work.  I don't know what failed - if I can't figure it out I might get rid of that option.  I know Amazon's sites work, though it might take a few days for the book to be available on all of them. 

Erick

#54 Re: mORMot 1 » new book about mORMot » 2017-02-02 19:41:40

Good news, it's available, neater, better, more topics, cheaper. 
I've started a new thread about the 2nd edition.

#55 mORMot 1 » 2nd Edition of mORMot book » 2017-02-02 18:55:30

erick
Replies: 10

Today I've published the 2nd edition of my mORMot / Elevate Web Builder book:
Enterprise Delphi Databases by Erick Engelke.

There are significant changes from the first edition:

- formatting all done with Latex, looks like any normal book now, gets rid of
  production problems that plagued first edition, incl. fonts, tables, etc.
  A few testers have gone through the printed version and yesterday we
  fixed the two very small typing issues that remained.  Latex formats
  Pascal natively, so examples look good.

-new and expanded examples (including source + description) for introductory
  materials.

- enhanced chapter on ORM/de-normalization

- a complete JavaScript/ECMAscript example will be in the downloads.

- new book section entirely devoted to Domain Driven Design (DDD),
  including concepts and practical example code, when to use DDD and not,
  and applying principles of DDD to object pascal

-numbered chapters, source code ordered by chapter #

- price - it's still $59 US at Amazon, but can be ordered at $49 US from
  https://www.createspace.com/6896195 if you use the discount code
  WHPS5D2R before March 2017.  I do not know how well the createspace
  store works, and will revisit the decision after people give me feedback.
  The createspace store is still operated by Amazon, and Amazon does the
  fulfillment, but they apparently charge less.    Let me know how you like it.

- kindle edition - There will be a kindle edition in a week or so, but I'm still
  adjusting the layout for that format, I want it to be as usable as possible.

These were the main takeaways I saw in the Email and postings.
There were other suggestions, but these were the main ones, and I wanted to
get these changes out there before more people bought the 1st edition. 

I am beginning work on an expanded 3rd edition for 2018 with a more leisurely
schedule.  As before, your comments, help and criticisms will be very influential
and I thank you in advance.

About 1st edition: I am planning on making more of the updated text available for
purchasers  of the first edition.  Or if you really want, I will pay for your copy of
the 2nd edition if you pay for shipping from Amazon - but you must contact me
first because I will buy it through the Author's channel at a discount rate.

Finally, if you have need of several copies, Email me and I can supply a 'bookstore' rate
through CreateSpace.

mORMot is an excellent work, and I hope you will find this book a useful addition to it.

ErickEngelke@gmail.com

#56 Re: mORMot 1 » new book about mORMot » 2017-01-22 03:31:17

Great timing Albert, I just signed in tonight to say

Good News: HOLD THE PRESSES

I've spent many hours yesterday and today converting the text to LaTex.  And there are some new chapters which haven't been made public yet, I'll work tomorrow to putting them into LaTex too.  I'll send it out for printing on monday, proof/fix in a while loop.

A second edition will be available on Amazon by mid Febrary.  I'll announce it here when it is available.

Erick

#57 Re: mORMot 1 » new book about mORMot » 2017-01-20 04:42:55

erick wrote:

> There are ready-made classes to create your book. For example, I took a sample chapter provided earlier in this thread, opened it with Word, saved as .docx, then used docxtolatex to convert the file. After some _very_ minor editing, got the following:

Which docxtolatex program, there are several  different ones?  I'm using a Mac version of Word, some  conversion programs try to use OLE and I can't use that.  I also tried pandoc but it seems to generate many many errors in Latex, I gave up on it.

E

#58 Re: mORMot 1 » new book about mORMot » 2017-01-20 02:50:31

> (Before counting me off as some Microsoft basher, let me assure you that Excel and Word are my two favorites pieces of software of all time, period. I truly think they are a monument to human ingenuity.)

I can tell you I was seriously thinking about it a few times in the last few months, as LaTex is something I've used years ago and a close friend just rediscovered it last year and reminded me.  But I had already invested a lot in the Word version and didn't know a good way to convert Word to LaTex.  I figured that would wait until the next project.

Well, I'm ready to renew my Knuth membership card today.  I still have all the books.

The only thing I liked about Word was the grammar checking.   But the autocorrections were killing me as I cut and paste code.

> There are ready-made classes to create your book. For example, I took a sample chapter provided earlier in this thread, opened it with Word, saved as .docx, then used docxtolatex to convert the file. After some _very_ minor editing, got the following:

I will definitely pursue this option.  Thanks for some excellent advice and the effort you put into this.

#59 Re: mORMot 1 » new book about mORMot » 2017-01-20 02:30:49

DKA wrote:

OK Erick,
For example, I cannot find the needed source to compile and run the delivered apps. For example, no wbp file in the ewbmormot.zip file.
And the ewbmormot.zip file is "only" 3.5 Mb. So it is not large (in my opinion).

I'm confused.

I don't know why you would use a wpb file?  I believe it is a webshot connection file, never actually used one myself.

I put everything into one file for simplicity.  Some people felt the download file was too large, maybe they use modems.  In the future I may break out the binaries into a separate download as most developers will not need to have the big EXE files.

Erick

#60 Re: mORMot 1 » new book about mORMot » 2017-01-12 19:13:45

I wrote:
"So far I've written chapters about Sharding/De-Normalization..."

and that first six page chapter is now available.

It, and future chapters as they come available, can be downloaded at http://www.erickengelke.com/ewbmormot2.zip

The same files are included in my large ewbmormot.zip, but that file is huge and I don't expect everyone to keep downloading it every week..

If you can send your suggestions to my Email address, I will communicate with you to refine the topics in Email before I post a complete article to the web.  Try to include a little description of each so I can understand why it seems confusing.

Thanks
Erick

I updated the file the clarify a point a few hours later.
Erick

#61 Re: mORMot 1 » new book about mORMot » 2017-01-10 23:43:03

DKA wrote:

Hi Erick,

I'm frustrated because i expected a complete small application including CRUD, Auth, Sharding, JSON (Un)Serialization, logging. Some kind of Starter Kit. I would pay 65 euros for this even if the book was 100 pages only.


I have to say that I'm glad that some people are writing books about MORMOT and EWB. Hope those remarks (critics) will help you to improve your next editions ;-)

Trust me, the comments are making it better. 

To be honest, on a first edition you never know if you hit the ball out of the park (baseball reference) or not until you get replies.  My test audience scored differently than the public.   While the EWB book was a huge success,  this one has met with criticism.

But part of the responsibility of an honest author is to fix what's wrong.  So here is my proposal:

I've been working on the second edition with new and a few updated chapters based on comments and suggestions.  These are copyrighted material, but I will publicly release the new chapters as downloadable PDFs from my web site.

The book remains copyrighted, but existing customers get some benefit of the second edition without spending additional money.

So far I've written chapters about Sharding/De-Normalization and a lot about DDD.  All of them are on the advanced side of the room.  Now that you mention it, I will also do a starter kit included in the book's download.

I will make the first instalment available sometime this coming weekend.

Unlike the BBS, the printed form gives opportunity for thoughtful, detailed and illustrated answers.
Feel free to Email me about topics.  I can't answer quickly, but I can research and include responses in my documents.

I hope that sounds agreeable.

Sincerely,
Erick

#62 Re: mORMot 1 » Theres oficial dataset component available in mormot? » 2017-01-07 17:36:50

Hi,

I'd say it depends on your client.  You said you are getting my book, it shows using mormot to output JSON, and using web clients based on Elevate Web Builder which accepts that JSON as a dataset and lets you walk through the JSON as a TDataSet in terms that feel very Delphi-like.

I would recommend using the SOA RPCs in the book, as they are the most flexible way of accessing data.

Good luck.
Erick

#63 Re: mORMot 1 » new book about mORMot » 2017-01-07 17:27:35

Thanks for the helpful input.  I will certainly try to address these concerns and improve it for the next release sometime midway through this year.  Most of the work will be in February or March, but the timing of the release... I'm not sure.

Many of the people I consulted were from non-mormot groups who felt mormot had a really steep learning curve and were scared off by the multi thousand page SAD.   There was no obvious path, and they didn't know where to begin.    You see some of them post in this newsgroup, and there were many in the Elevate Web Builder group who echoed that sentiment.

The first few chapters you discussed are for those people.  They want a fast course to get them migrated off other technologies.  I believe that is where we can bring growth to our mormot community.

The sections on Elevate Web Builder is quite a departure for mormot developers, it opens opportunities to rephrase our applications to real web clients.  I really hope you will find value in that.

Erick

#64 Re: mORMot 1 » new book about mORMot » 2017-01-06 13:23:54

The formatting was a problem.  I agree generally, though we will all have personal opinions on some aspects.

I will be significantly reformatting this book in 2017, probably in March as I will have a month at home for a medical leave.  There may be a few minor edits for clarification too.

That doesn't help you directly, but it does benefit the Delphi/NewPascal/Mormot/EWB communities we all care deeply about.

I will update this thread when the new revision is available.

#65 Re: mORMot 1 » Single Sign On (SSO) authorization with Web Browser and mORMot » 2016-12-29 14:50:47

In my implementation I didn't keep track of the session time (in seconds), because there may be other reasons the session closes, such as if the mormot exe gets restarted.  I just keep using it until I get an appropriate HTTP/S errors.

Hope that helps,

Erick

#66 Re: mORMot 1 » mORMot Use Case Question » 2016-12-23 13:10:45

edwinsn wrote:

Multitenancy is a new term to me too smile

It's new to me too, but it makes sense instantly!

My suggestion of using multitenancy is because people like using on application where they can, rather than a bunch of smaller applications they might have to sign into.

In practice, I find I struggle between making small single-purposed apps that are well defined, and later addressing larger needs with a single-mega-app.

If you have single sign on (SSO), like CAS or OpenID, it makes less of an inconvenience for the user to use multiple apps as they don't have to sign in each time.

Erick

#67 Re: mORMot 1 » Single Sign On (SSO) authorization with Web Browser and mORMot » 2016-12-23 13:04:28

Doing the authentication and updating the signature on each message - well it's a bit difficult at first.  Everything you need to accomplish it can be found on this board.  I implemented it in Pascal compiled to
JavaScript for my book following the leads of others who had done it in typescript and javascript.

Erick

#68 Re: mORMot 1 » Registering New User via REST » 2016-12-23 12:55:32

DavidRM wrote:

Is there an example of how this would be implemented?

>I've ordered Erick Engelke's new book, but it won't get here until next week, and I have no idea if it covers >this. And I'm impatient. So I'm asking here. smile

Hi David,

Since you've ordered the book, you'll be happy to know it comes with source code that auto-adds people.  In my implementation I first check that they pass an active directory or NT-styled password challenge, but you can change the code to support whatever addition requirements you desire.  I wrote it to support EWB clients in a company, but it works just fine for Delphi clients too.

If I remember correctly, you authenticate with a pseudo-guest account to gain access, then you send whatever credentials to the server using the guest account.  It processes the request and auto-adds a userid. Then you log in with that userid and you are all set to do anything. 

Merry Christmas,

Erick

#69 Re: mORMot 1 » new book about mORMot » 2016-12-23 12:43:40

HollosCs wrote:

Can I buy your book any digital format (pdf, mobi, epub)?

No, sorry, I've done that before and my books quickly ended up on file sharing sites.

Erick

#70 Re: mORMot 1 » new book about mORMot » 2016-12-23 04:15:27

firstfriday wrote:

I just got the book. I did not read it fully but it tells you less than the documentation at Synopse. It's a book for beginners.

I'm sorry you are disappointed.  As I listed in my blog, the first few chapters are to get new people started that are not familiar with mORMot.  The steady stream of beginner questions on the board indicates there was a need for such a section.   But once you get past that... hopefully not too much more disappointment.

I disagree that there is no SOA as there are both Delphi and EWB SOA examples.

There are also examples of SQL and ORM methods depending on which model you need to use for your project.

Starting page 127 to about page 190, it should all be new material to you because it covers REST and SOA RPCs with Elevate Web Builder that is definitely not documented anywhere on Synopse and I think the Web is the right direction to head for market acceptance. 

It includes a new library which supports REST+SOA with mORMot from EWB, which does auto-reconnect of sessions and supports Active Directory for authentication on all web browsers.  We're using it in production here for a couple of months so it's stable and opens new opportunities that didn't exist prior to the publishing.

I will take your recommendations on DDD, etc. and try to incorporate them into a future edition.  That doesn't help you right now, but it will help others in the future.

Somebody "above" wrote the book has a good quality. I really cannot agree with this. At least not my version: Printed in Poland by Amazon Fulfillment.

Amazon is a world-wide company.  My copy was printed on premium Canadian paper, but they demand-print for US, EU and UK and quality may vary by market, the only choices they offer the author are cream or white paper  and glossy or matte cover.  I picked them because shipping to EU and UK is expensive and past experience indicates people are keen for fast and, I believe, free delivery.   I've never seen a Polish book so I have nothing to compare.

The font is a readable 12 point recommended by the publisher.  Apparently 10  or 11 are hard-to-read for many people.  To compensate for the font size, the book uses a large page size of 8x10.   Book sizes are standardized for shipping purposes.

Some of the text boxes were reformatted by the publisher, and I agree there is sloppiness introduced in that last section where they messed up the frames.  Probably I'm to blame for having used MS-Word with text boxes.  This didn't show up in the pre-publishing copies because it had to do with PageMaker or whatever they use.  I do apologize for that.  But every time you submit the document they reformat it.  I thought it was gold this time, I was wrong.

For almost 60€ I've expected a better quality - far to expensive.

I know it's in line with prices for timely US technology books I buy.  I do not know the price of European books.  Approximately 1/3 of my books published on Amazon are sold in the EU so I think it must not be too outrageous.

On-Demand publishing is more expensive, but it is perfect for things like mORMot which gets extended regularly and which is so niche that no regular publisher would touch it.

This book has been a passion for a year and a half, with countless hours going into documentation, writing stripped down working samples,  and also building the next technologies which are unencumbered open source in the accompanying download.

I hope most readers will look past the production problems and see it as a valuable and timely resource.  I could have spent another year finessing the text and layout, but AB and I thought timeliness was critical in our Emails, I was starting to think he might be giving up on me :-).

The price reflects two facts: one the market size is currently very small - meaning its hard to recoup my expenses, and two, the fact I have to legally turn some of this into money to qualify for writing off expenses on my taxes.  Otherwise it's just an expensive time-consuming hobby to the tax man.  I promising you, writing a computer text about a wonderful but niche product is not a lucrative deal.

I've been heavily contributing to the open source comunity for almost 30 years, sometimes as programmer, sometimes as book author, often both.   And I think you have to look at how something like this book will help grow the project, and will save many people many days or weeks of effort, and in the case of EWB, open up new opportunities which didn't exist in that form prior to my work.  In my case, my books subsidize my development environment and activities.  I hope it will benefit you.

I guess people might wonder why pay for something related to open-source, it's all free, right?   To the contrary, I hope people reward AB by trying to help answer questions to save him him time, and by contributing to the project however they can, including donating source and helping financially when they can.

#71 Re: mORMot 1 » Delphi RAD Server comparison » 2016-12-22 13:51:22

Thanks Ab.

I apparently overpriced EWB, it's only $359 US.  I was mistakenly wrote what I paid in Canadian dollars.

Yes, the mormot analytics are very powerful indeed, I will put that into the videos comments if you haven't already.

I made the video on a Mac using PowerPoint, with Quicktime audio/screen recorder, and iMovie to trim the length.

Erick

#72 Re: mORMot 1 » new book about mORMot » 2016-12-22 04:20:54

emaxx wrote:

@erick, you should redesign your landing page http://www.erickengelke.com/.
It's IMHO no good idea to present an EWB-Demo which scales horrific at mobile with GPRS (50kb/s download, 500ms latency),

Sorry, I've simplified it a lot a few seconds ago.  GPRS... I remember that.

Erick

#73 Re: mORMot 1 » ORM Question - Server Override Load/Save » 2016-12-22 03:08:25

Yes, you can override the Setter and Getter for any attribute.

For example, the standard mORMot database userids store a hash of the password.  You can set the password, and it is hashed before being stored, so you cannot read it back as plain text.

Erick

#74 mORMot 1 » Delphi RAD Server comparison » 2016-12-22 03:03:42

erick
Replies: 3

I was asked today to comment on RAD Server in comparison with the mORMot + optional Elevate Web Builder solution.

I made a three and a half minute video comparing:

   RAD Server   versus   mORMot   versus   mORMot + Elevate Web Builder

I describe pricing as well as general features. 

It's at https://youtu.be/__BoOxUHWoU

Erick

#75 Re: mORMot 1 » mORMot Use Case Question » 2016-12-21 00:22:54

DavidRM wrote:
mpv wrote:

See Multiple databases in one Mormot server for similar discussion

>That didn't answer my questions. Also, my case is nowhere near that extreme. At most a dozen external databases, and that's on the long side.

You can host mysql, oracle, mssql on the same server or different servers, though usually you'd use only one brand at a time because of sanity!

You can access different tables in different databases from the same project.  I tend to make one userid running on the mORMot server and grant it access to all required tables.

You can use SQL or ORM.  I recommend ORM for new projects, or SQL if you are working with an existing database that doesn't easily support ID  or similar as an index.


DavidRM wrote:

>I'm looking at multiple collections of object models, each tied to a separate database on the server. That is, one set of models tied to the main server (the collection of databases), and a set per open database.

Why not make a mega-application that does all these things in one?  I mean, you might  spend more time migrating things from one DB to another, why not make a program that can access subsets of any of it.


DavidRM wrote:

>Is that doable in a single client connected to a single server? And can I still use the ORM features?

mORMot is incredibly flexible, and that can bite you early in your mORMot career.

PLUG: My mormot book gives examples of both ORM and SQL and will get you started much faster than trying to figure out the online examples by yourself.

#76 Re: mORMot 1 » new book about mORMot » 2016-12-15 21:56:26

Yes, the source code url is in the book.  I don't have it handy at the moment but it's on page 17 under "Acquiring the software".

The cover art is for the zen-like peaceful feeling one has when the database is working hard and many people are using it, and everything is just humming along.  You look at the netstat to count sessions, you look at the disk lights, and the process stats, and you just know that people are being served their data and nobody is complaining.

Erick

#77 Re: mORMot 1 » new book about mORMot » 2016-12-15 03:48:15

I've put up a rough overview of the chapters and pagecounts at: http://erickengelke.com/blog.html

Erick

#78 Re: mORMot 1 » new book about mORMot » 2016-12-15 02:19:49

jbroussia wrote:

Any idea when the book will be available in Europe ? Amazon FR tells me it's not in stock.

It is available in Germany, and they've already reported a few sales there this week. 

https://www.amazon.de/dp/1517516005/ref … +databases

Erick

#79 Re: mORMot 1 » new book about mORMot » 2016-12-14 12:25:40

hnb wrote:

Thanks for your work. First real book about mORMot!

>Btw. nice to see NewPascal in description smile

erick wrote:

Use either Delphi Professional or the free and open source New Pascal to develop on Windows, Linux and other platforms.  Active Directory authentication and local passwords are both demonstrated.

Another news feed I follow is the Elevate Web Builder's product support group.  I think almost all had Delphi experience since it is also an Object Pascal environment, but many did not want to have to purchase a new Delphi license again.  mORMot's support of heritage Delphi versions, and now New Pascal are real selling features to that audience.

Erick

#80 mORMot 1 » new book about mORMot » 2016-12-13 13:36:25

erick
Replies: 40

I’m pleased to announce my new book exclusively about mORMot and Elevate Web Builder, it is called “Enterprise Delphi Databases” and can be purchased on Amazon.  Check for free shipping available to many locations!

It describes End-to-End Object Pascal multi-tier development using mORMot for servers and clients, and using Elevate Web Builder’s Object Pascal to JavaScript to build professional Web clients.

The book was proofread by mORMot Project Manager: Arnaud Bouchez, and he also provided key suggestions for topics including Websockets.

I cover using both ORM and standard SQL with mORMot, and examples of how to use each when creating web clients.  ORM is perfect for new implementations, but mORMot’s SQL interface is great when you must interface with an existing database.

Use either Delphi Professional or the free and open source New Pascal to develop on Windows, Linux and other platforms.  Active Directory authentication and local passwords are both demonstrated.

Some of the mORMot material is introductory for new users, and can be skimmed by experienced mORMot developers.  But it will quickly bring your new staff up-to-speed quickly and will give reassurance to management that mORMot skills are not in a single-employee silo.  There are also some aspects discussed for even seasoned developers.

The numerous chapters on Elevate Web Builder open new opportunities for experienced mORMot developers to quickly generate powerful and attractive web based clients.  The Web is often the best strategy for clients, and the power and features of Elevate Web Builder make it the best choice to deliver the systems of the future.  All of this is done using SOA and REST services mORMot does so well, and the Single Web Page strategy that gives Facebook, Gmail and other web applications their fast, fluid, professional look and feel.

Book information follows:

Order from Amazon US, UK, EU - details at http://www.erickengelke.com

Enterprise Delphi Databases
With mORMot and Elevate Web Builder
By Erick Engelke
Available on Amazon (US, UK, EU)
 
What makes a database Enterprise quality?  There are no hard rules, but one can assert the following are usually true
 
-        Scalable performance
o   Support 100 to 100,000 concurrent users
-        n-Tier database capable
-        caching used for performance improvements
-        multiplatform through SOA
-        web accessible interface
-        inherent security
o   externalized authentication (LDAP, RADIUS, Kerberos, OAuth2, etc.)
o   authorization enforced based on principles of least privilege
o   auditing
o   prepared statements
 
In this book we introduce mORMot, a Pascal based database ecosystem including support for all popular databases (Oracle, MySQL, MariaDB, MS-SQL, PostgreSQL, Mongo and others).
 
mORMot databases are instantly network-ready.  Using Delphi or FreePascal you can compile clients for almost any operating system (Windows, OS/X, iOS, Android, X-Windows) which can converse with Windows or Linux servers. 
 
And when we add Elevate Web Builder (EWB), you can create rich, engaging Web based database applications that run on any Web client and interface with mORMot’s standards-based Service Oriented Architecture (SOA) technologies.
 
Unique to this environment, mORMot and EWB present fast and reliable end-to-end Pascal solutions.
 
Fully enterprise-ready, you can configure your applications to use local database passwords, Active Directory or other solutions for user authentication.
 
In addition to describing essential mORMot and Elevate Web Builder, this book introduces an interface library that bridges the two technologies.  Call a Pascal function in the EWB code and the corresponding function is automatically called on the server, passing all parameters with ease.  mORMot and EWB automatically marshal the data to and from each other using standard JSON notation.
 
This  book covers all you need to know to get started, and works through more than 30 example programs and concepts from beginner through to multiplatform Web applications, PDF Report generation, HTTPS configuration and clustering.

This is Erick Engelke’s fifth book, following his popular Using Elevate Web Builder book and other books on topics of web, network and systems programming.  Several of his books are available on Amazon.

#81 Re: mORMot 1 » recent presentation + book coming » 2016-12-09 01:53:05

ab wrote:

Great input!

Thanks.  It was my read of the market today, and a lot of people agreed once they saw the flow of ideas.  In the slides I focused more on the GUI nature, but the back end (which was mORMot for several apps) is critical, and mORMot fits perfectly.

Erick

#82 mORMot 1 » recent presentation + book coming » 2016-12-08 16:55:19

erick
Replies: 2

I did a recent presentation at an IT conference where I talked about end-to-end Pascal on Web+server using mORMot and Elevate Web Builder.  Response was very positive.  I mentioned my new mORMot book which I hope to release before Christmas called Enterprise Delphi Databases which focuses on these two products combined.

http://www.youtube.com/watch?v=cfXolAJK … e=youtu.be


WatITis Talk : Web and Mobile Apps
By Erick Engelke
Director, Engineering Computing
University of Waterloo,
Ontario, Canada

What do users expect from today’s applications?  Why is the web increasingly important for database applications?  What is an enterprise-capable application?  Which Web technology promises did not pan out?  How can you leverage today’s tools for faster, reliable development of modern Web and Mobile applications?  How can you reduce the amount of code and eliminate most run-time errors?

In this presentation, I answer the above questions and demonstrate using Elevate Web Builder and mORMot using SOA to create attractive, fast, powerful and useful applications.

URLs of interest:

mORMot : http://synopse.info
NewPascal (variant of FreePascal) : http://www.newpascal.org
Delphi: http://embarcadero.com
Elevate Web Builder:  http://www.elevatesoft.com

Using Elevate Web Builder: http://www.erickengelke.com
Enterprise Delphi Databases: http://www.erickengelke.com

#83 Re: mORMot 1 » AccessRights - I don't understand » 2016-11-25 01:14:33

Thanks, I have it figured out now.

#84 Re: mORMot 1 » AccessRights - I don't understand » 2016-11-24 17:10:58

I've figured out almost everything else I need, but this escapes me.

14 maps AllowRemoteExecute to what?  It's not function #14.  Why is it not 13, or 12.  What does 14 mean?


Also, the CRUD numbers - I'm assuming a bitfield for 0-256 tables ordered from the database tables.

So I tried an experiment:

// grp.AccessRights was = '14,3-256,0,3-256,0,3-256,0,3-256,0';
grp.SQLAccessRights.Edit(1, True, false, false, false);
TSQLLog.Add.Log(sllTrace, 'accessrights % ',  [UTF8toString(grp.AccessRights)]);

to see how the bits get changed.  But they didn't.

20161124 16542458 res   SynSQLite3.TSQLDatabase(027CAC30) [{"ID":5,"Ident":"EWBlogin","SessionTimeout":60,"AccessRights":"14,3-256,0,3-256,0,3-256,0,3-256,0"}]
20161124 16542717 trace accessrights 14,3-256,0,3-256,0,3-256,0,3-256,0

No change.  So I clearly don't understand this.

Thanks in advance
Erick

#85 Re: mORMot 1 » Upload and download of big files » 2016-11-24 04:01:45

It depends how big.

In my JavaScript client I load the file in JavaScript in 64 bit encoding, then upload a few kB (currently 4 kB) at a time.  This way I can pass the chunk to a mORMot SOA function and it appends it to a file without filling mORMot process' memory.  This allows me to show progress of upload too if I choose.   Even on phones, this allows you to upload many MB files.  But if you are talking GB, you will need a different solution because it relies on the JavaScript system holding the whole file in memory.

I posted a demo to the Video's topic at the top of the mORMot sticky list.

Erick

#86 mORMot 1 » AccessRights - I don't understand » 2016-11-24 03:34:17

erick
Replies: 4

I'm looking at the Group Access Rights and they are like
grp.AccessRights := '14,3-256,0,3-256,0,3-256,0,3-256,0';

What does the 14 mean, the 3-256 mean, etc.

I searched and couldn't find an explanation anywhere in the documentation.

#87 Re: mORMot 1 » ElevateDB? » 2016-11-24 03:17:35

erick wrote:
trinione wrote:

Hi:
I need to develop a Mac OSX application that connects to an ElevateDB database running on a Windows machine on a local network.

Does mORMot work with ElevateDB database engine?

No, it does not.

Well, in retrospect I thought of a way you could do it.

You could use mORMot for it's SOA interface and link in ElevateDB to handle the database part.
The SOA system lets you plug in any code you want, so it could make references to EDB's code.

Hope that helps,

Erick

#88 Re: mORMot 1 » ElevateDB? » 2016-11-24 02:17:37

trinione wrote:

Hi:
I need to develop a Mac OSX application that connects to an ElevateDB database running on a Windows machine on a local network.

Does mORMot work with ElevateDB database engine?

No, it does not.

#89 Re: mORMot 1 » My mORMot Videos » 2016-11-24 02:14:28

I wrote a Machine Shop  job management system using mORMot and Elevate Web Builder.

The goal is a simple way for customers to submit jobs, drawings, material safety data sheets, etc.
and for staff to manage the jobs.

Here are the two user interfaces, one is an extension of the other
Customers:  https://www.youtube.com/watch?v=5yNPm25JU00
Staff:          https://youtu.be/SXa6XwMF38w

I have other systems, but will have to blur out confidential information.

Erick

#91 Re: mORMot 1 » httpd.sys and SSL » 2016-11-17 02:07:25

Bo wrote:
erick wrote:

I have been struggling for hours trying to get HTTPD.SYS to work with SSL under Windows 10

...

I'm guessing it doesn't like the GUID?  People seem to just make up a GUID and it works for them.  Any suggestions?

Erick

The GUID does not play an important role at all, I made up one too. Most likely would be certificate's issue. I tried self-sign certificate by following the step's in the document but was not successful, then I reused the set of certificates from a production server and it worked immediately since then.

It turned out to be a bad certificate.  I got it reissued and everything quickly fell into place and worked perfectly.  Thanks for the clues everyone.

Erick

#92 Re: mORMot 1 » httpd.sys and SSL » 2016-11-15 00:50:11

mpv wrote:

Try to add a certificate using fake IIS site. After this stop IIS site and run your service..

Okay, my SSL cert doesn't work with IIS either.  So that will help me debugging, thanks.

Erick

#93 mORMot 1 » httpd.sys and SSL » 2016-11-14 20:02:45

erick
Replies: 4

I have been struggling for hours trying to get HTTPD.SYS to work with SSL under Windows 10

I added the certificate using the Certificate Manager.  And now

D:\shop\server>netsh http show urlacl

  ...
  Reserved URL            : https://+:443/root/
        User: \Everyone
            Listen: Yes
            Delegate: Yes
            SDDL: D:(A;;GA;;;WD)

Which is what I want I think.

D:\shop\server>netsh http show sslcert

SSL Certificate bindings:
-------------------------

    IP:port                      : 0.0.0.0:4482
    Certificate Hash             : 8d9c00edafceefabd3a6b71a69d2b25251ef1fc4
    Application ID               : {6470088c-1553-44ea-8ee0-97f2042249e8}
    Certificate Store Name       : My
    Verify Client Certificate Revocation : Enabled
    Verify Revocation Using Cached Client Certificate Only : Disabled
    Usage Check                  : Disabled
    Revocation Freshness Time    : 0
    URL Retrieval Timeout        : 0
    Ctl Identifier               : (null)
    Ctl Store Name               : (null)
    DS Mapper Usage              : Disabled
    Negotiate Client Certificate : Disabled
    Reject Connections           : Disabled

I don't know why it bound to that port.  I deleted it, then try to bind it to 443, assuming I would use the same GUID as was above
but that doesn't work.

D:\shop\server>netsh http add sslcert ipport=0.0.0.0:443 certhash=8d9c00edafceefabd3a6b71a69d2b25251ef1fc4  appid={6470088c-1553-44ea-8ee0-97f2042249e8}

SSL Certificate add failed, Error: 1312
A specified logon session does not exist. It may already have been terminated.

I'm guessing it doesn't like the GUID?  People seem to just make up a GUID and it works for them.  Any suggestions?

Erick

#94 Re: mORMot 1 » From client side, how to detect the server has gone away. » 2016-11-10 22:18:20

NJL wrote:

Has anyone else ran into this issue?

>I also need to know this so I can handle if I've lost connection to the server to somehow cache the data being transacted locally and then feed it to the server once I'm able to talk to it again.  But if my application hangs when the server goes away I'm unable to create a solution for this.  Any guidance would be greatly appreciated.

I'm thinking of doing this by opening a websocket.  The server will  (probably) close the socket when it goes down gracefully, or the socket will close in time if the network connection fails (assuming keepalives).

E

#95 Re: mORMot 1 » Elevate Web Builder » 2016-10-31 12:03:08

@AB

I just checked it. 

Chrome blocks google's popup by default. 
recaptcha__en.js:245Uncaught DOMException: Blocked a frame with origin "https://www.google.com" from accessing a cross-origin frame.(…)
How ironic, their own browser defeats their recapta system.

I will report this.
Thanks

#96 Re: mORMot 1 » Elevate Web Builder » 2016-10-30 23:17:12

Just an update, I'm expecting the mormot book to be ready before Christmas, actually aiming for late November.  It covers essentials about mormot, and building web clients with Elevate Web Builder.  So it's end-to-end pascal!

I'll post some example videos soon.  For the time being, here is a sample of the recaptcha done with
Elevate Web Builder, showing how to weed out humans from the many bots that will try your code.

http://dark.uwaterloo.ca/temp/recaptcha.html

The book will be technically published in Canada, but available through Amazon EU, UK and US.  Today's Canadian European Trade Agreement may have an impact on price for European readers.

Erick

Take care
Erick

#97 Re: SyNode » Beta release of SyNode - ES6 JavaScript + NPM modules » 2016-10-30 14:43:35

x64 bit - incredible news!  Congratulations!!!

Erick

#98 Re: mORMot 1 » Elevate Web Builder » 2016-09-18 13:46:50

edwinsn wrote:
erick wrote:
edwinsn wrote:

Thanks for your answer, Erick, I understand you.

From what I have seen so far, EWB has advantages over SMS in that it's well documented, and is NOT mobile-only.

SMS is not mobile-only.  It can generate web pages viewable on any device.

Erick

Yes, but "viewable on any device"  != "designed with desktop web app in mind".
It's obvouse that, the layout and controls optimized for mobile web is different from one that's designed for traditional web apps.

Apple's documentation reminds developers that their mobile versions should have different goals than desktop or web apps, it's not just a screen real estate issue but also a matter of thumbs and shorter attention spans on mobile, so make it dumbed down.

Erick

#99 Re: mORMot 1 » Elevate Web Builder » 2016-09-14 12:36:16

edwinsn wrote:

Thanks for your answer, Erick, I understand you.

From what I have seen so far, EWB has advantages over SMS in that it's well documented, and is NOT mobile-only.

SMS is not mobile-only.  It can generate web pages viewable on any device.

Erick

#100 Re: mORMot 1 » Elevate Web Builder » 2016-09-14 00:40:34

I think that doing RPCs to mormot encourages one to do their business logic in the server, and leave the client for handling presentation only, which is how I'd recommend anyone program - separating logic from presentation. 

a) I recognize the SMS in the example you gave.  That one looks like SMS, it would take *me* about 15 minutes to code it in EWB except for the circled images, that would take longer because circle images aren't a native thing in EWB.  I don't know how long it would take other people, I think I might
have more experience than many.

b) Like many compiled languages, Delphi and FPC included, the executable is larger than hand-coded assember/javascript.  In fact, the first thing most people say when they compile for FPC/Lazarus is WTF, why is it so hug?  But the overhead grows linearly from that point.  For example, I have a huge 30 form application I'm doing in my job, it compiles to UNCOMPRESSED

       871,368 faculty.html
    1,672,593 faculty.js
      857,422 libsodium.min.js
          5,015 sha256.js
        68,988 shield.png
               5 File(s)      3,475,386 bytes

When compressed, the faculty.js file will be much smaller than lib sodium.min.js.  And the png and jpg images I download will be the real bandwidth hogs.

When you call services-methods or RPCs, you have a completion handler, which is the other half of your subroutine.  SMS handles that differently
than EWB - and again, it's a preference matter as to which is superior.  I think completion functions are cleaner for me to look at.  Some other people
rave about .. I forget the name... it's been a long day... but writing nameless functions, or whatever they're called.    I liken them to 8 bit assembler where you could only jump a short distance and were stuck with intermixing your code.  I think it's hideous and error-prone.  But that's how javascript people like to do it.

c) I'm not the author or owner of EWB, I've paid my subscription fees just like everyone else.   I don't know the exact price, but it was half what I pay for Delphi, and I find I'm using it more than Delphi these days.  No, it does not have code insight or code completion at this time.

The code generated for user functions is efficient, but there is overhead for the windowing library.

Erick

Board footer

Powered by FluxBB