def flocker_dataset_agent_main():
 service_factory = DatasetServiceFactory()
 agent_script = AgentScript(service_factory=service_factory.get_service)
 options = DatasetAgentOptions()
 pr = cProfile.Profile(clock)
 signal.signal(signal.SIGUSR1, partial(enable_profiling, pr))
 signal.signal(signal.SIGUSR2, partial(disable_profiling, pr, 'dataset'))
 return FlockerScriptRunner(script=agent_script, options=options).main()

def flocker_dataset_agent_main ( ) : service_factory = DatasetServiceFactory ( ) agent_script = AgentScript ( service_factory = service_factory . get_service ) options = DatasetAgentOptions ( ) pr = cProfile . Profile ( clock ) signal . signal ( signal . SIGUSR1 , partial ( enable_profiling , pr ) ) signal . signal ( signal . SIGUSR2 , partial ( disable_profiling , pr , 'dataset' ) ) return FlockerScriptRunner ( script = agent_script , options = options ) . main ( )
implementation of the flocker-dataset-agent command line script .