Skip to content

v6.3.1 Release

Latest

Choose a tag to compare

@github-actions github-actions released this 14 Nov 15:41
b28e8bd

6.3.1 is a patch release. It stops a malformed API key from appearing in exception messages and logs, and fixes three bugs: async writes lost on close(), ids with an unpaired surrogate overwriting each other, and a ResponseMetadataListener that could hang a call. No method signatures changed. Three error cases are now handled more strictly: build() rejects an API key that could never have worked, calls reject ids and namespaces that were being silently rewritten, and close() waits up to 5 seconds for in-flight calls.

What to do

  • Upgrade to 6.3.1.
  • If your API key has ever had leading or trailing whitespace, a newline or a tab (common when it is read from a file or a Kubernetes secret), search your logs and error tracker for it and rotate it. Details under Security.
  • If you build ids or namespaces with substring or other truncation, expect PineconeValidationException where a split emoji used to be stored as ?.

Security

  • A malformed API key is no longer echoed into exception messages and logs. (f75a19c)
    • Affected: applications whose API key has leading or trailing whitespace or control characters, typically a trailing newline from a file or a Kubernetes secret.
    • Risk: before 6.3.1, Pinecone.Builder.build() accepted such a key. With a newline, every later call threw an IllegalArgumentException whose message contained the full key. With a tab, gRPC dropped the api-key header and logged the key, with no exception. Log aggregators and error trackers may hold a copy.
    • Fix: build() now trims surrounding whitespace and control characters and logs a warning that does not include the key. After trimming, a key that is empty or contains anything other than printable ASCII (such as an embedded newline or a pasted smart quote) is rejected at build() with a PineconeConfigurationException that does not echo it.
    • Action: if your key ever had such characters, whether or not you saw errors, search your logs and error tracker for it and rotate it in the Pinecone console.

Fixes

  • Async writes are no longer lost on close(). Index.close() and AsyncIndex.close() cancelled any call still running when they shut down the gRPC channel, so fire-and-forget async upserts failed with CANCELLED or UNAVAILABLE. Calls already issued now get up to 5 seconds to finish before any still running are cancelled, and closing the last index object on a connection can block that long. Waiting on your futures before closing is still the safe pattern. (b0173a8)
  • Ids and namespaces with an unpaired surrogate are rejected instead of rewritten. A string with half an emoji (such as "x\uD83D", left when a substring splits one) was sent as ?, so "x\uD83D" and "x\uDE00" were both stored as "x?" and overwrote each other. These values now throw PineconeValidationException before the request is sent, for upsert, query, fetch, update, delete, upsertRecords, the namespace calls and list prefixes. On AsyncIndex the exception is thrown by the call itself, not through the returned future. Well-formed emoji are unaffected. (5743f8c, 7553fa2)
  • A ResponseMetadataListener that throws an Error no longer hangs the call. An Error such as a JUnit AssertionError thrown by the listener made the Index call block forever, or the AsyncIndex future never complete. It is now logged and ignored, as exceptions already were, so an assertion inside a listener no longer fails the call. Separately, fetchByMetadata calls now report to the listener with operation name fetchbymetadata. (6dbd0b8)
  • README configure examples keep deletion protection on. The "Scale replicas" and "Configure read capacity" examples passed "disabled" for deletion protection, which disabled the protection the create example enables. They now pass null, which keeps the current setting. If you copied them, check your index with describeIndex and re-enable deletion protection if you want it. Docs only, no library change. (12e7eb4)

Upgrading

<dependency>
  <groupId>io.pinecone</groupId>
  <artifactId>pinecone-client</artifactId>
  <version>6.3.1</version>
</dependency>
implementation "io.pinecone:pinecone-client:6.3.1"

6.3.1 is signed with the same key as 6.3.0 (68D9 DCB2 AB93 7981 13C2 9B8D A87E C316 B916 2471).

Full Changelog: v6.3.0...v6.3.1