You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2019/09/21 07:13:00 UTC

[jira] [Work logged] (POOL-376) invalidateObject should not return NullPointerException

     [ https://issues.apache.org/jira/browse/POOL-376?focusedWorklogId=316077&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-316077 ]

ASF GitHub Bot logged work on POOL-376:
---------------------------------------

                Author: ASF GitHub Bot
            Created on: 21/Sep/19 07:12
            Start Date: 21/Sep/19 07:12
    Worklog Time Spent: 10m 
      Work Description: sazzad16 commented on pull request #24: POOL-376 invalidateObject should not throw NPE
URL: https://github.com/apache/commons-pool/pull/24
 
 
   `GenericObjectPool.invalidateObject(T obj)` and/or `GenericObjectPool.destroy(PooledObject<T> toDestroy)` should not throw NullPointerException when respective parameter (`obj/`toDestroy`) is not `null`.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Issue Time Tracking
-------------------

            Worklog Id:     (was: 316077)
    Remaining Estimate: 0h
            Time Spent: 10m

> invalidateObject should not return NullPointerException
> -------------------------------------------------------
>
>                 Key: POOL-376
>                 URL: https://issues.apache.org/jira/browse/POOL-376
>             Project: Commons Pool
>          Issue Type: Improvement
>    Affects Versions: 2.6.2
>            Reporter: M Sazzadul Hoque
>            Priority: Major
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> {{GenericObjectPool.invalidateObject(T obj)}} should not return {{NullPointerException}} when obj is not null.
> Please see following stack trace:
> {code:java}
> Caused by: java.lang.NullPointerException
>         at org.apache.commons.pool2.impl.LinkedBlockingDeque.putLast(LinkedBlockingDeque.java:454)
>         at org.apache.commons.pool2.impl.LinkedBlockingDeque.put(LinkedBlockingDeque.java:788)
>         at org.apache.commons.pool2.impl.GenericObjectPool.destroy(GenericObjectPool.java:939)
>         at org.apache.commons.pool2.impl.GenericObjectPool.invalidateObject(GenericObjectPool.java:618)
> {code}
> Apparent reason: In {{destroy(PooledObject<T> toDestroy)}}, create() may return null even though {{toDestroy}} is already destroyed.
> Please make the fix available for JDK 1.7.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)