yarn

package
v0.0.0-...-eecaf76 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create_new_nodemanager

func Create_new_nodemanager(nm_config Nodemanager_config)

Create a new nodemanager and start it

func Decommis_nodemanagers

func Decommis_nodemanagers(nodemanagers []string)

Decommising the nodemanagers on each resourcemanagers. No matter which yarn clusters the nodemanager belonging to, you can put the in the same nodefile togethter. Magpie will recognize the yarn cluster automatically.

func Decommis_nodemanagers_through_file

func Decommis_nodemanagers_through_file(nodefile string)

Decommising the nodemanager of the nodefile

func Get_yarn_status

func Get_yarn_status(cluster_names []string)

Get yarn cluster node status

func Offline_host

func Offline_host(hostname string)

Offline the host, decommsing the nodemanagers and then delete the docker contianers.

func Yarn_distribution

func Yarn_distribution(clustername string)

Show the yarn nodemanagers distribution.

func Yarn_view

func Yarn_view(clustername string)

Inspect the yarn cluster container view

Types

type Nodemanager_config

type Nodemanager_config struct {
	//The config items with all capital alphabet are docker image ENV
	//The following items have default config on docker image
	HA                  string //default yes
	NAMESERVICE         string
	ACTIVE_NAMENODE_IP  string
	STANDBY_NAMENODE_IP string
	ACTIVE_NAMENODE_ID  string
	STANDBY_NAMENODE_ID string
	HA_ZOOKEEPER_QUORUM string

	//You must set the following items with your own address
	YARN_ZK_DIR        string
	YARN_CLUSTER_ID    string
	YARN_RM1_IP        string
	YARN_RM2_IP        string
	YARN_JOBHISTORY_IP string

	//Without HA config
	NAMENODE_IP        string
	RESOURCEMANAGER_IP string

	CPU_CORE_NUM          string //default 4
	NODEMANAGER_MEMORY_MB string //default 10240
	Network_mode          string //default mynet
	Limit_cpus            int64  //default 5
	Limit_memory_mb       int64  //default 12288

	Image          string //nodemanager docker image
	Container_name string //docker container name
}

type YarnStatus

type YarnStatus struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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