masato-hi
masato-hi
EN) Fixed to disconnect all connection_handlers in ActiveRecord 6 and later versions. JA) ActiveRecord 6では `ActiveRecord::Base#clear_all_connections!` 及び `ActiveRecord::Base#clear_active_connections!` は `ActiveRecord::Base#default_connection_handler` に処理が移譲されるため、 単一のデータベース接続を扱う場合は正常に動作しますが、複数のデータベース接続を扱う場合はdefault_connection_handler以外のconnection_handlerの接続が切れません。 (多くの場合default_connection_handlerはPrimaryデータベース, それ以外のconnection_handlerはReplicaデータベースへ接続されています) `ActiveRecord::Base#connection_handlers` はActiveRecord 6で追加されたため、バージョン6以降とそれ以前で処理を分岐し、複数のデータベース接続においてもコネクションを切断出来るよう修正しました。
`PATH_WITHOUT_PHPBREW` will be only remove`$PHPBREW_ROOT/php` from `$PATH`. For example, Install phpbrew to `$HOME/.phpbrew/bin/phpbrew`. Will not be able to find phpbrew after running `__phpbrew_set_path`. I think appropriate to remove `$PHPBREW_ROOT/php`. Because...