Skip to content

Commit

Permalink
Release v0.8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Jamil-Najafov authored Jan 30, 2024
2 parents 68a5b06 + c4300aa commit f400af5
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions inscacheable/cacheable.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ type Cacher[K comparable, V any] interface {
Set(k K, v V, ttl time.Duration)
Exists(k K) bool
Delete(k K)
Stop()
}

type Cache[K comparable, V any] struct {
Expand Down Expand Up @@ -38,6 +39,11 @@ func (c *Cache[K, V]) Delete(k K) {
c.cache.Delete(k)
}

// Stop stops the expired key clean-up.
func (c *Cache[K, V]) Stop() {
c.cache.Stop()
}

// Cacheable is the main function that should be used as
// func getter(key string) string { ... the original getter function ... }
// var ttl = 1 * time.Minute
Expand Down
2 changes: 1 addition & 1 deletion insredis/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ geospatial operations, and more.
To use this package, install it using Go modules:

```bash
go get github.com/useinsider/insredis
go get github.com/useinsider/go-pkg/insredis
```

## Usage
Expand Down
2 changes: 1 addition & 1 deletion insrequester/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ The insrequester package is designed to provide a resilient way to make HTTP req

```go
import (
"github.com/useinsider/insrequester"
"github.com/useinsider/go-pkg/insrequester"
)
```

Expand Down
2 changes: 1 addition & 1 deletion inssimpleroute/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"net/http"
"strings"

"github.com/useinsider/inssimpleroute"
"github.com/useinsider/go-pkg/inssimpleroute"
)

// Request type for the use case
Expand Down

0 comments on commit f400af5

Please sign in to comment.