Skip to content

Commit 67cfa38

Browse files
1 parent 060f581 commit 67cfa38

7 files changed

Lines changed: 300 additions & 24 deletions

src/CloudRedis.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,16 @@ public function __construct($clientOrConfig = [], $rootUrl = null)
7979
'required' => true,
8080
],
8181
],
82+
],'getSharedRegionalCertificateAuthority' => [
83+
'path' => 'v1/{+name}',
84+
'httpMethod' => 'GET',
85+
'parameters' => [
86+
'name' => [
87+
'location' => 'path',
88+
'type' => 'string',
89+
'required' => true,
90+
],
91+
],
8292
],'list' => [
8393
'path' => 'v1/{+name}/locations',
8494
'httpMethod' => 'GET',

src/CloudRedis/Cluster.php

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,22 @@ class Cluster extends \Google\Collection
5151
* Redis standard small node_type.
5252
*/
5353
public const NODE_TYPE_REDIS_STANDARD_SMALL = 'REDIS_STANDARD_SMALL';
54+
/**
55+
* Server CA mode not specified.
56+
*/
57+
public const SERVER_CA_MODE_SERVER_CA_MODE_UNSPECIFIED = 'SERVER_CA_MODE_UNSPECIFIED';
58+
/**
59+
* Each cluster has its own Google managed CA.
60+
*/
61+
public const SERVER_CA_MODE_SERVER_CA_MODE_GOOGLE_MANAGED_PER_INSTANCE_CA = 'SERVER_CA_MODE_GOOGLE_MANAGED_PER_INSTANCE_CA';
62+
/**
63+
* The cluster uses Google managed shared CA in the region.
64+
*/
65+
public const SERVER_CA_MODE_SERVER_CA_MODE_GOOGLE_MANAGED_SHARED_CA = 'SERVER_CA_MODE_GOOGLE_MANAGED_SHARED_CA';
66+
/**
67+
* The cluster uses customer managed CA from CAS.
68+
*/
69+
public const SERVER_CA_MODE_SERVER_CA_MODE_CUSTOMER_MANAGED_CAS_CA = 'SERVER_CA_MODE_CUSTOMER_MANAGED_CAS_CA';
5470
/**
5571
* Not set.
5672
*/
@@ -228,6 +244,12 @@ class Cluster extends \Google\Collection
228244
* @var int
229245
*/
230246
public $replicaCount;
247+
/**
248+
* Optional. Input only. Rotate the server certificates.
249+
*
250+
* @var bool
251+
*/
252+
public $rotateServerCertificate;
231253
/**
232254
* Optional. Output only. Reserved for future use.
233255
*
@@ -240,6 +262,20 @@ class Cluster extends \Google\Collection
240262
* @var bool
241263
*/
242264
public $satisfiesPzs;
265+
/**
266+
* Optional. Server CA mode for the cluster.
267+
*
268+
* @var string
269+
*/
270+
public $serverCaMode;
271+
/**
272+
* Optional. Customer-managed CA pool for the cluster. Only applicable for
273+
* BYOCA i.e. if server_ca_mode is SERVER_CA_MODE_CUSTOMER_MANAGED_CAS_CA.
274+
* Format: "projects/{project}/locations/{region}/caPools/{ca_pool}".
275+
*
276+
* @var string
277+
*/
278+
public $serverCaPool;
243279
/**
244280
* Optional. Number of shards for the Redis cluster.
245281
*
@@ -787,6 +823,22 @@ public function getReplicaCount()
787823
{
788824
return $this->replicaCount;
789825
}
826+
/**
827+
* Optional. Input only. Rotate the server certificates.
828+
*
829+
* @param bool $rotateServerCertificate
830+
*/
831+
public function setRotateServerCertificate($rotateServerCertificate)
832+
{
833+
$this->rotateServerCertificate = $rotateServerCertificate;
834+
}
835+
/**
836+
* @return bool
837+
*/
838+
public function getRotateServerCertificate()
839+
{
840+
return $this->rotateServerCertificate;
841+
}
790842
/**
791843
* Optional. Output only. Reserved for future use.
792844
*
@@ -819,6 +871,45 @@ public function getSatisfiesPzs()
819871
{
820872
return $this->satisfiesPzs;
821873
}
874+
/**
875+
* Optional. Server CA mode for the cluster.
876+
*
877+
* Accepted values: SERVER_CA_MODE_UNSPECIFIED,
878+
* SERVER_CA_MODE_GOOGLE_MANAGED_PER_INSTANCE_CA,
879+
* SERVER_CA_MODE_GOOGLE_MANAGED_SHARED_CA,
880+
* SERVER_CA_MODE_CUSTOMER_MANAGED_CAS_CA
881+
*
882+
* @param self::SERVER_CA_MODE_* $serverCaMode
883+
*/
884+
public function setServerCaMode($serverCaMode)
885+
{
886+
$this->serverCaMode = $serverCaMode;
887+
}
888+
/**
889+
* @return self::SERVER_CA_MODE_*
890+
*/
891+
public function getServerCaMode()
892+
{
893+
return $this->serverCaMode;
894+
}
895+
/**
896+
* Optional. Customer-managed CA pool for the cluster. Only applicable for
897+
* BYOCA i.e. if server_ca_mode is SERVER_CA_MODE_CUSTOMER_MANAGED_CAS_CA.
898+
* Format: "projects/{project}/locations/{region}/caPools/{ca_pool}".
899+
*
900+
* @param string $serverCaPool
901+
*/
902+
public function setServerCaPool($serverCaPool)
903+
{
904+
$this->serverCaPool = $serverCaPool;
905+
}
906+
/**
907+
* @return string
908+
*/
909+
public function getServerCaPool()
910+
{
911+
return $this->serverCaPool;
912+
}
822913
/**
823914
* Optional. Number of shards for the Redis cluster.
824915
*
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\CloudRedis;
19+
20+
class RegionalCertChain extends \Google\Collection
21+
{
22+
protected $collection_key = 'certificates';
23+
/**
24+
* The certificates that form the CA chain, from leaf to root order.
25+
*
26+
* @var string[]
27+
*/
28+
public $certificates;
29+
30+
/**
31+
* The certificates that form the CA chain, from leaf to root order.
32+
*
33+
* @param string[] $certificates
34+
*/
35+
public function setCertificates($certificates)
36+
{
37+
$this->certificates = $certificates;
38+
}
39+
/**
40+
* @return string[]
41+
*/
42+
public function getCertificates()
43+
{
44+
return $this->certificates;
45+
}
46+
}
47+
48+
// Adding a class alias for backwards compatibility with the previous class name.
49+
class_alias(RegionalCertChain::class, 'Google_Service_CloudRedis_RegionalCertChain');
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\CloudRedis;
19+
20+
class RegionalManagedCertificateAuthority extends \Google\Collection
21+
{
22+
protected $collection_key = 'caCerts';
23+
protected $caCertsType = RegionalCertChain::class;
24+
protected $caCertsDataType = 'array';
25+
26+
/**
27+
* The PEM encoded CA certificate chains for redis managed server
28+
* authentication
29+
*
30+
* @param RegionalCertChain[] $caCerts
31+
*/
32+
public function setCaCerts($caCerts)
33+
{
34+
$this->caCerts = $caCerts;
35+
}
36+
/**
37+
* @return RegionalCertChain[]
38+
*/
39+
public function getCaCerts()
40+
{
41+
return $this->caCerts;
42+
}
43+
}
44+
45+
// Adding a class alias for backwards compatibility with the previous class name.
46+
class_alias(RegionalManagedCertificateAuthority::class, 'Google_Service_CloudRedis_RegionalManagedCertificateAuthority');

