Nov
21
comment In-memory batch buffer for writing objects to a database
Sure :) It would also prevent data stacking up in the queue
Nov
19
asked In-memory batch buffer for writing objects to a database
Nov
19
accepted Advanced message filter rules in Mozilla Thunderbird
Nov
8
accepted Java 8: Applying Stream map and filter in one go
Nov
6
comment Java 8: Applying Stream map and filter in one go
Well I assume the stream has to be processed two times, once for map and once for filter. I want to discard the unnessecary elements within the map operation, that should be faster in any case.
Nov
6
asked Java 8: Applying Stream map and filter in one go
Oct
17
comment Why does this print method work? shouldn't it fail?
The problem is that null does not have a type, so this results in a compiler error, because java doesn't know which overloaded method to call. First cast the value to a String: System.out.println((String) null);
Oct
17
answered Running JUnit tests in terminal
Oct
8
comment Foolproof detection of OutOfmemory in Java
Here are some examples: stackoverflow.com/questions/1759831/…
Oct
6
revised How to represent empty char in Java Character class
added 6 characters in body
Sep
24
awarded Autobiographer
Sep
12
comment How to read all lines of a file in parallel in Java 8
I changed the method I used for testing, I seem to be wrong, as I accidentally limited the result size to 200 before doing the final operation (forEach(System.out::println) on the resulting stream. Actually, Files.lines(Path) reads the given file as a sequential stream. Moreover, most of the time was actually spent reading the file and not on computations, plus I ran into some GC problems. I timed Files.lines(Path).toArray() vs a method using a MappedByteBuffer(readonly, 0, file.size). The results were actually the quite same, MappedByteBuffer a bit slower here and there.
Sep
12
accepted How to read all lines of a file in parallel in Java 8
Sep
7
comment How to read all lines of a file in parallel in Java 8
I edited the question to clarify that there is practically no seeking time - compared to a hard disk. Even if I add the 2 seconds for splitting the file, there is still > 18 seconds difference.
Sep
7
revised How to read all lines of a file in parallel in Java 8
provided more pieces of information
Sep
7
comment How to read all lines of a file in parallel in Java 8
In bash, you can use split -l #lines, combine that with wc -l to split it into two halves. Micheal Petch understood my idea :)
Sep
7
asked How to read all lines of a file in parallel in Java 8
Aug
5
comment recordmydesktop Segmentation fault (core dumped)
Have you foudn a solution? I also have this problem
Jul
22
revised Calculating rotation angle X-Y-Z
added 11 characters in body
Jul
22
answered Calculating rotation angle X-Y-Z
1 2 3 4 5