Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 566983 - More efficient write technique in SafeFileOutputStream
Summary: More efficient write technique in SafeFileOutputStream
Status: RESOLVED INVALID
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Resources (show other bugs)
Version: 4.17   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-Resources-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-09-15 03:28 EDT by Lars Vogel CLA
Modified: 2020-09-29 12:55 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Vogel CLA 2020-09-15 03:28:04 EDT
Follow-up for Bug 566685 but for SafeFileOutputStream which should use the same optimization as SafeChunkyOutputStream.
Comment 1 Eclipse Genie CLA 2020-09-15 03:29:14 EDT
New Gerrit change created: https://git.eclipse.org/r/c/platform/eclipse.platform.resources/+/169344
Comment 2 Karsten Thoms CLA 2020-09-15 05:24:15 EDT
I'm not sure that the same optimization is an optimization here. Do you have some benchmark indicating it?
Comment 3 Andrey Loskutov CLA 2020-09-15 05:32:22 EDT
(In reply to Karsten Thoms from comment #2)
> I'm not sure that the same optimization is an optimization here. Do you have
> some benchmark indicating it?

Same for bug 566986. Just patching some low level code in a hope it could be faster is not the right way to work. Tests are must have.
See bug 566685 comment 4 for an example.
Comment 4 Lars Vogel CLA 2020-09-21 08:45:52 EDT
Jeremy, can you help here?
Comment 5 Jeremy Whiting CLA 2020-09-29 11:50:08 EDT
 I've looked at the class SafeFileOutputStream and I agree with Karsten T. and Andrey L.'s comments. The application of the same optimization isn't applicable here. There is a BufferedOutputStream used to override the FilterOutputStream.write(byte[], int, int)  method.
Comment 6 Lars Vogel CLA 2020-09-29 12:55:21 EDT
Thanks, Jeremy for the check.