Timestamps in versions above 2.0.0

I have a question regarding the Daml version above 2.0.0:

I have in hands a daml project that consists in a system of 2 participants and 1 domain, and I would like to make performance tests based on time. I noticed that when a contract is created with participant1 in which participant2 is observer, the contract creation date is the same in both participants. However, participant1 creates the contract at a certain time, the information reaches the domain, and only then participant2 has access to the contract. I wonder if there is any way to know the time of arrival of the contract to the domain, and the time when participant2 notices that a contract was created? Is it possible to create a timestamp in sourcecode?

Hi @Derek , I would recommend taking timings in API clients for benchmark purposes. The “domain time” is called record time on the API and tells you the time of commit, but if the domain is on its own machine, that doesn’t help you time from submission to commit as you’d need a precise measurement of clock skew between the machines.

1 Like