Michael Cafarella wrote:
Ugh - doing fs work under Java is very hard. No way to test for free bytes on disk, no way to perform the test
you describe...


Doug mentioned to me that we might want to create a
*very* small platform-specific library of fs functions.
We even thought about writing them using unix (cygwin) commands, rather than C.


I'm beginning to like this idea more.

Yes, this would solve the problem rather nicely... we could provide a fallback mechanism to use when the native implementation is not available.


The advantage of using native lib is that you avoid fork/exec cost, and I guess during the lifetime of NutchFS there would be quite a few calls to the native utilities... I'm afraid this would give a poor performance. Also, on different Unixes (and on Cygwin) command-line parameters for many FS-specific utilities are different.

One idea would be to wrap a bunch of FS-specific functions into a native mini-server, start it from let's say FileUtils, and use pipes for IPC. This should give a decent performance, at the risk that this server might die unexpectedly (but then it could be restarted). On the other hand, if you use JNI and you experience a problem, the whole application dies.

--
Best regards,
Andrzej Bialecki

-------------------------------------------------
Software Architect, System Integration Specialist
CEN/ISSS EC Workshop, ECIMF project chair
EU FP6 E-Commerce Expert/Evaluator
-------------------------------------------------
FreeBSD developer (http://www.freebsd.org)



-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Nutch-developers mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nutch-developers

Reply via email to