identus-cloud-agent icon indicating copy to clipboard operation
identus-cloud-agent copied to clipboard

Async issue with Identus call not complete when returning (POST present-proof) its content

Open incubiq opened this issue 1 year ago • 4 comments

Is this a regression?

Yes

Description

A call to POST present-proof/presentations/{presentationId} (see https://docs.atalaprism.io/agent-api/#tag/Present-Proof/operation/requestPresentation) can return OK but if a holder checks it straight away (within less than a second) with a GET /present-proof/presentations ?thid=<thid...> then this GET call will return empty, whereas if the holder waits a few seconds before asking, it will get it.

I do not think it is normal, since you are in control of when you insert into your own DB... so when the first POST returns, the holder should be able to do a GET straight away as soon as it gets notified.

Please provide the exception or error you saw

No response

Please provide the environment you discovered this bug in

v1.33.0

Anything else?

No response

incubiq avatar Jun 21 '24 16:06 incubiq

it seems that there is a similar problem also with the PATCH call of the holder accepting presentation request, as if the verifier checks straight away, again the call fails (this time with an error (No request found for this record: ...) whereas if the verifier waits for a few seconds, the call does not fail.

incubiq avatar Jun 21 '24 16:06 incubiq

I have not tested all cases, but I know that configs with waiting less than 4 seconds fail. In some case the call does not go into error but returns nothing, in other cases it can fail with error code 500 (Request failed with status code 500 - java.rmi.UnexpectedException: Invalid row count result: 0). I think I also got a partial proof in one case (it was missing all the claims inside) but I cannot reproduce, so I will put it as a possible error on my part, but the lack of a guaranteed same behaviour in each call is a real problem...

I have now implemented a wait of 8 seconds before each calls, and it seems to work up to the presentation of proof. I do not feel this is a correct behaviour, as I would prefer to be able to show proofs within a second, instead of having to slow down my app just because Identus would fail otherwise if I call it "normally"

incubiq avatar Jun 21 '24 17:06 incubiq

Thank you for your contribution to the project.

The core base of Hyperledger Identus maintainers is currently focused on delivering specific goals, which means that we are temporarily unable to address new issues, feature requests, or support inquiries at this time. However, we do recognize the importance of community and want to assure you that your issue, as well as all other community issues, have been noted and will be reviewed once bandwidth is available.

We will make exceptions for critical bugs or security incidents. If you are reporting a security issue, please go to this link and click the "Report a vulnerability" green button.

In the meantime, you can contact the community via our Discord channel. Other community members may be able to assist you with your issue.

We appreciate your understanding and patience as we work towards our goals. Thank you for supporting the Hyperledger Identus project!

Best regards, Hyperledger Identus Maintainers

essbante-io avatar Jun 21 '24 22:06 essbante-io

Moving it back to the cloud-agent repository. Let's discuss it at the architecture meeting. Probably, @amagyar-iohk should try to reproduce the issue and add more details.

yshyn-iohk avatar Jun 04 '25 07:06 yshyn-iohk