directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "lucas theisen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DIRAPI-200) unBind() followed by bind() on the same connection may throw an IllegalStateException
Date Fri, 07 Nov 2014 23:26:34 GMT

    [ https://issues.apache.org/jira/browse/DIRAPI-200?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14202928#comment-14202928
] 

lucas theisen commented on DIRAPI-200:
--------------------------------------

I think all of my errors must have been some {{NFS}} wonkiness.  Good news though, the unit
test on my little linux server completed ALL 30,000 iterations of rebind without failure:

{code}
[ltheisen ldap-client-test]$ mvn -Dtest=LdapConnectionPoolTest#testRebindNoPool test
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Apache Directory LDAP Client API test 2.0.0-M18-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-remote-resources-plugin:1.2.1:process (default) @ ldap-client-test ---
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ ldap-client-test ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 0 resource
[INFO] Copying 3 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ ldap-client-test ---
[INFO] Nothing to compile - all classes are up to date
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ ldap-client-test
---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] Copying 3 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ ldap-client-test
---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 23 source files to /home/ltheisen/svn/ads-trunk-with-dependencies/apacheds/ldap-client-test/target/test-classes
[INFO]
[INFO] --- maven-surefire-plugin:2.17:test (default-test) @ ldap-client-test ---
[INFO] Surefire report directory: /home/ltheisen/svn/ads-trunk-with-dependencies/apacheds/ldap-client-test/target/surefire-reports

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.apache.directory.shared.client.api.LdapConnectionPoolTest
Iteration # 0
Iteration # 100
Iteration # 200
Iteration # 300
Iteration # 400
Iteration # 500
Iteration # 600
Iteration # 700
Iteration # 800
Iteration # 900
Iteration # 1000
Iteration # 1100
Iteration # 1200
Iteration # 1300
Iteration # 1400
Iteration # 1500
Iteration # 1600
Iteration # 1700
Iteration # 1800
Iteration # 1900
Iteration # 2000
Iteration # 2100
Iteration # 2200
Iteration # 2300
Iteration # 2400
Iteration # 2500
Iteration # 2600
Iteration # 2700
Iteration # 2800
Iteration # 2900
Iteration # 3000
Iteration # 3100
Iteration # 3200
Iteration # 3300
Iteration # 3400
Iteration # 3500
Iteration # 3600
Iteration # 3700
Iteration # 3800
Iteration # 3900
Iteration # 4000
Iteration # 4100
Iteration # 4200
Iteration # 4300
Iteration # 4400
Iteration # 4500
Iteration # 4600
Iteration # 4700
Iteration # 4800
Iteration # 4900
Iteration # 5000
Iteration # 5100
Iteration # 5200
Iteration # 5300
Iteration # 5400
Iteration # 5500
Iteration # 5600
Iteration # 5700
Iteration # 5800
Iteration # 5900
Iteration # 6000
Iteration # 6100
Iteration # 6200
Iteration # 6300
Iteration # 6400
Iteration # 6500
Iteration # 6600
Iteration # 6700
Iteration # 6800
Iteration # 6900
Iteration # 7000
Iteration # 7100
Iteration # 7200
Iteration # 7300
Iteration # 7400
Iteration # 7500
Iteration # 7600
Iteration # 7700
Iteration # 7800
Iteration # 7900
Iteration # 8000
Iteration # 8100
Iteration # 8200
Iteration # 8300
Iteration # 8400
Iteration # 8500
Iteration # 8600
Iteration # 8700
Iteration # 8800
Iteration # 8900
Iteration # 9000
Iteration # 9100
Iteration # 9200
Iteration # 9300
Iteration # 9400
Iteration # 9500
Iteration # 9600
Iteration # 9700
Iteration # 9800
Iteration # 9900
Iteration # 10000
Iteration # 10100
Iteration # 10200
Iteration # 10300
Iteration # 10400
Iteration # 10500
Iteration # 10600
Iteration # 10700
Iteration # 10800
Iteration # 10900
Iteration # 11000
Iteration # 11100
Iteration # 11200
Iteration # 11300
Iteration # 11400
Iteration # 11500
Iteration # 11600
Iteration # 11700
Iteration # 11800
Iteration # 11900
Iteration # 12000
Iteration # 12100
Iteration # 12200
Iteration # 12300
Iteration # 12400
Iteration # 12500
Iteration # 12600
Iteration # 12700
Iteration # 12800
Iteration # 12900
Iteration # 13000
Iteration # 13100
Iteration # 13200
Iteration # 13300
Iteration # 13400
Iteration # 13500
Iteration # 13600
Iteration # 13700
Iteration # 13800
Iteration # 13900
Iteration # 14000
Iteration # 14100
Iteration # 14200
Iteration # 14300
Iteration # 14400
Iteration # 14500
Iteration # 14600
Iteration # 14700
Iteration # 14800
Iteration # 14900
Iteration # 15000
Iteration # 15100
Iteration # 15200
Iteration # 15300
Iteration # 15400
Iteration # 15500
Iteration # 15600
Iteration # 15700
Iteration # 15800
Iteration # 15900
Iteration # 16000
Iteration # 16100
Iteration # 16200
Iteration # 16300
Iteration # 16400
Iteration # 16500
Iteration # 16600
Iteration # 16700
Iteration # 16800
Iteration # 16900
Iteration # 17000
Iteration # 17100
Iteration # 17200
Iteration # 17300
Iteration # 17400
Iteration # 17500
Iteration # 17600
Iteration # 17700
Iteration # 17800
Iteration # 17900
Iteration # 18000
Iteration # 18100
Iteration # 18200
Iteration # 18300
Iteration # 18400
Iteration # 18500
Iteration # 18600
Iteration # 18700
Iteration # 18800
Iteration # 18900
Iteration # 19000
Iteration # 19100
Iteration # 19200
Iteration # 19300
Iteration # 19400
Iteration # 19500
Iteration # 19600
Iteration # 19700
Iteration # 19800
Iteration # 19900
Iteration # 20000
Iteration # 20100
Iteration # 20200
Iteration # 20300
Iteration # 20400
Iteration # 20500
Iteration # 20600
Iteration # 20700
Iteration # 20800
Iteration # 20900
Iteration # 21000
Iteration # 21100
Iteration # 21200
Iteration # 21300
Iteration # 21400
Iteration # 21500
Iteration # 21600
Iteration # 21700
Iteration # 21800
Iteration # 21900
Iteration # 22000
Iteration # 22100
Iteration # 22200
Iteration # 22300
Iteration # 22400
Iteration # 22500
Iteration # 22600
Iteration # 22700
Iteration # 22800
Iteration # 22900
Iteration # 23000
Iteration # 23100
Iteration # 23200
Iteration # 23300
Iteration # 23400
Iteration # 23500
Iteration # 23600
Iteration # 23700
Iteration # 23800
Iteration # 23900
Iteration # 24000
Iteration # 24100
Iteration # 24200
Iteration # 24300
Iteration # 24400
Iteration # 24500
Iteration # 24600
Iteration # 24700
Iteration # 24800
Iteration # 24900
Iteration # 25000
Iteration # 25100
Iteration # 25200
Iteration # 25300
Iteration # 25400
Iteration # 25500
Iteration # 25600
Iteration # 25700
Iteration # 25800
Iteration # 25900
Iteration # 26000
Iteration # 26100
Iteration # 26200
Iteration # 26300
Iteration # 26400
Iteration # 26500
Iteration # 26600
Iteration # 26700
Iteration # 26800
Iteration # 26900
Iteration # 27000
Iteration # 27100
Iteration # 27200
Iteration # 27300
Iteration # 27400
Iteration # 27500
Iteration # 27600
Iteration # 27700
Iteration # 27800
Iteration # 27900
Iteration # 28000
Iteration # 28100
Iteration # 28200
Iteration # 28300
Iteration # 28400
Iteration # 28500
Iteration # 28600
Iteration # 28700
Iteration # 28800
Iteration # 28900
Iteration # 29000
Iteration # 29100
Iteration # 29200
Iteration # 29300
Iteration # 29400
Iteration # 29500
Iteration # 29600
Iteration # 29700
Iteration # 29800
Iteration # 29900
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 123.448 sec - in org.apache.directory.shared.client.api.LdapConnectionPoolTest

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 02:40 min
[INFO] Finished at: 2014-11-07T18:24:32-05:00
[INFO] Final Memory: 27M/355M
[INFO] ------------------------------------------------------------------------
{code}

