Hostname is now no longer available until after the server is running.

This commit is contained in:
Technosophos 2012-07-05 15:24:28 -05:00
parent c50b708880
commit 63d23df388
2 changed files with 10 additions and 4 deletions

View File

@ -58,6 +58,10 @@ class InstanceDetails {
$o->password = $json['credential']['password'];
}
if (!empty($json['name'])) {
$o->name = $json['name'];
}
return $o;
}
@ -138,8 +142,8 @@ class InstanceDetails {
* is returned.
*
* @attention
* In version 1.0 of the DBaaS protocol, this is ONLY available immediately
* after creation or from the results of an Instance::describe() call.
* In version 1.0 of the DBaaS protocol, this is ONLY available after the
* DB instance has been brought all the way up.
*
* This returns the DNS name of the host (or possibly an IP address).
*

View File

@ -68,7 +68,8 @@ class DBaaSInstanceTest extends DBaaSTestCase {
$this->assertNotEmpty($details->username());
$this->assertNotEmpty($details->password());
$this->assertNotEmpty($details->id());
$this->assertNotEmpty($details->hostname());
// This is now no longer returned from a create().
//$this->assertNotEmpty($details->hostname());
$this->assertNotEmpty($details->createdOn());
$this->assertEquals($dbName, $details->name());
@ -101,7 +102,8 @@ class DBaaSInstanceTest extends DBaaSTestCase {
$this->assertEmpty($details->username());
$this->assertEmpty($details->password());
$this->assertNotEmpty($details->hostname());
// This is no longer available until after the server is up.
//$this->assertNotEmpty($details->hostname());
$this->assertNotEmpty($details->createdOn());
$this->assertEquals($db->id(), $details->id());