db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Armin Waibel <ar...@code-au-lait.de>
Subject Re: [ENH] - More info in MetadataException while parsing repository.xml
Date Thu, 30 Oct 2003 13:38:19 GMT
Hi Antonio,

Antonio Gallardo wrote:
> Hi:
> 
> I will suggest to add the line where the problem occurs in the error:
> 
> 
> Caused by: org.apache.ojb.broker.metadata.MetadataException: Can not read
> repository class descriptor data, using repository: repository.xml
> 
MetadataException only wraps the original
thrown exception. Normally you should get
a stack trace say something like "Caused by: ..."
point to the original exception.

> If you have a more than 1,000 lines, where to find? :-D
> 

Normally you will get some error logging like

[DEFAULT] ERROR: ** org.apache.ojb.broker.metadata.RepositoryTags: Tag 
'field-descripto' is not defined. **

typo in element declaration.

Or
[Fatal Error] repository_junit.xml:82:6: The element type 
"field-descriptor" must be terminated by the matching end-tag 
"</field-descriptor>".

If this does not help set log level for
org.apache.ojb.broker.metadata.RepositoryXmlHandler
org.apache.ojb.broker.metadata.ConnectionDescriptorXmlHandler
to debug.

> The ideal will be adding the line+column on where the MetadataManager
> found the error.
> 
Agree this would be a perfect solution, but I don't know how to 
implement this - please send me a patch ;-)

regards,
Armin

> -------------------------------------------------
> The same apply for this error:
> 
> Caused by: org.apache.ojb.broker.metadata.MetadataException: Exception
> when reading metadata information, please check your repository.xml file
> 
> Best Regards,
> 
> Antonio Gallardo
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-dev-help@db.apache.org
> 
> 
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message