src/CloudRedis/Resource/ProjectsLocations.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919

2020
use Google\Service\CloudRedis\ListLocationsResponse;
2121
use Google\Service\CloudRedis\Location;
22+
use Google\Service\CloudRedis\SharedRegionalCertificateAuthority;
2223

2324
/**
2425
* The "locations" collection of methods.
@@ -44,6 +45,23 @@ public function get($name, $optParams = [])
4445
$params = array_merge($params, $optParams);
4546
return $this->call('get', [$params], Location::class);
4647
}
48+
/**
49+
* Gets the details of regional certificate authority information for Redis
50+
* cluster. (locations.getSharedRegionalCertificateAuthority)
51+
*
52+
* @param string $name Required. Regional certificate authority resource name
53+
* using the form: `projects/{project_id}/locations/{location_id}/sharedRegional
54+
* CertificateAuthority` where `location_id` refers to a Google Cloud region.
55+
* @param array $optParams Optional parameters.
56+
* @return SharedRegionalCertificateAuthority
57+
* @throws \Google\Service\Exception
58+
*/
59+
public function getSharedRegionalCertificateAuthority($name, $optParams = [])
60+
{
61+
$params = ['name' => $name];
62+
$params = array_merge($params, $optParams);
63+
return $this->call('getSharedRegionalCertificateAuthority', [$params], SharedRegionalCertificateAuthority::class);
64+
}
4765
/**
4866
* Lists information about the supported locations for this service. This method
4967
* can be called in two ways: * **List all public locations:** Use the path `GET

src/CloudRedis/ResourceMaintenanceInfo.php

Lines changed: 16 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ class ResourceMaintenanceInfo extends \Google\Collection
4848
*/
4949
public const MAINTENANCE_STATE_ERROR = 'ERROR';
5050
protected $collection_key = 'denyMaintenanceSchedules';
51+
protected $currentVersionReleaseDateType = Date::class;
52+
protected $currentVersionReleaseDateDataType = '';
5153
protected $denyMaintenanceSchedulesType = ResourceMaintenanceDenySchedule::class;
5254
protected $denyMaintenanceSchedulesDataType = 'array';
5355
/**
@@ -75,15 +77,23 @@ class ResourceMaintenanceInfo extends \Google\Collection
7577
public $maintenanceVersion;
7678
protected $upcomingMaintenanceType = UpcomingMaintenance::class;
7779
protected $upcomingMaintenanceDataType = '';
80+
7881
/**
79-
* Optional. This field will contain the date when the last version update was
80-
* applied to the database resource. This will be used to calculate the age of
81-
* the maintenance version.
82+
* Optional. The date when the current maintenance version was released.
8283
*
83-
* @var string
84+
* @param Date $currentVersionReleaseDate
8485
*/
85-
public $versionUpdateTime;
86-
86+
public function setCurrentVersionReleaseDate(Date $currentVersionReleaseDate)
87+
{
88+
$this->currentVersionReleaseDate = $currentVersionReleaseDate;
89+
}
90+
/**
91+
* @return Date
92+
*/
93+
public function getCurrentVersionReleaseDate()
94+
{
95+
return $this->currentVersionReleaseDate;
96+
}
8797
/**
8898
* Optional. List of Deny maintenance period for the database resource.
8999
*
@@ -187,24 +197,6 @@ public function getUpcomingMaintenance()
187197
{
188198
return $this->upcomingMaintenance;
189199
}
190-
/**
191-
* Optional. This field will contain the date when the last version update was
192-
* applied to the database resource. This will be used to calculate the age of
193-
* the maintenance version.
194-
*
195-
* @param string $versionUpdateTime
196-
*/
197-
public function setVersionUpdateTime($versionUpdateTime)
198-
{
199-
$this->versionUpdateTime = $versionUpdateTime;
200-
}
201-
/**
202-
* @return string
203-
*/
204-
public function getVersionUpdateTime()
205-
{
206-
return $this->versionUpdateTime;
207-
}
208200
}
209201

210202
// Adding a class alias for backwards compatibility with the previous class name.

0 commit comments

Comments
 (0)