|
List Info
Thread: SchemaCompiler.main() acts differently to scomp
|
|
| SchemaCompiler.main() acts differently
to scomp |

|
2006-09-13 14:45:09 |
I think I may have found a bug. Would be interested to know
if anyone
else can reproduce it.
Take a valid schema. Check that it is valid by running scomp
from the
command line.
Edit the schema by adding an xs:import to a non-existent
file.
Run scomp again. Scomp behaves correctly and complains
about the
missing file and prints "build failed".
Looking at the code for scomp, it literally just calls java
with the
SchemaCompiler class.
Yet, from a java program, call SchemaCompiler.main() and
pass in the
path to the edited schema and it will successfully build the
xmlTypes.jar!
So, I tried running scomp directly using Runtime.exec().
This still
does not notice the error!
Running windows 2000 sp4, java 1.5.0_08, xml beans 2.2.0.
--
Chris
HMGCC
The information contained in this message (and any
attachments) may
be confidential and is intended for the sole use of the
named addressee.
Access, copying, alteration or re-use of the e-mail by
anyone other
than the intended recipient is unauthorised. If you are not
the intended
recipient please advise the sender immediately by returning
the e-mail
and deleting it from your system.
This information may be exempt from disclosure under Freedom
Of Information
Act 2000 and may be subject to exemption under other UK
information
legislation. Refer disclosure requests to the Information
Officer.
The original of this email was scanned for viruses by
Government Secure Intranet (GSi) virus scanning service
supplied exclusively by Cable & Wireless in partnership
with MessageLabs.
On leaving the GSI this email was certified virus free.
The MessageLabs Anti Virus Service is the first managed
service to achieve the CSIA Claims Tested Mark (CCTM
Certificate Number 2006/04/0007), the UK Government quality
mark initiative for information security products and
services. For more information about this please visit
www.cctmark.gov.uk
------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribe xmlbeans.apache.org
For additional commands, e-mail: dev-help xmlbeans.apache.org
|
|
| SchemaCompiler.main() acts differently
to scomp |

|
2006-09-14 09:23:08 |
I take it back, using scomp via Runtime.exec() does behave
correctly
although certain files cause scompProcess.waitFor() to wait
forever.
SchemaCompiler.main() still always successfully compiles
schemas though.
Any help or light anyone can throw on this issue would be
appreciated.
Chris wrote:
> I think I may have found a bug. Would be interested to
know if anyone
> else can reproduce it.
>
> Take a valid schema. Check that it is valid by running
scomp from the
> command line.
> Edit the schema by adding an xs:import to a
non-existent file.
> Run scomp again. Scomp behaves correctly and complains
about the
> missing file and prints "build failed".
>
> Looking at the code for scomp, it literally just calls
java with the
> SchemaCompiler class.
> Yet, from a java program, call SchemaCompiler.main()
and pass in the
> path to the edited schema and it will successfully
build the xmlTypes.jar!
> So, I tried running scomp directly using
Runtime.exec(). This still
> does not notice the error!
>
> Running windows 2000 sp4, java 1.5.0_08, xml beans
2.2.0.
--
Chris
HMGCC
The information contained in this message (and any
attachments) may
be confidential and is intended for the sole use of the
named addressee.
Access, copying, alteration or re-use of the e-mail by
anyone other
than the intended recipient is unauthorised. If you are not
the intended
recipient please advise the sender immediately by returning
the e-mail
and deleting it from your system.
This information may be exempt from disclosure under Freedom
Of Information
Act 2000 and may be subject to exemption under other UK
information
legislation. Refer disclosure requests to the Information
Officer.
The original of this email was scanned for viruses by
Government Secure Intranet (GSi) virus scanning service
supplied exclusively by Cable & Wireless in partnership
with MessageLabs.
On leaving the GSI this email was certified virus free.
The MessageLabs Anti Virus Service is the first managed
service to achieve the CSIA Claims Tested Mark (CCTM
Certificate Number 2006/04/0007), the UK Government quality
mark initiative for information security products and
services. For more information about this please visit
www.cctmark.gov.uk
------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribe xmlbeans.apache.org
For additional commands, e-mail: dev-help xmlbeans.apache.org
|
|
| SchemaCompiler.main() acts differently
to scomp |

