### Apply Spotless formatting to all modules
Source: https://github.com/apache/ws-axiom/blob/master/AGENTS.md
Run this command to format Java source files across the entire project.
```bash
./mvnw spotless:apply
```
--------------------------------
### Deploy and publish site
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Deploy the Maven site and publish it to the staging repository.
```sh
mvn site-deploy
mvn scm-publish:publish-scm -Dscmpublish.skipCheckin=true
```
--------------------------------
### Configure Maven settings for release
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Add the GPG passphrase and Nexus credentials to your ~/.m2/settings.xml file to enable automated signing and deployment.
```xml
...
apache-release
...
```
```xml
...
apache.releases.https
...
```
--------------------------------
### Apply Spotless formatting to a specific module
Source: https://github.com/apache/ws-axiom/blob/master/AGENTS.md
Run this command to format Java source files within a specific Maven module.
```bash
./mvnw -pl spotless:apply
```
--------------------------------
### Configure OMMetaFactory for DOOM
Source: https://github.com/apache/ws-axiom/blob/master/src/site/markdown/release-notes/1.2.9.md
Set this system property to use the DOOM implementation.
```text
org.apache.axiom.om.OMMetaFactory=org.apache.axiom.om.impl.dom.factory.OMDOMMetaFactory
```
--------------------------------
### Configure OMMetaFactory for LLOM
Source: https://github.com/apache/ws-axiom/blob/master/src/site/markdown/release-notes/1.2.9.md
Set this system property to use the LLOM implementation, which is the default behavior.
```text
org.apache.axiom.om.OMMetaFactory=org.apache.axiom.om.impl.llom.factory.OMLinkedListMetaFactory
```
--------------------------------
### Execute Maven release commands
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Use these commands to prepare and perform the release process via the Maven release plugin.
```sh
mvn release:prepare
```
```sh
mvn release:perform
```
--------------------------------
### Publish the project website via SVN
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Updates the project website by checking out the site repository, removing the old version, and moving the staged site into place.
```sh
svn co --depth=immediates https://svn.apache.org/repos/asf/webservices/website ws-site
cd ws-site
svn rm axiom
svn mv axiom-staging axiom
svn commit
```
--------------------------------
### Execute Maven release commands
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Commands to verify the release profile, perform a dry run, and clean up the release environment.
```sh
mvn clean install -Papache-release -DskipTests=true
```
```sh
mvn release:prepare -DdryRun=true
```
```sh
mvn release:clean
```
--------------------------------
### Run axiom-testsuite validation tests
Source: https://github.com/apache/ws-axiom/blob/master/testing/axiom-testsuite/AGENTS.md
Execute this command to run tests for both axiom-impl and axiom-dom implementations after modifying the test suite.
```bash
./mvnw -pl testing/axiom-testsuite,implementations/axiom-impl,implementations/axiom-dom -am test
```
--------------------------------
### Create site staging area
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Copy the current website to a staging area for review before publication.
```sh
svn copy \
https://svn.apache.org/repos/asf/webservices/website/axiom \
https://svn.apache.org/repos/asf/webservices/website/axiom-staging
```
--------------------------------
### Visualize Guice Injector Hierarchy
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
A structural representation of how the root injector branches into child injectors based on dimension values to satisfy test case dependencies.
```text
Root Injector
binds: implementation-level objects
│
├─ Child Injector (DimensionA → value1)
│ ├─ MatrixTest → injector.getInstance(SomeTestCase.class) → setUp/runTest/tearDown
│ └─ MatrixTest → injector.getInstance(AnotherTestCase.class) → setUp/runTest/tearDown
│
└─ Child Injector (DimensionA → value2)
├─ MatrixTest → injector.getInstance(SomeTestCase.class) → setUp/runTest/tearDown
└─ MatrixTest → injector.getInstance(AnotherTestCase.class) → setUp/runTest/tearDown
```
--------------------------------
### Define a Matrix Test Suite
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
Construct a test suite by building an InjectorNode with fan-out dimensions and registered test classes.
```java
public class MyTestSuite {
public static MatrixTestNode create(SomeFactory factory) {
SomeImplementation impl = new SomeImplementation(factory);
FanOutNode dimensions = new FanOutNode<>(
Multiton.getInstances(SomeDimension.class),
Binding.singleton(Key.get(SomeDimension.class)),
LabelBinding.simpleString("dimension", SomeDimension::getName),
new ParentNode(
new MatrixTest(TestSomeBehavior.class),
new MatrixTest(TestOtherBehavior.class)));
MatrixTestNode suite = new InjectorNode(
binder -> binder.bind(SomeImplementation.class).toInstance(impl),
dimensions);
return suite;
}
}
```
--------------------------------
### Publish distribution artifacts via SVN
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Moves the release artifacts from the development repository to the release repository using SVN.
```sh
svn mv https://dist.apache.org/repos/dist/dev/ws/axiom/ \
https://dist.apache.org/repos/dist/release/ws/axiom/
```
--------------------------------
### Export GPG public key
Source: https://github.com/apache/ws-axiom/blob/master/docs/release-process.md
Export your public key to be added to the project's KEYS file.
```sh
gpg --armor --export
```
--------------------------------
### Implement Single-Method Test Case
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
Define a test class implementing Executable with dependencies injected via @Inject.
```java
public class TestSomeBehavior implements Executable {
@Inject private SomeImplementation impl;
@Inject private SomeDimension dimension;
@Override
public void execute() throws Throwable {
// test logic using injected fields
}
}
```
--------------------------------
### Define InjectorNode toDynamicNodes method
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
The method signature for creating dynamic nodes within an InjectorNode.
```java
public Stream toDynamicNodes(BiPredicate, Map> excludes)
```
--------------------------------
### Implement Multi-Method Test Case
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
Group related tests in a class using @org.apache.axiom.testutils.suite.Test to ensure independent execution per method.
```java
public class SomeBehaviorTests {
@Inject private SomeImplementation impl;
@Inject private SomeDimension dimension;
@Test
public void behaviorA() throws Throwable {
// test logic
}
@Test
public void behaviorB() throws Throwable {
// test logic
}
}
```
--------------------------------
### Register Multi-Method Test Container
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
Register the multi-method test class as a single leaf node using MatrixTestContainer.
```java
new MatrixTestContainer(SomeBehaviorTests.class)
```
--------------------------------
### Legacy Iterator Usage Pattern
Source: https://github.com/apache/ws-axiom/blob/master/src/site/markdown/release-notes/1.2.11.md
This pattern was used internally in previous versions but is now problematic because next() no longer builds the node, causing issues when attempting to consume nodes.
```java
while (children.hasNext()) {
OMNodeEx omNode = (OMNodeEx) children.next();
omNode.internalSerializeAndConsume(writer);
}
```
--------------------------------
### Consume a Matrix Test Suite in JUnit 5
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
Implement a @TestFactory method to convert the test suite into dynamic nodes, optionally applying filters.
```java
class MyImplTest {
@TestFactory
Stream tests() {
MatrixTestNode suite = MyTestSuite.create(new MyFactoryImpl());
MatrixTestFilters excludes = MatrixTestFilters.builder()
.add(TestSomeBehavior.class, "(dimension=problematicValue)")
.build();
return suite.toDynamicNodes(excludes);
}
}
```
--------------------------------
### Define MatrixTestNode abstract method
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
The base class for all nodes in the test tree, requiring implementation of the toDynamicNodes method.
```java
abstract Stream toDynamicNodes(
Injector parentInjector,
Map inheritedLabels,
BiPredicate, Map> excludes);
```
--------------------------------
### Register Single-Method Test
Source: https://github.com/apache/ws-axiom/blob/master/testing/matrix-testsuite/README.md
Register the test class as a leaf node in the matrix.
```java
new MatrixTest(TestSomeBehavior.class)
```
--------------------------------
### Removing Child Elements via Iterator
Source: https://github.com/apache/ws-axiom/blob/master/src/site/markdown/release-notes/1.2.11.md
Demonstrates the transition from using detach() on the element to using the iterator's remove() method to safely remove elements during iteration.
```java
Iterator iterator = element.getChildrenWithName(qname);
while (iterator.hasNext()) {
OMElement child = (OMElement)iterator.next();
child.detach();
}
```
```java
Iterator iterator = element.getChildrenWithName(qname);
while (iterator.hasNext()) {
iterator.next();
iterator.remove();
}
```
=== COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.