> unBind() followed by bind() on the same connection may throw an IllegalStateException
> -------------------------------------------------------------------------------------
>
>                 Key: DIRAPI-200
>                 URL: https://issues.apache.org/jira/browse/DIRAPI-200
>             Project: Directory Client API
>          Issue Type: Bug
>    Affects Versions: 1.0.0-M23
>            Reporter: lucas theisen
>
> Not sure if this even should be allowed but the fact that it can result in an exception
is disconcerting.  I added a test case to {{LdapConnectionPoolTest}} (with the {{unBind()}}
currently commented out) that can be used to reproduce this issue.
> The main question here, in my mind, is whether or not this should be allowed.  If not
allowed, we should immediately throw a more reasonable exception if any operation is attempted
on an {{LdapConnection}} that has had {{unBind()}} called on it.  Perhaps still an {{IllegalStateException}},
but maybe with a message stating _connection no longer valid after unBind()_.  More importantly,
this should happen every time, rather than just when the race condition bears its ugly face.
 For more discussion, see [this email chain|http://mail-archives.apache.org/mod_mbox/directory-dev/201407.mbox/%3CEE6ADC61AF2D71408E4FA7F9517DB7710A9C07E5%40IMCMBX03.MITRE.ORG%3E].



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

Mime
View raw message