Package cm_api :: Package endpoints :: Module services :: Class ApiServiceSetupInfo
[hide private]
[frames] | no frames]

Class ApiServiceSetupInfo

source code

         object --+            
                  |            
types.BaseApiObject --+        
                      |        
  types.BaseApiResource --+    
                          |    
                 ApiService --+
                              |
                             ApiServiceSetupInfo

Instance Methods [hide private]
 
__init__(self, name=None, type=None, config=None, roles=None)
Initializes internal state and sets all known writable properties of the object to None.
source code
 
set_config(self, config)
Set the service configuration.
source code
 
add_role_type_info(self, role_type, config)
Add a role type setup info.
source code
 
add_role_info(self, role_name, role_type, host_id, config=None)
Add a role info.
source code
 
first_run(self)
Prepare and start this service.
source code

Inherited from ApiService: __str__, add_watched_directory, bootstrap_hdfs_stand_by, cancel_impala_query, cleanup_zookeeper, collect_yarn_application_diagnostics, create_beeswax_warehouse, create_hbase_root, create_hdfs_tmp, create_hive_metastore_database, create_hive_metastore_tables, create_hive_userdir, create_hive_warehouse, create_impala_catalog_database, create_impala_catalog_database_tables, create_impala_user_dir, create_oozie_db, create_oozie_embedded_database, create_replication_schedule, create_role, create_role_config_group, create_sentry_database, create_sentry_database_tables, create_snapshot_policy, create_solr_hdfs_home_dir, create_sqoop_database_tables, create_sqoop_user_dir, create_yarn_application_diagnostics_bundle, create_yarn_cm_container_usage_input_dir, create_yarn_job_history_dir, create_yarn_node_manager_remote_app_log_dir, decommission, delete_replication_schedule, delete_role, delete_role_config_group, delete_snapshot_policy, deploy_client_config, disable_hdfs_auto_failover, disable_hdfs_ha, disable_jt_ha, disable_llama_ha, disable_llama_rm, disable_nn_ha, disable_oozie_ha, disable_rm_ha, dump_hue_db, enable_hdfs_auto_failover, enable_hdfs_ha, enable_jt_ha, enable_llama_ha, enable_llama_rm, enable_nn_ha, enable_oozie_ha, enable_rm_ha, enter_maintenance_mode, exit_maintenance_mode, failover_hdfs, finalize_metadata_upgrade, finalize_rolling_upgrade, format_hdfs, get_activity, get_all_role_config_groups, get_all_roles, get_commands, get_config, get_impala_queries, get_impala_query_attributes, get_metrics, get_query_details, get_replication_command_history, get_replication_schedule, get_replication_schedules, get_role, get_role_config_group, get_role_types, get_roles_by_type, get_running_activities, get_snapshot_command_history, get_snapshot_policies, get_snapshot_policy, get_yarn_application_attributes, get_yarn_applications, import_mr_configs_into_yarn, init_hdfs_auto_failover, init_hdfs_shared_dir, init_solr, init_zookeeper, install_oozie_sharelib, jmap_dump, jmap_histo, jstack, kill_yarn_application, list_commands_by_name, list_watched_directories, load_hue_db, lsof, offline, query_activities, recommission, recommission_with_start, refresh, remove_watched_directory, restart, restart_roles, role_command_by_name, roll_edits_hdfs, rolling_restart, service_command_by_name, start, start_roles, stop, stop_roles, switch_to_mr2, sync_hue_db, trigger_replication_schedule, update_config, update_metastore_namenodes, update_replication_schedule, update_role_config_group, update_snapshot_policy, upgrade_hbase, upgrade_hdfs_metadata, upgrade_hive_metastore, upgrade_oozie_db, upgrade_sentry_database_tables, upgrade_sqoop_db, validate_hive_metastore_schema

Inherited from types.BaseApiObject: __setattr__, to_json_dict

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __sizeof__, __subclasshook__

Class Methods [hide private]

Inherited from types.BaseApiObject: from_json_dict

Inherited from types.BaseApiObject (private): _get_attributes

Static Methods [hide private]

Inherited from types.BaseApiObject: init

Class Variables [hide private]
  _ATTRIBUTES = {'name': None, 'type': None, 'config': Attr(ApiC...

Inherited from types.BaseApiObject (private): _WHITELIST

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, name=None, type=None, config=None, roles=None)
(Constructor)

source code 

Initializes internal state and sets all known writable properties of the object to None. Then initializes the properties given in the provided attributes dictionary.

Parameters:
  • resource_root - API resource object.
  • attrs - optional dictionary of attributes to set. This should only contain r/w attributes.
Overrides: object.__init__
(inherited documentation)

set_config(self, config)

source code 

Set the service configuration.

Parameters:
  • config - A dictionary of config key/value

add_role_type_info(self, role_type, config)

source code 

Add a role type setup info.

Parameters:
  • role_type - Role type
  • config - A dictionary of role type configuration

add_role_info(self, role_name, role_type, host_id, config=None)

source code 

Add a role info. The role will be created along with the service setup.

Parameters:
  • role_name - Role name
  • role_type - Role type
  • host_id - The host where the role should run
  • config - (Optional) A dictionary of role config values

first_run(self)

source code 

Prepare and start this service. Perform all the steps needed to prepare and start this service.

Returns:
Reference to the submitted command.

Since: API v7


Class Variable Details [hide private]

_ATTRIBUTES

Value:
{'name': None, 'type': None, 'config': Attr(ApiConfig), 'roles': Attr(\
roles.ApiRole),}