#NEWLINE# @ logging . log_task_wrapper ( LOG . info , _ ( 'Enter context: `Sahara Input Data Sources`' ) ) #NEWLINE# def setup( self ) : #NEWLINE# #INDENT# utils . init_sahara_context ( self ) #NEWLINE# self . context [ 'sahara' ] [ 'swift_objects' ] = [ ] #NEWLINE# self . context [ 'sahara' ] [ 'container_name' ] = None #NEWLINE# for ( user , tenant_id ) in rutils . iterate_per_tenants ( self . context [ 'users' ] ) : #NEWLINE# #INDENT# clients = osclients . Clients ( user [ 'credential' ] ) #NEWLINE# if ( self . config [ 'input_type' ] == 'swift' ) : #NEWLINE# #INDENT# self . setup_inputs_swift ( clients , tenant_id , self . config [ 'input_url' ] , self . config [ 'swift_files' ] , user [ 'credential' ] . username , user [ 'credential' ] . password ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . setup_inputs ( clients , tenant_id , self . config [ 'input_type' ] , self . config [ 'input_url' ] )