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

RC/Sirius patch 2 #5816

Merged
merged 70 commits into from
Feb 2, 2024
Merged
Changes from 13 commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
cb14bf3
- fixed the log.Warn in esdt.go - getSpecialRoles
iulianpascalau Jan 5, 2024
5251b8e
Merge branch 'master' into non-critical-fixes-sirius-2023.01.05
iulianpascalau Jan 5, 2024
b52d783
- made the dbConfigHandler more robust
iulianpascalau Jan 5, 2024
e799743
- fixes after review
iulianpascalau Jan 5, 2024
4790f86
- fixes after review
iulianpascalau Jan 5, 2024
d1fe13e
- fixed comments
iulianpascalau Jan 8, 2024
3d35226
Merge pull request #5812 from multiversx/fix-prefs-toml-comments
iulianpascalau Jan 8, 2024
f524255
Merge branch 'rc/sirius-patch-2' into non-critical-fixes-sirius-2023.…
iulianpascalau Jan 8, 2024
0c17fc8
Merge pull request #5805 from multiversx/non-critical-fixes-sirius-20…
iulianpascalau Jan 9, 2024
3ffb1df
send invalid signers from leader
sstanculeanu Jan 9, 2024
aaa62e1
redundancy node should not send invalid signers
sstanculeanu Jan 9, 2024
53ad9b3
fixed tests
sstanculeanu Jan 9, 2024
2b34ce7
fix after review
sstanculeanu Jan 9, 2024
034fb59
- fixed assessment tool
iulianpascalau Jan 10, 2024
8d177e1
Merge pull request #5820 from multiversx/fix-assessment-tool
iulianpascalau Jan 10, 2024
cc43302
- fixed the redundancy metric to include the multikey status
iulianpascalau Jan 12, 2024
161452b
Merge branch 'rc/sirius-patch-2' into fix-redundancy-metric
iulianpascalau Jan 12, 2024
a0fcccb
change indexer version
miiu96 Jan 12, 2024
6622473
Merge remote-tracking branch 'origin/master' into update-rc-sirius-pa…
iulianpascalau Jan 12, 2024
29ffc47
Merge pull request #5831 from multiversx/update-rc-sirius-patch-2023.…
iulianpascalau Jan 15, 2024
f037a6f
Merge branch 'rc/sirius-patch-2' into fix-redundancy-metric
iulianpascalau Jan 15, 2024
3121214
fixes after review
sstanculeanu Jan 15, 2024
624cbd5
Merge branch 'rc/sirius-patch-2' into fix_multikey_invalid_signers
sstanculeanu Jan 15, 2024
633c9a6
Merge branch 'rc/sirius-patch-2' into upgrade-indexer-version-sirius
gabi-vuls Jan 15, 2024
96d32fb
verify header hash
AdoAdoAdo Jan 15, 2024
5f981bc
proper tag
miiu96 Jan 16, 2024
7177707
Merge pull request #5829 from multiversx/fix-redundancy-metric
iulianpascalau Jan 16, 2024
fa3adb1
Merge branch 'rc/sirius-patch-2' into verify-hash
iulianpascalau Jan 16, 2024
daa6651
Merge pull request #5836 from multiversx/verify-hash
iulianpascalau Jan 16, 2024
7e3c244
Merge branch 'rc/sirius-patch-2' into upgrade-indexer-version-sirius
iulianpascalau Jan 16, 2024
a7707af
Merge pull request #5830 from multiversx/upgrade-indexer-version-sirius
iulianpascalau Jan 16, 2024
d5d23aa
Merge branch 'rc/sirius-patch-2' into fix_multikey_invalid_signers
sstanculeanu Jan 16, 2024
83a95f0
Merge branch 'master' into update-master-rc-sirius-patch2-2023.01.16
iulianpascalau Jan 16, 2024
0e20091
Merge pull request #5817 from multiversx/fix_multikey_invalid_signers
sstanculeanu Jan 16, 2024
179470f
Merge branch 'rc/sirius-patch-2' into update-master-rc-sirius-patch2-…
iulianpascalau Jan 16, 2024
e8bccc0
- fixed wrong backup machine step-in by correctly resetting counters …
iulianpascalau Jan 16, 2024
7cf5d48
Merge branch 'rc/sirius-patch-2' into fix-wrong-backup-step-in
iulianpascalau Jan 16, 2024
5042328
- fix after merge
iulianpascalau Jan 16, 2024
e9ad64c
- fixes after review: renaming + code optimization
iulianpascalau Jan 17, 2024
9d88539
Merge pull request #5838 from multiversx/update-master-rc-sirius-patc…
iulianpascalau Jan 17, 2024
3de2f82
Merge branch 'master' into update-master-rc-sirius-patch-2-2023.01.17
iulianpascalau Jan 17, 2024
6e6d2cb
- proper releases
iulianpascalau Jan 17, 2024
f69b0fd
remove suffix when migrating from NotSpecified to AutoBalanceEnabled …
BeniaminDrasovean Jan 17, 2024
ef869b7
fix imports
BeniaminDrasovean Jan 17, 2024
8ed7c58
Merge branch 'rc/sirius-patch-2' into fix-wrong-backup-step-in
iulianpascalau Jan 17, 2024
d91ac82
fix tests
BeniaminDrasovean Jan 18, 2024
54775cd
move hostParameters to common
ssd04 Jan 18, 2024
45ba97d
update assessment
ssd04 Jan 18, 2024
639da41
cpu flags checks
ssd04 Jan 18, 2024
2bc1c58
- fix after review
iulianpascalau Jan 18, 2024
0db2dc0
use cpuid implementation for cpu flags check
ssd04 Jan 19, 2024
da2544a
fix typo
ssd04 Jan 19, 2024
c580833
add integration tests
BeniaminDrasovean Jan 19, 2024
f362608
change enable epoch for migrateDataTrie
BeniaminDrasovean Jan 19, 2024
685b847
add cpu flags to config
ssd04 Jan 22, 2024
64ca8a0
use ParseFeature func from cpuid
ssd04 Jan 22, 2024
dbf6d2e
Merge pull request #5842 from multiversx/update-master-rc-sirius-patc…
iulianpascalau Jan 22, 2024
9ee2c79
Merge branch 'rc/sirius-patch-2' into migrate-data-trie-fix
BeniaminDrasovean Jan 22, 2024
a9a630a
linter fix
BeniaminDrasovean Jan 22, 2024
728c22b
Merge branch 'rc/sirius-patch-2' into hardware-requirements-checks
ssd04 Jan 22, 2024
e0566b9
update go mod
BeniaminDrasovean Jan 22, 2024
40d73dd
update enable flags
BeniaminDrasovean Jan 22, 2024
c84a6e6
Merge pull request #5852 from multiversx/hardware-requirements-checks
ssd04 Jan 23, 2024
7cab217
Merge branch 'rc/sirius-patch-2' into fix-wrong-backup-step-in
iulianpascalau Jan 23, 2024
4cea6b5
Merge pull request #5840 from multiversx/fix-wrong-backup-step-in
iulianpascalau Jan 23, 2024
8be2796
Merge branch 'rc/sirius-patch-2' into migrate-data-trie-fix
BeniaminDrasovean Jan 25, 2024
8fb567d
use proper releases in go mod
BeniaminDrasovean Jan 25, 2024
86575d4
Merge pull request #5849 from multiversx/migrate-data-trie-fix
iulianpascalau Jan 25, 2024
591433d
- fixed the multikey backup step-in
iulianpascalau Jan 26, 2024
b3f8514
Merge pull request #5882 from multiversx/fix-multikey-step-in
iulianpascalau Jan 30, 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
2 changes: 1 addition & 1 deletion cmd/assessment/main.go
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@ import (
"github.com/multiversx/mx-chain-core-go/core"
"github.com/multiversx/mx-chain-go/cmd/assessment/benchmarks"
"github.com/multiversx/mx-chain-go/cmd/assessment/benchmarks/factory"
"github.com/multiversx/mx-chain-go/cmd/assessment/hostParameters"
"github.com/multiversx/mx-chain-go/common/hostParameters"
logger "github.com/multiversx/mx-chain-logger-go"
"github.com/urfave/cli"
)
11 changes: 7 additions & 4 deletions cmd/node/config/config.toml
Original file line number Diff line number Diff line change
@@ -35,10 +35,13 @@
# SyncProcessTimeInMillis is the value in milliseconds used when processing blocks while synchronizing blocks
SyncProcessTimeInMillis = 12000