|
2006-09-14 09:23:08 |
I take it back, using scomp via Runtime.exec() does behave
correctly
although certain files cause scompProcess.waitFor() to wait
forever.
SchemaCompiler.main() still always successfully compiles
schemas though.
Any help or light anyone can throw on this issue would be
appreciated.
Chris wrote:
> I think I may have found a bug. Would be interested to
know if anyone
> else can reproduce it.
>
> Take a valid schema. Check that it is valid by running
scomp from the
> command line.
> Edit the schema by adding an xs:import to a
non-existent file.
> Run scomp again. Scomp behaves correctly and complains
about the
> missing file and prints "build failed".
>
> Looking at the code for scomp, it literally just calls
java with the
> SchemaCompiler class.
> Yet, from a java program, call SchemaCompiler.main()
and pass in the
> path to the edited schema and it will successfully
build the xmlTypes.jar!
> So, I tried running scomp directly using
Runtime.exec(). This still
> does not notice the error!
>
> Running windows 2000 sp4, java 1.5.0_08, xml beans
2.2.0.
--
Chris
HMGCC
The information contained in this message (and any
attachments) may
be confidential and is intended for the sole use of the
named addressee.
Access, copying, alteration or re-use of the e-mail by
anyone other
than the intended recipient is unauthorised. If you are not
the intended
recipient please advise the sender immediately by returning
the e-mail
and deleting it from your system.
This information may be exempt from disclosure under Freedom
Of Information
Act 2000 and may be subject to exemption under other UK
information
legislation. Refer disclosure requests to the Information
Officer.
The original of this email was scanned for viruses by
Government Secure Intranet (GSi) virus scanning service
supplied exclusively by Cable & Wireless in partnership
with MessageLabs.
On leaving the GSI this email was certified virus free.
The MessageLabs Anti Virus Service is the first managed
service to achieve the CSIA Claims Tested Mark (CCTM
Certificate Number 2006/04/0007), the UK Government quality
mark initiative for information security products and
services. For more information about this please visit
www.cctmark.gov.uk
------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribe xmlbeans.apache.org
For additional commands, e-mail: dev-help xmlbeans.apache.org
|
|
| SchemaCompiler.main() acts differently
to scomp |

|
2006-09-15 00:14:11 |
This seems like a classpath-related issue. XMLBeans uses the
current
classpath (classloader) to load pre-compiled Schema types,
just as Java
uses it to load compiled Java classes. Therefore, if you
have some jar
on your classpath that contains the types that you say are
missing,
XMLBeans will link against those and compilation will
succeed. In fact,
this is one of the more powerful features of XMLBeans.
One other comment that I would like to make is that
SchemaCompiler.main() is really intended to be called *only*
from the
command line script. Try using XmlBeans.compileXsd() from
Java code.
Radu
-----Original Message-----
From: Chris [mailto:chrishe hmgcc.gsi.gov.uk]
Sent: Thursday, September 14, 2006 2:23 AM
To: dev xmlbeans.apache.org
Subject: Re: SchemaCompiler.main() acts differently to scomp
I take it back, using scomp via Runtime.exec() does behave
correctly
although certain files cause scompProcess.waitFor() to wait
forever.
SchemaCompiler.main() still always successfully compiles
schemas though.
Any help or light anyone can throw on this issue would be
appreciated.
Chris wrote:
> I think I may have found a bug. Would be interested to
know if anyone
> else can reproduce it.
>
> Take a valid schema. Check that it is valid by running
scomp from the
> command line.
> Edit the schema by adding an xs:import to a
non-existent file.
> Run scomp again. Scomp behaves correctly and complains
about the
> missing file and prints "build failed".
>
> Looking at the code for scomp, it literally just calls
java with the
> SchemaCompiler class.
> Yet, from a java program, call SchemaCompiler.main()
and pass in the
> path to the edited schema and it will successfully
build the
xmlTypes.jar!
> So, I tried running scomp directly using
Runtime.exec(). This still
> does not notice the error!
>
> Running windows 2000 sp4, java 1.5.0_08, xml beans
2.2.0.
--
Chris
HMGCC
The information contained in this message (and any
attachments) may be
confidential and is intended for the sole use of the named
addressee.
Access, copying, alteration or re-use of the e-mail by
anyone other than
the intended recipient is unauthorised. If you are not the
intended
recipient please advise the sender immediately by returning
the e-mail
and deleting it from your system.
This information may be exempt from disclosure under Freedom
Of
Information Act 2000 and may be subject to exemption under
other UK
information legislation. Refer disclosure requests to the
Information
Officer.
The original of this email was scanned for viruses by
Government Secure
Intranet (GSi) virus scanning service supplied exclusively
by Cable &
Wireless in partnership with MessageLabs.
On leaving the GSI this email was certified virus free.
The MessageLabs Anti Virus Service is the first managed
service to
achieve the CSIA Claims Tested Mark (CCTM Certificate Number
2006/04/0007), the UK Government quality mark initiative for
information
security products and services. For more information about
this please
visit www.cctmark.gov.uk
------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribe xmlbeans.apache.org
For additional commands, e-mail: dev-help xmlbeans.apache.org
>>Register now for BEA World 2006 --- See http://www.bea.co
m/beaworld<<
____________________________________________________________
___________
Notice: This email message, together with any attachments,
may contain
information of BEA Systems, Inc., its subsidiaries and
affiliated
entities, that may be confidential, proprietary,
copyrighted and/or
legally privileged, and is intended solely for the use of
the individual
or entity named in this message. If you are not the intended
recipient,
and have received this message in error, please immediately
return this
by email and then delete it.
------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribe xmlbeans.apache.org
For additional commands, e-mail: dev-help xmlbeans.apache.org
|
|
[1-4]
|
|