When trying to use the current version on eXist-db 6.x.x the following error is reported:
HTTP ERROR 500 jakarta.servlet.ServletException: jakarta.servlet.ServletException: An error occurred while processing request to /exist/apps/myapp/index.html: err:XPTY0004 xs:dateTimeStamp(2023-08-25T14:22:00.502-05:00) is not a sub-type of xs:string [at line 114, column 49, source: /db/apps/existdb-saml/content/exsaml.xqm] In function: exsaml:store-authnreqid(xs:string, xs:string) [114:19:/db/apps/existdb-saml/content/exsaml.xqm] exsaml:build-saml-authnreq() [92:17:/db/apps/existdb-saml/content/exsaml.xqm] exsaml:build-authnreq-redir-url(xs:string) [53:29:/db/apps/existdb-saml/content/exsaml.xqm]
This occurs because fn:dateTime has been updated to be in compliance with the newer XQuery 3.1 definition, which causes it to return as xs:dateTimeStamp, this cannot be simply downcast to an xs:string which is what the function exsaml:store-authnreqid expects.
Instead to fix this (whilst maintaining backwards compatibility) the value should be passed around as an xs:dateTime.
When trying to use the current version on eXist-db 6.x.x the following error is reported:
This occurs because
fn:dateTime
has been updated to be in compliance with the newer XQuery 3.1 definition, which causes it to return asxs:dateTimeStamp
, this cannot be simply downcast to anxs:string
which is what the functionexsaml:store-authnreqid
expects. Instead to fix this (whilst maintaining backwards compatibility) the value should be passed around as anxs:dateTime
.