command

package
v0.0.0-...-b4f292d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 24, 2024 License: Apache-2.0 Imports: 39 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// HistoryExample history command example.
	HistoryExample = `` /* 414-byte string literal not displayed */

)

Variables

View Source
var PDCli pd.Client

PDCli is a pd HTTP client

Functions

func NewAddLearnerCommand

func NewAddLearnerCommand() *cobra.Command

NewAddLearnerCommand returns a command to add region learner.

func NewAddOperatorCommand

func NewAddOperatorCommand() *cobra.Command

NewAddOperatorCommand returns a command to add operators.

func NewAddPeerCommand

func NewAddPeerCommand() *cobra.Command

NewAddPeerCommand returns a command to add region peer.

func NewAddSchedulerCommand

func NewAddSchedulerCommand() *cobra.Command

NewAddSchedulerCommand returns a command to add scheduler.

func NewBalanceHotRegionSchedulerCommand

func NewBalanceHotRegionSchedulerCommand() *cobra.Command

NewBalanceHotRegionSchedulerCommand returns a command to add a balance-hot-region-scheduler.

func NewBalanceLeaderSchedulerCommand

func NewBalanceLeaderSchedulerCommand() *cobra.Command

NewBalanceLeaderSchedulerCommand returns a command to add a balance-leader-scheduler.

func NewBalanceRegionSchedulerCommand

func NewBalanceRegionSchedulerCommand() *cobra.Command

NewBalanceRegionSchedulerCommand returns a command to add a balance-region-scheduler.

func NewBalanceWitnessSchedulerCommand

func NewBalanceWitnessSchedulerCommand() *cobra.Command

NewBalanceWitnessSchedulerCommand returns a command to add a balance-witness-scheduler.

func NewCancelDeleteStoreByAddrCommand

func NewCancelDeleteStoreByAddrCommand() *cobra.Command

NewCancelDeleteStoreByAddrCommand returns a subcommand of cancel delete

func NewCancelDeleteStoreCommand

func NewCancelDeleteStoreCommand() *cobra.Command

NewCancelDeleteStoreCommand return a cancel delete subcommand of storeCmd

func NewCheckLabels

func NewCheckLabels() *cobra.Command

NewCheckLabels returns a isolation label check.

func NewCheckOperatorCommand

func NewCheckOperatorCommand() *cobra.Command

NewCheckOperatorCommand returns a command to show status of the operator.

func NewClusterCommand

func NewClusterCommand() *cobra.Command

NewClusterCommand return a cluster subcommand of rootCmd

func NewClusterStatusCommand

func NewClusterStatusCommand() *cobra.Command

NewClusterStatusCommand return a cluster status subcommand of clusterCmd

func NewCompletionCommand

func NewCompletionCommand() *cobra.Command

NewCompletionCommand return a completion subcommand of root command

func NewConfigCommand

func NewConfigCommand() *cobra.Command

NewConfigCommand return a config subcommand of rootCmd

func NewConfigSchedulerCommand

func NewConfigSchedulerCommand() *cobra.Command

NewConfigSchedulerCommand returns commands to config scheduler.

func NewDeleteConfigCommand

func NewDeleteConfigCommand() *cobra.Command

NewDeleteConfigCommand a set subcommand of cfgCmd

func NewDeleteLabelPropertyConfigCommand

func NewDeleteLabelPropertyConfigCommand() *cobra.Command

NewDeleteLabelPropertyConfigCommand a set subcommand of delete subcommand.

func NewDeleteMemberCommand

func NewDeleteMemberCommand() *cobra.Command

NewDeleteMemberCommand return a delete subcommand of memberCmd

func NewDeleteServiceGCSafepointCommand

func NewDeleteServiceGCSafepointCommand() *cobra.Command

NewDeleteServiceGCSafepointCommand return a subcommand to delete service gc safepoint

func NewDeleteStoreByAddrCommand

func NewDeleteStoreByAddrCommand() *cobra.Command

