mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-19 18:34:59 +00:00
Release 3.5.0 (#563)
* Changelog and version for Release 3.5.0 * PT-2076 add rhel9 dependency * PT-2128 Updated version to 3.5.0 Co-authored-by: svetasmirnova <sveta.smirnova@percona.com> Co-authored-by: EvgeniyPatlan <evgeniy.patlan@percona.com>
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
package proto
|
||||
|
||||
// ProfilerStatus is a struct to hold the results of db.getProfilingLevel()
|
||||
// var ps proto.ProfilerStatus
|
||||
// err := db.Run(bson.M{"profile": -1}, &ps)
|
||||
//
|
||||
// var ps proto.ProfilerStatus
|
||||
// err := db.Run(bson.M{"profile": -1}, &ps)
|
||||
type ProfilerStatus struct {
|
||||
Was int64 `bson:"was"`
|
||||
SlowMs int64 `bson:"slowms"`
|
||||
|
@@ -184,21 +184,22 @@ func GetHostnames(ctx context.Context, client *mongo.Client) ([]string, error) {
|
||||
}
|
||||
|
||||
/*
|
||||
"members" : [
|
||||
{
|
||||
"_id" : 0,
|
||||
"name" : "localhost:17001",
|
||||
"health" : 1,
|
||||
"state" : 1,
|
||||
"stateStr" : "PRIMARY",
|
||||
"uptime" : 4700,
|
||||
"optime" : Timestamp(1486554836, 1),
|
||||
"optimeDate" : ISODate("2017-02-08T11:53:56Z"),
|
||||
"electionTime" : Timestamp(1486651810, 1),
|
||||
"electionDate" : ISODate("2017-02-09T14:50:10Z"),
|
||||
"configVersion" : 1,
|
||||
"self" : true
|
||||
},
|
||||
"members" : [
|
||||
|
||||
{
|
||||
"_id" : 0,
|
||||
"name" : "localhost:17001",
|
||||
"health" : 1,
|
||||
"state" : 1,
|
||||
"stateStr" : "PRIMARY",
|
||||
"uptime" : 4700,
|
||||
"optime" : Timestamp(1486554836, 1),
|
||||
"optimeDate" : ISODate("2017-02-08T11:53:56Z"),
|
||||
"electionTime" : Timestamp(1486651810, 1),
|
||||
"electionDate" : ISODate("2017-02-09T14:50:10Z"),
|
||||
"configVersion" : 1,
|
||||
"self" : true
|
||||
},
|
||||
*/
|
||||
func buildHostsListFromReplStatus(replStatus proto.ReplicaSetStatus) []string {
|
||||
hostnames := []string{}
|
||||
@@ -211,17 +212,20 @@ func buildHostsListFromReplStatus(replStatus proto.ReplicaSetStatus) []string {
|
||||
return hostnames
|
||||
}
|
||||
|
||||
/* Example
|
||||
/*
|
||||
Example
|
||||
|
||||
mongos> db.getSiblingDB('admin').runCommand('getShardMap')
|
||||
{
|
||||
"map" : {
|
||||
"config" : "localhost:19001,localhost:19002,localhost:19003",
|
||||
"localhost:17001" : "r1/localhost:17001,localhost:17002,localhost:17003",
|
||||
"r1" : "r1/localhost:17001,localhost:17002,localhost:17003",
|
||||
"r1/localhost:17001,localhost:17002,localhost:17003" : "r1/localhost:17001,localhost:17002,localhost:17003",
|
||||
},
|
||||
"ok" : 1
|
||||
}.
|
||||
|
||||
{
|
||||
"map" : {
|
||||
"config" : "localhost:19001,localhost:19002,localhost:19003",
|
||||
"localhost:17001" : "r1/localhost:17001,localhost:17002,localhost:17003",
|
||||
"r1" : "r1/localhost:17001,localhost:17002,localhost:17003",
|
||||
"r1/localhost:17001,localhost:17002,localhost:17003" : "r1/localhost:17001,localhost:17002,localhost:17003",
|
||||
},
|
||||
"ok" : 1
|
||||
}.
|
||||
*/
|
||||
func buildHostsListFromShardMap(shardsMap proto.ShardsMap) []string {
|
||||
hostnames := []string{}
|
||||
|
@@ -316,7 +316,6 @@ type crSecrets struct {
|
||||
func (d *Dumper) getIndividualFiles(resource, namespace string, podName, path, location string, tw *tar.Writer) error {
|
||||
args := []string{"-n", namespace, "cp", podName + ":" + path, "/dev/stdout"}
|
||||
output, err := d.runCmd(args...)
|
||||
|
||||
if err != nil {
|
||||
d.logError(err.Error(), args...)
|
||||
log.Printf("Error: get path %s for resource %s in namespace %s: %v", path, resource, d.namespace, err)
|
||||
|
@@ -2,11 +2,12 @@ package main
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"golang.org/x/exp/slices"
|
||||
"os/exec"
|
||||
"path"
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
"golang.org/x/exp/slices"
|
||||
)
|
||||
|
||||
/*
|
||||
|
@@ -48,7 +48,7 @@ const (
|
||||
var (
|
||||
Build string = "2020-04-23" //nolint
|
||||
GoVersion string = "1.14.1" //nolint
|
||||
Version string = "3.4.0" //nolint
|
||||
Version string = "3.5.0" //nolint
|
||||
Commit string //nolint
|
||||
)
|
||||
|
||||
|
@@ -41,7 +41,7 @@ const (
|
||||
var (
|
||||
Build string = "2020-04-23" //nolint
|
||||
GoVersion string = "1.14.1" //nolint
|
||||
Version string = "3.4.0" //nolint
|
||||
Version string = "3.5.0" //nolint
|
||||
Commit string //nolint
|
||||
)
|
||||
|
||||
|
@@ -57,7 +57,7 @@ const (
|
||||
var (
|
||||
Build string = "2020-04-23"
|
||||
GoVersion string = "1.14.1"
|
||||
Version string = "3.4.0"
|
||||
Version string = "3.5.0"
|
||||
Commit string
|
||||
|
||||
defaultConnectionTimeout = 3 * time.Second
|
||||
|
@@ -10,8 +10,8 @@ import (
|
||||
"github.com/alecthomas/kingpin"
|
||||
_ "github.com/lib/pq"
|
||||
"github.com/pkg/errors"
|
||||
log "github.com/sirupsen/logrus"
|
||||
"github.com/sirupsen/logrus"
|
||||
log "github.com/sirupsen/logrus"
|
||||
|
||||
"github.com/percona/percona-toolkit/src/go/lib/pginfo"
|
||||
"github.com/percona/percona-toolkit/src/go/pt-pg-summary/templates"
|
||||
@@ -21,7 +21,7 @@ var (
|
||||
Build string = "2020-04-23" //nolint
|
||||
Commit string //nolint
|
||||
GoVersion string = "1.14.1" //nolint
|
||||
Version string = "3.4.0" //nolint
|
||||
Version string = "3.5.0" //nolint
|
||||
)
|
||||
|
||||
type connOpts struct {
|
||||
|
@@ -15,8 +15,8 @@ import (
|
||||
"github.com/alecthomas/kingpin"
|
||||
"github.com/go-ini/ini"
|
||||
"github.com/pkg/errors"
|
||||
log "github.com/sirupsen/logrus"
|
||||
"github.com/sirupsen/logrus"
|
||||
log "github.com/sirupsen/logrus"
|
||||
"golang.org/x/crypto/ssh/terminal"
|
||||
)
|
||||
|
||||
@@ -86,7 +86,7 @@ var (
|
||||
|
||||
Build string = "2020-04-23" //nolint
|
||||
GoVersion string = "1.14.1" //nolint
|
||||
Version string = "3.4.0" //nolint
|
||||
Version string = "3.5.0" //nolint
|
||||
Commit string //nolint
|
||||
)
|
||||
|
||||
|
Reference in New Issue
Block a user