Skip to content

XSLT Parameter Tutorial#3076

Merged
rrayst merged 1 commit into
masterfrom
xslt-parameters-tutorial
Jul 10, 2026
Merged

XSLT Parameter Tutorial#3076
rrayst merged 1 commit into
masterfrom
xslt-parameters-tutorial

Conversation

@predic8

@predic8 predic8 commented Jul 10, 2026

Copy link
Copy Markdown
Member

…Interceptor

Summary by CodeRabbit

  • New Features

    • Added a tutorial demonstrating how exchange properties can be passed as XSLT parameters.
    • Added an XSLT example that enriches XML output with a configurable library attribute.
  • Tests

    • Added integration coverage verifying the tutorial’s transformed XML response and HTTP behavior.
  • Documentation

    • Expanded XSLT interceptor documentation with clearer configuration examples.

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 10adcbba-9250-4a24-893b-e3cff2530d8c

📥 Commits

Reviewing files that changed from the base of the PR and between d6d92d4 and 7150e2e.

📒 Files selected for processing (4)
  • core/src/main/java/com/predic8/membrane/core/interceptor/xslt/XSLTInterceptor.java
  • distribution/src/test/java/com/predic8/membrane/tutorials/xml/XsltParameterTutorialTest.java
  • distribution/tutorials/xml/41-XSLT-Parameter.yaml
  • distribution/tutorials/xml/add-library.xsl

📝 Walkthrough

Walkthrough

Adds an XSLT parameter tutorial with a YAML route, stylesheet, and integration test. The XSLT interceptor receives documentation and formatting-only updates without observable behavior changes.

Changes

XSLT parameter tutorial

Layer / File(s) Summary
XSLT interceptor updates
core/src/main/java/com/predic8/membrane/core/interceptor/xslt/XSLTInterceptor.java
Updates class documentation and transformer initialization formatting while preserving existing behavior.
Tutorial transformation flow
distribution/tutorials/xml/41-XSLT-Parameter.yaml, distribution/tutorials/xml/add-library.xsl, distribution/src/test/java/com/predic8/membrane/tutorials/xml/XsltParameterTutorialTest.java
Configures an exchange property as an XSLT parameter, adds the stylesheet transformation, and verifies the HTTP 200 XML response.

Estimated code review effort: 2 (Simple) | ~10 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Client
  participant MembraneGateway
  participant XSLTInterceptor
  Client->>MembraneGateway: POST books.xml
  MembraneGateway->>XSLTInterceptor: Set library exchange property
  XSLTInterceptor->>XSLTInterceptor: Apply add-library.xsl with library
  XSLTInterceptor-->>MembraneGateway: Return transformed books XML
  MembraneGateway-->>Client: HTTP 200 XML response
Loading

Possibly related PRs

Suggested reviewers: rrayst, christiangoerdes

Poem

A rabbit hops through XML bright,
Passing library left and right.
The stylesheet blooms, books align,
“predic8” shines on every line.
Tests thump softly: status two-oh-oh!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: a new XSLT parameter tutorial with supporting interceptor updates.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch xslt-parameters-tutorial

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@rrayst rrayst merged commit 92af82a into master Jul 10, 2026
5 checks passed
@rrayst rrayst deleted the xslt-parameters-tutorial branch July 10, 2026 08:49
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.

2 participants