original_docstring: Register a newly created job request
docstring: Register a newly created job request
docstring_tokens: Register a newly created job request
code: def send_job_request(self, current_request):
          """Register a newly created job request"""
          self._assert_request_state(current_request, JOB_UNKNOWN)
  
          gearman_job = current_request.job
  
          # Handle the I/O for requesting a job - determine which COMMAND we need to send
          cmd_type = submit_cmd_for_background_priority(current_request.background, current_request.priority)
  
          outbound_data = self.encode_data(gearman_job.data)
          self.send_command(cmd_type, task=gearman_job.task, unique=gearman_job.unique, data=outbound_data)
  
          # Once this command is sent, our request needs to wait for a handle
          current_request.state = JOB_PENDING
  
          self.requests_awaiting_handles.append(current_request)
code_tokens: def send_job_request ( self , current_request ) : self . _assert_request_state ( current_request , JOB_UNKNOWN ) gearman_job = current_request . job cmd_type = submit_cmd_for_background_priority ( current_request . background , current_request . priority ) outbound_data = self . encode_data ( gearman_job . data ) self . send_command ( cmd_type , task = gearman_job . task , unique = gearman_job . unique , data = outbound_data ) current_request . state = JOB_PENDING self . requests_awaiting_handles . append ( current_request )
short_docstring: Register a newly created job request
short_docstring_tokens: Register a newly created job request
comment: """Register a newly created job request"""$SEP$# Handle the I/O for requesting a job - determine which COMMAND we need to send$SEP$# Once this command is sent, our request needs to wait for a handle