<s> import sahara . plugins . mapr . base . base_cluster_context as bc <EOL> import sahara . plugins . mapr . services . yarn . yarn as yarn <EOL> class Context ( bc . BaseClusterContext ) : <EOL> def __init__ ( self , cluster , version_handler , added = None , removed = None ) : <EOL> super ( Context , self ) . __init__ ( cluster , version_handler , added , removed ) <EOL> self . _hadoop_version = yarn . YARNv270 ( ) . version <EOL> self . _hadoop_lib = None <EOL> self . _hadoop_conf = None <EOL> self . _cluster_mode = yarn . YARNv270 . cluster_mode <EOL> self . _node_aware = True <EOL> self . _resource_manager_uri = "<STR_LIT>" <EOL> self . _mapr_version = "<STR_LIT>" <EOL> self . _ubuntu_ecosystem_repo = ( <EOL> "<STR_LIT>" ) <EOL> self . _centos_ecosystem_repo = ( <EOL> "<STR_LIT>" ) <EOL> @ property <EOL> def hadoop_lib ( self ) : <EOL> if not self . _hadoop_lib : <EOL> self . _hadoop_lib = "<STR_LIT>" % self . hadoop_home <EOL> return self . _hadoop_lib <EOL> @ property <EOL> def hadoop_conf ( self ) : <EOL> if not self . _hadoop_conf : <EOL> self . _hadoop_conf = "<STR_LIT>" % self . hadoop_home <EOL> return self . _hadoop_conf <EOL> @ property <EOL> def resource_manager_uri ( self ) : <EOL> return self . _resource_manager_uri <EOL> @ property <EOL> def configure_sh ( self ) : <EOL> if not self . _configure_sh : <EOL> configure_sh_template = "<STR_LIT>" <EOL> args = { <EOL> "<STR_LIT>" : super ( Context , self ) . configure_sh , <EOL> "<STR_LIT>" : self . get_historyserver_ip ( ) , <EOL> } <EOL> self . _configure_sh = configure_sh_template % args <EOL> return self . _configure_sh </s>
