Bug 240909 - [80cat]Unable to Generate Webservice client with Glassfish 4
Summary: [80cat]Unable to Generate Webservice client with Glassfish 4
Status: RESOLVED WORKSFORME
Alias: None
Product: webservices
Classification: Unclassified
Component: Client (show other bugs)
Version: 8.0
Hardware: Macintosh Mac OS X
: P3 normal with 1 vote (vote)
Assignee: Milan Kuchtiak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-24 03:25 UTC by manikantannaren
Modified: 2015-05-07 12:51 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description manikantannaren 2014-01-24 03:25:42 UTC
[ BUILD # : 201401230001 ]
[ JDK VERSION : 1.8 ]

Setup:

Refer tutorial - https://netbeans.org/kb/docs/websvc/client.html for creating
project using Lastest build with Glassfish 4 server


STEPS:
   * Create a webservice client by using the WSDL provided in the tutorial    
http://wsf.cdyne.com/SpellChecker/check.asmx?wsdl
   * Click on button "Click me"

ACTUAL:
Generate sources and WS references

EXPECTED:
  Exception (Full stack trace below)

ant -f /Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1
wsimport-client-check
init:
wsimport-init:
Created dir:
/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/build/generated-sourc
es/jax-ws
wsimport-client-check:
Created dir:
/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/build/generated/jax-w
sCache/check
JAX-WS RI 2.2.8
command line: wsimport -d
/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/build/generated/jax-w
sCache/check -extension -Xnocompile -Xendorsed -keep -s
/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/build/generated/jax-w
sCache/check -encoding UTF-8 -catalog
/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/catalog.xml -verbose
/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/src/conf/xml-resource
s/web-service-references/check/wsdl/wsf.cdyne.com/SpellChecker/check.asmx.wsdl
-wsdllocation http://wsf.cdyne.com/SpellChecker/check.asmx?wsdl
parsing WSDL...


/Users/Kaiser/work/Netcat/8.0/tutorials/SpellCheckService1/nbproject/jaxws-build
.xml:31: 
java.lang.AssertionError: org.xml.sax.SAXParseException; systemId:
jar:file:/Applications/NetBeans/glassfish-4.0/glassfish/modules/jaxb-osgi.jar!/c
om/sun/tools/xjc/reader/xmlschema/bindinfo/binding.xsd; lineNumber: 52;
columnNumber: 88; schema_reference: Failed to read schema document 'xjc.xsd',
because 'file' access is not allowed due to restriction set by the
accessExternalSchema property. 
	at com.sun.tools.xjc.SchemaCache.newValidator(SchemaCache.java:80)
	at
com.sun.tools.xjc.reader.internalizer.SCDBasedBindingSet.apply(SCDBasedBindingSe
t.java:237)
	at com.sun.tools.xjc.ModelLoader.createXSOM(ModelLoader.java:541)
	at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:2
69)
	at
com.sun.tools.xjc.api.impl.s2j.SchemaCompilerImpl.bind(SchemaCompilerImpl.java:9
5)
	at
com.sun.tools.ws.processor.modeler.wsdl.JAXBModelBuilder.bind(JAXBModelBuilder.j
ava:142)
	at
com.sun.tools.ws.processor.modeler.wsdl.WSDLModeler.buildJAXBModel(WSDLModeler.j
ava:2298)
	at
com.sun.tools.ws.processor.modeler.wsdl.WSDLModeler.internalBuildModel(WSDLModel
er.java:198)
	at
com.sun.tools.ws.processor.modeler.wsdl.WSDLModeler.buildModel(WSDLModeler.java:
141)
	at
com.sun.tools.ws.wscompile.WsimportTool.buildWsdlModel(WsimportTool.java:444)
	at com.sun.tools.ws.wscompile.WsimportTool.run(WsimportTool.java:205)
	at com.sun.tools.ws.wscompile.WsimportTool.run(WsimportTool.java:183)
	at com.sun.tools.ws.ant.WsImport2.execute(WsImport2.java:874)
	at com.sun.istack.tools.ProtectedTask.execute(ProtectedTask.java:103)
	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
	at sun.reflect.GeneratedMethodAccessor93.invoke(Unknown Source)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
a:43)
	at java.lang.reflect.Method.invoke(Method.java:483)
	at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
	at org.apache.tools.ant.Task.perform(Task.java:348)
	at org.apache.tools.ant.Target.execute(Target.java:435)
	at org.apache.tools.ant.Target.performTasks(Target.java:456)
	at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
	at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
	at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:
41)
	at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
	at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:286)
	at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:555)
	at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:153)
Caused by: org.xml.sax.SAXParseException; systemId:
jar:file:/Applications/NetBeans/glassfish-4.0/glassfish/modules/jaxb-osgi.jar!/c
om/sun/tools/xjc/reader/xmlschema/bindinfo/binding.xsd; lineNumber: 52;
columnNumber: 88; schema_reference: Failed to read schema document 'xjc.xsd',
because 'file' access is not allowed due to restriction set by the
accessExternalSchema property. 
	at
com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseExcept
ion(ErrorHandlerWrapper.java:203)
	at
com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHand
lerWrapper.java:177)
	at
com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorRep
orter.java:441)
	at
com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.reportSchemaErr
(XSDHandler.java:4162)
	at
com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.reportSchemaFat
alError(XSDHandler.java:4141)
	at
com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.getSchemaDocume
nt(XSDHandler.java:2168)
	at
com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.resolveSchema(X
SDHandler.java:2078)
	at
com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.constructTrees(
XSDHandler.java:1008)
	at
com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.parseSchema(XSD
Handler.java:620)
	at
com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadSchema(XMLSchemaL
oader.java:616)
	at
com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar(XMLSchema
Loader.java:574)
	at
com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar(XMLSchema
Loader.java:540)
	at
com.sun.org.apache.xerces.internal.jaxp.validation.XMLSchemaFactory.newSchema(XM
LSchemaFactory.java:255)
	at javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:638)
	at javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:670)
	at com.sun.tools.xjc.SchemaCache.newValidator(SchemaCache.java:77)
	... 28 more
BUILD FAILED (total time: 0 seconds)
Comment 1 manikantannaren 2014-01-24 03:26:29 UTC
Works with Tomcat 7.x and Java EE 6 setting though
Comment 2 manikantannaren 2014-01-24 05:45:12 UTC
sorry for the typo in the text 
Expected output
Generate sources and WS references
Actual is the exception trace.
Comment 3 Jan Stola 2015-05-07 12:51:31 UTC
I am not able to reproduce this issue with Glassfish 4.1 and the latest development build of NetBeans.