feat(speech): generate bidi streaming methods and add integration test - #6477
feat(speech): generate bidi streaming methods and add integration test#6477suzmue wants to merge 5 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request enables bidirectional streaming for the google-cloud-speech-v2 crate, adding generated prost models, conversion helpers, and the streaming_recognize client method. It also introduces an integration test to verify the streaming functionality. The feedback recommends optimizing the integration test by using Bytes::slice to stream audio chunks without copying data, thereby avoiding unnecessary allocations.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6477 +/- ##
==========================================
- Coverage 96.51% 96.51% -0.01%
==========================================
Files 304 304
Lines 87943 87943
==========================================
- Hits 84881 84879 -2
- Misses 3062 3064 +2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
ed1a2a9 to
83fc6d9
Compare
|
|
||
| <!-- Code generated by sidekick. DO NOT EDIT. --> | ||
|
|
||
| **WARNING:** some RPCs have no corresponding Rust function to call them. |
| // limitations under the License. | ||
|
|
||
| pub mod error_details; | ||
| #[cfg(google_cloud_unstable_gapic_streaming)] |
There was a problem hiding this comment.
The changes in the README and using a #[cfg()] to get all the features is slightly odd.
There was a problem hiding this comment.
I agree 100%.
I plan to hold onto this change until after the release, so we don't make the README updates and will then have the config flags removed before the release that makes those updates.
Enable bidirectional streaming support for Google Cloud Speech v2 by setting include_bidi_streaming_methods: true in librarian.yaml, updating the librarian version, and regenerating the crate. Add a live integration test for Speech::streaming_recognize() that streams 4KB chunks from the public hello.wav sample, verifies bidirectional streaming lifecycle and half-closing, and validates that the transcribed text contains "hello".
Enable bidirectional streaming support for Google Cloud Speech v2 by setting
include_bidi_streaming_methods: trueinlibrarian.yamland regenerating the crate.Add a live integration test for
Speech::streaming_recognize()that streams 4KB chunks from the publichello.wavsample, verifies bidirectional streaming lifecycle and half-closing, and validates that the transcribed text contains "hello".