【发布时间】:2023-03-11 22:20:02
【问题描述】:
如何检查用户是否能够更新或插入marklogic数据库中的任何文档?
例如,有4个用户,有的有更新权限,有的有权限读取marklogic数据库中的文档
try{
let $uri := abc.xml
let $doc : <a/>
if (condition)
then check whether the current user is able to update or insert the doc in marklogic or not , if it is not then throw fn:error()
else
xdmp:document-insert($uri,$doc) (:it will throw error, when user have no permission to insert the doc:)
}
catch($e)
{$e}
【问题讨论】:
标签: security authentication permissions marklogic roles