Error: Referenced type (unqualified)

103 views
Skip to first unread message

Tony Marjakangas

unread,
Nov 28, 2012, 10:52:05 AM11/28/12
to sca...@googlegroups.com
Hi

Im trying to use scalaxb for a new project I have just started and would like to generate some classes to use for talking to a SOAP/XML service. I have done this before in Java and had no problems doing that with jaxws but would like to use Scala now :)

Anyway when im generating my classes I get an error either:
Error: Referenced type (unqualified) CoverageType was not found.
or
Error: Referenced type (unqualified) FormattedTextType was not found.

And im not able to find any information about why this happens. The types are specified in the XSD files.
Same error no matter if im using sbt or the command line.


Link to XSD files (parts of Open Travel Alliance 2010B specification)


Some help would really be appriciated.

Thanks
Tony

eugene yokota

unread,
Nov 28, 2012, 11:09:53 AM11/28/12
to sca...@googlegroups.com
I'll look at it later. In the mean time, I created a gist of your files: https://gist.github.com/4162166

-eugene

Tony Marjakangas

unread,
Nov 28, 2012, 12:01:21 PM11/28/12
to sca...@googlegroups.com
Iam able to compile the common types files but not the messages.

I can generate classes for these:
OTA_CommonPrefs.xsd
OTA_CommonTypes.xsd
OTA_SimpleTypes.xsd
OTA_VehicleCommonTypes.xsd

But not any of the other files that includes these.

The files:
OTA_AllRQ.xsd
OTA_AllRS.xsd
are just meta files we used with jaxws and are optional as those only contain imports of all request or response types.


/Tony

eugene yokota

unread,
Nov 29, 2012, 2:28:37 AM11/29/12
to sca...@googlegroups.com
Hi Tony,

The behavior is likely  a scalaxb bug that's not handling the targetNamespace and namespaces correctly when xsd files are included into another. We can work around this bug by manually supplying targetNamespace and namespace bindings: https://github.com/eed3si9n/scalaxb-sample/tree/opentravel/opentravel

I was able to generate source code, but unfortunately due to the number of types (700+),
the generated source probably won't compile. scalaxb 1.0 generates implicits for all types,
and after some number Scala compiler can't handle them. I'll have to somehow address it in future scalaxb.

-eugene

eugene yokota

unread,
Nov 29, 2012, 2:36:42 AM11/29/12
to sca...@googlegroups.com
I may have spoke too soon. It took me about an hour, but the code did eventually compile.
You'd probably want to keep this in a separate project, so you don't accidentally hit recompilation.

-eugene

Tony Marjakangas

unread,
Nov 29, 2012, 3:17:25 AM11/29/12
to sca...@googlegroups.com
Is is possible that not using implicit types will make the compilation run much faster?
Not a big fan of 1 hour compilations even though the schema used wont be changed often.

Myself I ran into this during compilation
[error] java.util.concurrent.ExecutionException: java.lang.OutOfMemoryError: GC overhead limit exceeded

eugene yokota

unread,
Nov 29, 2012, 3:25:39 AM11/29/12
to sca...@googlegroups.com
It's all possible, but it won't be part of 1.0.

-eugene

Tony Marjakangas

unread,
Nov 29, 2012, 3:30:39 AM11/29/12
to sca...@googlegroups.com
Thanks for looking into the issue.

/Tony

Vinicius Paiva

unread,
Nov 22, 2013, 3:14:06 PM11/22/13
to sca...@googlegroups.com
Hi guys,

  I've seen you have experience with OTA.
  Do you have or know where I can find a server example built in .Net?
  Where can I find the OTA wsdl to import? With provided OTA stuff I can only find the isolated .xsd files. Isn't there an OTA wsdl to get imported?

Thanks in advance,
Vinícius
Reply all
Reply to author
Forward
0 new messages