Canton behaviour when handling non-enabled informee (observer)

Hi Team,

For a testing I see some interesting behaviours on canton when handling non-enabled (non-allocated) informee.

I am using examples/01-simple-topology and a project defined with daml new testproject, without modifying anything. Both daml sdk and canton run in 2.3.1.

The canton network is brought up. Alice is enabled on participant1 while Bob is NOT enabled on participant2 (later Bob is used as the unknown informee in the tests). DAR is uploaded in both participant nodes, I use Navigator to access participant1 act as Alice to perform the following test.

Test 1: Alice creates an asset in which Alice is owner, and then Alice exercises Give to Bob (where Bob is carrying the same namespace of participant2, i.e. Bob::<ns_pn2>)

I see in the log that multi-domain is needed

2022-08-22 07:17:20,358 [canton-env-execution-context-27] INFO  c.d.c.p.s.CantonSyncService:participant=participant1 tid:10181f4a2e2f5107d4417b2b903b484b - MULTI_DOMAIN_SUPPORT_NOT_ENABLED(9,10181f4a): This transaction requires multi-domain support which is turned off on this participant.
 Used contracts reside on domains Set(mydomain::1220a52c66fa...).  err-context:{applicationId=Navigator-2dd4f270-a5cf-4bcc-ab46-997f5e3fb77f#4cc06f119409c611, commandId=9ea3e5d325f66bb5, domains=Set(mydomain::1220a52c66fa...), location=DomainRouter.scala:172} 
2022-08-22 07:17:20,385 [canton-env-execution-context-27] INFO  c.d.p.a.s.ApiSubmissionService - Rejected: Submission failed with error MULTI_DOMAIN_SUPPORT_NOT_ENABLED(9,10181f4a): This transaction requires multi-domain support which is turned off on this participant.
 Used contracts reside on domains Set(mydomain::1220a52c66fa...). , context: {participant: "participant1", commands: {readAs: [], deduplicationPeriod: {duration: "PT30S"}, submittedAt: "2022-08-22T06:17:20.338799Z", ledgerId: "participant1", applicationId: "Navigator-2dd4f270-a5cf-4bcc-ab46-997f5e3fb77f#4cc06f119409c611", submissionId: "203af922-ed4e-4e9c-8c7b-7aadf726f01e", actAs: ["Alice::122059180064044c1e3bac79eb43cbcc233497133af57d9d3f8e52369835a6d64e76"], commandId: "9ea3e5d325f66bb5", workflowId: "20d9aeb18d34062f"}}
2022-08-22 07:17:20,388 [canton-env-execution-context-27] INFO  c.d.c.n.g.ApiRequestLogger:participant=participant1 tid:10181f4a2e2f5107d4417b2b903b484b - Request c.d.l.a.v.CommandSubmissionService/Submit by /127.0.0.1:61172: failed with FAILED_PRECONDITION/MULTI_DOMAIN_SUPPORT_NOT_ENABLED(9,10181f4a): This transaction requires multi-domain support which is turned off on this participant.
 Used contracts reside on domains Set(mydomain::1220a52c66fa...). 

Test 2: Alice creates an asset in which Bob is owner (where Bob is carrying the same namespace of participant2, i.e. Bob::<ns_pn2>)

The log shows that the informee not known.

2022-08-22 07:23:03,557 [canton-env-execution-context-21] INFO  c.d.p.a.s.ApiSubmissionService - Submitting transaction, context: {participant: "participant1", commands: {readAs: [], deduplicationPeriod: {duration: "PT30S"}, submittedAt: "2022-08-22T06:23:03.556745Z", ledgerId: "participant1", applicationId: "Navigator-2dd4f270-a5cf-4bcc-ab46-997f5e3fb77f#4cc06f119409c611", submissionId: "f6b373bf-9bc5-4f22-b59b-84b7a3bdc868", actAs: ["Alice::122059180064044c1e3bac79eb43cbcc233497133af57d9d3f8e52369835a6d64e76"], commandId: "594e62e2c6d04cff", workflowId: "f4b6bf5f54aa722"}}
2022-08-22 07:23:03,566 [canton-env-execution-context-22] INFO  c.d.c.p.s.CantonSyncService:participant=participant1 tid:dbe8a0bede359f577974e25ebb12c85f - UNKNOWN_INFORMEES(11,dbe8a0be): The participant is not connected to any domain where the given informees are known. err-context:{applicationId=Navigator-2dd4f270-a5cf-4bcc-ab46-997f5e3fb77f#4cc06f119409c611, commandId=594e62e2c6d04cff, location=DomainRouter.scala:770, unknownInformees=Set(Bob::122039f0ce6d8fa9bf4d56824a6582a01f9e3c57dee4b428ca4afcecbce85fbbd131)} 
2022-08-22 07:23:03,566 [canton-env-execution-context-22] INFO  c.d.p.a.s.ApiSubmissionService - Rejected: Submission failed with error UNKNOWN_INFORMEES(11,dbe8a0be): The participant is not connected to any domain where the given informees are known., context: {participant: "participant1", commands: {readAs: [], deduplicationPeriod: {duration: "PT30S"}, submittedAt: "2022-08-22T06:23:03.556745Z", ledgerId: "participant1", applicationId: "Navigator-2dd4f270-a5cf-4bcc-ab46-997f5e3fb77f#4cc06f119409c611", submissionId: "f6b373bf-9bc5-4f22-b59b-84b7a3bdc868", actAs: ["Alice::122059180064044c1e3bac79eb43cbcc233497133af57d9d3f8e52369835a6d64e76"], commandId: "594e62e2c6d04cff", workflowId: "f4b6bf5f54aa722"}}
2022-08-22 07:23:03,567 [canton-env-execution-context-21] INFO  c.d.c.n.g.ApiRequestLogger:participant=participant1 tid:dbe8a0bede359f577974e25ebb12c85f - Request c.d.l.a.v.CommandSubmissionService/Submit by /127.0.0.1:61172: failed with NOT_FOUND/UNKNOWN_INFORMEES(11,dbe8a0be): The participant is not connected to any domain where the given informees are known.

Questions

(1) It seems the handling of contract creation (test 2) and exercising choice (test 1) is different. See if it’s the correct case.

(2) In this case the error message “multi-domain” (test 1) is less intuitive as it is not something on top of my mind. The message of “unknown informee” (test2) is more correct.

(3) Finally, and most importantly, in test 2, despite the fact that Bob::<ns_pn2> is not enabled, is it possible that participant1 continues processing as long as the ns_pn2 is correct? Bob will receive back this contract once it is enabled on pn2 later.

Thanks in advance.

kc

Hi @kctam

Apologies for the bad error messages. We’ve noticed that the error reporting in the DomainRouter with respect to unknown has room for improvement. We’ve scheduled this for Q3, so will likely be fixed in 2.5.

Cheers,
Ratko

1 Like