From: Graham B. <gb...@po...> - 2001-06-16 06:02:08
|
Yes your loop does seem right, but there are no docs for async mode because it is not really complete. But async mode will not get you any more information from the server, I don't know why you think it will. The code below is *exactly* what Net::LDAP will do in normal mode. Graham. On Sat, Jun 16, 2001 at 07:05:44AM +0200, eric German wrote: > Hi , I want to make request with async mode : my code is now like this: > > #!/usr/bin/perl -w > use Net::LDAP; > my $ldap = Net::LDAP->new('10.75.6.34', > version =>3, > async =>1,); > my $code = $ldap->bind(dn => > 'uid=michel.xxxxx-cp,ou=personnes,ou=dgcp,ou=mefi,o=gouv,c=fr' , > password =>'0' , > ); > $selector =IO::Select->new($ldap->socket); > while ($selector ->can_read($timeout)) { > $ldap->_recvresp(); > last if ($code->done()); > } > print "stop" ; > > the goal of the job is to fetch the supply info send by Directory Server at > the time of binding . A code whi tell : your password will expire in n days > etc.. > > first , is my loop seem correct for async operation ? > where can find some doc or exemple about async op with net::ldap > thank a lot > eric german > france > > > > |