Re: Subject: Proposal: Standardizing String Concatenation in Apache Commons

2024-12-15 Thread Peter Burka
ntages of using StringBuilder explicitly, that I can think of, are: * No risk of accidentally constructing multiple StringBuilders, e.g. (strA + strB) + (strC + strD) * Ability to explicitly set the right capacity, e.g. new StringBuilder(new size) Peter On Sun, Dec 15, 2024, 11:03 AM Elliotte Rust

Re: Subject: Proposal: Standardizing String Concatenation in Apache Commons

2024-12-15 Thread Peter Burka
Before Java 9, javac always generated StringBuilder calls for string concatenation (or StringBuffer prior to Java 2). Using + is less verbose, generates the same code, is more readable, and, when we do finally bump the compile target, will generate better code. Peter On Sun, Dec 15, 2024, 7

Re: Subject: Proposal: Standardizing String Concatenation in Apache Commons

2024-12-14 Thread Peter Burka
I presume this is referring to https://openjdk.org/jeps/280 (JEP 280: Indify String Concatenation) which was implemented in Java 9. On Sat, Dec 14, 2024, 6:26 PM Elliotte Rusty Harold wrote: > On Sat, Dec 14, 2024 at 3:08 PM Serw wrote: > > > Would the community support using string concatenat

Re: [CLI] [DISCUSS] Help formatter extension proposal

2024-09-30 Thread Peter Burka
My vote (which everyone is free to ignore) is still for HelpWriter. It's simple and intuitive, and it's consistent with the names of the methods the interface declares (e.g. writePara, writeTable). I find SemanticAppendableDecorator too verbose and I have no intuition for what it means.

Re: [CLI] [DISCUSS] Help formatter extension proposal

2024-09-25 Thread Peter Burka
That sounds similar to java.io.Writer. Maybe this should be a HelpWriter? On Wed, Sep 25, 2024, 7:11 PM Claude Warren wrote: > Actually the Producer constructor takes an "Appendable" as an argument and > then provides methods like > > printPara("Some text here") > > Which would output a paragrap

Re: [beanutils] Thoughts on PR https://github.com/apache/commons-beanutils/pull/276

2024-09-04 Thread Peter Burka
I agree with Gary. If an object is exposing sensitive data in its toString() then the problem should be fixed at the source. Peter On Tue, Sep 3, 2024, 11:04 AM Gary D. Gregory wrote: > I appreciate the intent but this feels like bad solution. If a toString() > method return a password

Re: [LANG] LANG-1747: Measure the execution time of functional interfaces #1254

2024-08-17 Thread Peter Burka
his.) I'd propose renaming all of the functional interface-wrapping functions to use a single, overloaded name, e.g. StopWatch::timed(...) or StopWatch::withTiming(...) /peter On Fri, Aug 16, 2024, 10:50 PM Gary Gregory wrote: > Hi all, > > Please provide any feedback on > - LANG-

Re: [COLLECTIONS] CartesianProductIterator

2024-06-26 Thread Peter Burka
I don't know if it's been proposed before, but I think any implementation would necessarily be inefficient. I imagine such an iterator would need to produce objects of type Pair. This would lead to a lot of allocation and could create garbage collection pressure. The same functionality can be achie

Re: [RDF] adding Quads - Bulk

2024-03-10 Thread Peter Hull
ps://github.com/apache/commons-rdf/pull/205 > I did it right after the mail. > > Thanks Fredy > > On 10.03.24 13:42, Peter Hull wrote: > > On Sat, 9 Mar 2024 at 22:37, Fred Hauschel wrote: > > > >> Is there a reason, why there is no Method like GraphLike#add(List

Re: [RDF] adding Quads - Bulk

2024-03-10 Thread Peter Hull
ng the multiple connections) I don't think this would break compatibility unless someone had already implemented addAll on a subclass, with a different signature. Peter diff --git a/commons-rdf-api/src/main/java/org/apache/commons/rdf/api/GraphLike.java b/commons-rdf-api/src/main/java/org/apa

Re: [COMPRESS] Help needed to fix COMPRESS-651

2024-03-09 Thread Peter Hull
On Sat, 9 Mar 2024 at 18:19, Peter Hull wrote: > There's another constructor for BZip2CompressorInputStream which > allows for this, it's not the default. Specifically, the patch below makes the test pass. Whether this should be default for the one-arg constructor is a matte

Re: [COMPRESS] Help needed to fix COMPRESS-651

2024-03-09 Thread Peter Hull
n cat'ing those compressed chunks together. There's another constructor for BZip2CompressorInputStream which allows for this, it's not the default. I can't find any record of it though, maybe I'm losing my mind. Peter -

