code: def validate(cls, job_config):
      
      super(AbstractDatastoreInputReader, cls).validate(job_config)
      params = job_config.input_reader_params
  
      # Check for the required entity kind parameter.
      if cls.ENTITY_KIND_PARAM not in params:
        raise errors.BadReaderParamsError("Missing input reader parameter "
                                          "'entity_kind'")
      # Validate the batch size parameter.
      if cls.BATCH_SIZE_PARAM in params:
        try:
          batch_size = int(params[cls.BATCH_SIZE_PARAM])
          if batch_size < 1:
            raise errors.BadReaderParamsError("Bad batch size: %s" % batch_size)
        except ValueError, e:
          raise errors.BadReaderParamsError("Bad batch size: %s" % e)
      # Validate the keys only parameter.
      try:
        bool(params.get(cls.KEYS_ONLY_PARAM, False))
      except:
        raise errors.BadReaderParamsError("keys_only expects a boolean value but "
                                          "got %s",
                                          params[cls.KEYS_ONLY_PARAM])
      # Validate the namespace parameter.
      if cls.NAMESPACE_PARAM in params:
        if not isinstance(params[cls.NAMESPACE_PARAM],
                          (str, unicode, type(None))):
          raise errors.BadReaderParamsError("Expected a single namespace string")
  
      # Validate the filters parameter.
      if cls.FILTERS_PARAM in params:
        filters = params[cls.FILTERS_PARAM]
        if not isinstance(filters, list):
          raise errors.BadReaderParamsError("Expected list for filters parameter")
        for f in filters:
          if not isinstance(f, (tuple, list)):
            raise errors.BadReaderParamsError("Filter should be a tuple or list: "
                                              "%s", f)
          if len(f) != 3:
            raise errors.BadReaderParamsError("Filter should be a 3-tuple: %s", f)
          prop, op, _ = f
          if not isinstance(prop, basestring):
            raise errors.BadReaderParamsError("Property should be string: %s",
                                              prop)
          if not isinstance(op, basestring):
            raise errors.BadReaderParamsError("Operator should be string: %s", op)
docs: Inherit docs.