open-feature / open-feature/php-sdk

[FEATURE] Support of Caching PSR-16

Open
#106 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement Needs Triage
Dominant language
PHP
Stars
43
Forks
14
Avg merge
4d 12h
Merged PRs (30d)
4

Description

Requirements

It would be nice if the SDK would support caching of the flag requests.
For example add a psr/simple-cache compatible cache storage and then store the results for better performance.
This way not every provider has to implement its own caching.

I looked into hooks but as far as I understand its not possible to implement a caching hook.
The return type is always just an EvaluationContext so its not possible to prevent requesting within a hook.

Contributor guide

Open the contributing guide

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

No files, tests, or entry points are named. Start by mapping the SDK's flag-request flow and the hook return type described in the issue, then compare that flow with the PSR-16/simple-cache contract. Define the cache boundary, expiry behavior, and provider-independent tests; done means repeated flag requests can use shared caching without provider-specific implementations.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.