Skip to content

Add Resource::waiting($read, $connect) to set timeouts - #23

Merged
thekid merged 1 commit into
mainfrom
feature/timeouts
Jul 27, 2026
Merged

Add Resource::waiting($read, $connect) to set timeouts#23
thekid merged 1 commit into
mainfrom
feature/timeouts

Conversation

@thekid

@thekid thekid commented Jul 27, 2026

Copy link
Copy Markdown
Member

Example:

use com\amazon\aws\{ServiceEndpoint, CredentialProvider};

$runtime= (new ServiceEndpoint('bedrock', CredentialProvider::default()))
  ->using('bedrock-runtime.')
  ->in('eu-central-1')
;

$response= $runtime
  ->resource('/model/{0}/converse-stream', [$model])
  ->waiting(read: 600, connect: 4) // <-- here!
  ->transmit($context)
;

See xp-forge/rest-client#24

@thekid
thekid merged commit bf839d4 into main Jul 27, 2026
16 checks passed
@thekid
thekid deleted the feature/timeouts branch July 27, 2026 19:04
@thekid

thekid commented Jul 27, 2026

Copy link
Copy Markdown
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant