Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade CXF to 4.0.4-SNAPSHOT #312

Merged
merged 7 commits into from
Nov 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 28 additions & 24 deletions .github/workflows/wildfly-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,45 +4,49 @@ name: WildFly Test Build

on:
schedule:
- cron: '30 0 * * *' # Every day at 00:30 UTC
- cron: '30 0 * * *' # Every day at 00:30 UTC

jobs:
wildfly-build:
runs-on: ubuntu-latest
outputs:
wildfly-version: ${{steps.version.outputs.wildfly-version}}
uses: wildfly/wildfly/.github/workflows/shared-wildfly-build.yml@main
with:
wildfly-branch: "main"
wildfly-repo: "wildfly/wildfly"
jbossws-build:
runs-on: ${{ matrix.os }}
needs: wildfly-build
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest]
java: [ '17']
steps:
- name: Checkout WildFly
uses: actions/checkout@v2
- uses: actions/checkout@v4
- uses: actions/download-artifact@v3
with:
repository: wildfly/wildfly
fetch-depth: 0
- name: Set up JDK 11
uses: actions/setup-java@v2
name: wildfly-maven-repository
path: .
- name: Extract Maven Repo
shell: bash
run: tar -xzf wildfly-maven-repository.tar.gz -C ~
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v3
with:
java-version: 11
distribution: 'adopt'
java-version: ${{ matrix.java }}
distribution: 'temurin'
cache: 'maven'
- name: Build WildFly
run: 'mvn clean install -Prelease,gendoc -DskipTests -Dcheckstyle.skip=true -Denforcer.skip=true'
- id: version
run: echo "::set-output name=wildfly-version::$(mvn -B help:evaluate -Dexpression=project.version -pl . | grep -v '^\[')"
- name: Checkout jbossws-cxf
uses: actions/checkout@v2
with:
repository: jbossws/jbossws-cxf
- name: Build with Maven Java ${{ matrix.java }} on WildFly ${{needs.wildfly-build.outputs.wildfly-version}}
run: |
mvn -s ./.m2-settings.xml -B -V -fae -Pwildflydev clean install
- name: Upload surefire reports
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
if: failure()
with:
name: surefire-reports-${{ matrix.os }}-${{ matrix.java }}
path: '**/surefire-reports/*.*'
path: '**/surefire-reports/'
- name: Upload server logs
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
if: failure()
with:
name: server-logs-${{ matrix.os }}-${{ matrix.java }}
path: '**/*/*.log'
path: '**/*.log'
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,6 @@ public class Constants
public static final String JBWS_CXF_JAXWS_CLIENT_BUS_SELECTOR = "org.jboss.ws.cxf.jaxws-client.bus.selector";
public static final String JBWS_CXF_DISABLE_DEPLOYMENT_USER_DEFAULT_THREAD_BUS = "org.jboss.ws.cxf.disable-deployment-user-default-thread-bus";
public static final String JBWS_CXF_DISABLE_SCHEMA_CACHE = "org.jboss.ws.cxf.disableSchemaCache";
//The flag to force use the URLConnectionHTTPConduit instead of the HttpClientHTTPConduit since CXF 4.0.3
public static final String FORCE_URL_CONNECTION_CONDUIT = "force.urlconnection.http.conduit";
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import org.apache.cxf.configuration.Configurer;
import org.apache.cxf.resource.ResourceManager;
import org.jboss.wsf.stack.cxf.client.ClientBusSelector;
import org.jboss.wsf.stack.cxf.client.Constants;
import org.jboss.wsf.stack.cxf.client.ProviderImpl;
import org.jboss.wsf.stack.cxf.client.injection.JBossWSResourceInjectionResolver;

Expand All @@ -45,7 +46,7 @@
public class JBossWSBusFactory extends CXFBusFactory
{
private static final Map<ClassLoader, Bus> classLoaderBusses = new WeakHashMap<ClassLoader, Bus>();

private final boolean forceURLConnectionConduit = Boolean.getBoolean(Constants.FORCE_URL_CONNECTION_CONDUIT);
@Override
public Bus createBus(Map<Class<?>, Object> extensions, Map<String, Object> properties) {
if (extensions == null)
Expand Down Expand Up @@ -75,6 +76,9 @@ protected void initializeBus(Bus bus) {
final ResourceManager resourceManager = bus.getExtension(ResourceManager.class);
resourceManager.addResourceResolver(JBossWSResourceInjectionResolver.getInstance());
SecurityProviderConfig.setup(bus);
if (forceURLConnectionConduit) {
bus.setProperty(Constants.FORCE_URL_CONNECTION_CONDUIT, true);
}
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,12 @@
import org.apache.cxf.transport.MessageObserver;
import org.apache.cxf.transport.http.HTTPConduit;
import org.jboss.logging.Logger;
import org.jboss.wsf.stack.cxf.client.Constants;

public class SOAPConnectionImpl extends SOAPConnection
{
private volatile boolean closed = false;
private volatile boolean closed = false;
private boolean forceURLConnectionConduit = Boolean.getBoolean(Constants.FORCE_URL_CONNECTION_CONDUIT);

@Override
public SOAPMessage call(SOAPMessage msgOut, Object addressObject) throws SOAPException
Expand All @@ -74,6 +76,9 @@ public SOAPMessage call(SOAPMessage msgOut, Object addressObject) throws SOAPExc
Exchange exch = new ExchangeImpl();
outMessage.setExchange(exch);
exch.put("org.apache.cxf.transport.process_fault_on_http_400", true); //JBWS-3945
if (forceURLConnectionConduit) {
exch.put(Constants.FORCE_URL_CONNECTION_CONDUIT, true);
}

// sent SOAPMessage
try
Expand Down
125 changes: 125 additions & 0 deletions modules/feature-pack/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,131 @@
<artifactId>opensaml-xacml-saml-impl</artifactId>
<scope>provided</scope>
</dependency>
<!--CXF dependencies-->
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-security</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-bindings-soap</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-bindings-coloc</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-databinding-jaxb</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-features-clustering</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-jaxws</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-management</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-transports-http</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-transports-jms</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-transports-local</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-transports-http-hc</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-bindings-xml</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-simple</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-addr</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-wsdl</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-mex</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-rm</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-policy</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-tools-java2ws</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.services.sts</groupId>
<artifactId>cxf-services-sts-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.services.ws-discovery</groupId>
<artifactId>cxf-services-ws-discovery-api</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-tools-wsdlto-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-tools-wsdlto-databinding-jaxb</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-tools-wsdlto-frontend-jaxws</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-features-logging</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.xjcplugins</groupId>
<artifactId>cxf-xjc-boolean</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.xjcplugins</groupId>
<artifactId>cxf-xjc-bug986</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.xjcplugins</groupId>
<artifactId>cxf-xjc-dv</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.xjcplugins</groupId>
<artifactId>cxf-xjc-ts</artifactId>
</dependency>
<dependency>
<groupId>org.apache.cxf.xjc-utils</groupId>
<artifactId>cxf-xjc-runtime</artifactId>
</dependency>
<dependency>
<groupId>org.wildfly</groupId>
<artifactId>wildfly-ee-galleon-pack</artifactId>
Expand Down
Loading
Loading