Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store is a Redis storage adapter for hap.Server.
func NewStore ¶
NewStore creates a Redis adapter that conforms to hap.Store.
Set its context to the server's context to cancel stuck Redis operations when the server is shut down, or to context.Background() when no ordinary shutdown is implemented.
The client instance must be created through go-redis.
The prefix must be unique for your hap server instance. It is convention to use a colon symbol as separator in Redis keys. The prefix length is irrelevant with the amount of data stored by hap. An example for a short and nice prefix is "fooapp:barhost:", where barhost is a hostname.
Click to show internal directories.
Click to hide internal directories.