NewDeleteStoreByAddrCommand returns a subcommand of delete

func NewDeleteStoreCommand

func NewDeleteStoreCommand() *cobra.Command

NewDeleteStoreCommand return a delete subcommand of storeCmd

func NewDescribeSchedulerCommand

func NewDescribeSchedulerCommand() *cobra.Command

NewDescribeSchedulerCommand returns command to describe the scheduler.

func NewEvictLeaderSchedulerCommand

func NewEvictLeaderSchedulerCommand() *cobra.Command

NewEvictLeaderSchedulerCommand returns a command to add a evict-leader-scheduler.

func NewEvictSlowStoreSchedulerCommand

func NewEvictSlowStoreSchedulerCommand() *cobra.Command

NewEvictSlowStoreSchedulerCommand returns a command to add a evict-slow-store-scheduler.

func NewExitCommand

func NewExitCommand() *cobra.Command

NewExitCommand New a exit subcommand of the rootCmd

func NewGrantHotRegionSchedulerCommand

func NewGrantHotRegionSchedulerCommand() *cobra.Command

NewGrantHotRegionSchedulerCommand returns a command to add a grant-hot-region-scheduler.

func NewGrantLeaderSchedulerCommand

func NewGrantLeaderSchedulerCommand() *cobra.Command

NewGrantLeaderSchedulerCommand returns a command to add a grant-leader-scheduler.

func NewHealthCommand

func NewHealthCommand() *cobra.Command

NewHealthCommand return a health subcommand of rootCmd

func NewHistoryOperatorCommand

func NewHistoryOperatorCommand() *cobra.Command

NewHistoryOperatorCommand returns a command to history finished operators.

func NewHotBucketsCommand

func NewHotBucketsCommand() *cobra.Command

NewHotBucketsCommand return a hot buckets subcommand of hotSpotCmd

func NewHotReadRegionCommand

func NewHotReadRegionCommand() *cobra.Command

NewHotReadRegionCommand return a hot read regions subcommand of hotSpotCmd

func NewHotRegionsHistoryCommand

func NewHotRegionsHistoryCommand() *cobra.Command

NewHotRegionsHistoryCommand return a hot history regions subcommand of hotSpotCmd

func NewHotSpotCommand

func NewHotSpotCommand() *cobra.Command

NewHotSpotCommand return a hot subcommand of rootCmd

func NewHotStoreCommand

func NewHotStoreCommand() *cobra.Command

NewHotStoreCommand return a hot stores subcommand of hotSpotCmd

func NewHotWriteRegionCommand

func NewHotWriteRegionCommand() *cobra.Command

NewHotWriteRegionCommand return a hot regions subcommand of hotSpotCmd

func NewKeyspaceCommand

func NewKeyspaceCommand() *cobra.Command

NewKeyspaceCommand returns a keyspace subcommand of rootCmd.

func NewKeyspaceGroupCommand

func NewKeyspaceGroupCommand() *cobra.Command

NewKeyspaceGroupCommand return a keyspace group subcommand of rootCmd

func NewLabelCommand

func NewLabelCommand() *cobra.Command

NewLabelCommand return a member subcommand of rootCmd

func NewLabelListStoresCommand

func NewLabelListStoresCommand() *cobra.Command

NewLabelListStoresCommand return a label subcommand of labelCmd

func NewLabelSchedulerCommand

func NewLabelSchedulerCommand() *cobra.Command

NewLabelSchedulerCommand returns a command to add a label-scheduler.

func NewLabelStoreCommand

func NewLabelStoreCommand() *cobra.Command

NewLabelStoreCommand returns a label subcommand of storeCmd.

func NewLeaderMemberCommand

func NewLeaderMemberCommand() *cobra.Command

NewLeaderMemberCommand return a leader subcommand of memberCmd

func NewLoadPluginCommand

func NewLoadPluginCommand() *cobra.Command

