When you dereference a null pointer, you get an NPE. We can agree to that.
We can also agree it's not inherently wrong to throw IAE on a null argument
check, but this discussion has never been about that. The discussion has
always centered on what the trend setters are doing -- and they say go with
On 6 May 2014 22:54, Paul Benedict wrote:
> This is not a matter of law. If Oracle/Sun set a direction on how to use
> NPE, it's a really good idea to follow them -- even if you don't agree, do
> it for the sake of consistency. I don't think using IAE is somehow "better"
> Java than what they are
On 6 May 2014 18:43, Benedikt Ritter wrote:
> 2014-05-06 9:39 GMT+02:00 Benedikt Ritter :
>
>>
>>
>> 2014-05-06 5:06 GMT+02:00 Julien Aymé :
>>
>> Hi,
>>>
>>>
>>> How can the compiler know whether max(1,2,3) is max(a,b,c) or max(a...) ?
>>>
>>>
>>> max(1,2,3) is compiled to max(a,b,c). The compi
This is not a matter of law. If Oracle/Sun set a direction on how to use
NPE, it's a really good idea to follow them -- even if you don't agree, do
it for the sake of consistency. I don't think using IAE is somehow "better"
Java than what they are doing. And I give weight to what Joshua said
becaus
On 6 May 2014 22:27, "Michael Osipov" <1983-01...@gmx.net> wrote:
>
> Am 2014-05-06 15:27, schrieb Benedikt Ritter:
>
>> Hi Thiago,
>>
>>
>> 2014-05-06 14:53 GMT+02:00 Thiago Andrade :
>>
>>> Hello people,
>>>
>>> Analizing the JIRA issue
https://issues.apache.org/jira/browse/LANG-1008the
>>> contr
Yes, it's supposed to throw NPE for the reasons stated a couple times in
this thread. That's by design, not accident. The "official" version in
java.lang.Objects (JDK 7+) does the same thing.
Cheers,
Paul
On Tue, May 6, 2014 at 4:00 PM, Duncan Jones wrote:
> On 6 May 2014 20:41, Phil Steitz
It's an old debate but the "official" Java coding style has become NPE for
null arguments and IAE for invalid non-null arguments. Lang3 was supposed
to go down that path because that's how the stewards of Java (Oracle/Sun)
are coding and it's part of the best practices found in Joshua Bloch's book.
Online report :
https://continuum-ci.apache.org/continuum/buildResult.action?buildId=30324&projectId=79
Build statistics:
State: Failed
Previous State: Ok
Started at: Tue 6 May 2014 21:22:55 +
Finished at: Tue 6 May 2014 21:23:44 +
Total time: 48s
Build Trigger: Schedule
Bui
On 6 May 2014 20:41, Phil Steitz wrote:
> On 5/6/14, 10:09 AM, sebb wrote:
>> On 6 May 2014 14:27, Benedikt Ritter wrote:
>>> Hi Thiago,
>>>
>>>
>>> 2014-05-06 14:53 GMT+02:00 Thiago Andrade :
>>>
Hello people,
Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-100
On 6 May 2014 19:19, Paul Benedict wrote:
> NPE is implicit if the method does not allow an argument to be null. This
> doesn't have to be the case. This has nothing to do with the JDK vs. 3rd
> party source. It's just about the contract. As long as you document which
> arguments can be null, then
That's my experience too. So let's go for the concurrenthashmap impl
(patch on jira) and then see how we do the invalidation stuff in a
2.1?
Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/
Am 2014-05-06 15:27, schrieb Benedikt Ritter:
Hi Thiago,
2014-05-06 14:53 GMT+02:00 Thiago Andrade :
Hello people,
Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-1008the
contributors noticed that NumberUtils.max/min methods all have the same
problem:
They all throw an Il
Hello,
I tried several times to understand how the testconfiguration and suite
building is working but I failed.
I noticed that most of the tests have
totally unrelated class-names when run in Eclipse JUnit runner (but can
be used). So I typically do the same as you did, make standalone tests
or
Am 2014-05-06 15:27, schrieb Benedikt Ritter:
Hi Thiago,
2014-05-06 14:53 GMT+02:00 Thiago Andrade :
Hello people,
Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-1008the
contributors noticed that NumberUtils.max/min methods all have the same
problem:
They all throw an Il
On 5/6/14, 10:09 AM, sebb wrote:
> On 6 May 2014 14:27, Benedikt Ritter wrote:
>> Hi Thiago,
>>
>>
>> 2014-05-06 14:53 GMT+02:00 Thiago Andrade :
>>
>>> Hello people,
>>>
>>> Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-1008the
>>> contributors noticed that NumberUtils.max/m
Hi Petar,
Am 06.05.2014 15:45, schrieb Petar Tahchiev:
> Hi Gary,
>
> actually I found this:
>
> final Properties props =
> ConfigurationConverter.getProperties(configuration);
>
> which does the job.
I also would have pointed you to this method, but was not 100% sure what
you meant.
My first
NPE is implicit if the method does not allow an argument to be null. This
doesn't have to be the case. This has nothing to do with the JDK vs. 3rd
party source. It's just about the contract. As long as you document which
arguments can be null, then you're good -- otherwise throw an NPE to
capture t
Github user asfgit closed the pull request at:
https://github.com/apache/commons-lang/pull/13
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is
Well my personal experience only:
1.) I barely use distributed caches. I use ehcache in most of my projects as of
today, but do not use the distribution feature much. Way too complicated
2.) What actually IS useful is distributed cache invalidation. The caching side
is fine to just select any
Github user asfgit closed the pull request at:
https://github.com/apache/commons-lang/pull/22
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is
Github user asfgit closed the pull request at:
https://github.com/apache/commons-lang/pull/21
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is
2014-05-06 9:39 GMT+02:00 Benedikt Ritter :
>
>
> 2014-05-06 5:06 GMT+02:00 Julien Aymé :
>
> Hi,
>>
>>
>> How can the compiler know whether max(1,2,3) is max(a,b,c) or max(a...) ?
>>
>>
>> max(1,2,3) is compiled to max(a,b,c). The compiler will use the finer
>> method instead of using the more
On 6 May 2014 14:27, Benedikt Ritter wrote:
> Hi Thiago,
>
>
> 2014-05-06 14:53 GMT+02:00 Thiago Andrade :
>
>> Hello people,
>>
>> Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-1008the
>> contributors noticed that NumberUtils.max/min methods all have the same
>> problem:
>>
Hi,
I'm trying to reproduce VFS-298 with the unit test (in trunk)
because I met a similar exception in my application, but I can't
execute the unit test, ProviderRenameTests.
When I run `mvn clean install' in the root folder, I can't find
'core/target/surefire-reports/*ProviderRenameTests*.txt'
Hi,
I'm trying to reproduce VFS-298 with the unit test (in trunk)
because I met a similar exception in my application, but I can't
execute the unit test, ProviderRenameTests.
When I run `mvn clean install' in the root folder, I can't find
'core/target/surefire-reports/*ProviderRenameTests*.txt'
Hi Gary,
actually I found this:
final Properties props =
ConfigurationConverter.getProperties(configuration);
which does the job.
2014-05-06 16:21 GMT+03:00 Gary Gregory :
> Hi Petar, good to see you here.
>
> Feel free to provide a patch to move the ball forward. The next question
> would b
Hi Thiago,
2014-05-06 14:53 GMT+02:00 Thiago Andrade :
> Hello people,
>
> Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-1008the
> contributors noticed that NumberUtils.max/min methods all have the same
> problem:
> They all throw an IllegalArgumentException when according
Hi Petar, good to see you here.
Feel free to provide a patch to move the ball forward. The next question
would be should the returned object be a safe copy or should changes in the
object be reflected in the config?
Gary
On Tue, May 6, 2014 at 7:45 AM, Petar Tahchiev wrote:
> Hi guys,
>
> I'm
Hello people,
Analizing the JIRA issue https://issues.apache.org/jira/browse/LANG-1008 the
contributors noticed that NumberUtils.max/min methods all have the same
problem:
They all throw an IllegalArgumentException when according to the official
documentation (Oracle|Sun) says that a NullPointerEx
Hi guys,
I'm looking at the API and I can't seem to find a method that returns all
the Properties in a Configuration object. I know I can access the keys and
then iterate and get the property with that key, but is there any method
like getAllProperties? If not is there any reason not to add one?
Here some pseudo-core details about my first mail:
New internals:
* NetworkTopology
* EntryRepartitor: compute the index of the
* Node (LocalNode which is current impl and RemoteNode which is just a
remote facade relying Network)
NetworkTopology { // impl using udp/tcp/or whatever
Node[] fin
FYI I attached a patch using a ConcurrentHashMap here
https://issues.apache.org/jira/browse/JCS-127
It is pretty fast compared to previous impl.
Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github
Online report :
https://continuum-ci.apache.org/continuum/buildResult.action?buildId=30288&projectId=286
Build statistics:
State: Failed
Previous State: Failed
Started at: Tue 6 May 2014 08:00:04 +
Finished at: Tue 6 May 2014 08:04:16 +
Total time: 4m 12s
Build Trigger: Schedu
2014-05-06 5:06 GMT+02:00 Julien Aymé :
> Hi,
>
>
> How can the compiler know whether max(1,2,3) is max(a,b,c) or max(a...) ?
>
>
> max(1,2,3) is compiled to max(a,b,c). The compiler will use the finer
> method instead of using the more generic one.
>
> This is used for example in logging framew
Online report :
https://continuum-ci.apache.org/continuum/buildResult.action?buildId=30287&projectId=286
Build statistics:
State: Failed
Previous State: Failed
Started at: Tue 6 May 2014 07:20:39 +
Finished at: Tue 6 May 2014 07:24:27 +
Total time: 3m 48s
Build Trigger: Schedu
35 matches
Mail list logo