|Re: [jgit-dev] Missing tree during self-tests on NonStop|
> -----Original Message----- > From: Christian Halstrick [mailto:christian.halstrick@xxxxxxxxx] > Sent: March 4, 2015 7:40 AM > To: Randall S. Becker > Cc: Shawn Pearce; jgit-dev > Subject: Re: [jgit-dev] Missing tree during self-tests on NonStop > > I like that JGit gains one more supported platform. But we should take care that > we are not slowing down JGit on standard JVMs. Doing extra file-system calls is > something I really avoid in JGit. I am not caring too much about JGitTestUtil but > changes to the run-time code should not decrease performance. Maybe one > could add a detection whether we run on a JVM/filesystem which creates > executable files on > File.createNewFile() and set a flag. That flag could be used to do avoid extra > filesystem calls to correct the executable bits. Or, alternatively, when > initializing repositories in the filesystem check the behaviour of > File.createNewFile() and set a configuration parameter (like core.filemode). The situation at the moment is that java.io.File#createNewFile() documentation from Oracle is silent on the file mode used so it is implementation specific, not an issue of standards. Given that JGit and git are sensitive to this attribute, leaving it to chance is unwise even if it costs a file system call. For NonStop Java 1.6, the execute bit is set by this call. We are moving to 1.7 but I suspect that there is no change. Sure, a factory pattern could be used to pick off a NonStop personality, but that seems a bit extreme to me in this specific situation.
Back to the top