|
| | __construct (array $params) |
| | You probably want to use newFromConnection instead.
|
| |
| | __destruct () |
| |
| | approvePrimaryChanges (array $options, $fname=__METHOD__) |
| | Perform all pre-commit checks for things like replication safety.
|
| |
| | beginPrimaryChanges ( $fname=__METHOD__) |
| | Flush any primary transaction snapshots and set DBO_TRX (if DBO_DEFAULT is set)
|
| |
| | closeAll ( $fname=__METHOD__) |
| | Close all open connections.
|
| |
| | closeConnection (IDatabase $conn) |
| | Close a connection.
|
| |
| | commitAll ( $fname=__METHOD__) |
| | Commit transactions on all open connections.
|
| |
| | commitPrimaryChanges ( $fname=__METHOD__) |
| | Issue COMMIT on all open primary connections to flush changes and view snapshots.
|
| |
| | disable ( $fname=__METHOD__) |
| | Close all connections and disable this load balancer.
|
| |
| | explicitTrxActive () |
| | Determine whether an explicit transaction is active on any open primary connection.
|
| |
| | finalizePrimaryChanges ( $fname=__METHOD__) |
| | Run pre-commit callbacks and defer execution of post-commit callbacks.
|
| |
| | flushPrimarySessions ( $fname=__METHOD__) |
| | Release/destroy session-level named locks, table locks, and temp tables.
|
| |
| | flushPrimarySnapshots ( $fname=__METHOD__) |
| | Commit all primary DB transactions so as to flush any REPEATABLE-READ or SSI snapshots.
|
| |
| | flushReplicaSnapshots ( $fname=__METHOD__) |
| | Commit all replica DB transactions so as to flush any REPEATABLE-READ or SSI snapshots.
|
| |
| | forEachOpenConnection ( $callback, array $params=[]) |
| | Call a function with each open connection object.
|
| |
| | forEachOpenPrimaryConnection ( $callback, array $params=[]) |
| | Call a function with each open connection object to a primary.
|
| |
| | getAnyOpenConnection ( $i, $flags=0) |
| | Get an existing DB handle to the given server index (on any domain)
|
| |
| | getClusterName () |
| | Get the logical name of the database cluster.
|
| |
| | getConnection ( $i, $groups=[], $domain=false, $flags=0) |
| | Get a lazy-connecting database handle for a specific or virtual (DB_PRIMARY/DB_REPLICA) server index.
|
| |
| | getConnectionInternal ( $i, $groups=[], $domain=false, $flags=0) |
| |
| | getConnectionRef ( $i, $groups=[], $domain=false, $flags=0) |
| |
| | getLaggedReplicaMode ( $domain=false) |
| |
| | getLagTimes ( $domain=false) |
| | Get an estimate of replication lag (in seconds) for each server.
|
| |
| | getLazyConnectionRef ( $i, $groups=[], $domain=false, $flags=0) |
| | Get a lazy-connecting database handle for a server index.
|
| |
| | getLocalDomainID () |
| | Get the local (and default) database domain ID of connection handles.
|
| |
| | getMaintenanceConnectionRef ( $i, $groups=[], $domain=false, $flags=0) |
| | Get a DB handle, suitable for migrations and schema changes, for a server index.
|
| |
| | getMaxLag ( $domain=false) |
| | Get the name and lag time of the most-lagged replica server.
|
| |
| | getPrimaryPos () |
| | Get the current primary replication position.
|
| |
| | getReaderIndex ( $group=false, $domain=false) |
| | Get the specific server index of the reader connection for a given group.
|
| |
| | getReadOnlyReason ( $domain=false) |
| |
| | getReplicaResumePos () |
| | Get the highest DB replication position for chronology control purposes.
|
| |
| | getServerAttributes ( $i) |
| | Get basic attributes of the server with the specified index without connecting.
|
| |
| | getServerConnection ( $i, $domain, $flags=0) |
| | Get a DB handle for a specific server index.
|
| |
| | getServerCount () |
| | Get the number of servers defined in configuration.
|
| |
| | getServerInfo ( $i) |
| | Return the server configuration map for the server with the specified index.
|
| |
| | getServerName ( $i) |
| | Get the readable name of the server with the specified index.
|
| |
| | getServerType ( $i) |
| | Get the RDBMS type of the server with the specified index (e.g.
|
| |
| | getTransactionRoundStage () |
| |
| | getWriterIndex () |
| | Get the specific server index of the primary server.
|
| |
| | hasOrMadeRecentPrimaryChanges ( $age=null) |
| | Check if this load balancer object had any recent or still pending writes issued against it by this PHP thread.
|
| |
| | hasPrimaryChanges () |
| | Whether there are pending changes or callbacks in a transaction by this thread.
|
| |
| | hasPrimaryConnection () |
| |
| | hasReplicaServers () |
| | Whether there are any replica servers configured.
|
| |
| | hasStreamingReplicaServers () |
| | Whether any replica servers use streaming replication from the primary server.
|
| |
| | haveIndex ( $i) |
| | Returns true if the specified index is a valid server index.
|
| |
| | isNonZeroLoad ( $i) |
| | Returns true if the specified index is valid and has non-zero load.
|
| |
| | laggedReplicaUsed () |
| | Checks whether the database for generic connections this request was both:
|
| |
| | lastPrimaryChangeTimestamp () |
| | Get the timestamp of the latest write query done by this thread.
|
| |
| | pendingPrimaryChangeCallers () |
| | Get the list of callers that have pending primary changes.
|
| |
| | pingAll () |
| |
| | reconfigure (array $params) |
| | Apply updated configuration.
|
| |
| | redefineLocalDomain ( $domain) |
| | Close all connection and redefine the local domain for testing or schema creation.
|
| |
| | resolveDomainID ( $domain) |
| |
| | reuseConnection (IDatabase $conn) |
| |
| | reuseConnectionInternal (IDatabase $conn) |
| |
| | rollbackPrimaryChanges ( $fname=__METHOD__) |
| | Issue ROLLBACK only on primary, only if queries were done on connection.
|
| |
| | runPrimaryTransactionIdleCallbacks ( $fname=__METHOD__) |
| | Consume and run all pending post-COMMIT/ROLLBACK callbacks and commit dangling transactions.
|
| |
| | runPrimaryTransactionListenerCallbacks ( $fname=__METHOD__) |
| | Run all recurring post-COMMIT/ROLLBACK listener callbacks.
|
| |
| | setDomainAliases (array $aliases) |
| | Convert certain database domains to alternative ones.
|
| |
| | setIndexAliases (array $aliases) |
| | Convert certain index names to alternative names before querying the DB.
|
| |
| | setLocalDomainPrefix ( $prefix) |
| | Set a new table prefix for the existing local domain ID for testing.
|
| |
| | setTableAliases (array $aliases) |
| | Make certain table names use their own database, schema, and table prefix when passed into SQL queries pre-escaped and without a qualified database name.
|
| |
| | setTempTablesOnlyMode ( $value, $domain) |
| | Indicate whether the tables on this domain are only temporary tables for testing.
|
| |
| | setTransactionListener ( $name, callable $callback=null) |
| | Set a callback via IDatabase::setTransactionListener() on all current and future primary connections of this load balancer.
|
| |
| | waitFor ( $pos) |
| | Set the primary position to reach before the next generic group DB query.
|
| |
| | waitForAll ( $pos, $timeout=null) |
| | Set the primary wait position and wait for ALL replica DBs to catch up to it.
|
| |
| | waitForPrimaryPos (IDatabase $conn, $pos=false, $timeout=null) |
| | Wait for a replica DB to reach a specified primary position.
|
| |
Trivial LoadBalancer that always returns an injected connection handle.
Definition at line 29 of file LoadBalancerSingle.php.