diff --git a/Gax/README.md b/Gax/README.md index 2f5a1d9322c9..59e6d0665b2f 100644 --- a/Gax/README.md +++ b/Gax/README.md @@ -80,6 +80,8 @@ be found for Mac or Windows. > vendor/bin/phpunit ``` + For Showcase Conformance testing and client generation, see [tests/Conformance/README.md](tests/Conformance/README.md). + 4. Run static analysis tools ```sh diff --git a/Gax/tests/Conformance/README.md b/Gax/tests/Conformance/README.md new file mode 100644 index 000000000000..0858b2c77cf6 --- /dev/null +++ b/Gax/tests/Conformance/README.md @@ -0,0 +1,46 @@ +# GAX Showcase Conformance Testing + +This directory contains the integration conformance test suite (`ShowcaseTest.php`) and generated client SDK for `gapic-showcase`. + +## Prerequisites + +- **Protobuf Compiler (`protoc`)**: Ensure `protoc` is installed and available in your `$PATH`. +- **Dev Dependencies**: Ensure dev dependencies are installed: + ```sh + composer install -d dev/ + ``` + +## Generating the Showcase Client + +To generate or update the Showcase client SDK, message classes, and metadata using the PHP CLI tool: + +```sh +# From the repository root, run the console command: +./dev/google-cloud showcase:generate +``` + +Options: +- `-o, --out-dir
google.showcase.v1beta1.AttemptStreamingSequenceRequest
*/
class AttemptStreamingSequenceRequest extends \Google\Protobuf\Internal\Message
@@ -26,19 +28,6 @@ class AttemptStreamingSequenceRequest extends \Google\Protobuf\Internal\Message
*/
protected $last_fail_index = 0;
- /**
- * @param string $name Please see {@see SequenceServiceClient::streamingSequenceName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\AttemptStreamingSequenceRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/AttemptStreamingSequenceResponse.php b/Gax/tests/Conformance/src/V1beta1/AttemptStreamingSequenceResponse.php
index 87caa59a51f1..d042dca59134 100644
--- a/Gax/tests/Conformance/src/V1beta1/AttemptStreamingSequenceResponse.php
+++ b/Gax/tests/Conformance/src/V1beta1/AttemptStreamingSequenceResponse.php
@@ -9,7 +9,7 @@
use Google\Protobuf\Internal\GPBUtil;
/**
- * The response message for the Echo methods.
+ * The response message for the AttemptStreamingSequence method.
*
* Generated from protobuf message google.showcase.v1beta1.AttemptStreamingSequenceResponse
*/
diff --git a/Gax/tests/Conformance/src/V1beta1/Client/ComplianceClient.php b/Gax/tests/Conformance/src/V1beta1/Client/ComplianceClient.php
index 913c3456efec..90829232eaa3 100644
--- a/Gax/tests/Conformance/src/V1beta1/Client/ComplianceClient.php
+++ b/Gax/tests/Conformance/src/V1beta1/Client/ComplianceClient.php
@@ -1,6 +1,6 @@
:optional int32 p_int32 = 18;
*/
protected $p_int32 = null;
+ /**
+ * Generated from protobuf field optional sint32 p_sint32 = 39;
+ */
+ protected $p_sint32 = null;
+ /**
+ * Generated from protobuf field optional sfixed32 p_sfixed32 = 40;
+ */
+ protected $p_sfixed32 = null;
+ /**
+ * Generated from protobuf field optional uint32 p_uint32 = 41;
+ */
+ protected $p_uint32 = null;
+ /**
+ * Generated from protobuf field optional fixed32 p_fixed32 = 42;
+ */
+ protected $p_fixed32 = null;
+ /**
+ * Generated from protobuf field optional int64 p_int64 = 43;
+ */
+ protected $p_int64 = null;
+ /**
+ * Generated from protobuf field optional sint64 p_sint64 = 44;
+ */
+ protected $p_sint64 = null;
+ /**
+ * Generated from protobuf field optional sfixed64 p_sfixed64 = 45;
+ */
+ protected $p_sfixed64 = null;
+ /**
+ * Generated from protobuf field optional uint64 p_uint64 = 46;
+ */
+ protected $p_uint64 = null;
+ /**
+ * Generated from protobuf field optional fixed64 p_fixed64 = 47;
+ */
+ protected $p_fixed64 = null;
+ /**
+ * Generated from protobuf field optional float p_float = 48;
+ */
+ protected $p_float = null;
/**
* Generated from protobuf field optional double p_double = 19;
*/
@@ -134,6 +174,16 @@ class ComplianceData extends \Google\Protobuf\Internal\Message
* @type \Google\Showcase\V1beta1\ComplianceDataChild $f_child
* @type string $p_string
* @type int $p_int32
+ * @type int $p_sint32
+ * @type int $p_sfixed32
+ * @type int $p_uint32
+ * @type int $p_fixed32
+ * @type int|string $p_int64
+ * @type int|string $p_sint64
+ * @type int|string $p_sfixed64
+ * @type int|string $p_uint64
+ * @type int|string $p_fixed64
+ * @type float $p_float
* @type float $p_double
* @type bool $p_bool
* @type int $p_kingdom
@@ -593,6 +643,326 @@ public function setPInt32($var)
return $this;
}
+ /**
+ * Generated from protobuf field optional sint32 p_sint32 = 39;
+ * @return int
+ */
+ public function getPSint32()
+ {
+ return isset($this->p_sint32) ? $this->p_sint32 : 0;
+ }
+
+ public function hasPSint32()
+ {
+ return isset($this->p_sint32);
+ }
+
+ public function clearPSint32()
+ {
+ unset($this->p_sint32);
+ }
+
+ /**
+ * Generated from protobuf field optional sint32 p_sint32 = 39;
+ * @param int $var
+ * @return $this
+ */
+ public function setPSint32($var)
+ {
+ GPBUtil::checkInt32($var);
+ $this->p_sint32 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional sfixed32 p_sfixed32 = 40;
+ * @return int
+ */
+ public function getPSfixed32()
+ {
+ return isset($this->p_sfixed32) ? $this->p_sfixed32 : 0;
+ }
+
+ public function hasPSfixed32()
+ {
+ return isset($this->p_sfixed32);
+ }
+
+ public function clearPSfixed32()
+ {
+ unset($this->p_sfixed32);
+ }
+
+ /**
+ * Generated from protobuf field optional sfixed32 p_sfixed32 = 40;
+ * @param int $var
+ * @return $this
+ */
+ public function setPSfixed32($var)
+ {
+ GPBUtil::checkInt32($var);
+ $this->p_sfixed32 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional uint32 p_uint32 = 41;
+ * @return int
+ */
+ public function getPUint32()
+ {
+ return isset($this->p_uint32) ? $this->p_uint32 : 0;
+ }
+
+ public function hasPUint32()
+ {
+ return isset($this->p_uint32);
+ }
+
+ public function clearPUint32()
+ {
+ unset($this->p_uint32);
+ }
+
+ /**
+ * Generated from protobuf field optional uint32 p_uint32 = 41;
+ * @param int $var
+ * @return $this
+ */
+ public function setPUint32($var)
+ {
+ GPBUtil::checkUint32($var);
+ $this->p_uint32 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional fixed32 p_fixed32 = 42;
+ * @return int
+ */
+ public function getPFixed32()
+ {
+ return isset($this->p_fixed32) ? $this->p_fixed32 : 0;
+ }
+
+ public function hasPFixed32()
+ {
+ return isset($this->p_fixed32);
+ }
+
+ public function clearPFixed32()
+ {
+ unset($this->p_fixed32);
+ }
+
+ /**
+ * Generated from protobuf field optional fixed32 p_fixed32 = 42;
+ * @param int $var
+ * @return $this
+ */
+ public function setPFixed32($var)
+ {
+ GPBUtil::checkUint32($var);
+ $this->p_fixed32 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional int64 p_int64 = 43;
+ * @return int|string
+ */
+ public function getPInt64()
+ {
+ return isset($this->p_int64) ? $this->p_int64 : 0;
+ }
+
+ public function hasPInt64()
+ {
+ return isset($this->p_int64);
+ }
+
+ public function clearPInt64()
+ {
+ unset($this->p_int64);
+ }
+
+ /**
+ * Generated from protobuf field optional int64 p_int64 = 43;
+ * @param int|string $var
+ * @return $this
+ */
+ public function setPInt64($var)
+ {
+ GPBUtil::checkInt64($var);
+ $this->p_int64 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional sint64 p_sint64 = 44;
+ * @return int|string
+ */
+ public function getPSint64()
+ {
+ return isset($this->p_sint64) ? $this->p_sint64 : 0;
+ }
+
+ public function hasPSint64()
+ {
+ return isset($this->p_sint64);
+ }
+
+ public function clearPSint64()
+ {
+ unset($this->p_sint64);
+ }
+
+ /**
+ * Generated from protobuf field optional sint64 p_sint64 = 44;
+ * @param int|string $var
+ * @return $this
+ */
+ public function setPSint64($var)
+ {
+ GPBUtil::checkInt64($var);
+ $this->p_sint64 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional sfixed64 p_sfixed64 = 45;
+ * @return int|string
+ */
+ public function getPSfixed64()
+ {
+ return isset($this->p_sfixed64) ? $this->p_sfixed64 : 0;
+ }
+
+ public function hasPSfixed64()
+ {
+ return isset($this->p_sfixed64);
+ }
+
+ public function clearPSfixed64()
+ {
+ unset($this->p_sfixed64);
+ }
+
+ /**
+ * Generated from protobuf field optional sfixed64 p_sfixed64 = 45;
+ * @param int|string $var
+ * @return $this
+ */
+ public function setPSfixed64($var)
+ {
+ GPBUtil::checkInt64($var);
+ $this->p_sfixed64 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional uint64 p_uint64 = 46;
+ * @return int|string
+ */
+ public function getPUint64()
+ {
+ return isset($this->p_uint64) ? $this->p_uint64 : 0;
+ }
+
+ public function hasPUint64()
+ {
+ return isset($this->p_uint64);
+ }
+
+ public function clearPUint64()
+ {
+ unset($this->p_uint64);
+ }
+
+ /**
+ * Generated from protobuf field optional uint64 p_uint64 = 46;
+ * @param int|string $var
+ * @return $this
+ */
+ public function setPUint64($var)
+ {
+ GPBUtil::checkUint64($var);
+ $this->p_uint64 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional fixed64 p_fixed64 = 47;
+ * @return int|string
+ */
+ public function getPFixed64()
+ {
+ return isset($this->p_fixed64) ? $this->p_fixed64 : 0;
+ }
+
+ public function hasPFixed64()
+ {
+ return isset($this->p_fixed64);
+ }
+
+ public function clearPFixed64()
+ {
+ unset($this->p_fixed64);
+ }
+
+ /**
+ * Generated from protobuf field optional fixed64 p_fixed64 = 47;
+ * @param int|string $var
+ * @return $this
+ */
+ public function setPFixed64($var)
+ {
+ GPBUtil::checkUint64($var);
+ $this->p_fixed64 = $var;
+
+ return $this;
+ }
+
+ /**
+ * Generated from protobuf field optional float p_float = 48;
+ * @return float
+ */
+ public function getPFloat()
+ {
+ return isset($this->p_float) ? $this->p_float : 0.0;
+ }
+
+ public function hasPFloat()
+ {
+ return isset($this->p_float);
+ }
+
+ public function clearPFloat()
+ {
+ unset($this->p_float);
+ }
+
+ /**
+ * Generated from protobuf field optional float p_float = 48;
+ * @param float $var
+ * @return $this
+ */
+ public function setPFloat($var)
+ {
+ GPBUtil::checkFloat($var);
+ $this->p_float = $var;
+
+ return $this;
+ }
+
/**
* Generated from protobuf field optional double p_double = 19;
* @return float
diff --git a/Gax/tests/Conformance/src/V1beta1/CreateBlurbRequest.php b/Gax/tests/Conformance/src/V1beta1/CreateBlurbRequest.php
index 2e591f68cbdc..8202d7120812 100644
--- a/Gax/tests/Conformance/src/V1beta1/CreateBlurbRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/CreateBlurbRequest.php
@@ -30,23 +30,6 @@ class CreateBlurbRequest extends \Google\Protobuf\Internal\Message
*/
protected $blurb = null;
- /**
- * @param string $parent The resource name of the chat room or user profile that this blurb will
- * be tied to. Please see
- * {@see MessagingClient::userName()} for help formatting this field.
- * @param \Google\Showcase\V1beta1\Blurb $blurb The blurb to create.
- *
- * @return \Google\Showcase\V1beta1\CreateBlurbRequest
- *
- * @experimental
- */
- public static function build(string $parent, \Google\Showcase\V1beta1\Blurb $blurb): self
- {
- return (new self())
- ->setParent($parent)
- ->setBlurb($blurb);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/CreateRoomRequest.php b/Gax/tests/Conformance/src/V1beta1/CreateRoomRequest.php
index e06b41262b2f..aa6100ebacb1 100644
--- a/Gax/tests/Conformance/src/V1beta1/CreateRoomRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/CreateRoomRequest.php
@@ -23,19 +23,6 @@ class CreateRoomRequest extends \Google\Protobuf\Internal\Message
*/
protected $room = null;
- /**
- * @param \Google\Showcase\V1beta1\Room $room The room to create.
- *
- * @return \Google\Showcase\V1beta1\CreateRoomRequest
- *
- * @experimental
- */
- public static function build(\Google\Showcase\V1beta1\Room $room): self
- {
- return (new self())
- ->setRoom($room);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/CreateSequenceRequest.php b/Gax/tests/Conformance/src/V1beta1/CreateSequenceRequest.php
index 824bb223a633..23f2c0a06e70 100644
--- a/Gax/tests/Conformance/src/V1beta1/CreateSequenceRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/CreateSequenceRequest.php
@@ -9,6 +9,8 @@
use Google\Protobuf\Internal\GPBUtil;
/**
+ * Request message for creating a sequence of unary calls
+ *
* Generated from protobuf message google.showcase.v1beta1.CreateSequenceRequest
*/
class CreateSequenceRequest extends \Google\Protobuf\Internal\Message
@@ -18,19 +20,6 @@ class CreateSequenceRequest extends \Google\Protobuf\Internal\Message
*/
protected $sequence = null;
- /**
- * @param \Google\Showcase\V1beta1\Sequence $sequence
- *
- * @return \Google\Showcase\V1beta1\CreateSequenceRequest
- *
- * @experimental
- */
- public static function build(\Google\Showcase\V1beta1\Sequence $sequence): self
- {
- return (new self())
- ->setSequence($sequence);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/CreateStreamingSequenceRequest.php b/Gax/tests/Conformance/src/V1beta1/CreateStreamingSequenceRequest.php
index 60eaae273f4e..e724762df98d 100644
--- a/Gax/tests/Conformance/src/V1beta1/CreateStreamingSequenceRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/CreateStreamingSequenceRequest.php
@@ -9,6 +9,8 @@
use Google\Protobuf\Internal\GPBUtil;
/**
+ * Request message for the sequences of responses to be sent in a server streaming call
+ *
* Generated from protobuf message google.showcase.v1beta1.CreateStreamingSequenceRequest
*/
class CreateStreamingSequenceRequest extends \Google\Protobuf\Internal\Message
@@ -18,19 +20,6 @@ class CreateStreamingSequenceRequest extends \Google\Protobuf\Internal\Message
*/
protected $streaming_sequence = null;
- /**
- * @param \Google\Showcase\V1beta1\StreamingSequence $streamingSequence
- *
- * @return \Google\Showcase\V1beta1\CreateStreamingSequenceRequest
- *
- * @experimental
- */
- public static function build(\Google\Showcase\V1beta1\StreamingSequence $streamingSequence): self
- {
- return (new self())
- ->setStreamingSequence($streamingSequence);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/CreateUserRequest.php b/Gax/tests/Conformance/src/V1beta1/CreateUserRequest.php
index 72af5e185bbc..8c7a8aca9f03 100644
--- a/Gax/tests/Conformance/src/V1beta1/CreateUserRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/CreateUserRequest.php
@@ -23,19 +23,6 @@ class CreateUserRequest extends \Google\Protobuf\Internal\Message
*/
protected $user = null;
- /**
- * @param \Google\Showcase\V1beta1\User $user The user to create.
- *
- * @return \Google\Showcase\V1beta1\CreateUserRequest
- *
- * @experimental
- */
- public static function build(\Google\Showcase\V1beta1\User $user): self
- {
- return (new self())
- ->setUser($user);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/DeleteBlurbRequest.php b/Gax/tests/Conformance/src/V1beta1/DeleteBlurbRequest.php
index 33d021c69a43..ce88e5fa80c1 100644
--- a/Gax/tests/Conformance/src/V1beta1/DeleteBlurbRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/DeleteBlurbRequest.php
@@ -23,20 +23,6 @@ class DeleteBlurbRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name The resource name of the requested blurb. Please see
- * {@see MessagingClient::blurbName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\DeleteBlurbRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/DeleteRoomRequest.php b/Gax/tests/Conformance/src/V1beta1/DeleteRoomRequest.php
index 7c5f4b83f76e..d0faf0a5d8b1 100644
--- a/Gax/tests/Conformance/src/V1beta1/DeleteRoomRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/DeleteRoomRequest.php
@@ -23,20 +23,6 @@ class DeleteRoomRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name The resource name of the requested room. Please see
- * {@see MessagingClient::roomName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\DeleteRoomRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/DeleteUserRequest.php b/Gax/tests/Conformance/src/V1beta1/DeleteUserRequest.php
index b0f77bf415f7..f711e3ac2ee9 100644
--- a/Gax/tests/Conformance/src/V1beta1/DeleteUserRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/DeleteUserRequest.php
@@ -23,20 +23,6 @@ class DeleteUserRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name The resource name of the user to delete. Please see
- * {@see IdentityClient::userName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\DeleteUserRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/ExpandRequest.php b/Gax/tests/Conformance/src/V1beta1/ExpandRequest.php
index ff777df17271..c7c7680878e3 100644
--- a/Gax/tests/Conformance/src/V1beta1/ExpandRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/ExpandRequest.php
@@ -34,21 +34,6 @@ class ExpandRequest extends \Google\Protobuf\Internal\Message
*/
protected $stream_wait_time = null;
- /**
- * @param string $content The content that will be split into words and returned on the stream.
- * @param \Google\Rpc\Status $error The error that is thrown after all words are sent on the stream.
- *
- * @return \Google\Showcase\V1beta1\ExpandRequest
- *
- * @experimental
- */
- public static function build(string $content, \Google\Rpc\Status $error): self
- {
- return (new self())
- ->setContent($content)
- ->setError($error);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/GetBlurbRequest.php b/Gax/tests/Conformance/src/V1beta1/GetBlurbRequest.php
index 5746c7116432..83b7a1978b5a 100644
--- a/Gax/tests/Conformance/src/V1beta1/GetBlurbRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/GetBlurbRequest.php
@@ -23,20 +23,6 @@ class GetBlurbRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name The resource name of the requested blurb. Please see
- * {@see MessagingClient::blurbName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\GetBlurbRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/GetRoomRequest.php b/Gax/tests/Conformance/src/V1beta1/GetRoomRequest.php
index f80ff9f40ea4..90b1a4715fce 100644
--- a/Gax/tests/Conformance/src/V1beta1/GetRoomRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/GetRoomRequest.php
@@ -23,20 +23,6 @@ class GetRoomRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name The resource name of the requested room. Please see
- * {@see MessagingClient::roomName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\GetRoomRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/GetSequenceReportRequest.php b/Gax/tests/Conformance/src/V1beta1/GetSequenceReportRequest.php
index 9cff8d1d607a..c33e199e0e73 100644
--- a/Gax/tests/Conformance/src/V1beta1/GetSequenceReportRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/GetSequenceReportRequest.php
@@ -18,19 +18,6 @@ class GetSequenceReportRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name Please see {@see SequenceServiceClient::sequenceReportName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\GetSequenceReportRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/GetStreamingSequenceReportRequest.php b/Gax/tests/Conformance/src/V1beta1/GetStreamingSequenceReportRequest.php
index 8817ae7b93ff..e54ac620167f 100644
--- a/Gax/tests/Conformance/src/V1beta1/GetStreamingSequenceReportRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/GetStreamingSequenceReportRequest.php
@@ -18,19 +18,6 @@ class GetStreamingSequenceReportRequest extends \Google\Protobuf\Internal\Messag
*/
protected $name = '';
- /**
- * @param string $name Please see {@see SequenceServiceClient::streamingSequenceReportName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\GetStreamingSequenceReportRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/GetUserRequest.php b/Gax/tests/Conformance/src/V1beta1/GetUserRequest.php
index a10d124a1f61..3f26ad3432d4 100644
--- a/Gax/tests/Conformance/src/V1beta1/GetUserRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/GetUserRequest.php
@@ -23,20 +23,6 @@ class GetUserRequest extends \Google\Protobuf\Internal\Message
*/
protected $name = '';
- /**
- * @param string $name The resource name of the requested user. Please see
- * {@see IdentityClient::userName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\GetUserRequest
- *
- * @experimental
- */
- public static function build(string $name): self
- {
- return (new self())
- ->setName($name);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/ListBlurbsRequest.php b/Gax/tests/Conformance/src/V1beta1/ListBlurbsRequest.php
index bd659054d7dc..2e71020fe5d6 100644
--- a/Gax/tests/Conformance/src/V1beta1/ListBlurbsRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/ListBlurbsRequest.php
@@ -39,20 +39,6 @@ class ListBlurbsRequest extends \Google\Protobuf\Internal\Message
*/
protected $page_token = '';
- /**
- * @param string $parent The resource name of the requested room or profile who blurbs to list. Please see
- * {@see MessagingClient::userName()} for help formatting this field.
- *
- * @return \Google\Showcase\V1beta1\ListBlurbsRequest
- *
- * @experimental
- */
- public static function build(string $parent): self
- {
- return (new self())
- ->setParent($parent);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/PagedExpandLegacyMappedResponse.php b/Gax/tests/Conformance/src/V1beta1/PagedExpandLegacyMappedResponse.php
index 4be88d99a26f..77d87f5ca6e6 100644
--- a/Gax/tests/Conformance/src/V1beta1/PagedExpandLegacyMappedResponse.php
+++ b/Gax/tests/Conformance/src/V1beta1/PagedExpandLegacyMappedResponse.php
@@ -18,7 +18,7 @@ class PagedExpandLegacyMappedResponse extends \Google\Protobuf\Internal\Message
* (-- aip.dev/not-precedent: This is a legacy, non-standard pattern that violates
* aip.dev/158. Ordinarily, this should be a `repeated` field, as in PagedExpandResponse. --)
*
- * Generated from protobuf field repeated .google.showcase.v1beta1.PagedExpandResponseList alphabetized = 1;
+ * Generated from protobuf field map alphabetized = 1;
*/
private $alphabetized;
/**
@@ -34,7 +34,7 @@ class PagedExpandLegacyMappedResponse extends \Google\Protobuf\Internal\Message
* @param array $data {
* Optional. Data for populating the Message object.
*
- * @type array<\Google\Showcase\V1beta1\PagedExpandResponseList>|\Google\Protobuf\Internal\RepeatedField $alphabetized
+ * @type array|\Google\Protobuf\Internal\MapField $alphabetized
* The words that were expanded, indexed by their initial character.
* (-- aip.dev/not-precedent: This is a legacy, non-standard pattern that violates
* aip.dev/158. Ordinarily, this should be a `repeated` field, as in PagedExpandResponse. --)
@@ -52,8 +52,8 @@ public function __construct($data = NULL) {
* (-- aip.dev/not-precedent: This is a legacy, non-standard pattern that violates
* aip.dev/158. Ordinarily, this should be a `repeated` field, as in PagedExpandResponse. --)
*
- * Generated from protobuf field repeated .google.showcase.v1beta1.PagedExpandResponseList alphabetized = 1;
- * @return \Google\Protobuf\Internal\RepeatedField
+ * Generated from protobuf field map alphabetized = 1;
+ * @return \Google\Protobuf\Internal\MapField
*/
public function getAlphabetized()
{
@@ -65,13 +65,13 @@ public function getAlphabetized()
* (-- aip.dev/not-precedent: This is a legacy, non-standard pattern that violates
* aip.dev/158. Ordinarily, this should be a `repeated` field, as in PagedExpandResponse. --)
*
- * Generated from protobuf field repeated .google.showcase.v1beta1.PagedExpandResponseList alphabetized = 1;
- * @param array<\Google\Showcase\V1beta1\PagedExpandResponseList>|\Google\Protobuf\Internal\RepeatedField $var
+ * Generated from protobuf field map alphabetized = 1;
+ * @param array|\Google\Protobuf\Internal\MapField $var
* @return $this
*/
public function setAlphabetized($var)
{
- $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Showcase\V1beta1\PagedExpandResponseList::class);
+ $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Showcase\V1beta1\PagedExpandResponseList::class);
$this->alphabetized = $arr;
return $this;
diff --git a/Gax/tests/Conformance/src/V1beta1/SearchBlurbsRequest.php b/Gax/tests/Conformance/src/V1beta1/SearchBlurbsRequest.php
index 984f508bf4cd..35cf83c8cc9e 100644
--- a/Gax/tests/Conformance/src/V1beta1/SearchBlurbsRequest.php
+++ b/Gax/tests/Conformance/src/V1beta1/SearchBlurbsRequest.php
@@ -48,23 +48,6 @@ class SearchBlurbsRequest extends \Google\Protobuf\Internal\Message
*/
protected $page_token = '';
- /**
- * @param string $parent The rooms or profiles to search. If unset, `SearchBlurbs` will search all
- * rooms and all profiles.
- * @param string $query The query used to search for blurbs containing to words of this string.
- * Only posts that contain an exact match of a queried word will be returned.
- *
- * @return \Google\Showcase\V1beta1\SearchBlurbsRequest
- *
- * @experimental
- */
- public static function build(string $parent, string $query): self
- {
- return (new self())
- ->setParent($parent)
- ->setQuery($query);
- }
-
/**
* Constructor.
*
diff --git a/Gax/tests/Conformance/src/V1beta1/Sequence.php b/Gax/tests/Conformance/src/V1beta1/Sequence.php
index b8565b20374c..055b85bbbbec 100644
--- a/Gax/tests/Conformance/src/V1beta1/Sequence.php
+++ b/Gax/tests/Conformance/src/V1beta1/Sequence.php
@@ -9,6 +9,8 @@
use Google\Protobuf\Internal\GPBUtil;
/**
+ * A sequence of responses to be returned in order for each unary call attempt
+ *
* Generated from protobuf message google.showcase.v1beta1.Sequence
*/
class Sequence extends \Google\Protobuf\Internal\Message
diff --git a/Gax/tests/Conformance/src/V1beta1/SequenceReport.php b/Gax/tests/Conformance/src/V1beta1/SequenceReport.php
index 990664340637..adbe727d59f6 100644
--- a/Gax/tests/Conformance/src/V1beta1/SequenceReport.php
+++ b/Gax/tests/Conformance/src/V1beta1/SequenceReport.php
@@ -9,6 +9,8 @@
use Google\Protobuf\Internal\GPBUtil;
/**
+ * A report of the results of a sequence of unary responses
+ *
* Generated from protobuf message google.showcase.v1beta1.SequenceReport
*/
class SequenceReport extends \Google\Protobuf\Internal\Message
diff --git a/Gax/tests/Conformance/src/V1beta1/StreamingSequence.php b/Gax/tests/Conformance/src/V1beta1/StreamingSequence.php
index 4ee0a4047639..2bbcdaf9e43a 100644
--- a/Gax/tests/Conformance/src/V1beta1/StreamingSequence.php
+++ b/Gax/tests/Conformance/src/V1beta1/StreamingSequence.php
@@ -9,16 +9,22 @@
use Google\Protobuf\Internal\GPBUtil;
/**
+ * A sequence of responses to be returned in order at the delay specified
+ * as part of the server streaming call
+ *
* Generated from protobuf message google.showcase.v1beta1.StreamingSequence
*/
class StreamingSequence extends \Google\Protobuf\Internal\Message
{
/**
+ * The name of the streaming sequence.
+ *
* Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
*/
protected $name = '';
/**
- * The Content that the stream will send
+ * The content that the stream will send
+ * this was specified when the sequence was created
*
* Generated from protobuf field string content = 2;
*/
@@ -38,8 +44,10 @@ class StreamingSequence extends \Google\Protobuf\Internal\Message
* Optional. Data for populating the Message object.
*
* @type string $name
+ * The name of the streaming sequence.
* @type string $content
- * The Content that the stream will send
+ * The content that the stream will send
+ * this was specified when the sequence was created
* @type array<\Google\Showcase\V1beta1\StreamingSequence\Response>|\Google\Protobuf\Internal\RepeatedField $responses
* Sequence of responses to return in order for each attempt. If empty, the
* default response is an immediate OK.
@@ -51,6 +59,8 @@ public function __construct($data = NULL) {
}
/**
+ * The name of the streaming sequence.
+ *
* Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
* @return string
*/
@@ -60,6 +70,8 @@ public function getName()
}
/**
+ * The name of the streaming sequence.
+ *
* Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
* @param string $var
* @return $this
@@ -73,7 +85,8 @@ public function setName($var)
}
/**
- * The Content that the stream will send
+ * The content that the stream will send
+ * this was specified when the sequence was created
*
* Generated from protobuf field string content = 2;
* @return string
@@ -84,7 +97,8 @@ public function getContent()
}
/**
- * The Content that the stream will send
+ * The content that the stream will send
+ * this was specified when the sequence was created
*
* Generated from protobuf field string content = 2;
* @param string $var
diff --git a/Gax/tests/Conformance/src/V1beta1/StreamingSequence/Response.php b/Gax/tests/Conformance/src/V1beta1/StreamingSequence/Response.php
index fde26643cd1e..4c5449e39226 100644
--- a/Gax/tests/Conformance/src/V1beta1/StreamingSequence/Response.php
+++ b/Gax/tests/Conformance/src/V1beta1/StreamingSequence/Response.php
@@ -28,7 +28,7 @@ class Response extends \Google\Protobuf\Internal\Message
*/
protected $delay = null;
/**
- * The index that the status should be sent
+ * The index that the status should be sent at
*
* Generated from protobuf field int32 response_index = 3;
*/
@@ -45,7 +45,7 @@ class Response extends \Google\Protobuf\Internal\Message
* @type \Google\Protobuf\Duration $delay
* The amount of time to delay sending the response.
* @type int $response_index
- * The index that the status should be sent
+ * The index that the status should be sent at
* }
*/
public function __construct($data = NULL) {
@@ -126,7 +126,7 @@ public function setDelay($var)
}
/**
- * The index that the status should be sent
+ * The index that the status should be sent at
*
* Generated from protobuf field int32 response_index = 3;
* @return int
@@ -137,7 +137,7 @@ public function getResponseIndex()
}
/**
- * The index that the status should be sent
+ * The index that the status should be sent at
*
* Generated from protobuf field int32 response_index = 3;
* @param int $var
diff --git a/Gax/tests/Conformance/src/V1beta1/StreamingSequenceReport.php b/Gax/tests/Conformance/src/V1beta1/StreamingSequenceReport.php
index 6ed3e26d15e6..e475bbcd07a0 100644
--- a/Gax/tests/Conformance/src/V1beta1/StreamingSequenceReport.php
+++ b/Gax/tests/Conformance/src/V1beta1/StreamingSequenceReport.php
@@ -9,6 +9,8 @@
use Google\Protobuf\Internal\GPBUtil;
/**
+ * A report of the results of a streaming sequence.
+ *
* Generated from protobuf message google.showcase.v1beta1.StreamingSequenceReport
*/
class StreamingSequenceReport extends \Google\Protobuf\Internal\Message
diff --git a/Gax/tests/Conformance/src/V1beta1/gapic_metadata.json b/Gax/tests/Conformance/src/V1beta1/gapic_metadata.json
index ae1e9b817740..81aca6de4d64 100644
--- a/Gax/tests/Conformance/src/V1beta1/gapic_metadata.json
+++ b/Gax/tests/Conformance/src/V1beta1/gapic_metadata.json
@@ -126,7 +126,8 @@
}
}
}
- }
+ },
+ "apiVersion": "v1_20240408"
},
"Identity": {
"clients": {
@@ -162,85 +163,6 @@
}
}
},
- "Messaging": {
- "clients": {
- "grpc": {
- "libraryClient": "MessagingGapicClient",
- "rpcs": {
- "Connect": {
- "methods": [
- "connect"
- ]
- },
- "CreateBlurb": {
- "methods": [
- "createBlurb"
- ]
- },
- "CreateRoom": {
- "methods": [
- "createRoom"
- ]
- },
- "DeleteBlurb": {
- "methods": [
- "deleteBlurb"
- ]
- },
- "DeleteRoom": {
- "methods": [
- "deleteRoom"
- ]
- },
- "GetBlurb": {
- "methods": [
- "getBlurb"
- ]
- },
- "GetRoom": {
- "methods": [
- "getRoom"
- ]
- },
- "ListBlurbs": {
- "methods": [
- "listBlurbs"
- ]
- },
- "ListRooms": {
- "methods": [
- "listRooms"
- ]
- },
- "SearchBlurbs": {
- "methods": [
- "searchBlurbs"
- ]
- },
- "SendBlurbs": {
- "methods": [
- "sendBlurbs"
- ]
- },
- "StreamBlurbs": {
- "methods": [
- "streamBlurbs"
- ]
- },
- "UpdateBlurb": {
- "methods": [
- "updateBlurb"
- ]
- },
- "UpdateRoom": {
- "methods": [
- "updateRoom"
- ]
- }
- }
- }
- }
- },
"SequenceService": {
"clients": {
"grpc": {
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/compliance_descriptor_config.php b/Gax/tests/Conformance/src/V1beta1/resources/compliance_descriptor_config.php
index e1e9126106fd..963e7dee225e 100644
--- a/Gax/tests/Conformance/src/V1beta1/resources/compliance_descriptor_config.php
+++ b/Gax/tests/Conformance/src/V1beta1/resources/compliance_descriptor_config.php
@@ -1,6 +1,6 @@
true,
];
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/echo_descriptor_config.php b/Gax/tests/Conformance/src/V1beta1/resources/echo_descriptor_config.php
index 63b503e5c1c5..784685cbba7c 100644
--- a/Gax/tests/Conformance/src/V1beta1/resources/echo_descriptor_config.php
+++ b/Gax/tests/Conformance/src/V1beta1/resources/echo_descriptor_config.php
@@ -1,6 +1,6 @@
[
+ 'requestId' => \Google\Api\FieldInfo\Format::UUID4,
+ 'otherRequestId' => \Google\Api\FieldInfo\Format::UUID4,
+ ],
],
'EchoErrorDetails' => [
'callType' => \Google\ApiCore\Call::UNARY_CALL,
@@ -145,15 +149,7 @@
'responseType' => 'Google\Showcase\V1beta1\PagedExpandResponse',
],
'PagedExpandLegacyMapped' => [
- 'pageStreaming' => [
- 'requestPageTokenGetMethod' => 'getPageToken',
- 'requestPageTokenSetMethod' => 'setPageToken',
- 'requestPageSizeGetMethod' => 'getPageSize',
- 'requestPageSizeSetMethod' => 'setPageSize',
- 'responsePageTokenGetMethod' => 'getNextPageToken',
- 'resourcesGetMethod' => 'getAlphabetized',
- ],
- 'callType' => \Google\ApiCore\Call::PAGINATED_CALL,
+ 'callType' => \Google\ApiCore\Call::UNARY_CALL,
'responseType' => 'Google\Showcase\V1beta1\PagedExpandLegacyMappedResponse',
],
],
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/echo_rest_client_config.php b/Gax/tests/Conformance/src/V1beta1/resources/echo_rest_client_config.php
index f1a999b60fbf..70b815644deb 100644
--- a/Gax/tests/Conformance/src/V1beta1/resources/echo_rest_client_config.php
+++ b/Gax/tests/Conformance/src/V1beta1/resources/echo_rest_client_config.php
@@ -1,6 +1,6 @@
true,
];
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/identity_descriptor_config.php b/Gax/tests/Conformance/src/V1beta1/resources/identity_descriptor_config.php
index b544be013f13..73b3f625e43a 100644
--- a/Gax/tests/Conformance/src/V1beta1/resources/identity_descriptor_config.php
+++ b/Gax/tests/Conformance/src/V1beta1/resources/identity_descriptor_config.php
@@ -1,6 +1,6 @@
true,
];
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/messaging_client_config.json b/Gax/tests/Conformance/src/V1beta1/resources/messaging_client_config.json
deleted file mode 100644
index 05a964f8f028..000000000000
--- a/Gax/tests/Conformance/src/V1beta1/resources/messaging_client_config.json
+++ /dev/null
@@ -1,109 +0,0 @@
-{
- "interfaces": {
- "google.showcase.v1beta1.Messaging": {
- "retry_codes": {
- "no_retry_codes": [],
- "no_retry_1_codes": [],
- "retry_policy_1_codes": [
- "UNAVAILABLE",
- "UNKNOWN"
- ]
- },
- "retry_params": {
- "no_retry_params": {
- "initial_retry_delay_millis": 0,
- "retry_delay_multiplier": 0.0,
- "max_retry_delay_millis": 0,
- "initial_rpc_timeout_millis": 0,
- "rpc_timeout_multiplier": 1.0,
- "max_rpc_timeout_millis": 0,
- "total_timeout_millis": 0
- },
- "no_retry_1_params": {
- "initial_retry_delay_millis": 0,
- "retry_delay_multiplier": 0.0,
- "max_retry_delay_millis": 0,
- "initial_rpc_timeout_millis": 5000,
- "rpc_timeout_multiplier": 1.0,
- "max_rpc_timeout_millis": 5000,
- "total_timeout_millis": 5000
- },
- "retry_policy_1_params": {
- "initial_retry_delay_millis": 100,
- "retry_delay_multiplier": 2.0,
- "max_retry_delay_millis": 3000,
- "initial_rpc_timeout_millis": 10000,
- "rpc_timeout_multiplier": 1.0,
- "max_rpc_timeout_millis": 10000,
- "total_timeout_millis": 10000
- }
- },
- "methods": {
- "Connect": {
- "timeout_millis": 10000
- },
- "CreateBlurb": {
- "timeout_millis": 5000,
- "retry_codes_name": "no_retry_1_codes",
- "retry_params_name": "no_retry_1_params"
- },
- "CreateRoom": {
- "timeout_millis": 5000,
- "retry_codes_name": "no_retry_1_codes",
- "retry_params_name": "no_retry_1_params"
- },
- "DeleteBlurb": {
- "timeout_millis": 5000,
- "retry_codes_name": "no_retry_1_codes",
- "retry_params_name": "no_retry_1_params"
- },
- "DeleteRoom": {
- "timeout_millis": 5000,
- "retry_codes_name": "no_retry_1_codes",
- "retry_params_name": "no_retry_1_params"
- },
- "GetBlurb": {
- "timeout_millis": 10000,
- "retry_codes_name": "retry_policy_1_codes",
- "retry_params_name": "retry_policy_1_params"
- },
- "GetRoom": {
- "timeout_millis": 10000,
- "retry_codes_name": "retry_policy_1_codes",
- "retry_params_name": "retry_policy_1_params"
- },
- "ListBlurbs": {
- "timeout_millis": 10000,
- "retry_codes_name": "retry_policy_1_codes",
- "retry_params_name": "retry_policy_1_params"
- },
- "ListRooms": {
- "timeout_millis": 10000,
- "retry_codes_name": "retry_policy_1_codes",
- "retry_params_name": "retry_policy_1_params"
- },
- "SearchBlurbs": {
- "timeout_millis": 10000,
- "retry_codes_name": "retry_policy_1_codes",
- "retry_params_name": "retry_policy_1_params"
- },
- "SendBlurbs": {
- "timeout_millis": 5000
- },
- "StreamBlurbs": {
- "timeout_millis": 5000
- },
- "UpdateBlurb": {
- "timeout_millis": 5000,
- "retry_codes_name": "no_retry_1_codes",
- "retry_params_name": "no_retry_1_params"
- },
- "UpdateRoom": {
- "timeout_millis": 5000,
- "retry_codes_name": "no_retry_1_codes",
- "retry_params_name": "no_retry_1_params"
- }
- }
- }
- }
-}
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/messaging_descriptor_config.php b/Gax/tests/Conformance/src/V1beta1/resources/messaging_descriptor_config.php
deleted file mode 100644
index f29f84658c63..000000000000
--- a/Gax/tests/Conformance/src/V1beta1/resources/messaging_descriptor_config.php
+++ /dev/null
@@ -1,216 +0,0 @@
- [
- 'google.showcase.v1beta1.Messaging' => [
- 'SearchBlurbs' => [
- 'longRunning' => [
- 'operationReturnType' => '\Google\Showcase\V1beta1\SearchBlurbsResponse',
- 'metadataReturnType' => '\Google\Showcase\V1beta1\SearchBlurbsMetadata',
- 'initialPollDelayMillis' => '500',
- 'pollDelayMultiplier' => '1.5',
- 'maxPollDelayMillis' => '5000',
- 'totalPollTimeoutMillis' => '300000',
- ],
- 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL,
- 'headerParams' => [
- [
- 'keyName' => 'parent',
- 'fieldAccessors' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'Connect' => [
- 'grpcStreaming' => [
- 'grpcStreamingType' => 'BidiStreaming',
- ],
- 'callType' => \Google\ApiCore\Call::BIDI_STREAMING_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\StreamBlurbsResponse',
- ],
- 'CreateBlurb' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\Blurb',
- 'headerParams' => [
- [
- 'keyName' => 'parent',
- 'fieldAccessors' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'CreateRoom' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\Room',
- ],
- 'DeleteBlurb' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Protobuf\GPBEmpty',
- 'headerParams' => [
- [
- 'keyName' => 'name',
- 'fieldAccessors' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'DeleteRoom' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Protobuf\GPBEmpty',
- 'headerParams' => [
- [
- 'keyName' => 'name',
- 'fieldAccessors' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'GetBlurb' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\Blurb',
- 'headerParams' => [
- [
- 'keyName' => 'name',
- 'fieldAccessors' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'GetRoom' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\Room',
- 'headerParams' => [
- [
- 'keyName' => 'name',
- 'fieldAccessors' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'ListBlurbs' => [
- 'pageStreaming' => [
- 'requestPageTokenGetMethod' => 'getPageToken',
- 'requestPageTokenSetMethod' => 'setPageToken',
- 'requestPageSizeGetMethod' => 'getPageSize',
- 'requestPageSizeSetMethod' => 'setPageSize',
- 'responsePageTokenGetMethod' => 'getNextPageToken',
- 'resourcesGetMethod' => 'getBlurbs',
- ],
- 'callType' => \Google\ApiCore\Call::PAGINATED_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\ListBlurbsResponse',
- 'headerParams' => [
- [
- 'keyName' => 'parent',
- 'fieldAccessors' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'ListRooms' => [
- 'pageStreaming' => [
- 'requestPageTokenGetMethod' => 'getPageToken',
- 'requestPageTokenSetMethod' => 'setPageToken',
- 'requestPageSizeGetMethod' => 'getPageSize',
- 'requestPageSizeSetMethod' => 'setPageSize',
- 'responsePageTokenGetMethod' => 'getNextPageToken',
- 'resourcesGetMethod' => 'getRooms',
- ],
- 'callType' => \Google\ApiCore\Call::PAGINATED_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\ListRoomsResponse',
- ],
- 'SendBlurbs' => [
- 'grpcStreaming' => [
- 'grpcStreamingType' => 'ClientStreaming',
- ],
- 'callType' => \Google\ApiCore\Call::CLIENT_STREAMING_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\SendBlurbsResponse',
- 'headerParams' => [
- [
- 'keyName' => 'parent',
- 'fieldAccessors' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'StreamBlurbs' => [
- 'grpcStreaming' => [
- 'grpcStreamingType' => 'ServerStreaming',
- ],
- 'callType' => \Google\ApiCore\Call::SERVER_STREAMING_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\StreamBlurbsResponse',
- 'headerParams' => [
- [
- 'keyName' => 'name',
- 'fieldAccessors' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'UpdateBlurb' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\Blurb',
- 'headerParams' => [
- [
- 'keyName' => 'blurb.name',
- 'fieldAccessors' => [
- 'getBlurb',
- 'getName',
- ],
- ],
- ],
- ],
- 'UpdateRoom' => [
- 'callType' => \Google\ApiCore\Call::UNARY_CALL,
- 'responseType' => 'Google\Showcase\V1beta1\Room',
- 'headerParams' => [
- [
- 'keyName' => 'room.name',
- 'fieldAccessors' => [
- 'getRoom',
- 'getName',
- ],
- ],
- ],
- ],
- 'templateMap' => [
- 'blurb' => 'users/{user}/blurbs/{blurb}',
- 'room' => 'rooms/{room}',
- 'roomBlurb' => 'rooms/{room}/blurbs/{blurb}',
- 'roomLegacyRoom' => 'rooms/{room}/legacy_room/{legacy_room}',
- 'roomLegacyRoomBlurb' => 'rooms/{room}/legacy_room/{legacy_room}/blurbs/{blurb}',
- 'user' => 'users/{user}',
- 'userBlurb' => 'users/{user}/blurbs/{blurb}',
- 'userBlurbLegacyUser' => 'users/{user}/blurbs/{blurb}/legacy/{legacy_user}',
- ],
- ],
- ],
-];
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/messaging_rest_client_config.php b/Gax/tests/Conformance/src/V1beta1/resources/messaging_rest_client_config.php
deleted file mode 100644
index 4b080078c321..000000000000
--- a/Gax/tests/Conformance/src/V1beta1/resources/messaging_rest_client_config.php
+++ /dev/null
@@ -1,349 +0,0 @@
- [
- 'google.cloud.location.Locations' => [
- 'ListLocations' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{name=projects/*}/locations',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'GetLocation' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{name=projects/*/locations/*}',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- ],
- 'google.iam.v1.IAMPolicy' => [
- 'SetIamPolicy' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=users/*}:setIamPolicy',
- 'body' => '*',
- 'additionalBindings' => [
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=rooms/*}:setIamPolicy',
- 'body' => '*',
- ],
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=rooms/*/blurbs/*}:setIamPolicy',
- 'body' => '*',
- ],
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=sequences/*}:setIamPolicy',
- 'body' => '*',
- ],
- ],
- 'placeholders' => [
- 'resource' => [
- 'getters' => [
- 'getResource',
- ],
- ],
- ],
- ],
- 'GetIamPolicy' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{resource=users/*}:getIamPolicy',
- 'additionalBindings' => [
- [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{resource=rooms/*}:getIamPolicy',
- ],
- [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{resource=rooms/*/blurbs/*}:getIamPolicy',
- ],
- [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{resource=sequences/*}:getIamPolicy',
- ],
- ],
- 'placeholders' => [
- 'resource' => [
- 'getters' => [
- 'getResource',
- ],
- ],
- ],
- ],
- 'TestIamPermissions' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=users/*}:testIamPermissions',
- 'body' => '*',
- 'additionalBindings' => [
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=rooms/*}:testIamPermissions',
- 'body' => '*',
- ],
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=rooms/*/blurbs/*}:testIamPermissions',
- 'body' => '*',
- ],
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{resource=sequences/*}:testIamPermissions',
- 'body' => '*',
- ],
- ],
- 'placeholders' => [
- 'resource' => [
- 'getters' => [
- 'getResource',
- ],
- ],
- ],
- ],
- ],
- 'google.longrunning.Operations' => [
- 'ListOperations' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/operations',
- ],
- 'GetOperation' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{name=operations/**}',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'DeleteOperation' => [
- 'method' => 'delete',
- 'uriTemplate' => '/v1beta1/{name=operations/**}',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'CancelOperation' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{name=operations/**}:cancel',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- ],
- 'google.showcase.v1beta1.Messaging' => [
- 'CreateBlurb' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{parent=rooms/*}/blurbs',
- 'body' => '*',
- 'additionalBindings' => [
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{parent=users/*/profile}/blurbs',
- 'body' => '*',
- ],
- ],
- 'placeholders' => [
- 'parent' => [
- 'getters' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'CreateRoom' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/rooms',
- 'body' => '*',
- ],
- 'DeleteBlurb' => [
- 'method' => 'delete',
- 'uriTemplate' => '/v1beta1/{name=rooms/*/blurbs/*}',
- 'additionalBindings' => [
- [
- 'method' => 'delete',
- 'uriTemplate' => '/v1beta1/{name=users/*/profile/blurbs/*}',
- ],
- ],
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'DeleteRoom' => [
- 'method' => 'delete',
- 'uriTemplate' => '/v1beta1/{name=rooms/*}',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'GetBlurb' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{name=rooms/*/blurbs/*}',
- 'additionalBindings' => [
- [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{name=users/*/profile/blurbs/*}',
- ],
- ],
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'GetRoom' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{name=rooms/*}',
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'ListBlurbs' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{parent=rooms/*}/blurbs',
- 'additionalBindings' => [
- [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/{parent=users/*/profile}/blurbs',
- ],
- ],
- 'placeholders' => [
- 'parent' => [
- 'getters' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'ListRooms' => [
- 'method' => 'get',
- 'uriTemplate' => '/v1beta1/rooms',
- ],
- 'SearchBlurbs' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{parent=rooms/*}/blurbs:search',
- 'body' => '*',
- 'additionalBindings' => [
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{parent=users/*/profile}/blurbs:search',
- 'body' => '*',
- ],
- ],
- 'placeholders' => [
- 'parent' => [
- 'getters' => [
- 'getParent',
- ],
- ],
- ],
- ],
- 'StreamBlurbs' => [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{name=rooms/*}/blurbs:stream',
- 'body' => '*',
- 'additionalBindings' => [
- [
- 'method' => 'post',
- 'uriTemplate' => '/v1beta1/{name=users/*/profile}/blurbs:stream',
- 'body' => '*',
- ],
- ],
- 'placeholders' => [
- 'name' => [
- 'getters' => [
- 'getName',
- ],
- ],
- ],
- ],
- 'UpdateBlurb' => [
- 'method' => 'patch',
- 'uriTemplate' => '/v1beta1/{blurb.name=rooms/*/blurbs/*}',
- 'body' => 'blurb',
- 'additionalBindings' => [
- [
- 'method' => 'patch',
- 'uriTemplate' => '/v1beta1/{blurb.name=users/*/profile/blurbs/*}',
- 'body' => 'blurb',
- ],
- ],
- 'placeholders' => [
- 'blurb.name' => [
- 'getters' => [
- 'getBlurb',
- 'getName',
- ],
- ],
- ],
- ],
- 'UpdateRoom' => [
- 'method' => 'patch',
- 'uriTemplate' => '/v1beta1/{room.name=rooms/*}',
- 'body' => 'room',
- 'placeholders' => [
- 'room.name' => [
- 'getters' => [
- 'getRoom',
- 'getName',
- ],
- ],
- ],
- ],
- ],
- ],
- 'numericEnums' => true,
-];
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/sequence_service_descriptor_config.php b/Gax/tests/Conformance/src/V1beta1/resources/sequence_service_descriptor_config.php
index 64096e0fe8bf..90bbf9d47dea 100644
--- a/Gax/tests/Conformance/src/V1beta1/resources/sequence_service_descriptor_config.php
+++ b/Gax/tests/Conformance/src/V1beta1/resources/sequence_service_descriptor_config.php
@@ -1,6 +1,6 @@
true,
];
diff --git a/Gax/tests/Conformance/src/V1beta1/resources/testing_descriptor_config.php b/Gax/tests/Conformance/src/V1beta1/resources/testing_descriptor_config.php
index 6f62206cbe47..7b604c0134fe 100644
--- a/Gax/tests/Conformance/src/V1beta1/resources/testing_descriptor_config.php
+++ b/Gax/tests/Conformance/src/V1beta1/resources/testing_descriptor_config.php
@@ -1,6 +1,6 @@
true,
];
diff --git a/dev/composer.json b/dev/composer.json
index 6c22b72e72a0..d462e10b3dd6 100644
--- a/dev/composer.json
+++ b/dev/composer.json
@@ -5,7 +5,7 @@
"php": ">=8.2",
"vierbergenlars/php-semver": "^3.0",
"symfony/console": " ^6.2",
- "symfony/yaml": "^3.3||^6.0",
+ "symfony/yaml": "^3.3||^5.2||^6.0",
"symfony/process": "^6.0",
"google/cloud": "dev-parent",
"symfony/filesystem": "^6.0",
@@ -21,6 +21,8 @@
}
},
"require-dev": {
+ "google/gapic-generator": "dev-main",
+ "google/gapic-showcase": "dev-main",
"phpunit/phpunit": "^9.0",
"phpspec/prophecy-phpunit": "^2.0",
"swaggest/json-schema": "^0.12.0",
@@ -37,6 +39,25 @@
"google/cloud": "dev-parent"
}
}
+ },
+ "gapic-generator": {
+ "type": "vcs",
+ "url": "https://github.com/googleapis/gapic-generator-php.git",
+ "options": {
+ "submodules": true
+ }
+ },
+ "gapic-showcase": {
+ "type": "package",
+ "package": {
+ "name": "google/gapic-showcase",
+ "version": "dev-main",
+ "source": {
+ "url": "https://github.com/googleapis/gapic-showcase.git",
+ "type": "git",
+ "reference": "main"
+ }
+ }
}
},
"config": {
diff --git a/dev/google-cloud b/dev/google-cloud
index 9ca23d233153..cf7e68d33daf 100755
--- a/dev/google-cloud
+++ b/dev/google-cloud
@@ -30,6 +30,7 @@ use Google\Cloud\Dev\Command\ComponentUpdateCommand;
use Google\Cloud\Dev\Command\ComponentUpdateReadmeSampleCommand;
use Google\Cloud\Dev\Command\ComponentUpdateDepsCommand;
use Google\Cloud\Dev\Command\DocFxCommand;
+use Google\Cloud\Dev\Command\ShowcaseGenerateCommand;
use Google\Cloud\Dev\Command\ReleaseInfoCommand;
use Google\Cloud\Dev\Command\ReleaseVerifyCommand;
use Google\Cloud\Dev\Command\RepoComplianceCommand;
@@ -55,6 +56,7 @@ $app->add(new ComponentUpdateCommand($rootDirectory));
$app->add(new ComponentUpdateReadmeSampleCommand($rootDirectory));
$app->add(new ComponentUpdateDepsCommand());
$app->add(new DocFxCommand());
+$app->add(new ShowcaseGenerateCommand($rootDirectory));
$app->add(new ReleaseInfoCommand());
$app->add(new ReleaseVerifyCommand());
$app->add(new RepoComplianceCommand());
diff --git a/dev/src/Command/ShowcaseGenerateCommand.php b/dev/src/Command/ShowcaseGenerateCommand.php
new file mode 100644
index 000000000000..d3bc3518c782
--- /dev/null
+++ b/dev/src/Command/ShowcaseGenerateCommand.php
@@ -0,0 +1,249 @@
+rootDirectory = rtrim($rootDirectory, '/') . '/';
+ $this->fs = new Filesystem();
+ parent::__construct();
+ }
+
+ protected function configure()
+ {
+ $this->setName('showcase:generate')
+ ->setDescription('Generates the GAPIC Showcase client SDK for Conformance tests')
+ ->addOption(
+ 'out-dir',
+ 'o',
+ InputOption::VALUE_REQUIRED,
+ 'Output directory relative to root (defaults to Gax)',
+ 'Gax'
+ )
+ ->addOption(
+ 'generator-path',
+ 'g',
+ InputOption::VALUE_REQUIRED,
+ 'Path to local gapic-generator repository (defaults to installed vendor dependency)'
+ )
+ ->addOption(
+ 'showcase-path',
+ 'p',
+ InputOption::VALUE_REQUIRED,
+ 'Path to local gapic-showcase repository (defaults to installed vendor dependency)'
+ )
+ ->addOption(
+ 'googleapis-path',
+ 'a',
+ InputOption::VALUE_REQUIRED,
+ 'Path to googleapis repository (defaults to submodule in gapic-generator)'
+ );
+ }
+
+ protected function execute(InputInterface $input, OutputInterface $output): int
+ {
+ $executableFinder = new ExecutableFinder();
+ if (!$executableFinder->find('protoc')) {
+ $output->writeln('