# File lib/openshift-origin-controller/app/controllers/legacy_broker_controller.rb, line 382
  def validate_request
    @reply = ResultIO.new
    begin
      @req = LegacyRequest.new.from_json(params['json_data'])
      if @req.invalid?
        log_action('nil','nil', 'nil', "LEGACY_BROKER", false, "Validation error: #{@req.errors.first[1][:message]}")
        @reply.resultIO << @req.errors.first[1][:message]
        @reply.exitcode = @req.errors.first[1][:exit_code]
        render :json => @reply, :status => :bad_request
      end
    end
  end