Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-20 Thread Emmanuel Lécharny



On 20/03/2020 15:43, Francesco Chicchiriccò wrote:

On 2020/03/20 04:18:44, Emmanuel Lécharny  wrote:

Hi Francesco,

I applied a fix for this bug (and another one that I found at the same
time).
  
I may cut a release soon.

Hey, I was about to ask the JIRA number but a new release is way better, thanks 
:-)



https://issues.apache.org/jira/browse/DIRSERVER-2302

https://issues.apache.org/jira/browse/DIRSERVER-2303



The new release will take a bit of time.


May I suggest you change your filter to use (objectClass=*) instead of 
(objectClass=top) ?



-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-20 Thread Francesco Chicchiriccò
On 2020/03/20 04:18:44, Emmanuel Lécharny  wrote: 
> Hi Francesco,
> 
> I applied a fix for this bug (and another one that I found at the same 
> time).
>  
> I may cut a release soon.

Hey, I was about to ask the JIRA number but a new release is way better, thanks 
:-)

> On 19/03/2020 19:08, Emmanuel Lécharny wrote:
> > Hi Francesco
> >
> >
> > sorry for the latency...
> >
> > There is a clear bug in the way we handle a filter like 
> > (ObjectClass=top) in the search engine. As 'top' is never present in 
> > the index - for obvious reason : *every* single entry has such an 
> > attribute value -, the filter returns no candidate, so the 
> > encapsulating filter evaluation simply stops :
> >
> > (&(objectClass=top:[0])(cn=testLDAPGroup))  (note the [0] here).
> >
> >
> > The code that does that is :
> >
> >     private long getConjunctionScan( PartitionTxn partitionTxn, 
> > BranchNode node ) throws LdapException
> >     {
> >     long count = Long.MAX_VALUE;
> >     List children = node.getChildren();
> >
> >     for ( ExprNode child : children )
> >     {
> >     if ( ( count == 1 ) && ( child instanceof ScopeNode ) )
> >     {
> >     // We can stop here
> >     break;
> >     }
> >
> >     annotate( partitionTxn, child );
> >     count = Math.min( ( ( Long ) child.get( COUNT_ANNOTATION ) 
> > ), count );
> >
> >     if ( count == 0 )
> >     {
> >     // No need to continue   <- Obviously a bad idea 
> > in this very case...
> >     break;
> >     }
> >     }
> >
> > In your case,  there is a workaround : changing your filter to be 
> > "(&(objectClass=*)(cn=testLDAPGroup))"
> >
> >
> > I'll open a JIRA.
> >
> >
> > Thanks for the report and the test case !
> >
> >
> > On 17/03/2020 15:02, Francesco Chicchiriccò wrote:
> >> On 2020/03/15 14:46:27, Francesco Chicchiricc��  
> >> wrote:
> >>> On 2020/03/15 14:14:56, Emmanuel Lécharny  wrote:
>  Hi Francesco,
> 
>  On 15/03/2020 14:49, Francesco Chicchiriccò wrote:
> > Hi there,
> > I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing 
> > some troubles.
>  Hmmm, there is no such 2.0.0.
> >>> Ah, sorry, I was meaning 2.0.0.AM26 of course.
> >>>
> > For example, this used to work fine (e.g.  to find the group with 
> > the given cn) previously:
> >
> > ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b 
> > "ou=groups,o=isp" 
> > '(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))'
> >  
> > cn
> >
> > Now this does not return any result; when I change the filter to
> >
> > '(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'
> >
> > it works again.
> >
> > Also
> >
> > '(&(objectClass=top)(cn=lastGroup3ae5600a))'
> >
> > is working fine; so it seems that top is somehow disturbing.
> >
> > Any ideas? Thanks!
>  Do you have an env I can use to test that ?
> >> Hi Emmanuel,
> >> sorry it took so long to get something simpler to reproduce the problem.
> >>
> >> I have assembled at
> >>
> >> https://github.com/ilgrosso/apacheds
> >>
> >> Just clone and run
> >>
> >> mvn clean verify
> >>
> >> The tests executed are
> >>
> >> https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L42
> >>  
> >>
> >>
> >> which runs with filter
> >>
> >> (&(objectClass=groupOfUniqueNames)(cn=testLDAPGroup))
> >>
> >> and finds the group, and
> >>
> >> https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L59
> >>  
> >>
> >>
> >> which runs with filter
> >>
> >> (&(objectClass=top)(cn=testLDAPGroup))
> >>
> >> and does not find the group.
> >>
> >> The ApacheDS init is in
> >>
> >> https://github.com/ilgrosso/apacheds/blob/master/src/main/java/net/tirasa/sample/apacheds/ApacheDSStart.java#L193
> >>  
> >>
> >>
> >> Thanks for your support.
> >> Regards.
> >>
> >>
> >> -
> >> To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
> >> For additional commands, e-mail: users-h...@directory.apache.org
> >>
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
> For additional commands, e-mail: users-h...@directory.apache.org
> 
> 

-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-19 Thread Emmanuel Lécharny

Hi Francesco,

I applied a fix for this bug (and another one that I found at the same 
time).



I may cut a release soon.

On 19/03/2020 19:08, Emmanuel Lécharny wrote:

Hi Francesco


sorry for the latency...

There is a clear bug in the way we handle a filter like 
(ObjectClass=top) in the search engine. As 'top' is never present in 
the index - for obvious reason : *every* single entry has such an 
attribute value -, the filter returns no candidate, so the 
encapsulating filter evaluation simply stops :


(&(objectClass=top:[0])(cn=testLDAPGroup))  (note the [0] here).


The code that does that is :

    private long getConjunctionScan( PartitionTxn partitionTxn, 
BranchNode node ) throws LdapException

    {
    long count = Long.MAX_VALUE;
    List children = node.getChildren();

    for ( ExprNode child : children )
    {
    if ( ( count == 1 ) && ( child instanceof ScopeNode ) )
    {
    // We can stop here
    break;
    }

    annotate( partitionTxn, child );
    count = Math.min( ( ( Long ) child.get( COUNT_ANNOTATION ) 
), count );


    if ( count == 0 )
    {
    // No need to continue   <- Obviously a bad idea 
in this very case...

    break;
    }
    }

In your case,  there is a workaround : changing your filter to be 
"(&(objectClass=*)(cn=testLDAPGroup))"



I'll open a JIRA.


Thanks for the report and the test case !


On 17/03/2020 15:02, Francesco Chicchiriccò wrote:
On 2020/03/15 14:46:27, Francesco Chicchiricc��  
wrote:

On 2020/03/15 14:14:56, Emmanuel Lécharny  wrote:

Hi Francesco,

On 15/03/2020 14:49, Francesco Chicchiriccò wrote:

Hi there,
I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing 
some troubles.

Hmmm, there is no such 2.0.0.

Ah, sorry, I was meaning 2.0.0.AM26 of course.

For example, this used to work fine (e.g.  to find the group with 
the given cn) previously:


ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b 
"ou=groups,o=isp" 
'(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))' 
cn


Now this does not return any result; when I change the filter to

'(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'

it works again.

Also

'(&(objectClass=top)(cn=lastGroup3ae5600a))'

is working fine; so it seems that top is somehow disturbing.

Any ideas? Thanks!

Do you have an env I can use to test that ?

Hi Emmanuel,
sorry it took so long to get something simpler to reproduce the problem.

I have assembled at

https://github.com/ilgrosso/apacheds

Just clone and run

mvn clean verify

The tests executed are

https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L42 



which runs with filter

(&(objectClass=groupOfUniqueNames)(cn=testLDAPGroup))

and finds the group, and

https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L59 



which runs with filter

(&(objectClass=top)(cn=testLDAPGroup))

and does not find the group.

The ApacheDS init is in

https://github.com/ilgrosso/apacheds/blob/master/src/main/java/net/tirasa/sample/apacheds/ApacheDSStart.java#L193 



Thanks for your support.
Regards.


-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-19 Thread Emmanuel Lécharny

Hi Francesco


sorry for the latency...

There is a clear bug in the way we handle a filter like 
(ObjectClass=top) in the search engine. As 'top' is never present in the 
index - for obvious reason : *every* single entry has such an attribute 
value -, the filter returns no candidate, so the encapsulating filter 
evaluation simply stops :


(&(objectClass=top:[0])(cn=testLDAPGroup))  (note the [0] here).


The code that does that is :

    private long getConjunctionScan( PartitionTxn partitionTxn, 
BranchNode node ) throws LdapException

    {
    long count = Long.MAX_VALUE;
    List children = node.getChildren();

    for ( ExprNode child : children )
    {
    if ( ( count == 1 ) && ( child instanceof ScopeNode ) )
    {
    // We can stop here
    break;
    }

    annotate( partitionTxn, child );
    count = Math.min( ( ( Long ) child.get( COUNT_ANNOTATION ) 
), count );


    if ( count == 0 )
    {
    // No need to continue   <- Obviously a bad idea in 
this very case...

    break;
    }
    }

In your case,  there is a workaround : changing your filter to be 
"(&(objectClass=*)(cn=testLDAPGroup))"



I'll open a JIRA.


Thanks for the report and the test case !


On 17/03/2020 15:02, Francesco Chicchiriccò wrote:

On 2020/03/15 14:46:27, Francesco Chicchiricc��  wrote:

On 2020/03/15 14:14:56, Emmanuel Lécharny  wrote:

Hi Francesco,

On 15/03/2020 14:49, Francesco Chicchiriccò wrote:

Hi there,
I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing some 
troubles.

Hmmm, there is no such 2.0.0.

Ah, sorry, I was meaning 2.0.0.AM26 of course.


For example, this used to work fine (e.g.  to find the group with the given cn) 
previously:

ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b "ou=groups,o=isp" 
'(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))' cn

Now this does not return any result; when I change the filter to

'(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'

it works again.

Also

'(&(objectClass=top)(cn=lastGroup3ae5600a))'

is working fine; so it seems that top is somehow disturbing.

Any ideas? Thanks!

Do you have an env I can use to test that ?

Hi Emmanuel,
sorry it took so long to get something simpler to reproduce the problem.

I have assembled at

https://github.com/ilgrosso/apacheds

Just clone and run

mvn clean verify

The tests executed are

https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L42

which runs with filter

(&(objectClass=groupOfUniqueNames)(cn=testLDAPGroup))

and finds the group, and

https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L59

which runs with filter

(&(objectClass=top)(cn=testLDAPGroup))

and does not find the group.

The ApacheDS init is in

https://github.com/ilgrosso/apacheds/blob/master/src/main/java/net/tirasa/sample/apacheds/ApacheDSStart.java#L193

Thanks for your support.
Regards.


-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-17 Thread Emmanuel Lécharny

Hi Francesco,


I was busy anyway... With the blockout we now are under in France (I 
wonder why it took us one more week than in Italy. We are probably 
dumber...), I had to cope with many things in the last coupe of days.



Will give it a try tonite.



-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-17 Thread Francesco Chicchiriccò
On 2020/03/15 14:46:27, Francesco Chicchiricc��  wrote: 
> On 2020/03/15 14:14:56, Emmanuel Lécharny  wrote: 
> > Hi Francesco,
> > 
> > On 15/03/2020 14:49, Francesco Chicchiriccò wrote:
> > > Hi there,
> > > I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing some 
> > > troubles.
> > 
> > Hmmm, there is no such 2.0.0.
> 
> Ah, sorry, I was meaning 2.0.0.AM26 of course.
> 
> > > For example, this used to work fine (e.g.  to find the group with the 
> > > given cn) previously:
> > >
> > > ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b 
> > > "ou=groups,o=isp" 
> > > '(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))'
> > >  cn
> > >
> > > Now this does not return any result; when I change the filter to
> > >
> > > '(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'
> > >
> > > it works again.
> > >
> > > Also
> > >
> > > '(&(objectClass=top)(cn=lastGroup3ae5600a))'
> > >
> > > is working fine; so it seems that top is somehow disturbing.
> > >
> > > Any ideas? Thanks!
> > 
> > Do you have an env I can use to test that ?

Hi Emmanuel,
sorry it took so long to get something simpler to reproduce the problem.

I have assembled at

https://github.com/ilgrosso/apacheds

Just clone and run

mvn clean verify

The tests executed are

https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L42

which runs with filter

(&(objectClass=groupOfUniqueNames)(cn=testLDAPGroup))

and finds the group, and

https://github.com/ilgrosso/apacheds/blob/master/src/test/java/net/tirasa/sample/apacheds/ApacheDSApplicationTests.java#L59

which runs with filter

(&(objectClass=top)(cn=testLDAPGroup))

and does not find the group.

The ApacheDS init is in

https://github.com/ilgrosso/apacheds/blob/master/src/main/java/net/tirasa/sample/apacheds/ApacheDSStart.java#L193

Thanks for your support.
Regards.


-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-15 Thread Francesco Chicchiriccò
On 2020/03/15 14:14:56, Emmanuel Lécharny  wrote: 
> Hi Francesco,
> 
> On 15/03/2020 14:49, Francesco Chicchiriccò wrote:
> > Hi there,
> > I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing some 
> > troubles.
> 
> Hmmm, there is no such 2.0.0.

Ah, sorry, I was meaning 2.0.0.AM26 of course.

> > For example, this used to work fine (e.g.  to find the group with the given 
> > cn) previously:
> >
> > ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b 
> > "ou=groups,o=isp" 
> > '(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))'
> >  cn
> >
> > Now this does not return any result; when I change the filter to
> >
> > '(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'
> >
> > it works again.
> >
> > Also
> >
> > '(&(objectClass=top)(cn=lastGroup3ae5600a))'
> >
> > is working fine; so it seems that top is somehow disturbing.
> >
> > Any ideas? Thanks!
> 
> Do you have an env I can use to test that ?

Repo is https://github.com/ilgrosso/syncope - in the branch 
2_1_X_APACHE_DS_2_0_0_M26

With JAVA_HOME set to JDK 8, do first

mvn -T 1C -PskipTests,all,without-eclipse

then

cd fit/build-tools
mvn -Pdebug

At this point you will see that

ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -w secret -b 
"ou=groups,o=isp" '(&(objectClass=top)(cn=testLDAPGroup))' cn

finds no items while

ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -w secret -b 
"ou=groups,o=isp" '(&(objectClass=groupOfUniqueNames)(cn=testLDAPGroup))' cn

works.

Thanks for you support.
Regards.


-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-15 Thread Emmanuel Lécharny

Hi Francesco,

On 15/03/2020 14:49, Francesco Chicchiriccò wrote:

Hi there,
I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing some 
troubles.


Hmmm, there is no such 2.0.0.




For example, this used to work fine (e.g.  to find the group with the given cn) 
previously:

ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b "ou=groups,o=isp" 
'(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))' cn

Now this does not return any result; when I change the filter to

'(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'

it works again.

Also

'(&(objectClass=top)(cn=lastGroup3ae5600a))'

is working fine; so it seems that top is somehow disturbing.

Any ideas? Thanks!


Do you have an env I can use to test that ?



-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-15 Thread Francesco Chicchiriccò
On 2020/03/15 13:49:27, Francesco Chicchiricc��  wrote: 
[...] 
> Also
> 
> '(&(objectClass=top)(cn=lastGroup3ae5600a))'
> 
> is working fine; so it seems that top is somehow disturbing.

Sorry, I was meaning that the filer above is *not* working.

Regards.


-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Problems upgrading ApacheDS 2.0.0.AM25 -> 2.0.0

2020-03-15 Thread Francesco Chicchiriccò
Hi there,
I am upgrading Apache DS from 2.0.0.AM25 to 2.0.0 and experiencing some 
troubles.

For example, this used to work fine (e.g.  to find the group with the given cn) 
previously:

ldapsearch -h localhost -p 1389 -D "uid=admin,ou=system" -x -W -b 
"ou=groups,o=isp" 
'(&(&(objectClass=top)(objectClass=groupOfUniqueNames))(cn=lastGroup3ae5600a))' 
cn

Now this does not return any result; when I change the filter to

'(&(objectClass=groupOfUniqueNames)(cn=lastGroup3ae5600a))'

it works again.

Also

'(&(objectClass=top)(cn=lastGroup3ae5600a))'

is working fine; so it seems that top is somehow disturbing.

Any ideas? Thanks!


-
To unsubscribe, e-mail: users-unsubscr...@directory.apache.org
For additional commands, e-mail: users-h...@directory.apache.org



Re: Upgrading ApacheDS

2017-02-20 Thread Emmanuel Lécharny


Le 20/02/2017 à 16:20, Mike Davis a écrit :
> We're currently running apacheds-2.0.0-M20 and would like to upgrade to
> apacheds-2.0.0-M23. I'm not finding any specifics on an upgrade versus a
> clean installation. Is there an upgrade process, or do we install the new
> version and migrate data from the old version via LDIF export/import?

Export/import data is the way to go, atm. It's even easier, as the
database format hasn't change since M20, so you ca simply copy/paste the
database files.

Note that we have updated the schema and added some configuration
elements, so be sure to review the config.

-- 
Emmanuel Lecharny

Symas.com
directory.apache.org



Upgrading ApacheDS

2017-02-20 Thread Mike Davis
We're currently running apacheds-2.0.0-M20 and would like to upgrade to
apacheds-2.0.0-M23. I'm not finding any specifics on an upgrade versus a
clean installation. Is there an upgrade process, or do we install the new
version and migrate data from the old version via LDIF export/import?

 

Mike Davis

REZ-1

Software Development Manager

100 William Street | Suite 100

Wellesley, MA 02481

t: 781.263.0200 ext. 529 | e:   mda...@rez1.com

w:   www.rez1.com | f: 339-686-3078

  LinkedIn |
 Twitter