Home/
Manual/
monitoring / commandstartedevent/ MongoDB\Driver\Monitoring\CommandStartedEvent::getHost
MongoDB\Driver\Monitoring\CommandStartedEvent::getHost
PHP function
Edit on GitHub ✎
(mongodb >=1.20.0)
Returns the server hostname for the command
Description
MongoDB\Driver\Monitoring\CommandStartedEvent::getHost(): string
Parameters Parameters
Return Values
Returns the hostname of the server on which the command was executed.