forked from etcd-io/etcd
-
Notifications
You must be signed in to change notification settings - Fork 22
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
OCPBUGS-861: Rebase openshift/etcd 4.12 onto v3.5.5 #144
Merged
openshift-merge-robot
merged 94 commits into
openshift:openshift-4.12
from
tjungblu:rebase-3.5.4-forkpoint
Oct 7, 2022
Merged
Changes from all commits
Commits
Show all changes
94 commits
Select commit
Hold shift + click to select a range
7656477
Revert "trim the suffix dot from the srv.Target for etcd-client DNS l…
liggitt 081b4e2
Add unit test for canonical SRV records
liggitt b872757
Merge pull request #13950 from liggitt/revert-srv-dot-3.5
ptabor 5c68f2e
Update conssitent_index when applying fails
ahrtr c3c908e
Merge pull request #13946 from ahrtr/move_cindex_on_apply_fail_353
serathius 08407ff
version: bump up to 3.5.4
serathius 5c44c30
Update golang.org/x/crypto to latest
cmurphy 8453b10
Merge pull request #13996 from cmurphy/update-crypto-3.5
ptabor cceb25d
server/auth: enable tokenProvider if recoved store enables auth
cfz b57881a
Merge pull request #13205 from cfz/cherry-pick-#13172
ptabor c76a010
scripts: Add tests for release scripts
serathius c4b0a56
Make DRY_RUN explicit
serathius 2e76dfb
Merge pull request #14043 from serathius/test-release-3.5-v2
serathius c05b9b1
scripts: Avoid additional repo clone
serathius 6aa934e
scripts: Detect staged files before building release
serathius 73876b1
Merge pull request #14050 from serathius/avoid-clone-v3.5
serathius acb1ee9
Backport two lease related bug fixes to 3.5
ahrtr 0be65da
Merge pull request #14087 from ahrtr/lease_revoke_race
serathius db0b67e
Add FileReader and FileBufReader utilities
ahrtr 621cd7b
restrict the max size of each WAL entry to the remaining size of the …
ahrtr 4443e14
Merge pull request #14127 from ahrtr/threshold_3.5
ahrtr df632ab
client/v3: do not overwrite authTokenBundle on dial
ahrtr c9f7473
Merge pull request #14132 from ahrtr/auth_bundle
serathius 4df61af
Client: fix check for WithPrefix op
spzala 57c1d92
Merge pull request #14187 from spzala/automated-cherry-pick-of-#14182…
ahrtr 40d1a43
add the uint32Value data type
ahrtr 437f377
Add flag `--max-concurrent-streams` to set the max concurrent stream …
ahrtr ff447b4
add e2e test cases to cover the maxConcurrentStreams
ahrtr fb71790
Merge pull request #14219 from ahrtr/3.5_backport_maxstream
ahrtr cbedaf9
Improve error message for incorrect values of ETCD_CLIENT_DEBUG
Jille 3237289
Merge pull request #14222 from Jille/backport-14203
ahrtr e15c005
server/auth: protect rangePermCache with a RW lock
mitake 9d7e108
Merge pull request #14227 from mitake/perm-cache-lock-3.5
serathius 4c013c9
Change default sampling rate from 100% to 0%
damemi 6145831
Merge pull request #14318 from damemi/3.5-tracing-sample
ahrtr 2d7e490
etcdserver: bump OpenTelemetry to 1.0.1
ahrtr 5a86ae2
move setupTracing into a separate file config_tracing.go
ahrtr 2751c61
update all related dependencies
ahrtr 8c5f110
Fix the failure in TestEndpointSwitchResolvesViolation
ahrtr 8fdca41
Change default sampling rate from 100% to 0%
ahrtr 9e95685
Merge pull request #14312 from ahrtr/3.5_bump_otl
ahrtr eab0b99
clientv3: close streams after use in lessor keepAliveOnce method
amdprophet 6bab367
Merge pull request #14361 from amdprophet/3.5-close-keepalive-stream
ahrtr 9ea5b1b
Refactor the keepAliveListener and keepAliveConn
ahrtr 74aa38e
Merge pull request #14366 from ahrtr/keepalive_3.5_20220820
ahrtr 67e4c59
Backport of pull/14354 to 3.5.5
biosvs 204d883
[backport 3.5] server: don't panic in readonly serializable txn
fbb14f9
Merge pull request #14397 from biosvs/backport-grpc-proxy-endpoints-a…
serathius 7eb696d
fix the potential data loss for clusters with only one member
ahrtr 747bf5c
Merge pull request #14424 from serathius/one_member_data_loss_raft_3_5
ahrtr 5c8aa08
move consistent_index forward when executing alarmList operation
ahrtr 204c031
Merge pull request #14429 from ahrtr/alarm_list_ci_3.5
ahrtr d32de2c
server: Extract triggerCorruptAlarm to function
serathius 35cbdf3
server: Extract corruption detection to dedicated struct
serathius 78a6f38
server: Cover corruptionMonitor with tests
serathius 336fef4
server: Test HashByRev values to make sure they don't change
serathius bc592c7
server: Extract unsafeHashByRev function
serathius 3f26995
server: Move unsafeHashByRev to new hash.go file
serathius f5ed371
server: Extract kvHash struct
serathius 679e327
server: Refactor hasher
serathius 22d3e4e
server: Return error from scheduleCompaction
serathius ea684db
server: Move reading KV index inside scheduleCompaction function
serathius f1a759a
server: Fix range in mock not returning same number of keys and values
serathius 21e5d5d
server: Calculate hash during compaction
serathius 2b8dd0d
server: Pass revision as int
serathius 991b429
server: Move adjusting revision to hasher
serathius 1ff5992
server: Store real rv range in hasher
serathius a3f609d
server: Return revision range that hash was calcualted for
serathius 6311072
server: Remove duplicated compaction revision
serathius 7358362
server: Extract hasher to separate interface
serathius 1200b10
server: Cache compaction hash for HashByRev API
serathius d3db3bc
tests: Add integration tests for compact hash
serathius 00bc8da
tests: Add tests for HashByRev HTTP API
serathius 037a898
tests: Unify TestCompactionHash and extend it to also Delete keys and…
serathius a8020a0
tests: Rename corruptHash to CorruptBBolt
serathius 8d4ca10
tests: Move CorruptBBolt to testutil
serathius 4a75e3d
server: Refactor compaction checker
serathius a56ec0b
tests: Cover periodic check in tests
serathius 21fb173
server: Implement compaction hash checking
serathius 5660bf0
server: Make corrtuption check optional and period configurable
serathius 2ddb9e0
tests: Fix member id in CORRUPT alarm
serathius ba52d5a
Merge pull request #14282 from serathius/fix-checks-v3.5
serathius c79f96d
server/etcdmain: add build support for Apple M1
dbussink 7639d93
server,test: refresh cache on each NewAuthStore
bb3fae4
Merge pull request #14409 from vivekpatani/release-3.5
mitake a5a33cb
Merge pull request #14436 from serathius/arm64
ahrtr eef5e22
testing: fix TestOpenWithMaxIndex cleanup
vsvastey 16d72c0
Merge pull request #14440 from vsvastey/usr/vsvastey/open-with-max-in…
ahrtr 243b7a1
etcdctl: fix move-leader for multiple endpoints
tjungblu 646ba66
Merge pull request #14434 from tjungblu/bz_1918413_3.5
ahrtr 6c26693
Merge pull request #14178 from lavacat/release-3.5-txn-panic
ahrtr 2f1171f
fix the flaky test fix_TestV3AuthRestartMember_20220913 for 3.5
ahrtr 2ba1bab
Merge pull request #14454 from ahrtr/fix_TestV3AuthRestartMember_2022…
ahrtr 19002cf
version: bump up to 3.5.5
serathius File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: Release | ||
on: [push, pull_request] | ||
jobs: | ||
main: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-go@v2 | ||
with: | ||
go-version: "1.16.15" | ||
- run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "Github Action" | ||
gpg --batch --gen-key <<EOF | ||
%no-protection | ||
Key-Type: 1 | ||
Key-Length: 2048 | ||
Subkey-Type: 1 | ||
Subkey-Length: 2048 | ||
Name-Real: Github Action | ||
Name-Email: [email protected] | ||
Expire-Date: 0 | ||
EOF | ||
DRY_RUN=true BRANCH=release-3.5 ./scripts/release --no-upload --no-docker-push 3.5.99 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
// Copyright 2022 The etcd Authors | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
package fileutil | ||
|
||
import ( | ||
"bufio" | ||
"io" | ||
"io/fs" | ||
"os" | ||
) | ||
|
||
// FileReader is a wrapper of io.Reader. It also provides file info. | ||
type FileReader interface { | ||
io.Reader | ||
FileInfo() (fs.FileInfo, error) | ||
} | ||
|
||
type fileReader struct { | ||
*os.File | ||
} | ||
|
||
func NewFileReader(f *os.File) FileReader { | ||
return &fileReader{f} | ||
} | ||
|
||
func (fr *fileReader) FileInfo() (fs.FileInfo, error) { | ||
return fr.Stat() | ||
} | ||
|
||
// FileBufReader is a wrapper of bufio.Reader. It also provides file info. | ||
type FileBufReader struct { | ||
*bufio.Reader | ||
fi fs.FileInfo | ||
} | ||
|
||
func NewFileBufReader(fr FileReader) *FileBufReader { | ||
bufReader := bufio.NewReader(fr) | ||
fi, err := fr.FileInfo() | ||
if err != nil { | ||
// This should never happen. | ||
panic(err) | ||
} | ||
return &FileBufReader{bufReader, fi} | ||
} | ||
|
||
func (fbr *FileBufReader) FileInfo() fs.FileInfo { | ||
return fbr.fi | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
// Copyright 2022 The etcd Authors | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
package fileutil | ||
|
||
import ( | ||
"os" | ||
"strings" | ||
"testing" | ||
|
||
"github.com/stretchr/testify/assert" | ||
) | ||
|
||
func TestFileBufReader(t *testing.T) { | ||
f, err := os.CreateTemp(t.TempDir(), "wal") | ||
if err != nil { | ||
t.Errorf("Unexpected error: %v", err) | ||
} | ||
fi, err := f.Stat() | ||
if err != nil { | ||
t.Errorf("Unexpected error: %v", err) | ||
} | ||
|
||
fbr := NewFileBufReader(NewFileReader(f)) | ||
|
||
if !strings.HasPrefix(fbr.FileInfo().Name(), "wal") { | ||
t.Errorf("Unexpected file name: %s", fbr.FileInfo().Name()) | ||
} | ||
assert.Equal(t, fi.Size(), fbr.FileInfo().Size()) | ||
assert.Equal(t, fi.IsDir(), fbr.FileInfo().IsDir()) | ||
assert.Equal(t, fi.Mode(), fbr.FileInfo().Mode()) | ||
assert.Equal(t, fi.ModTime(), fbr.FileInfo().ModTime()) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi -- are there 2 flags for darwin amd64?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That second arch flag for darwin is
arm64
notamd64
i.e Apple Silicon or M1 cpus:https://tip.golang.org/doc/go1.16#ports
etcd-io#14436
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep etcd 3.5.5 has m1 support now