DAML application on postgres and DLT/Blockchain

Can a DAML application be developed on Postgres and then place the same over HLF?
What are the major and minor changes to be made in the process, tech stack or an application?

How is organization separation and Consensus achieved when DAML application is developed on Postgresql instead of HLF?

Postgresql stores structured data and CouchDB stores unstructured data, how is this managed?

Hi @Hem-M,

Generally speaking, it’s easier for everyone involved if you open one thread per question, preferably with a clear title. When you put four separate questions in a single message like you did here, it makes it a lot harder for anyone to answer (“I only know the answer to two of them. Better to wait and see if someone else knows all of it.”). It makes it harder to decide whether the topic is answered, and to choose which message is “the correct answer”. And it makes it harder for anyone looking at message titles to decide whether the topic will be interesting to them, as you’re kind of forced, as you did here, to go for a .very generic title.

With all that said, I’ll take a stab at it.

Daml code, as observable through the Ledger API, will run functionally the same regardless of the underlying storage technology. So in that sense, yes, you can develop with PostgreSQL backend (or even in-memory, which is generally the recommended backend for development) and then run production on Fabric.

However, non-functional requirements will differ. Performance may be different, and specifically performance characteristics may be different. Maybe one backend will be faster with lots of small transactions, and another backend will be faster with fewer, bigger ones. If you need maximum performance, you may want to start testing from the ground up on the same storage you’ll end up using in production.

Privacy characteristics can also be different depending on storage. Daml always has the same privacy guarantees as seen through the Ledger API, but different backends can have different stories when given direct access to the underlying storage.

Finally, the story on both PostgreSQL and Fabric changes significantly with Daml 2, though I’m not the best person to give more details on that.

Or to answer the other three questions.