OK, I worked on this for a while today. I was able to once again observe the problem where namespace creation was successfully reported, but the namespace was not created. I wasn't able to reproduce it, just observe it the one time. My working hypothesis was that a race condition was causing the file to be modified, triggering the configuration reload, which overwrote the changes in-memory before the write could complete. I can't quite reconcile that with the fact that I have thread-level locking in place now, but it's the closest I could come to an answer.
As I was thinking about how to fix it, I realized that the threading issues are horrendously complex and decided that the best solution is to simply punt entirely. So I ripped out the code that watches the flexwiki.config file for changes and instead added a button to the admin pages that lets you reload it manually. My guess is that not too many people are going to edit the flexwiki.config file by hand, and those that do are going to be smart enough to either hit the button or restart the web app entirely. If it's a problem, I'll add some code that checks the modification time on the file periodically and reloads it if it has changed. Sort of like FileSystemWatcher, but manual so we can work around problems more easily. I'm guessing we'll never have to do that. Long story short: please download build 2.0.0.40 and see if it resolves the problems. Thanks again! > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:flexwiki- > [EMAIL PROTECTED] On Behalf Of Craig Andera > Sent: Thursday, April 19, 2007 7:20 AM > To: 'FlexWiki Users Mailing List' > Subject: Re: [Flexwiki-users] FlexWiki 2.0 Progress Report - Beta 1 > complete > > > It appears that the error is clearly due to some race condition > caused > > by the dual processors. When the system is loaded with other tasks > the > > process completes successfully > > OK, well, my system is single-processor, so that would explain one of > the > discrepancies. > > > (albiet that the namespace is created in the FlexWiki directory). > > I'm not sure I understand here - is it not being created where you > think it > should? > > > This looks like it is a known problem with FileWatcher type code, but > > was unable to determine quickly if there is any real fix. > > Ah yes, I could see this being a problem. The FileSystemWatcher grabs a > lock > on the file and *that* causes the write to fail. Can you tell me where > you > found documentation on this being a known issue? > > I have a couple of ideas about how I can work around this. I'll try > implementing one of them today. If you get a chance to test it out > again, > that would be helpful. > > Thanks again for all the great work on this bug! > > > > ----------------------------------------------------------------------- > -- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Flexwiki-users mailing list > Flexwiki-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/flexwiki-users ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Flexwiki-users mailing list Flexwiki-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flexwiki-users