NewLoadPluginCommand return a load subcommand of plugin command

func NewLogCommand

func NewLogCommand() *cobra.Command

NewLogCommand New a log subcommand of the rootCmd

func NewMemberCommand

func NewMemberCommand() *cobra.Command

NewMemberCommand return a member subcommand of rootCmd

func NewMergeRegionCommand

func NewMergeRegionCommand() *cobra.Command

NewMergeRegionCommand returns a command to merge two regions.

func NewMinResolvedTSCommand

func NewMinResolvedTSCommand() *cobra.Command

NewMinResolvedTSCommand return min resolved ts subcommand of rootCmd

func NewOperatorCommand

func NewOperatorCommand() *cobra.Command

NewOperatorCommand returns an operator command.

func NewPauseSchedulerCommand

func NewPauseSchedulerCommand() *cobra.Command

NewPauseSchedulerCommand returns a command to pause a scheduler.

func NewPingCommand

func NewPingCommand() *cobra.Command

NewPingCommand return a ping subcommand of rootCmd

func NewPlacementRulesCommand

func NewPlacementRulesCommand() *cobra.Command

NewPlacementRulesCommand placement rules subcommand

func NewPluginCommand

func NewPluginCommand() *cobra.Command

NewPluginCommand a set subcommand of plugin command

func NewRandomMergeSchedulerCommand

func NewRandomMergeSchedulerCommand() *cobra.Command

NewRandomMergeSchedulerCommand returns a command to add a random-merge-scheduler.

func NewRangesWithRangeHolesCommand

func NewRangesWithRangeHolesCommand() *cobra.Command

NewRangesWithRangeHolesCommand returns ranges with range-holes subcommand of regionCmd

func NewRegionCommand

func NewRegionCommand() *cobra.Command

NewRegionCommand returns a region subcommand of rootCmd

func NewRegionWithCheckCommand

func NewRegionWithCheckCommand() *cobra.Command

NewRegionWithCheckCommand returns a region with check subcommand of regionCmd

func NewRegionWithKeyCommand

func NewRegionWithKeyCommand() *cobra.Command

NewRegionWithKeyCommand return a region with key subcommand of regionCmd

func NewRegionWithKeyspaceCommand

func NewRegionWithKeyspaceCommand() *cobra.Command

NewRegionWithKeyspaceCommand returns regions with keyspace subcommand of regionCmd

func NewRegionWithSiblingCommand

func NewRegionWithSiblingCommand() *cobra.Command

NewRegionWithSiblingCommand returns a region with sibling subcommand of regionCmd

func NewRegionWithStoreCommand

func NewRegionWithStoreCommand() *cobra.Command

NewRegionWithStoreCommand returns regions with store subcommand of regionCmd

func NewRegionsByKeysCommand

func NewRegionsByKeysCommand() *cobra.Command

NewRegionsByKeysCommand returns regions in a given range [startkey, endkey) subcommand of regionCmd.

func NewRemoveFailedStoresCommand

func NewRemoveFailedStoresCommand() *cobra.Command

NewRemoveFailedStoresCommand returns the unsafe remove failed stores command.

func NewRemoveFailedStoresShowCommand

func NewRemoveFailedStoresShowCommand() *cobra.Command

NewRemoveFailedStoresShowCommand returns the unsafe remove failed stores show command.

func NewRemoveOperatorCommand

func NewRemoveOperatorCommand() *cobra.Command

NewRemoveOperatorCommand returns a command to remove operators.

func NewRemovePeerCommand

func NewRemovePeerCommand() *cobra.Command

NewRemovePeerCommand returns a command to add region peer.

func NewRemoveSchedulerCommand

func NewRemoveSchedulerCommand() *cobra.Command

NewRemoveSchedulerCommand returns a command to remove scheduler.

func NewRemoveTombStoneCommand

func NewRemoveTombStoneCommand() *cobra.Command

NewRemoveTombStoneCommand returns a tombstone subcommand of storesCmd.

