TinyInflux::__construct
Creates new TinyInflux instance
Signature
public function __construct([string
$host = '127.0.0.1',
[integer
$port = 8086,
[string
$database = '',
[string
$user = '',
[string
$password = '',
[string
$precision = 'ns',
[integer
$version = 1]]]]]]] )
Parameters
$host
—
string
- - InfluxDB host name or IP address
$port
—
integer
- - InfluxDB port
$database
—
string
- - InfluxDB database name
$user
—
string
- - InfluxDB user name - optional, if not provided, no authentication will be used
$password
—
string
- - InfluxDB user password - optional, if not provided, no authentication will be used
$precision
—
string
- - InfluxDB timestamp precision: ns, us, ms, s, m, h
$version
—
integer
- - InfluxDB version: 1 or 2