Configuring the LDAP connection pool

The LDAP service provider maintains a pool of connections and assigns them as needed. When a connection is closed, LDAP returns the connection to the pool for future use. This can improve performance significantly.

This page describes the site-wide settings for LDAP connection pooling in Crowd. 

The default implementation for LDAP connection pooling is using JNDI and the pool settings are set via system properties when starting Crowd.

JDK 8 vs. JDK 11

You configure the JDNI LDAP connection pool differently depending on your JDK version.

  • For JDK 8, you must use the system properties. The form in Crowd won't work.
  • For JDK 11, you must use the form in Crowd. The system properties won't work.

Depending on your JDK version, choose the right section below.

Configure the LDAP connection pool with JDK 8

Use these steps if you have JDK 8.

View the current configuration

You can view the current settings for LDAP connection pooling in Crowd.

To view the current configuration:

  1. Log in to the Crowd Administration Console.

  2. In the top navigation bar, select Administration.

  3. In the left-hand menu, select LDAP Connection Pool.

LDAP 接続プールを設定する

JNDI 接続プールを設定するには、次の手順を実行します。

  1. Go to <installation-directory>/bin, and edit the setenv.sh (Linux) or setenv.bat (Windows) file.

  2. 下のテーブルからプロパティを設定します。例:  

    -Dcom.sun.jndi.ldap.connect.pool.initsize=2
    -Dcom.sun.jndi.ldap.connect.pool.prefsize=1
    -Dcom.sun.jndi.ldap.connect.pool.maxsize=20

プール プロパティ

設定

Crowd system property

説明

既定値

初期プール サイズ

com.sun.jndi.ldap.connect.pool.initsize

プールに初めて接続した時に作成される LDAP コネクションの数。

1

推奨プール サイズ

com.sun.jndi.ldap.connect.pool.prefsize

最適なプールのサイズ。コネクションの数がこの値より大きくなると、LDAP はアイドル中のコネクションを削除します。値が 0 (ゼロ) の場合、推奨サイズがないことを意味するため、アイドル中のコネクションの数は制限されません。

10

最大プール サイズ

com.sun.jndi.ldap.connect.pool.maxsize

コネクション (接続) の最大数。コネクションの数がこの値に達すると、LDAP は以降のコネクションを拒否します。結果として、アプリケーションによって作成された LDAP サーバーに対するリクエストはブロックされます。この値が 0 (ゼロ) の場合、コネクション数は制限されません。

0

プール タイムアウト

com.sun.jndi.ldap.connect.pool.timeout

プールから削除される前にコネクションがアイドル状態で滞留できる時間 (秒)。アプリケーションがプールされたコネクションの使用を終えると、コネクションはアイドル状態としてマークされ、再利用を待ちます。この値が 0 (ゼロ) の場合は、アイドル時間が無制限であることを意味し、コネクションはタイムアウトされません。

30000

プール プロトコル

com.sun.jndi.ldap.connect.pool.protocol

これらのプロトコルタイプのみが LDAP に接続できます。複数のプロトコルを許可する場合は、スペース区切りで値を入力します。有効な値は以下のとおりです。

  • plain
  • ssl

plain ssl 
(plain と ssl の両方)

プール認証

com.sun.jndi.ldap.connect.pool.authentication

これらの認証タイプのみが LDAP に接続できます。複数の認証タイプを許可する場合は、スペース区切りで値を入力します。LDAP 認証方式の詳細については、RFC 2829 をご参照ください。有効な値は以下のとおりです。

  • none
  • simple
  • DIGEST-MD5

simple

Configure the LDAP connection pool with JDK 11

Use these steps if you have JDK 11.

View the current configuration

You can view the current settings for LDAP connection pooling in Crowd.

To view the current configuration:

  1. Log in to the Crowd Administration Console.

  2. In the top navigation bar, select Administration.

  3. In the left-hand menu, select LDAP Connection Pool.

LDAP 接続プールを設定する

JNDI 接続プールを設定するには、次の手順を実行します。

  1. Log in to the Crowd Administration Console.

  2. In the top navigation bar, select Administration.

  3. In the left-hand menu, select LDAP Connection Pool.

  4. The LDAP Connection Pool screen appears. Enter the details for each setting, as described in the table below.
  5. 更新を選択します。
  6. Restart Crowd to put the changes into effect.

プール プロパティ

Connection Pool Setting

説明

既定値

初期プール サイズ

プールに初めて接続した時に作成される LDAP コネクションの数。

1

推奨プール サイズ

最適なプールのサイズ。コネクションの数がこの値より大きくなると、LDAP はアイドル中のコネクションを削除します。値が 0 (ゼロ) の場合、推奨サイズがないことを意味するため、アイドル中のコネクションの数は制限されません。

10

最大プール サイズ

The maximum number of connections. When the number of connections reaches this value, LDAP will refuse further connections. As a result, requests made by an application to the LDAP server will be blocked. A value of 0 (zero) means that the number of connections is unlimited.

0

Pool Timeout

プールから削除される前にコネクションがアイドル状態で滞留できる時間 (秒)。アプリケーションがプールされたコネクションの使用を終えると、コネクションはアイドル状態としてマークされ、再利用を待ちます。この値が 0 (ゼロ) の場合、アイドル時間が無制限であることを意味し、コネクションはタイムアウトされません。

30

プール プロトコル

これらのプロトコルタイプのみが LDAP に接続できます。複数のプロトコルを許可する場合は、スペース区切りで値を入力します。有効な値は以下のとおりです。

  • plain
  • ssl

plain ssl
(plain と ssl の両方)

プール認証

これらの認証タイプのみが LDAP に接続できます。複数の認証タイプを許可する場合は、スペース区切りで値を入力します。LDAP 認証方式の詳細については、RFC 2829 をご参照ください。有効な値は以下のとおりです。

  • none
  • simple
  • DIGEST-MD5

simple

最終更新日: 2022 年 10 月 20 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.