Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 325245 - XMI serialization issue when using file buffer / flush threshold save options targeting some CVS connected folder
Summary: XMI serialization issue when using file buffer / flush threshold save options...
Status: RESOLVED WORKSFORME
Alias: None
Product: EMF
Classification: Modeling
Component: XML/XMI (show other bugs)
Version: 2.6.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Ed Merks CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 323247
  Show dependency tree
 
Reported: 2010-09-14 09:04 EDT by Fabien Giquel CLA
Modified: 2010-09-16 17:59 EDT (History)
0 users

See Also:


Attachments
Code sample related to the Exception (3.73 KB, application/zip)
2010-09-14 09:05 EDT, Fabien Giquel CLA
no flags Details
Stack Trace (5.25 KB, text/plain)
2010-09-14 09:05 EDT, Fabien Giquel CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Fabien Giquel CLA 2010-09-14 09:04:18 EDT
Hi,

we encounter some misc issue when using XMI serialization for one big model with options :

   options.put(XMLResource.OPTION_FLUSH_THRESHOLD, 10000);
   options.put(XMLResource.OPTION_USE_FILE_BUFFER, true);

We encounter some FileNotFoundException when writing the XMI file into a Java project connected to CVS. If we disconnect the project from CVS, everything is alright.

To get the error, I attached the source for one project, testXMISerialize, which implements a very simple XMI serialization :
- import the project in a workspace
- launch a second eclipse instance from this one
- checkout a project from a CVS repository (whatever it is)
- on the project, right click -> "new submenu" -> "new action"

The action tries to write a big model in "TestSerializationEMF.xmi"
You should obtain in error log : "Could not write file:
D:\XXX\TestSerializationEMF.xmi.".
If a TestSerializationEMF.xmi appears and a window "serialization ok", then
delete the file and try again.


Not sure but it is as if some CVS workspace listener causes some synchronization interruption between the first .xmi part serialization and the following.

Thanks in advance for your help.
Comment 1 Fabien Giquel CLA 2010-09-14 09:05:01 EDT
Created attachment 178823 [details]
Code sample related to the Exception
Comment 2 Fabien Giquel CLA 2010-09-14 09:05:37 EDT
Created attachment 178824 [details]
Stack Trace
Comment 3 Ed Merks CLA 2010-09-16 17:59:48 EDT
I can't reproduce this.  :-(

Given that you can, it will be useful to set breakpoints to see if the file really doesn't exist at the point the exception is thrown.  If it doesn't exist, I wonder who's deleting it?