directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (DIRSERVER-2016) Java 7 vs Java 8 : failure in Java 8
Date Thu, 13 Nov 2014 16:54:34 GMT

     [ https://issues.apache.org/jira/browse/DIRSERVER-2016?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Emmanuel Lecharny resolved DIRSERVER-2016.
------------------------------------------
    Resolution: Fixed

Fixed with http://svn.apache.org/r1639354

> Java 7 vs Java 8 : failure in Java 8
> ------------------------------------
>
>                 Key: DIRSERVER-2016
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-2016
>             Project: Directory ApacheDS
>          Issue Type: Bug
>    Affects Versions: 2.0.0-M17
>            Reporter: Emmanuel Lecharny
>            Priority: Blocker
>             Fix For: 2.0.0-M18
>
>
> We have a nasty bug when running the tests using Java 8 : all of sudden, we have some
faling tests in core-integ and server-integ.
> What happens is that when we do a global search, we go through all the partition, and
for each one of them, we create a cursor. Then in the NamingEnumeration we build around this
list of cursors, we do (CursorList class) :
> {code}
>    public boolean first() throws LdapException, CursorException
>    {
>        if ( listSize > 0 )
>        {
>            index = start;
>            return list.get( index ).first();
>        }
>        return false;
>    }
> {code}
> Obviously, if the first cursor has no candidate, we will return false, and we won't check
the second list.
> So why does it work in Java 7 ? Simple... The partitions is an HashMap, and we get all
the partition from it. In Java 7, we first get System (which returns results) then Schema
(which has no candidate). And it works. In java 8, we get Schema first and System second,
so the first cursor is empty, an the cursor.first() call return false...



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message