#NEWLINE# def get_port_addition_result( args , cluster , jobs , parsing_service , current_job , host_id , instance_id , val ) : #NEWLINE# #INDENT# reg_expr = JOB_PORT_EXPR_REGEX . match ( val ) #NEWLINE# job_name = reg_expr . group ( 'job' ) #NEWLINE# add_num = int ( reg_expr . group ( 'num' ) ) #NEWLINE# return ( get_base_port ( jobs [ job_name ] . base_port , instance_id ) + add_num )