func NewRemoveTombStoneCommandDeprecated

func NewRemoveTombStoneCommandDeprecated() *cobra.Command

NewRemoveTombStoneCommandDeprecated returns a tombstone subcommand of storesCmd.

func NewResourceManagerCommand

func NewResourceManagerCommand() *cobra.Command

NewResourceManagerCommand return a resource manager subcommand of rootCmd

func NewResumeSchedulerCommand

func NewResumeSchedulerCommand() *cobra.Command

NewResumeSchedulerCommand returns a command to resume a scheduler.

func NewScatterRangeSchedulerCommand

func NewScatterRangeSchedulerCommand() *cobra.Command

NewScatterRangeSchedulerCommand returns a command to add a scatter-range-scheduler.

func NewScatterRegionCommand

func NewScatterRegionCommand() *cobra.Command

NewScatterRegionCommand returns a command to scatter a region.

func NewSchedulerCommand

func NewSchedulerCommand() *cobra.Command

NewSchedulerCommand returns a scheduler command.

func NewServiceGCSafepointCommand

func NewServiceGCSafepointCommand() *cobra.Command

NewServiceGCSafepointCommand return a service gc safepoint subcommand of rootCmd

func NewSetAllLimitCommand

func NewSetAllLimitCommand() *cobra.Command

NewSetAllLimitCommand returns a set limit subcommand of set command.

func NewSetClusterVersionCommand

func NewSetClusterVersionCommand() *cobra.Command

NewSetClusterVersionCommand creates a set subcommand of set subcommand

func NewSetConfigCommand

func NewSetConfigCommand() *cobra.Command

NewSetConfigCommand return a set subcommand of configCmd

func NewSetLabelPropertyCommand

func NewSetLabelPropertyCommand() *cobra.Command

NewSetLabelPropertyCommand creates a set subcommand of set subcommand

func NewSetStoreWeightCommand

func NewSetStoreWeightCommand() *cobra.Command

NewSetStoreWeightCommand returns a weight subcommand of storeCmd.

func NewSetStoresCommand

func NewSetStoresCommand() *cobra.Command

NewSetStoresCommand returns a set subcommand of storesCmd.

func NewShowAllConfigCommand

func NewShowAllConfigCommand() *cobra.Command

NewShowAllConfigCommand return a show all subcommand of show subcommand

func NewShowAllStoresLimitCommand

func NewShowAllStoresLimitCommand() *cobra.Command

NewShowAllStoresLimitCommand return a show limit subcommand of show command

func NewShowClusterVersionCommand

func NewShowClusterVersionCommand() *cobra.Command

NewShowClusterVersionCommand returns a cluster version subcommand of show subcommand.

func NewShowConfigCommand

func NewShowConfigCommand() *cobra.Command

NewShowConfigCommand return a show subcommand of configCmd

func NewShowLabelPropertyCommand

func NewShowLabelPropertyCommand() *cobra.Command

NewShowLabelPropertyCommand returns a show label property subcommand of show subcommand.

func NewShowOperatorCommand

func NewShowOperatorCommand() *cobra.Command

NewShowOperatorCommand returns a command to show operators.

func NewShowReplicationConfigCommand

func NewShowReplicationConfigCommand() *cobra.Command

NewShowReplicationConfigCommand return a show all subcommand of show subcommand

func NewShowScheduleConfigCommand

func NewShowScheduleConfigCommand() *cobra.Command

NewShowScheduleConfigCommand return a show all subcommand of show subcommand

func NewShowSchedulerCommand

func NewShowSchedulerCommand() *cobra.Command

NewShowSchedulerCommand returns a command to show schedulers.

func NewShowServerConfigCommand

func NewShowServerConfigCommand() *cobra.Command

NewShowServerConfigCommand returns a server configuration of show subcommand.

func NewShowStoresCommand

func NewShowStoresCommand() *cobra.Command

NewShowStoresCommand returns a show subcommand of storesCmd.

