Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update fork #2

Open
wants to merge 36 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
8a8dbfb
chore: remove redundant type conversion (#541)
imxyb Dec 18, 2020
e2bc6db
chore: Remove unnecessary blank (_) identifier (#551)
withshubh Feb 16, 2021
dbd3ec6
chore: Enable golangci-lint and fix errors (#554)
stevenh Feb 18, 2021
9e4eba0
chore(docs): update godoc links (#482)
yjhmelody Feb 18, 2021
72af812
chore: Add clog config (#555)
stevenh Feb 18, 2021
46992b0
fix: DialURL compatibility with redis-cli (#566)
stevenh Jun 10, 2021
bf63cd5
feat: implement DialURLContext(...) (#574)
cameronelliott Sep 30, 2021
56d6448
feat: add DoContext and ReceiveContext (#537)
chenjie199234 Sep 30, 2021
574218b
fix: DoContext call to DoWithTimeout (#576)
stevenh Oct 15, 2021
cc6be48
fix(modules): upgrade testify
gkorland Dec 25, 2021
2fd670f
fix: retract tagged versions (#590)
stevenh Jan 4, 2022
a83ebbe
fix: surface underlying error for slice / map helpers (#580)
stevenh Jan 4, 2022
8eb5625
fix: correct instructions for detecting DialReadTimeout (#601)
pabigot Mar 14, 2022
3eb0774
feat: add RequestContext to PubSubConn (#603)
pabigot Mar 23, 2022
dbebed5
feat: add Float64Map (#605)
zuoshuwen Mar 24, 2022
dc67576
chore: add go test action (#607)
stevenh Mar 24, 2022
5b789c6
chore: refactor map helpers to reduce duplication (#606)
stevenh Mar 24, 2022
222ca62
fix: update golangci-lint for golang 1.18 (#616)
stevenh Jun 6, 2022
bcef0d8
fix: error message for SlowLog conversion (#612)
dmitri-lerko Jun 7, 2022
95c091f
fix: respect ctx in cmds run in DialContext (#620)
mitchsw Jul 1, 2022
2c2a5c2
chore: remove go1.7 and below support (#623)
stevenh Jul 1, 2022
d3b4cc3
fix: correct do script error check (#563)
wenpeng Jul 1, 2022
f1e923c
fix: Anonymous field pointers (#622)
stevenh Jul 6, 2022
d685447
feat: add support for latency command parsing (#614)
dmitri-lerko Jul 6, 2022
78e255f
fix: test goroutine leaks (#643)
stevenh May 11, 2023
a60882b
chore: update testify (#653)
stevenh Aug 20, 2023
9129745
core: update github actions and fix tests (#657)
stevenh Jan 29, 2024
8b1c13e
chore: run test server with enable-debug-command (#654)
elboulangero Feb 3, 2024
9f0d2e9
chore: remove debug check (#659)
stevenh Feb 3, 2024
1d393b3
feat: add TestOnBorrowContext (#660)
vasayxtx Feb 20, 2024
1bfd3c1
ci: add goreleaser, update action and go versions (#662)
stevenh Feb 20, 2024
cfabb1f
ci: remove deprecated goreleaser option (#663)
stevenh Feb 20, 2024
162ed02
chore: retract v1.8.10 (#664)
stevenh Feb 20, 2024
e05a63b
fix: bump go version to 1.17 (#666)
stevenh Feb 25, 2024
4c535aa
ci: fix go caching (#667)
stevenh Feb 25, 2024
247f6c0
chore: fix function name in comment (#668)
rustfix Apr 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .clog.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
[clog]
repository = "https://github.com/gomodule/redigo"
subtitle = "Release Notes"
from-latest-tag = true

[sections]
"Refactors" = ["refactor"]
"Chores" = ["chore"]
"Continuous Integration" = ["ci"]
"Improvements" = ["imp", "improvement"]
"Features" = ["feat", "feature"]
"Legacy" = ["legacy"]
"QA" = ["qa", "test"]
"Documentation" = ["doc", "docs"]
40 changes: 40 additions & 0 deletions .github/workflows/go-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: go-test
on:
push:
tags:
- v*
branches:
- master
pull_request:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
go-version:
- '1.21'
- '1.22'
os:
- 'ubuntu-latest'
redis:
- '7.2'
- '7.0'
- '6.2'
- '6.0'
name: Test go ${{ matrix.go-version }} redis ${{ matrix.redis }} on ${{ matrix.os }}
steps:
- name: Setup redis
uses: shogo82148/actions-setup-redis@v1
with:
redis-version: ${{ matrix.redis }}

- name: Checkout code
uses: actions/checkout@v4

- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}

- name: Go Test
run: go test -race ./...
32 changes: 32 additions & 0 deletions .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: golangci-lint
on:
push:
tags:
- v*
branches:
- master
pull_request:
jobs:
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup golang
uses: actions/setup-go@v4
with:
go-version: '1.22'
cache: false # Handled by golangci-lint.

- name: Validate go mod
run: |
go mod tidy
git --no-pager diff && [[ 0 -eq $(git status --porcelain | wc -l) ]]

- name: golangci-lint
uses: golangci/golangci-lint-action@v4
with:
version: v1.56.2
args: --out-format=colored-line-number
32 changes: 32 additions & 0 deletions .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Build Release

on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+*'

permissions:
contents: write

jobs:
goreleaser:
name: Release Go Binary
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.22'

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
46 changes: 46 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# When adding options check the documentation at https://goreleaser.com
builds:
- skip: true
release:
header: |
<a name='{{.Tag}}'></a>
### {{.Tag}} Release Notes ({{.Date}})
footer: |
[Full Changelog](https://{{ .ModulePath }}/compare/{{ .PreviousTag }}...{{ .Tag }})
changelog:
use: github
sort: asc
filters:
exclude:
- Merge pull request
- Merge remote-tracking branch
- Merge branch

# Group commits messages by given regex and title.
# Order value defines the order of the groups.
# Proving no regex means all commits will be grouped under the default group.
# Groups are disabled when using github-native, as it already groups things by itself.
# Matches are performed against strings of the form: "<abbrev-commit>[:] <title-commit>".
#
# Default is no groups.
groups:
- title: Features
regexp: '^.*?(feat|feature)(\([[:word:]]+\))??!?:.+$'
order: 0
- title: 'Bug fixes'
regexp: '^.*?fix(\([[:word:]]+\))??!?:.+$'
order: 1
- title: 'Chores'
regexp: '^.*?chore(\([[:word:]]+\))??!?:.+$'
order: 2
- title: 'Quality'
regexp: '^.*?(qa|test|tests)(\([[:word:]]+\))??!?:.+$'
order: 3
- title: 'Documentation'
regexp: '^.*?(doc|docs)(\([[:word:]]+\))??!?:.+$'
order: 4
- title: 'Continuous Integration'
regexp: '^.*?ci(\([[:word:]]+\))??!?:.+$'
order: 5
- title: Other
order: 999
21 changes: 10 additions & 11 deletions README.markdown
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
Redigo
======

[![Build Status](https://travis-ci.org/gomodule/redigo.svg?branch=master)](https://travis-ci.org/gomodule/redigo)
[![GoDoc](https://godoc.org/github.com/gomodule/redigo/redis?status.svg)](https://godoc.org/github.com/gomodule/redigo/redis)
[![GoDoc](https://godoc.org/github.com/gomodule/redigo/redis?status.svg)](https://pkg.go.dev/github.com/gomodule/redigo/redis)

Redigo is a [Go](http://golang.org/) client for the [Redis](http://redis.io/) database.

Features
-------

* A [Print-like](http://godoc.org/github.com/gomodule/redigo/redis#hdr-Executing_Commands) API with support for all Redis commands.
* [Pipelining](http://godoc.org/github.com/gomodule/redigo/redis#hdr-Pipelining), including pipelined transactions.
* [Publish/Subscribe](http://godoc.org/github.com/gomodule/redigo/redis#hdr-Publish_and_Subscribe).
* [Connection pooling](http://godoc.org/github.com/gomodule/redigo/redis#Pool).
* [Script helper type](http://godoc.org/github.com/gomodule/redigo/redis#Script) with optimistic use of EVALSHA.
* [Helper functions](http://godoc.org/github.com/gomodule/redigo/redis#hdr-Reply_Helpers) for working with command replies.
* A [Print-like](https://pkg.go.dev/github.com/gomodule/redigo/redis#hdr-Executing_Commands) API with support for all Redis commands.
* [Pipelining](https://pkg.go.dev/github.com/gomodule/redigo/redis#hdr-Pipelining), including pipelined transactions.
* [Publish/Subscribe](https://pkg.go.dev/github.com/gomodule/redigo/redis#hdr-Publish_and_Subscribe).
* [Connection pooling](https://pkg.go.dev/github.com/gomodule/redigo/redis#Pool).
* [Script helper type](https://pkg.go.dev/github.com/gomodule/redigo/redis#Script) with optimistic use of EVALSHA.
* [Helper functions](https://pkg.go.dev/github.com/gomodule/redigo/redis#hdr-Reply_Helpers) for working with command replies.

Documentation
-------------

- [API Reference](http://godoc.org/github.com/gomodule/redigo/redis)
- [API Reference](https://pkg.go.dev/github.com/gomodule/redigo/redis)
- [FAQ](https://github.com/gomodule/redigo/wiki/FAQ)
- [Examples](https://godoc.org/github.com/gomodule/redigo/redis#pkg-examples)
- [Examples](https://pkg.go.dev/github.com/gomodule/redigo/redis#pkg-examples)

Installation
------------
Expand All @@ -35,7 +34,7 @@ The Go distribution is Redigo's only dependency.
Related Projects
----------------

- [rafaeljusto/redigomock](https://godoc.org/github.com/rafaeljusto/redigomock) - A mock library for Redigo.
- [rafaeljusto/redigomock](https://pkg.go.dev/github.com/rafaeljusto/redigomock) - A mock library for Redigo.
- [chasex/redis-go-cluster](https://github.com/chasex/redis-go-cluster) - A Redis cluster client implementation.
- [FZambia/sentinel](https://github.com/FZambia/sentinel) - Redis Sentinel support for Redigo
- [mna/redisc](https://github.com/mna/redisc) - Redis Cluster client built on top of Redigo
Expand Down
16 changes: 14 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
module github.com/gomodule/redigo

go 1.14
go 1.17

require github.com/stretchr/testify v1.5.1
require github.com/stretchr/testify v1.8.4

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

retract (
v2.0.0+incompatible // Old development version not maintained or published.
v1.8.10 // Incorrect version tag for feature.
v0.0.0-do-not-use // Never used only present due to lack of retract.
)
16 changes: 11 additions & 5 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/testify v1.5.1 h1:nOGnQDM7FYENwehXlg/kFVnos3rEvtKTjRvOWSzb6H4=
github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v2 v2.2.2 h1:ZCJp+EgiOT7lHqUV2J862kp8Qj64Jo6az82+3Td9dZw=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
Loading