# SetGuardianEpochsDelay represents the delay in epochs between the execution time of the SetGuardian transaction and
# the activation of the configured guardian.
# Make sure that this is greater than the unbonding period!
SetGuardianEpochsDelay = 2 # TODO: for mainnet should be 20, 2 is just for testing
# SetGuardianEpochsDelay represents the delay in epochs between the execution time of the SetGuardian transaction and
# the activation of the configured guardian.
# Make sure that this is greater than the unbonding period!
SetGuardianEpochsDelay = 2 # TODO: for mainnet should be 20, 2 is just for testing

[HardwareRequirements]
CPUFlags = ["SSE4", "SSE42"]

[Versions]
DefaultVersion = "default"
32 changes: 32 additions & 0 deletions cmd/node/main.go
Original file line number Diff line number Diff line change
@@ -6,6 +6,7 @@ import (
"runtime"
"time"

"github.com/klauspost/cpuid/v2"
"github.com/multiversx/mx-chain-core-go/core"
"github.com/multiversx/mx-chain-core-go/core/check"
"github.com/multiversx/mx-chain-go/cmd/node/factory"
@@ -129,6 +130,11 @@ func startNodeRunner(c *cli.Context, log logger.Logger, baseVersion string, vers
cfgs.FlagsConfig.BaseVersion = baseVersion
cfgs.FlagsConfig.Version = version

err = checkHardwareRequirements(cfgs.GeneralConfig.HardwareRequirements)
if err != nil {
return fmt.Errorf("Hardware Requirements checks failed: %s", err.Error())
}

nodeRunner, errRunner := node.NewNodeRunner(cfgs)
if errRunner != nil {
return errRunner
@@ -301,3 +307,29 @@ func attachFileLogger(log logger.Logger, flagsConfig *config.ContextFlagsConfig)

return fileLogging, nil
}

func checkHardwareRequirements(cfg config.HardwareRequirementsConfig) error {
cpuFlags, err := parseFeatures(cfg.CPUFlags)
if err != nil {
return err
}

if !cpuid.CPU.Supports(cpuFlags...) {
return fmt.Errorf("CPU Flags: Streaming SIMD Extensions 4 required")
}

return nil
}

func parseFeatures(features []string) ([]cpuid.FeatureID, error) {
flags := make([]cpuid.FeatureID, 0)

for _, cpuFlag := range features {
featureID := cpuid.ParseFeature(cpuFlag)
if featureID == cpuid.UNKNOWN {
return nil, fmt.Errorf("CPU Flags: cpu flag %s not found", cpuFlag)
}
}

return flags, nil
}
File renamed without changes.
File renamed without changes.
24 changes: 15 additions & 9 deletions config/config.go
Original file line number Diff line number Diff line change
@@ -190,15 +190,16 @@ type Config struct {
PublicKeyPIDSignature CacheConfig
PeerHonesty CacheConfig

Antiflood AntifloodConfig
WebServerAntiflood WebServerAntifloodConfig
ResourceStats ResourceStatsConfig
HeartbeatV2 HeartbeatV2Config
ValidatorStatistics ValidatorStatisticsConfig
GeneralSettings GeneralSettingsConfig
Consensus ConsensusConfig
StoragePruning StoragePruningConfig
LogsAndEvents LogsAndEventsConfig
Antiflood AntifloodConfig
WebServerAntiflood WebServerAntifloodConfig
ResourceStats ResourceStatsConfig
HeartbeatV2 HeartbeatV2Config
ValidatorStatistics ValidatorStatisticsConfig
GeneralSettings GeneralSettingsConfig
Consensus ConsensusConfig
StoragePruning StoragePruningConfig
LogsAndEvents LogsAndEventsConfig
HardwareRequirements HardwareRequirementsConfig

NTPConfig NTPConfig
HeadersPoolConfig HeadersPoolConfig
@@ -285,6 +286,11 @@ type GeneralSettingsConfig struct {
SetGuardianEpochsDelay uint32
}

// HardwareRequirementsConfig will hold the hardware requirements config
type HardwareRequirementsConfig struct {
CPUFlags []string
}

// FacadeConfig will hold different configuration option that will be passed to the node facade
type FacadeConfig struct {
RestApiInterface string
9 changes: 4 additions & 5 deletions go.mod
Original file line number Diff line number Diff line change
@@ -20,8 +20,8 @@ require (
github.com/multiversx/mx-chain-logger-go v1.0.13
github.com/multiversx/mx-chain-scenario-go v1.2.1
github.com/multiversx/mx-chain-storage-go v1.0.14
github.com/multiversx/mx-chain-vm-common-go v1.5.10-0.20240116165528-e13d057575c2
github.com/multiversx/mx-chain-vm-go v1.5.24-0.20240116171344-b97ba9e3078e
github.com/multiversx/mx-chain-vm-common-go v1.5.10
github.com/multiversx/mx-chain-vm-go v1.5.24
github.com/multiversx/mx-chain-vm-v1_2-go v1.2.64
github.com/multiversx/mx-chain-vm-v1_3-go v1.3.65
github.com/multiversx/mx-chain-vm-v1_4-go v1.4.92
@@ -47,7 +47,7 @@ require (
github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 // indirect
github.com/containerd/cgroups v1.1.0 // indirect
github.com/coreos/go-systemd/v22 v22.5.0 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.0 // indirect
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c // indirect
github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect
github.com/denisbrodbeck/machineid v1.0.1 // indirect
@@ -150,8 +150,7 @@ require (
github.com/quic-go/quic-go v0.33.0 // indirect
github.com/quic-go/webtransport-go v0.5.3 // indirect
github.com/raulk/go-watchdog v1.3.0 // indirect
github.com/russross/blackfriday/v2 v2.0.1 // indirect
github.com/shurcooL/sanitized_anchor_name v1.0.0 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/smartystreets/assertions v1.13.1 // indirect
github.com/spaolacci/murmur3 v1.1.0 // indirect
github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect
15 changes: 8 additions & 7 deletions go.sum
Original file line number Diff line number Diff line change
@@ -72,8 +72,9 @@ github.com/coreos/go-systemd/v22 v22.1.0/go.mod h1:xO0FLkIi5MaZafQlIrOotqXZ90ih+
github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs=
github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/cpuguy83/go-md2man/v2 v2.0.0 h1:EoUDS0afbrsXAZ9YQ9jdu/mZ2sXgT1/2yyNng4PGlyM=
github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w=
github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
@@ -398,10 +399,10 @@ github.com/multiversx/mx-chain-scenario-go v1.2.1 h1:9eC6VcOEAKRRKZ7EbSWPLzCdNIM
github.com/multiversx/mx-chain-scenario-go v1.2.1/go.mod h1:EuZY7DpNFHVNSxJR8dKE1z2I8gBYfEFFPSwNUOXptqE=
github.com/multiversx/mx-chain-storage-go v1.0.14 h1:h0acoqPS3FKJ4S3cKBEriTU0OabSQnpxai5WKhi1YCs=
github.com/multiversx/mx-chain-storage-go v1.0.14/go.mod h1:sJ2q49tgjxNpMpsHysjABqCAB0FLBmDblbjBkQ8XfmA=
github.com/multiversx/mx-chain-vm-common-go v1.5.10-0.20240116165528-e13d057575c2 h1:Gzq8OEYp8JTqj7Mfs9/kUQuS5ANS9W3hQ8r5r6cBmYk=
github.com/multiversx/mx-chain-vm-common-go v1.5.10-0.20240116165528-e13d057575c2/go.mod h1:sqkKMCnwkWl8DURdb9q7pctK8IANghdHY1KJLE0ox2c=
github.com/multiversx/mx-chain-vm-go v1.5.24-0.20240116171344-b97ba9e3078e h1:Nl4JmMDPIMnT4L4C394b6z6jt1R5WhLa1tcednFXE5k=
github.com/multiversx/mx-chain-vm-go v1.5.24-0.20240116171344-b97ba9e3078e/go.mod h1:T03t+in5jqeTuFZKDt2wH/Sl9MSRczvWhmG+tQEIfec=
github.com/multiversx/mx-chain-vm-common-go v1.5.10 h1:VoqVt9yX1nQUa0ZujMpdT3J3pKSnQcB6WCQLvIW4sqw=
github.com/multiversx/mx-chain-vm-common-go v1.5.10/go.mod h1:sqkKMCnwkWl8DURdb9q7pctK8IANghdHY1KJLE0ox2c=
github.com/multiversx/mx-chain-vm-go v1.5.24 h1:6RhMvf84Ys8DksDovms+su7w6j9TWz3Rtm/PpgV12Yw=
github.com/multiversx/mx-chain-vm-go v1.5.24/go.mod h1:T03t+in5jqeTuFZKDt2wH/Sl9MSRczvWhmG+tQEIfec=
github.com/multiversx/mx-chain-vm-v1_2-go v1.2.64 h1:3BEpSxEQibMMi4LXBjpo2y5vUa1LS7olDC2eDkmUfFQ=
github.com/multiversx/mx-chain-vm-v1_2-go v1.2.64/go.mod h1:MUO2E4aEIu3siDkvjraO/WaBh/FxVeQyPWfsrZE+MTU=
github.com/multiversx/mx-chain-vm-v1_3-go v1.3.65 h1:H0Duuoz6lR6KapqLqMspWTojaVtQRiLA5lIm6XV9H04=
@@ -486,8 +487,9 @@ github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTE
github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6poM+XZ2dLUbcbE=
github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8=
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
github.com/russross/blackfriday/v2 v2.0.1 h1:lPqVAte+HuHNfhJ/0LC98ESWRz8afy9tM/0RK8m9o+Q=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI=
github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA=
@@ -512,7 +514,6 @@ github.com/shurcooL/notifications v0.0.0-20181007000457-627ab5aea122/go.mod h1:b
github.com/shurcooL/octicon v0.0.0-20181028054416-fa4f57f9efb2/go.mod h1:eWdoE5JD4R5UVWDucdOPg1g2fqQRq78IQa9zlOV1vpQ=
github.com/shurcooL/reactions v0.0.0-20181006231557-f2e0b4ca5b82/go.mod h1:TCR1lToEk4d2s07G3XGfz2QrgHXg4RJBvjrOozvoWfk=
github.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
github.com/shurcooL/sanitized_anchor_name v1.0.0 h1:PdmoCO6wvbs+7yrJyMORt4/BmY5IYyJwS/kOiWx8mHo=
github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
github.com/shurcooL/users v0.0.0-20180125191416-49c67e49c537/go.mod h1:QJTqeLYEDaXHZDBsXlPCDqdhQuJkuw4NOtaxYe3xii4=
github.com/shurcooL/webdavfs v0.0.0-20170829043945-18c3829fa133/go.mod h1:hKmq5kWdCj2z2KEozexVbfEZIWiTjhE0+UjmZgPqehw=
Loading