func NewShuffleHotRegionSchedulerCommand

func NewShuffleHotRegionSchedulerCommand() *cobra.Command

NewShuffleHotRegionSchedulerCommand returns a command to add a shuffle-hot-region-scheduler.

func NewShuffleLeaderSchedulerCommand

func NewShuffleLeaderSchedulerCommand() *cobra.Command

NewShuffleLeaderSchedulerCommand returns a command to add a shuffle-leader-scheduler.

func NewShuffleRegionSchedulerCommand

func NewShuffleRegionSchedulerCommand() *cobra.Command

NewShuffleRegionSchedulerCommand returns a command to add a shuffle-region-scheduler.

func NewSlowTrendEvictLeaderSchedulerCommand

func NewSlowTrendEvictLeaderSchedulerCommand() *cobra.Command

NewSlowTrendEvictLeaderSchedulerCommand returns a command to add a evict-slow-trend-scheduler.

func NewSplitBucketSchedulerCommand

func NewSplitBucketSchedulerCommand() *cobra.Command

NewSplitBucketSchedulerCommand returns a command to add a split-bucket-scheduler.

func NewSplitRegionCommand

func NewSplitRegionCommand() *cobra.Command

NewSplitRegionCommand returns a command to split a region.

func NewStoreCheckCommand

func NewStoreCheckCommand() *cobra.Command

NewStoreCheckCommand return a check subcommand of storeCmd

func NewStoreCommand

func NewStoreCommand() *cobra.Command

NewStoreCommand return a stores subcommand of rootCmd

func NewStoreLimitCommand

func NewStoreLimitCommand() *cobra.Command

NewStoreLimitCommand returns a limit subcommand of storeCmd.

func NewStoreLimitSceneCommand

func NewStoreLimitSceneCommand() *cobra.Command

NewStoreLimitSceneCommand returns a limit-scene command for store command

func NewStoresCommand

func NewStoresCommand() *cobra.Command

NewStoresCommand returns a store subcommand of rootCmd

func NewTSOCommand

func NewTSOCommand() *cobra.Command

NewTSOCommand return a TSO subcommand of rootCmd

func NewTransferLeaderCommand

func NewTransferLeaderCommand() *cobra.Command

NewTransferLeaderCommand returns a command to transfer leader.

func NewTransferPeerCommand

func NewTransferPeerCommand() *cobra.Command

NewTransferPeerCommand returns a command to transfer region.

func NewTransferRegionCommand

func NewTransferRegionCommand() *cobra.Command

NewTransferRegionCommand returns a command to transfer region.

func NewTransferWitnessLeaderSchedulerCommand

func NewTransferWitnessLeaderSchedulerCommand() *cobra.Command

NewTransferWitnessLeaderSchedulerCommand returns a command to add a transfer-witness-leader-shceudler.

func NewUnloadPluginCommand

func NewUnloadPluginCommand() *cobra.Command

NewUnloadPluginCommand return a unload subcommand of plugin command

func NewUnsafeCommand

func NewUnsafeCommand() *cobra.Command

NewUnsafeCommand returns the unsafe subcommand of rootCmd.

func RequireHTTPSClient

func RequireHTTPSClient(cmd *cobra.Command, _ []string) error

RequireHTTPSClient creates a HTTPS client if the related flags are set

func RunCompletion

func RunCompletion(cmd *cobra.Command, args []string)

RunCompletion wrapped the bash and zsh completion scripts

func ShowMinResolvedTS

func ShowMinResolvedTS(cmd *cobra.Command, _ []string)

ShowMinResolvedTS show min resolved ts

Types

type BodyOption

type BodyOption func(*bodyOption)

BodyOption sets the type and content of the body

func WithBody

func WithBody(body io.Reader) BodyOption

WithBody returns a BodyOption

type DoFunc

type DoFunc func(endpoint string) error

DoFunc receives an endpoint which you can issue request to

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL