Lucee 6.2 and SOAP webservices throwing an error

Description

After I upgraded to Lucee 6.2.0.321 from version 5.4 calling a simple webservice like:

component { remote string function hello() { return "My response"; } }

in SoapUI

<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:def="http://DefaultNamespace"> <soapenv:Header/> <soapenv:Body> <def:hello soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/> </soapenv:Body> </soapenv:Envelope>

I found an error - lucee.runtime.exp.NativeException: lucee.runtime.op.Caster.cfTypeToClass(java.lang.String):

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <soapenv:Fault> <faultcode>soapenv:Server.userException</faultcode> <faultstring>lucee.runtime.exp.NativeException: ; nested exception is: lucee.runtime.exp.NativeException: lucee.runtime.op.Caster.cfTypeToClass(java.lang.String)</faultstring> <detail> <ns1:hostname xmlns:ns1="http://xml.apache.org/axis/">MY-PC</ns1:hostname> </detail> </soapenv:Fault> </soapenv:Body> </soapenv:Envelope>

 

This worked OK in Lucee 5.4.

Generated WSDL also seemes OK.

<wsdl:definitions xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://localhost:9006/simple.cfc" xmlns:intf="http://localhost:9006/simple.cfc" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://localhost:9006/simple.cfc"> <script/> <!-- WSDL created by Apache Axis version: 1.4 Built on Apr 22, 2006 (06:55:48 PDT) --> <wsdl:message name="helloRequest"> </wsdl:message> <wsdl:message name="helloResponse"> <wsdl:part name="helloReturn" type="xsd:string"/> </wsdl:message> <wsdl:portType name="simple_wrap"> <wsdl:operation name="hello"> <wsdl:input message="impl:helloRequest" name="helloRequest"/> <wsdl:output message="impl:helloResponse" name="helloResponse"/> </wsdl:operation> </wsdl:portType> <wsdl:binding name="simple.cfcSoapBinding" type="impl:simple_wrap"> <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> <wsdl:operation name="hello"> <wsdlsoap:operation soapAction=""/> <wsdl:input name="helloRequest"> <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://DefaultNamespace" use="encoded"/> </wsdl:input> <wsdl:output name="helloResponse"> <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://localhost:9006/simple.cfc" use="encoded"/> </wsdl:output> </wsdl:operation> </wsdl:binding> <wsdl:service name="simple_wrapService"> <wsdl:port binding="impl:simple.cfcSoapBinding" name="simple.cfc"> <wsdlsoap:address location="http://localhost:9006/simple.cfc"/> </wsdl:port> </wsdl:service> </wsdl:definitions>

 

Is maybe a problem in method cfTypeToClass in Caster.java file?
https://github.com/lucee/Lucee/blob/6.2.0.321/core/src/main/java/lucee/runtime/op/Caster.java

Environment

  • Windows 11

  • JDK 21 LTS

  • Lucee 6.2.0.321, 6.2.1.107-SNAPSHOT

  • Axis extension 1.4.0.37

  • SoapUI 5.8.0

Attachments

2
  • 04 Apr 2025, 02:12 pm
  • 03 Apr 2025, 01:19 pm

Activity

Show:

alokra 2 days ago

Great, will test it when possible. Thank you!

Michael Offner 2 days ago

okay, found and fixed the problem.
https://github.com/lucee/Lucee/commit/17bd5c10ae93e5fbd9a32a07fb5306df9b450898

Problem is that the Axis Extension has a dynamic reference (via reflection) to the Caster class to a method no longer existing in Lucee 6.2.
This is from a time, Lucee was not yet providing a Caster interface for the outside world.

For the moment i added the missing method again to Lucee 6.2 and marked it, so it not get removed again in the future, i also made sure there are no other similar cases.

A better long time solution would be to rewrite the Axis extension, so it no longer depend on this dynamic method calls.
We did in the pat look for modern replacement of the Axis library without reinventing the wheel, sadly with no success.

So in short the issue should be fixed

Zac Spitzer 2 days ago

let me knock up an integration test over at

https://github.com/lucee/lucee-testlab

Michael Offner 2 days ago

i agree, problem is that we run our test cases via JSR223, that mean we have no web server running, but maybe has an idea how we could achieve that.

alokra 2 days ago

I understand the problem.

Details

Assignee

Reporter

Priority

Fix versions

New Issue warning screen

Before you create a new Issue, please post to the mailing list first https://dev.lucee.org

Once the issue has been verified, one of the Lucee team will ask you to file an issue

Affects versions

Created 3 days ago
Updated 2 days ago

Flag notifications