Skip to content

MLE-31887 Refactor xdmp privileges in test-rest-writer - #1967

Merged
jonmille merged 5 commits into
developfrom
MLE-31877-Refactor-xdmp-privileges
Aug 12, 2026
Merged

MLE-31887 Refactor xdmp privileges in test-rest-writer#1967
jonmille merged 5 commits into
developfrom
MLE-31877-Refactor-xdmp-privileges

Conversation

@jonmille

@jonmille jonmille commented Aug 12, 2026

Copy link
Copy Markdown

Changes:

  • Moved privileges xdmp:invoke, xdmp:xslt-invoke, xdmp:xslt-eval, and xdmp:value from test-rest-writer role to new role test-invoke.
  • Created new user writer-no-default-invoke to use new role test-invoke.
  • Updated AbstractOpicUpdateTest.java to use new user writer-no-default-invoke since it needs the xdmp:invoke privilege

Tests Requiring xdmp privileges:
xsltTransformWithoutParam() – com.marklogic.client.test.rows.TransformDocTest — XSLT stylesheet invoked by URI; needs xdmp:xslt-invoke

  • Error w/o privilege: com.marklogic.client.ForbiddenUserException: Local message: User is not allowed to apply resource at rows/update. Server Message: You do not have permission to this method and URL.

xsltTransformWithParam() – com.marklogic.client.test.rows.TransformDocTest — XSLT stylesheet invoked by URI; needs xdmp:xslt-invoke

  • Error w/o privilege: com.marklogic.client.ForbiddenUserException: Local message: User is not allowed to apply resource at rows/update. Server Message: You do not have permission to this method and URL.

testUsingFromParamAndSchematron() – com.marklogic.client.test.rows.ValidateDocTest — schematron compiled to XSLT (xdmp:xslt-invoke + xdmp:xslt-eval) then written via fromParam (xdmp:value)

  • Error w/o privilege: com.marklogic.client.ForbiddenUserException: Local message: User is not allowed to apply resource at rows/update. Server Message: You do not have permission to this method and URL.

https://progresssoftware.atlassian.net/browse/MLE-31877
Reference PR: #1966

Adding back the unprotected-uri and unprotected- collections privilege removed as part of xdmp-login removal
Adding "xdmp:xslt-invoke", "xdmp:xslt-eval", and "xdmp:value" to test-rest-writer role to fix tests. These were removed when java-test-xdmp-login.json was deleted.
Moved privileges `xdmp:invoke`, `xdmp:xslt-invoke`, `xdmp:xslt-eval`, and `xdmp:value` from test-rest-writer role to new role test-invoke.
Created new user writer-no-default-invoke to use new role test-invoke.
Updated AbstractOpicUpdateTest.java to use new user writer-no-default-invoke since it needs the `xdmp:invoke` privilege
rjrudin
rjrudin previously approved these changes Aug 12, 2026
RitaChen609
RitaChen609 previously approved these changes Aug 12, 2026
@jonmille
jonmille changed the base branch from MLE-31877-Revert-xdmp-login-changes to develop August 12, 2026 15:50
@jonmille
jonmille dismissed stale reviews from RitaChen609 and rjrudin August 12, 2026 15:50

The base branch was changed.

@jonmille
jonmille requested a review from RitaChen609 August 12, 2026 16:00
@jonmille
jonmille merged commit 0c45494 into develop Aug 12, 2026
4 checks passed
@jonmille
jonmille deleted the MLE-31877-Refactor-xdmp-privileges branch August 12, 2026 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants