configcatcache

package
v9.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 11, 2024 License: MIT Imports: 6 Imported by: 3

Documentation

Overview

Package configcatcache holds utility functions for the SDK's caching.

Index

Constants

View Source
const ConfigJSONCacheVersion = "v2"
View Source
const ConfigJSONName = "config_v6.json"

Variables

This section is empty.

Functions

func CacheSegmentsFromBytes

func CacheSegmentsFromBytes(cacheBytes []byte) (fetchTime time.Time, eTag string, config []byte, err error)

CacheSegmentsFromBytes deserializes a cache entry from a specific format used by the SDK.

func CacheSegmentsToBytes

func CacheSegmentsToBytes(fetchTime time.Time, eTag string, config []byte) []byte

CacheSegmentsToBytes serializes the input parameters to a specific format used for caching by the SDK.

func ProduceCacheKey

func ProduceCacheKey(sdkKey string, configJSONName string, cacheVersion string) string

ProduceCacheKey constructs a cache key from an SDK key used to identify a cache entry.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL