implement queue in data storage
Open
- Dominant language
- Go
- Stars
- 9.8k
- Forks
- 912
- Avg merge
- 2h 35m
- Merged PRs (30d)
- 9
Description
## Background
In Gorse v0.4.x, neighbors, and models are not updated until the next round of full dataset loading. In practice, it would be better to update neighbors or models once a new user, item, or feedback is inserted. A queue is required to achieve this goal.
## Design
```go
type Database interface {
// Enqueue put the value to the back of a named queue.
Enqueue(name, value string) error
// Dequeue remove the front value of a named queue and return this value.
// If no value in the queue, return io.EOF.
Dequeue(name string) (value string, err error)
}
```
Contributor guide
Assessment
This issue has not been assessed yet.