Return-Path: X-Original-To: apmail-directory-dev-archive@www.apache.org Delivered-To: apmail-directory-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AC6BF175C7 for ; Tue, 5 May 2015 17:40:01 +0000 (UTC) Received: (qmail 37555 invoked by uid 500); 5 May 2015 17:40:01 -0000 Delivered-To: apmail-directory-dev-archive@directory.apache.org Received: (qmail 37430 invoked by uid 500); 5 May 2015 17:40:01 -0000 Mailing-List: contact dev-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Apache Directory Developers List" Delivered-To: mailing list dev@directory.apache.org Received: (qmail 37342 invoked by uid 99); 5 May 2015 17:40:01 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 May 2015 17:40:01 +0000 Date: Tue, 5 May 2015 17:40:01 +0000 (UTC) From: "Stefan Seelmann (JIRA)" To: dev@directory.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (DIRAPI-239) Client API exposes implementation classes of common-pools MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DIRAPI-239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14528864#comment-14528864 ] Stefan Seelmann commented on DIRAPI-239: ---------------------------------------- We can consider to change that. However do you have a concrete broblem where this breaks your OSGi deployment? commons-pool 1.6 exports the org.apache.commons.pool.impl package. I was able create an LdapConnectionPool with such an GenericObjectPool.Config object in two environments: 1. in the API OSGi test suite that users PAX+Felix, see http://svn.apache.org/r1677869 2. Within Studio that uses Eclipse Equinox > Client API exposes implementation classes of common-pools > --------------------------------------------------------- > > Key: DIRAPI-239 > URL: https://issues.apache.org/jira/browse/DIRAPI-239 > Project: Directory Client API > Issue Type: Bug > Affects Versions: 1.0.0-M30 > Reporter: Federico Marmori > > The constructors: > LdapConnectionPool(LdapConnectionConfig connectionConfig, LdapApiService apiService, long timeout, org.apache.commons.pool.impl.GenericObjectPool.Config poolConfig) > and > LdapConnectionPool(org.apache.commons.pool.PoolableObjectFactory factory, org.apache.commons.pool.impl.GenericObjectPool.Config poolConfig) > ...allows the user to provide its own pool configuration. > However, using the Config object is really a bad idea. This forces the user code to depend on an implementation class of the commons-pool library, which will break any OSGI deployment and force the user to implement tedious workarounds. Probably common-pools could solve the issue by exposing the Config object in the API, however the DIRAPI can fix the issue by making sure that the LdapConnectionPool either: > - expose all pool configuration attributes in a constructor instead of the GenericObjectPool.Config > - provide its own LdapPoolConfiguration bean object instead of using the GenericObjectPool.Config > - provide an LdapConnectionPoolFactory instead -- This message was sent by Atlassian JIRA (v6.3.4#6332)