nodes: 0, module; 1, function_definition; 2, function_name:_get_query; 3, parameters; 4, block; 5, identifier:self; 6, identifier:cursor; 7, expression_statement; 8, expression_statement; 9, if_statement; 10, if_statement; 11, return_statement; 12, string; 13, assignment; 14, attribute; 15, block; 16, attribute; 17, block; 18, identifier:query; 19, string_content:Query tempalte for source Solr, sorts by id by default.; 20, identifier:query; 21, dictionary; 22, identifier:self; 23, identifier:_date_field; 24, expression_statement; 25, identifier:self; 26, identifier:_per_shard; 27, expression_statement; 28, pair; 29, pair; 30, pair; 31, pair; 32, assignment; 33, assignment; 34, string; 35, string; 36, string; 37, string; 38, string; 39, attribute; 40, string; 41, identifier:cursor; 42, subscript; 43, call; 44, subscript; 45, string; 46, string_content:q; 47, string_content:*:*; 48, string_content:sort; 49, string_content:id desc; 50, string_content:rows; 51, identifier:self; 52, identifier:_rows; 53, string_content:cursorMark; 54, identifier:query; 55, string; 56, attribute; 57, argument_list; 58, identifier:query; 59, string; 60, string_content:false; 61, string_content:sort; 62, string:"{} asc, id desc"; 63, identifier:format; 64, attribute; 65, string_content:distrib; 66, identifier:self; 67, identifier:_date_field
code: def _get_query(self, cursor):
          '''
          Query tempalte for source Solr, sorts by id by default.
          '''
          query = {'q':'*:*',
                  'sort':'id desc',
                  'rows':self._rows,
                  'cursorMark':cursor}
          if self._date_field:
              query['sort'] = "{} asc, id desc".format(self._date_field)
          if self._per_shard:
              query['distrib'] = 'false'
          return query