Re: [COMPRESS] Decompress BZIP2 File Max Output is 900000 chars

2024-01-31 Thread Peter Hull
bzip2/BZip2CompressorInputStream.html) says there is another constructor with a boolean flag for decompressing concatenated files. Using this constructor appears to work OK. Therefore I assume that pbzip2 creates concatenated bzip files? Hope that helps Peter On Wed, 31 Jan 2024 at 12:57, G

Re: [CRYPTO] Why does Makefile use CXX (C++) for linking?

2023-11-02 Thread Peter Hull
On Thu, 2 Nov 2023 at 10:35, sebb wrote: > On macOS, CC and CXX have the same definition, so it's not surprising > there was no difference in your testing. Face palm. Sorry - To unsubscribe, e-mail: dev-unsubscr...@commons.apache

Re: [CRYPTO] Why does Makefile use CXX (C++) for linking?

2023-11-02 Thread Peter Hull
uld be fixed by following the suggestion in that file, but I can't risk messing anything up just at the moment. So I don't think in that case using the C linker instead of the C++ linker caused any problems. This seems like a bit

Re: [IMAGING] Logging vs Throwing exceptions

2023-05-31 Thread Peter Hull
That whole class looks like it needs a bit of TLC (or Javadoc at least!) On Wed, 31 May 2023 at 06:49, Miguel Muñoz wrote: > > > In addition to logging and swallowing the exception, this method also then > returns null. This is also a bad practice. > > > > The caller has to check for null. One o

Re: [lang] Considering a new String utility class

2023-03-20 Thread Peter Verhas
set, I'm > not 100% sure yet. But you get the idea I hope. > > Any thoughts? > > Gary > > - > To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org > For additional commands, e-mail: dev-h...@commons.apache.org > > -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: [CSV] New feature to allow access to leading/trailing comments in CSV files?

2022-09-06 Thread Peter Hull
Gilles, I have done this, partly, and there are 14 test methods. I still have two tests in each method, one for hasXXX() and one for getXXX(). It seems a bit excessive already. In your judgement, should I cut some of them out? https://github.com/apache/commons-csv/pull/257/commits/0414d1e4b79a4f42d24c8b9a7547a8cbf4a40cf0 Peter

Re: [CSV] New feature to allow access to leading/trailing comments in CSV files?

2022-09-06 Thread Peter Hull
I assumed the github repo was just mirrored for convenience. Peter On Tue, 6 Sept 2022 at 15:23, Gary Gregory wrote: > Please see > > https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request

Re: [CSV] New feature to allow access to leading/trailing comments in CSV files?

2022-09-06 Thread Peter Hull
Hi Bruno, Thanks for the swift reply! I have created CSV-304. I attached a patch to the ticket but I don't know how to submit a pull request, please could you advise? Peter On Tue, 6 Sept 2022 at 11:37, Bruno Kinoshita wrote: > Hi Peter, > > I think not keeping comments may he

[CSV] New feature to allow access to leading/trailing comments in CSV files?

2022-09-06 Thread Peter Hull
ch? I appreciate there may be reasons I am not aware of as to why commons-csv doesn't do this already. Thanks, Peter [1]: https://stackoverflow.com/questions/72619095/get-leading-comments-from-csv-with-apache-commons-csv

Re: Re: New component proposal: commons-plugins

2022-04-14 Thread Peter Verhas
ceptor chains, not to speak of > > > interpolating configuration values from sources outside of Java. Even > > > less do I feel the need to have an abstraction layer that enables us to > > > swap out say, CDI for Spring or OSGi. Don't tempt me to cite XKCD 927 > on > > > you! > > > > > > Cheers, Thomas > > > > > > > > > - > > > To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org (mailto: > dev-unsubscr...@commons.apache.org) > > > For additional commands, e-mail: dev-h...@commons.apache.org (mailto: > dev-h...@commons.apache.org) > > > > > - > To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org > For additional commands, e-mail: dev-h...@commons.apache.org > > -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: New component proposal: commons-plugins

2022-04-08 Thread Peter Verhas
ious point, what is the high level architecture of a plugin system the library will support and what services will it provide? On Thu, Apr 7, 2022 at 7:57 PM Ralph Goers wrote: > > > > On Apr 7, 2022, at 2:52 AM, Peter Verhas wrote: > > > > > >> I would sugge

Re: New component proposal: commons-plugins

2022-04-07 Thread Peter Verhas
> > > The plugin system is design to convert configuration data into > instantiated objects. > For me that very much reads a dependency injection framework. -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: New component proposal: commons-plugins

