llmware-ai / llmware-ai/llmware

Add CLIENT SETNAME to Valkey client for connection identification

Open Beginner friendly
#1,303 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
14.8k
Forks
2.9k
PR merge metrics
No merged PRs in 30d

Description

## Summary

The llmware Valkey embeddings integration creates a `GlideClient` without setting a `client_name`. This means connections appear anonymous in monitoring tools like `CLIENT LIST` and Valkey Admin.

## Suggested Fix

In [`tests/embeddings/test_valkey_embeddings.py` (line ~37)](https://github.com/llmware-ai/llmware/blob/3b848a4d2d5c11c0071ee413add4a04276d9112d/tests/embeddings/test_valkey_embeddings.py#L37), add `client_name` to the `GlideClientConfiguration`:

```python
cfg = GlideClientConfiguration(
[NodeAddress(host, port)],
client_name="llmware_embedding_client",
)
```

## Why This Matters

When monitoring a Valkey server with multiple connected applications, `CLIENT LIST` shows each connection's name. Without a client name, operators cannot distinguish llmware connections from other anonymous clients. This is especially important in production environments with ElastiCache where multiple services share the same Valkey cluster.

Setting `client_name` sends a `CLIENT SETNAME` command on connection, making the connection identifiable in:
- `CLIENT LIST` output
- Monitoring dashboards (e.g., Valkey Admin)
- CloudWatch metrics (ElastiCache)

## Naming Convention

Suggested client name: `llmware_embedding_client`

Pattern: `{project}_{purpose}_client`
- `llmware` = project name
- `embedding` = purpose (embedding storage and retrieval)
- `_client` = convention (matches Valkey Admin naming pattern)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in tests/embeddings/test_valkey_embeddings.py around the GlideClientConfiguration setup and review how the Valkey embedding client is configured. Run the relevant embeddings test, then verify the connection uses the requested llmware_embedding_client name in Valkey monitoring output.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
databases
Issue type
Feature
Difficulty
1/5
Estimated time
Under an hour
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
88/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.