Hi, David.

Sorry for your trouble.

I've seen this weird error from time to time myself, and I am not sure what the 
root cause is. But
I suspect that what is happening is that there is an empty file or "project" 
metadata file
somewhere out there. 

The trick is to drill your way through the project meta data files until you 
find the project that
is giving you the error messages when you browse it. Was this the file you 
attempted to edit? 

You can find this file by following some of the guidelines in this doc:

http://www.sourcejammer.org/docAboutServerFiles.html

Once you find the project, you'll have to inspect all of its child files (both 
project and file),
to see which one is corrupt. It will probably be obvious. As I said, the file 
will probably be
blank. Once you've done this, you can delete the reference to the offending 
project/file from the
parent project file. Then re-start your SJ server.

I know this is a complete pain. We are about to start development on a 2.2 
release, and I think
some kind of corruption cleanup utility would be a nice thing to have. 
Obviously, in an ideal
world, issues like this would never occur. But until we can guarantee that they 
won't, it would be
nice if SJ at least recognized what the problem was and prompted you to clean 
out corrupt file
reference instead of crapping out completely.

Hopefully this is helpful.

--Rob

PS: My guess is that it is a recently added file or folder that is causing the 
trouble, so
hopefully you won't actually lose any data. Good luck.


--- David Rickard <[EMAIL PROTECTED]> wrote:

> Source Jammer: 2.1.0.0
> Tomcat: 4.1.29
> Java: j2sdk1.4.2_02
> Server: SunOS 5.8 Generic_108528-14 sun4u sparc SUNW,Ultra-5_10
> 
> We've been using SourceJammer for 1-2 years now, generally without 
> complaint.  Recently, SourceJammer began refusing to read one project 
> folder from our archive (all other projects read fine).  The error message is:
> Unable to access File information.  org.xml.sax.SAXParseException: 
> Premature end of file.
> 
> The following stack traces were produced in the logs:
> org.sourcejammer.util.ConfigurationException: 
> org.xml.sax.SAXParseException: Premature end of file. Premature end of 
> file. org
> .xml.sax.SAXParseException: Premature end of file. Premature end of file. 
> org.sourcejammer.project.model.FileAccessException: org.xml.
> sax.SAXParseException: Premature end of file. Premature end of file. 
> org.xml.sax.SAXParseException: Premature end of file.
> at 
> org.sourcejammer.project.model.filesys.ProjectNodeDeserializer.deserialize(Unknown
>  
> Source)
> at org.sourcejammer.project.model.filesys.XMLUtilFS.xmlToProject(Unknown 
> Source)
> at org.sourcejammer.project.model.filesys.Util.readProjectNode(Unknown Source)
> at 
> org.sourcejammer.project.model.filesys.NodeLibraryFS.getProjectNode(Unknown 
> Source)
> at 
> org.sourcejammer.project.controller.ProjectController.projectNodeToProject(Unknown
>  
> Source)
> at org.sourcejammer.project.controller.ProjectController.getProject(Unknown 
> Source)
> at 
> org.sourcejammer.project.view.MasterControlProgram.getProjectInfo(Unknown 
> Source)
> 
> org.sourcejammer.project.model.FileAccessException: 
> org.xml.sax.SAXParseException: Premature end of file. Premature end of fil
> e. org.xml.sax.SAXParseException: Premature end of file.
> at 
> org.sourcejammer.project.model.filesys.NodeLibraryFS.getProjectChildName(Unknown
>  
> Source)
> at 
> org.sourcejammer.project.model.filesys.ProjectNodeDeserializer.setChildren(Unknown
>  
> Source)
> at 
> org.sourcejammer.project.model.filesys.ProjectNodeDeserializer.deserialize(Unknown
>  
> Source)
> at org.sourcejammer.project.model.filesys.XMLUtilFS.xmlToProject(Unknown 
> Source)
> at org.sourcejammer.project.model.filesys.Util.readProjectNode(Unknown Source)
> at 
> org.sourcejammer.project.model.filesys.NodeLibraryFS.getProjectNode(Unknown 
> Source)
> at 
> org.sourcejammer.project.controller.ProjectController.projectNodeToProject(Unknown
>  
> Source)
> at org.sourcejammer.project.controller.ProjectController.getProject(Unknown 
> Source)
> at 
> org.sourcejammer.project.view.MasterControlProgram.getProjectInfo(Unknown 
> Source)
> 
>   org.xml.sax.SAXParseException: Premature end of file.
> at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
> at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
> at org.sourcejammer.xml.XMLUtil.getXMLDoc(Unknown Source)
> at org.sourcejammer.xml.XMLUtil.getXMLDoc(Unknown Source)
> at 
> org.sourcejammer.project.model.filesys.Util.readXMLDocFromFileSys(Unknown 
> Source)
> at org.sourcejammer.project.model.filesys.Util.readNodeName(Unknown Source)
> at 
> org.sourcejammer.project.model.filesys.NodeLibraryFS.getProjectChildName(Unknown
>  
> Source)
> at 
> org.sourcejammer.project.model.filesys.ProjectNodeDeserializer.setChildren(Unknown
>  
> Source)
> at 
> org.sourcejammer.project.model.filesys.ProjectNodeDeserializer.deserialize(Unknown
>  
> Source)
> at org.sourcejammer.project.model.filesys.XMLUtilFS.xmlToProject(Unknown 
> Source)
> at org.sourcejammer.project.model.filesys.Util.readProjectNode(Unknown Source)
> at 
> org.sourcejammer.project.model.filesys.NodeLibraryFS.getProjectNode(Unknown 
> Source)
> at 
> org.sourcejammer.project.controller.ProjectController.projectNodeToProject(Unknown
>  
> Source)
> at org.sourcejammer.project.controller.ProjectController.getProject(Unknown 
> Source)
> at 
> org.sourcejammer.project.view.MasterControlProgram.getProjectInfo(Unknown 
> Source)
> 
> I attempted to edit the parent file for the project folder (under the 
> archive project file)--but this caused SourceJammer to lose track of _all_ 
> projects in the archive (a quick restore of the original file brought the 
> projects back).
> 
> Is there any simple way to track down which file is causing the 
> problems?  And is there any simple/safe way to fix the file once we 
> identify the problem?
> 
> 
> --
> 
> David Rickard
> Software Engineer
> 
> TechBooks/GTS
> Your Single Source Solution!
> Los Angeles CA * York, PA * Boston,MA * New Delhi, India
> Visit us on the World Wide Web 
> <http://www.techbooks.com>http://www.techbooks.com
> 
> [EMAIL PROTECTED]
> 5650 Jillson St., Los Angeles, CA 90040
> (323) 888-8889 x331
> (323) 888-1849 (Fax)
> 
> 



                
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - now with 250MB free storage. Learn more.
http://info.mail.yahoo.com/mail_250


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
SourceJammer-users mailing list
SourceJammer-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sourcejammer-users

Reply via email to