p4rtridge opened a new pull request, #4763:
URL: https://github.com/apache/iggy/pull/4763

   ## Which issue does this PR address?
   
   Closes #4749
   
   ## Rationale
   
   Personal access token names must contain 1–255 bytes. Invalid names were 
serialized without an error, and lengths above 255 wrapped the one-byte length 
prefix.
   
   ## What changed?
   
   Both create and delete commands now validate name length before 
serialization and return `ErrInvalidPersonalAccessTokenName` for invalid names. 
Named minimum and maximum constants follow the validation pattern in 
`update_resource.go`. The existing serialization test table now includes empty 
and oversized names.
   
   ## Local Execution
   
   - Go SDK tests and passed with `go test -count=1 -race ./...`.
   - prek hooks passed.
   
   ## AI Usage
   
   - Tool: Codex
   - Scope: Assisted with reviewing my changes
   - Verification: I compared the Go encoding and expected test bytes with 
`CreatePersonalAccessTokenRequest` and `WireName` in server's binary protocol, 
confirming the 1–255-byte name bounds, one-byte length prefix, and 
little-endian 64-bit expiry.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to