2022-04-07 Thread Peter Verhas
` method. Again, if you find that answering the questions is difficult there may be several reasons. One thing is for sure: I am not trolling you. I am asking these questions because I honestly believe that any new library should address the things that are not addressed by other systems and libraries, and should provide a better way to do things, otherwise they will not be widely used. -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: New component proposal: commons-plugins

2022-04-04 Thread Peter Verhas
Thank Ralph for the answer related ServiceLoader. I understand your concerns. A new commons plugin module is in place if we identify the needs unmet with modern Java. However, the shortcomings you listed are mainly related to Java 8 and older versions. Thus I would appreciate it if you could clarif

Re: New component proposal: commons-plugins

2022-04-02 Thread Peter Verhas
on similar to how JUnit is > supported by IDEs and other tools. > > What do you think? Should this start in the Sandbox? Is anyone interested > in working on or using this? > > [0]: https://github.com/apache/logging-log4j2/tree/master/log4j-plugins < > https://github.com/apache/logging-log4j2/tree/master/log4j-plugins> > > — > Matt Sicker > > -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: [compress] 7z and Recovering Corrupt Archives

2021-06-06 Thread Peter Lee
+1 for the new option. A fast fail for corrupted archive could help a lot. Lee On 6 5 2021, at 4:32, Gary Gregory wrote: > In general, I think fail fast is ok with a clear exception message. > > Gary > On Fri, Jun 4, 2021, 15:44 Stefan Bodewig wrote: > > Hi all > > > > 7z archives provide CRCs f

Re: [all] OSS Fuzz

2021-04-22 Thread Peter Lee
Hi Fabian, Thanks a lot for all this. > One more thing: Could you perhaps add the following line to the READMEs of > compress and imaging? > I just created a PR in Compress https://github.com/apache/commons-compress/pull/189 Seems I missed a lot these days. :-( I also got a Google account(pete

Re: [all] OSS Fuzz

2021-04-15 Thread Peter Lee
+1 to fuzz. Fuzzing is widely used in many open source projects and it helped a lot in Compress. For the mailing list, many projects use Security. And creating a new one is OK for me. > I'd add myself as a moderator but we will need more moderators. If we need moderators, count me in. cheers, Le

Re: [COMPRESS] OSS-Fuzz integration

2021-03-07 Thread Peter Lee
I think the security list is a good choice. Lee On 3 8 2021, at 2:55, Stefan Bodewig wrote: > On 2021-03-07, Gary Gregory wrote: > > > This issue has popped as well WRT GitHub emails from Dependabot. > I don't think this is comparable. > The fuzzer may find issues that can be exploited as DoS att

[COMPRESS] Naming of a new option in Zip64Mode

2021-02-28 Thread Peter Lee
Hi, all. Recently there was a issue COMPRESS-565 about the Zip64. And I have pushed a fix PR #169 for it. The fix introduces a new option in Zip64Mode, which is a compromise solution for 7z, Expand-Archive and likely Excel. I named the new option `AlwaysWithCompatibility`, which may not be a goo

Re: [All][Math] GH PR and Travis-CI

2020-12-22 Thread Peter Lee
> but the build result is not shown in github. Correction : the build result is shown in github. I missed it cause the tab was hidden. :( Seems the travis build is triggered 10 hours later than the commit was submitted. cheers, Lee On 12 22 2020, at 7:50, Peter Lee wrote: > It's

Re: [All][Math] GH PR and Travis-CI

2020-12-22 Thread Peter Lee
It's weird cause travis seems have a successful build with this PR: https://travis-ci.com/github/apache/commons-math/builds/210145524 but the build result is not shown in github. Maybe it's just a accidental error and we can have a look till next PR? cheers, Lee On 12 21 2020, at 11:31, Gilles Sa

Re: [Compress] COMPRESS-540 : Random access of tar

2020-11-17 Thread Peter Lee
gt; not have to pay the price for a feature they don't want. Think of an app > that looks at large tar... > > Gary > On Sun, Nov 15, 2020, 21:51 Peter Lee wrote: > > Hi all, > > > > Robin has pushed a PR in github in July that implemented the random access > >

Re: [Compress] COMPRESS-540 : Random access of tar

2020-11-15 Thread Peter Lee
PR. > No blockers for me. Hope it helps. > Thanks for bringing it to the mailing list, and for the review. > CheersBruno > > On Monday, 16 November 2020, 3:51:48 pm NZDT, Peter Lee > wrote: > Hi all, > Robin has pushed a PR in github in July that implemented the random

[Compress] COMPRESS-540 : Random access of tar

2020-11-15 Thread Peter Lee
Hi all, Robin has pushed a PR in github in July that implemented the random access of tar : https://github.com/apache/commons-compress/pull/113 It's achieved by reading the tar once and have the start position of each tar entry stored. Tar is not designed to be random accessed so this may be a t

Re: [COMPRESS] Pack200 support in pack200 branch

2020-11-02 Thread Peter Lee
s looks acceptable, it can be merged > > and documented. > > > > The builds are green here > > https://github.com/apache/commons-compress/actions/runs/231719106 > > > > Gary > > > > > > On Mon, Aug 24, 2020 at 11:14 AM Gary Gregory > > wrote

Re: [compress] BZip2CompressorInputStream stops working without rhyme or reason ...

2020-10-16 Thread Peter Lee
Hi Albretch, This seems to be more suitable to be discussed in JIRA : https://issues.apache.org/jira/projects/COMPRESS/issues (https://link.getmailspring.com/link/1994dde5-ebdc-4f24-9bc7-105cf6551...@getmailspring.com/0?redirect=https%3A%2F%2Fissues.apache.org%2Fjira%2Fprojects%2FCOMPRESS%2Fissue

Re: [All] About Commons snapshot versions

2020-09-09 Thread Peter Lee
were set up to do so. A > migration to a new build system just took place and I don't know if we have > Commons builds on the new CI system yet. > > Gary > On Wed, Sep 9, 2020, 22:18 Peter Lee wrote: > > Hi all, > > > > I noticed that some Commons components snapshot v

[All] About Commons snapshot versions

2020-09-09 Thread Peter Lee
Hi all, I noticed that some Commons components snapshot versions released in https://repository.apache.org/content/groups/snapshots/org/apache/commons have not been updated for some time. Just curious about how do we publish snapshot versions and how often do we do that? cheers, Lee

Re: [COMPRESS] Pack200 support in pack200 branch

2020-08-23 Thread Peter Lee
After some debugging I found this at org.apache.harmony.pack200.Archive#171 : if (classes.size() > 0 && files.size() > 0) { segmentUnitList.add(new SegmentUnit(classes, files)); } Seems the Pack200 implementation in harmony requires existing of both classes AND files at the same time. The tests a

Re: [Compress] Build failure in jenkins and github actions

2020-08-22 Thread Peter Lee
hY2hlLm9yZw%3D%3D) cheers, Lee On 8 21 2020, at 10:18 , Gary Gregory wrote: > On Thu, Aug 20, 2020 at 7:57 AM Peter Lee wrote: > > > Hi all, > > > > The builds in jenkins and github actions are failing. > > For jenkins, the java7, 14 and 16 builds are failing. As we h

Re: [Compress] Build failure in jenkins and github actions

2020-08-21 Thread Peter Lee
the Pac200 from jdk and create a new lib for it, and we invoke > > that lib instead of jdk's Pac200. > > 3. we clean room a implementation of Pac200 (seems not quite worthy) > > > > So which will we pick? > > Or, any better ideas? > > > > Pe

Re: [Compress] Build failure in jenkins and github actions

2020-08-21 Thread Peter Lee
;m just thinking if we should make the builds' status green on JDK14+ by setting some "allow failure" config in GH actions and jenkins. cheers, Lee On 8 20 2020, at 8:06 , Gary Gregory wrote: > On Thu, Aug 20, 2020 at 7:57 AM Peter Lee wrote: > > > Hi all, > >

[Compress] Build failure in jenkins and github actions

2020-08-20 Thread Peter Lee
Hi all, The builds in jenkins and github actions are failing. For jenkins, the java7, 14 and 16 builds are failing. As we have moved from JAVA 7 to 8, maybe we should disable java 7 build in jenkins? Besides the java 14 and 16 are also failing, and we can have some "allow failure" config on them

Re: [COMPRESS] Java 7- > 8

2020-08-12 Thread Peter Lee
+1 for this. But it is not because of the lambdas(personally I do like the lambdas, but it is not a reason that could convince me to update the JDK). The OpenJDK7 is not supported basing on OpenJDK life cycle police any more recently(EOS since June, 2020) - and this is why I think should update

Re: [commons-compress] branch master updated: Enable GitHub Dependabot.

2020-07-26 Thread Peter Lee
It's why apache and open source is so charming and why we all love this so much. :-) cheers, Lee On 7 26 2020, at 10:04 , Rob Tompkins wrote: > > > > On Jul 26, 2020, at 9:53 AM, Peter Lee wrote: > > > > Hi Stefan, Rob, Gilles, Gary and all, > > > >

Re: [commons-compress] branch master updated: Enable GitHub Dependabot.

2020-07-26 Thread Peter Lee
t; conversation to be convinced and not even blink at the > subsequent automated emails. > > So a list of "bot" statements (in MD format) is now a good > enough substitute for that "conversation" (?). > > That's the kind of "progress" which GitHub b

Re: [commons-compress] branch master updated: Enable GitHub Dependabot.

2020-07-23 Thread Peter Lee
Got plenty of mails this morning(which surprised me a lot). Seems they are all triggered by github dependency bot. Have been too busy these days. Will try to look into them this weekend. On 7. 23 2020, at 5:12 , Gilles Sadowski wrote: > Hi. > > 2020-07-22 18:32 UTC+02:00, Stefan Bodewig : > > I h

[VFS] VFS-748 : about files cache

2020-06-28 Thread Peter Lee
Hi all, As the issue VFS-748 said, it seems there's a problem in TarFileSystem about the files cache : it will be removed after a JVM gc. I looked into the code and found out that the cache is held by the local variable strongRef : the variable strongRef and the variable fileObj are holding each

[Compress] COMPRESS-538 : about Zip64

2020-06-27 Thread Peter Lee
Hi all, The recent issue COMPRESS-538 talks about the zip64 extra field in Local File Header. Currently we will add a Zip64 extra field for the entries with uncompressed size unspecified. And we will update the zip64 extra field in ZipArchiveOutputStream.rewriteSizesAndCrc a little bit : if we ac

Re: About binary compatibility

2020-06-15 Thread Peter Lee
> I kind of like inaging1 even if it is weird and even though we do not have a > precedent here in Commons. I'm curious what others think. I think you are meaning imaging1 instead of inaging1 :) Indeed imaging1 is kind of weird but looks good to me. +1 On June, 16, 2020, at 7:06 , Gary Gregory

Re: Quick questions about this mailing list

2020-06-12 Thread Peter
The invalid has imho to do with, yahoo. You should be able to use a apache.org address, if you have commiter status. Just configure an alias on your email client. Am 13.06.20 um 06:06 schrieb Miguel Munoz: When I send an email to this list, my email address shows up in the archive as ending w

[VFS] A wildcard scheme for archives

2020-06-06 Thread Peter Lee
Hi all, The Commons Compress has the capality to provide many archive/compress types(zip, 7z, zstd, lz4 ...). I'm thinking about if we could provide a wildcard scheme for archives/compressors using Compress as the provider. WDYT? BTW : I can not connect to the Apache SMTP server(a.k.a mail-rely.a

Re: [commons-compress] branch master updated: minor typos cleanup

2020-06-01 Thread Peter Lee
Oops, I was looking the commit and found two @throws IllegalArgumentException, and I was thinking this is a duplicated throws caused by copy-paste. And I was so much foolish that I deleted it without any invesgating into the code. Really sorry about this. On Mon, Jun 1, 2020 at 10:57 PM Stefan Bod

Re: [commons-compress] branch master updated: COMPRESS-530 : skip non-number when parsing pax header

2020-05-27 Thread Peter Lee
Did some googles, can't find too much but this : https://www.systutorials.com/docs/linux/man/5-star/ And it says : > Each record starts with a a decimal length field. The length includes the total size of a record including the length field itself and the trailing new line. Seems we should throw a

Re: [commons-compress] branch master updated: COMPRESS-529 : throws IOException if non-number exists in pax header

2020-05-27 Thread Peter Lee
when we are trying to read it as a double. I'll find out a proper way to throw the detailed exception without breaking the compatibility. On Wed, May 27, 2020 at 9:15 PM Stefan Bodewig wrote: > On 2020-05-27, Peter Lee wrote: > > > Oops, sorry about that. > > No big deal.

Re: [commons-compress] branch master updated: COMPRESS-529 : throws IOException if non-number exists in pax header

2020-05-27 Thread Peter Lee
Oops, sorry about that. Will undo all the commits. On Tue, May 26, 2020 at 11:50 PM Stefan Bodewig wrote: > On 2020-05-26, wrote: > > > -public void addPaxHeader(String name,String value) { > > - processPaxHeader(name,value); > > +public void addPaxHeader(String name, String val

Re: [COMPRESS] Travis build fail with JDK14

2020-05-13 Thread Peter Lee
pache/commons-vfs/commit/249d1dc9fb3f2bd5209aaa299c4ed61414f1fd78#diff-354f30a63fb0907d4ad57269548329e3 > > > > > > adding a unpassable check in travis will makes all pull requests/commit > > return builld failure, which will hide problem and make checker's life > hard. > > > > Ste

[COMPRESS] Travis build fail with JDK14

2020-05-13 Thread Peter Lee
Hi,all The travis build of Compress is failing now cause the openjdk14 was added to travis.yml recently. The reason is the Pack200 was removed from JDK14 and there was a discussion about it in January. Emmanuel is working on his replacement project(https://github.com/pack200/pack200) but not fini

Re: what became of beanshell in Apache commons?

2020-04-25 Thread Peter Kovacs
Yes, my wrong. I think I got the impression from Wikipedia, and I did find the vote. Still, thanks for the response. Am 25.04.20 um 09:58 schrieb Stefan Bodewig: On 2020-04-24, Peter Kovacs wrote: Now I figured that beanshell was included into apache copmmons, which we also use. The move

what became of beanshell in Apache commons?

2020-04-24 Thread Peter Kovacs
, links and so on. Sorry I am a bit lost having to bridge 7 years gap. Thanks a lot for any support! (I am subscribing, So no worries.) All the Best Peter - To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org For additional

Re: [Compress]Add some easy-to-use APIs for Zip and other archivers

2020-03-10 Thread Peter Lee
> Peter, > > Please also take a look at Apache Commons VFS. Sure. I will look into Commons VFS. Thank you for your suggestion.

Re: [Compress]Add some easy-to-use APIs for Zip and other archivers

2020-03-10 Thread Peter Lee
Just finished reading the COMPRESS-118 and the 2 threads. I have to say that's a lot of content. :) I have also read the Archiver and the Expander, and I do like them a lot. They have great abstraction, and the implementation for callback(CloseableConsumer and Finisher) do impressed me. In the th

[Compress]Add some easy-to-use APIs for Zip and other archivers

2020-03-09 Thread Peter Lee
Hi all. I'm thinking about adding some easy-to-use APIs for Zip. Currently I got some ideas : 1. Add extractAll(String targetPath) in ZipFile : extract all the files to the specific directory. 2. Add getInputStream(String fileName) in ZipFile : get the input stream for a file by name. And I belie

Re: [Compress] Zip Files: History, Explanation and Implementation

2020-03-09 Thread Peter Lee
;m just hoping I can implement a fast deflater. Maybe the incubating VectorAPI may help me. It can achieve SIMD in native Java. Looks good. Stefan Bodewig 于2020年3月7日周六 下午11:13写道: > On 2020-03-07, Peter Lee wrote: > > > I'm planning to build a pure Java deflater/inflater on my own

Re: [Compress] Zip Files: History, Explanation and Implementation

2020-03-06 Thread Peter Lee
Great article. This may help a lot when learning about zip. I'm planning to build a pure Java deflater/inflater on my own. Believe this may help a lot. Gary Gregory 于2020年3月7日周六 上午10:30写道: > Just FYI:Zip Files: History, Explanation and Implementation > https://www.hanshq.net/zip.html > > Gary >

Re: [lang] NPE vs IAE

2020-03-05 Thread Peter Verhas
easurement proves that the assertions pose significant performance cost. Regards, Peter On Thu, Mar 5, 2020 at 4:12 PM sebb wrote: > On Wed, 4 Mar 2020 at 14:20, Gilles Sadowski wrote: > > > > Le mer. 4 mars 2020 à 15:16, sebb a écrit : > > > > > > On Wed,

Re: Java Modules Codec, Collections, IO and Lang

2020-03-01 Thread Peter Verhas
I used Jabel, and Maven profiles to generate jvm8 and also jvm11 jars in the Java::Geci project. I also wrote a document about what, why, and how I did it: https://javax0.wordpress.com/2019/11/06/supporting-java-8/ It may help. Peter On Sun, 1 Mar 2020 at 12:38, Romain Manni-Bucau wrote

Re: [lang] New Streams code breaks build

2020-02-04 Thread Peter Verhas
e to Checktyle errors. > > Please fix. > > Gary > -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

[Compress]Discussion about COMPRESS-499

2019-12-18 Thread Peter Lee
Hi all. A recent issue COMPRESS-499( https://issues.apache.org/jira/projects/COMPRESS/issues/COMPRESS-499) discussed about a potential problem in SeekableInMemoryByteChannel. Based on the java docs( https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/channels/SeekableByteChannel.

Re: [Compress]New PRs on github need reviews

2019-11-26 Thread Peter Lee
comments/questions to the PR for Tar. > > cheers, > Torsten > > On Tue, Nov 26, 2019 at 4:46 AM Peter Lee > wrote: > > > Hi all, > > > > I'm Lee and I'm new to commons-compress. I'm a amateur in compression > > algorithms. I like common

[Compress]New PRs on github need reviews

2019-11-25 Thread Peter Lee
Hi all, I'm Lee and I'm new to commons-compress. I'm a amateur in compression algorithms. I like commons-compress cause it supports so many specifications. I'd like to contribute to it. Recently I pushed 3 PRs in github : 1. Add support for Tar with sparse entries 2. the split/spanned zip support

[LANG] JavaDoc generation from unit test automatically

2019-09-06 Thread Peter Verhas
Here is the article that describes how to get the JavaDoc from unit tests. https://javax0.wordpress.com/2019/09/04/keep-javadoc-up-to-date/ -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: [LANG] Q: introduction of new development tool

2019-09-01 Thread Peter Verhas
it is published. Peter There are many projects where the documentation is not up-to-date. It is easy to forget to change the documentation after the code was changed. The reason is fairly understandable. There is a change in the code, then debug, then hopefully change in the tests (or the other

Re: [LANG] Q: introduction of new development tool

2019-08-28 Thread Peter Verhas
>Runtime retention is a potential problem, as an extra binary may be needed. >The jar might no longer be a drop-in replacement. That is exactly while the annotations are an option only to use. On Wed, Aug 28, 2019 at 4:17 PM sebb wrote: > On Wed, 28 Aug 2019 at 14:55, Peter Verh

Re: [LANG] Q: introduction of new development tool

2019-08-28 Thread Peter Verhas
a::Geci is a bit more flexible than that. I am not sure about that though. I think that the next step is that I will create a short sample with a pull request. Peter On Wed, Aug 28, 2019 at 10:12 AM Paul King wrote: > I haven't used Geci, so can't really comment on al

[LANG] Q: introduction of new development tool

2019-08-27 Thread Peter Verhas
st note: The tool is extremely non-invasive. Any project using it can decide at any point to discontinue the use. All it needs is to delete the tests that start the tool, remove the dependency from the POM file and that is it. -- Peter Verhas pe...@verhas.com t: +41791542095 skype: verhas

Re: [collections] breaking changes

2018-03-29 Thread Peter Burka
This could be solved if it were possible to force javac to generate bridge methods. There's an extension which would allow that here: https://github.com/infradna/bridge-method-injector, but I suspect it would complicate the build process quite a bit. On Thu, Mar 29, 2018 at 4:48 PM sebb wrote: >

Re: [text] Upper/Lower case enum

2018-02-22 Thread Peter Burka
This feels like it might have been more useful pre-Java 8. Why not use a lamda function, which would permit arbitrary string transformations? /peter On Thu, Feb 22, 2018, 7:42 PM Gary Gregory wrote: > On Thu, Feb 22, 2018 at 4:27 PM, sebb wrote: > > > On 22 February 2018 at

Re: [Numbers] Java version?

2017-04-30 Thread Peter Ansell
https://jenkins.io/blog/2017/01/17/Jenkins-is-upgrading-to-Java-8/ Cheers, Peter On 1 May 2017 at 02:22, Matt Sicker wrote: > Supporting Java 6 is going to continue to become harder and harder to do > with infrastructural upgrades across the board. Recent versions of Gradle > require Java

Re: [VFS] Interest in starting a Java 7 FileSystem-based version?

2017-03-15 Thread Peter Ansell
Feel free to merge your changes into Tika to update the barebones implementation I contributed there: https://github.com/apache/tika/blob/master/tika-java7/src/main/java/org/apache/tika/filetypedetector/TikaFileTypeDetector.java Cheers, Peter On 16 March 2017 at 14:46, Schalk Cronjé wrote

Re: [VFS] Interest in starting a Java 7 FileSystem-based version?

2017-03-15 Thread Peter Ansell
An example from Google of a custom Java-7 file system provider (Apache licensed) which may also be useful is at: https://github.com/google/jimfs Cheers, Peter On 16 March 2017 at 14:12, Matt Sicker wrote: > Ralph has mentioned in the past an idea about rewriting commons-vfs us

Re: Immutable builder pattern for parsers?

2017-02-09 Thread Peter Ansell
On 9 February 2017 at 13:38, Stian Soiland-Reyes wrote: > Peter Ansell raised a valid question about why in Commons RDF I made the > RDFParser interface as an immutable factory-like builder pattern. > > https://commons.apache.org/proper/commons-rdf/apidocs/org/apache/commons/rdf/

Re: Immutable builder pattern for parsers?

2017-02-08 Thread Peter Ansell
omplex and fixed to a particular use case, per its use of Future. My main comment is that I would prefer if there were either example code on how to use an ExecutorService to implement asynchronous parsing, or a helper utility, rather than it being required by the core API. Cheers, Peter On 9 Febru

Re: RDF commons testing

2017-01-29 Thread Peter Ansell
Hi Claude, Abstract test classes are working well for Commons RDF so far. Others may benefit from your solution, so feel free to suggest the approach to others who may be interested in exploring it. Cheers, Peter On 30 January 2017 at 03:11, Claude Warren wrote: > Peter, > > I have

Re: RDF commons testing

2017-01-28 Thread Peter Ansell
gt; > 3. It means that refactoring of parent interfaces / classes do not force > additional coding for the testing of derived classes. > > If you are interested I would be glad to help convert existing tests to > contract tests. Hi Claude,

Re: [lang] Thread safety annotations

2016-11-27 Thread Peter Ansell
eature. > > If I am a downstream user of Commons Lang's new annotations, I would need a > Maven scope that says "I need [lang] as a compile time only dependency" I > do not see such a scope on > https://maven.apache.org/guides/introduction/introduction-to-depen

Re: [lang] Thread safety annotations

2016-11-27 Thread Peter Ansell
e a recollection of having used the "optional" dependency feature for compile time annotations in the past: https://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html Cheers, Peter -

Re: [DISCUSS] Commons RDF as new component?

2016-11-21 Thread Peter Ansell
archived, but still exists to delineate the crossing point: https://github.com/commons-rdf/commons-rdf/graphs/contributors Cheers, Peter On 22 November 2016 at 13:47, John D. Ament wrote: > Sometimes, we have to believe in github's data. > > https://github.com/apache/incubator-com

Re: [DISCUSS] Commons RDF as new component?

2016-11-17 Thread Peter Ansell
intermediate > 0.4.0 under Commons? Just similar reviews would be a large help! > > On 16 Nov 2016 10:25 pm, "Peter Ansell" wrote: > >> Hi Stian, >> >> I personally don't think Commons RDF is ready for a 1.0.0 release. The >> APIs have still been c

Re: [DISCUSS] Commons RDF as new component?

2016-11-16 Thread Peter Ansell
they would not be easily addressed if a 1.0 release line was declared now. However, that isn't a reason to keep it in incubation. Good luck! Cheers, Peter On 17 November 2016 at 00:22, Stian Soiland-Reyes wrote: > Commons RDF (incubating) has been in the Apache Incubator since 2015,

Re: [DISCUSS] Commons RDF as new component?

2016-11-16 Thread Peter Ansell
ServiceLoader approach (just using the RDF interface) you don't have object level access to the mutators to create native Jena/RDF4J/etc. objects out of the Commons RDF objects. There should still be static methods for those cases, but they are less simple to use than the mutators in general. Cheers,

Re: [RDF] jena, rdf4j, json-ld integrations

2016-09-15 Thread Peter Ansell
On 15 September 2016 at 18:34, Stian Soiland-Reyes wrote: > On 15 Sep 2016 5:11 a.m., "Peter Ansell" wrote: >> One of the original goals was to help with migration and >> interoperability so if it doesn't then things would need to be >> reworked on the Com

Re: [RDF] Implementation class name style

2016-09-14 Thread Peter Ansell
at this point. If it would simplify things just to rely on the prefix, you may be able to drop the Impl suffix without confusion. Cheers, Peter On 15 September 2016 at 13:01, Stian Soiland-Reyes wrote: > On 13 Sep 2016 2:15 a.m., "Gary Gregory" wrote: >> &

Re: [RDF] jena, rdf4j, json-ld integrations

2016-09-14 Thread Peter Ansell
On 15 September 2016 at 12:49, Stian Soiland-Reyes wrote: > On 13 Sep 2016 5:14 a.m., "Peter Ansell" wrote: >> Sesame-4 will not have any more releases due to the Eclipse migration, >> so you will not have a large user-base for that. Even maintaining a >> Sesa

Re: [RDF] jena, rdf4j, json-ld integrations

2016-09-12 Thread Peter Ansell
-java-clerezza https://github.com/jsonld-java/jsonld-java-rdf2go However, both Jena and Sesame/RDF4J have ended up having their JSONLD-Java integrations moved back into their core repositories so it isn't the same for everyone. Cheers, Peter On 13 September 2016 at 09:55, Stian Soiland-Reyes w

Re: [csv] Update to Java 8

2016-06-13 Thread Peter Ansell
t the pattern should be similar. https://github.com/ansell/csvsum/blob/master/src/main/java/com/github/ansell/csv/util/CSVUtil.java#L98 Cheers, Peter On 14 June 2016 at 03:10, Stian Soiland-Reyes wrote: > 7 (email) or 8 (subject)? > > I'm +1 for either - but I'm not sure

Re: [VFS] NIO Version Questions

2016-06-01 Thread Peter Ansell
ly first before using NIO2. Cheers, Peter On 2 June 2016 at 11:24, Mark Fortner wrote: > Hi Peter, > Implementing a new file system just to support "home" or "Photos" virtual > roots, would be a rather heavyweight approach for something that should be > config

  1   2   >