File tree Expand file tree Collapse file tree 11 files changed +57
-4
lines changed
examples/simple/search_indexes
src/django_elasticsearch_dsl_drf Expand file tree Collapse file tree 11 files changed +57
-4
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,18 @@ are used for versioning (schema follows below):
1515 0.3.4 to 0.4).
1616- All backwards incompatible changes are mentioned in this document.
1717
18+ 0.16.3
19+ ------
20+ 2018-10-31
21+
22+ .. note ::
23+
24+ Release dedicated to Charles Aznavour.
25+
26+ - Make it possible to ignore certain Elastic exceptions by providing the
27+ appropriate ``ignore `` argument (on the view level). Default behaviour is
28+ intact. Set it to a list of integers (error codes) if you need it so.
29+
18300.16.2
1931------
20322018-09-21
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ Contents:
1818 nested_fields_usage_examples
1919 more_like_this
2020 global_aggregations
21- demo
21+ configuration_tweaks
2222 changelog
2323 django_elasticsearch_dsl_drf
2424
Original file line number Diff line number Diff line change 1+ ====================
2+ Configuration tweaks
3+ ====================
4+ Ignore certain Elasticsearch exceptions
5+ ---------------------------------------
6+ .. code-block :: python
7+
8+ class BookIgnoreIndexErrorsDocumentViewSet (DocumentViewSet ):
9+
10+ # ...
11+ ignore = [404 ]
12+ # ...
Original file line number Diff line number Diff line change 88 BookDefaultFilterLookupDocumentViewSet ,
99 BookDocumentViewSet ,
1010 BookFunctionalSuggesterDocumentViewSet ,
11+ BookIgnoreIndexErrorsDocumentViewSet ,
1112 BookMoreLikeThisDocumentViewSet ,
1213 BookMoreLikeThisNoOptionsDocumentViewSet ,
1314 BookMultiMatchSearchFilterBackendDocumentViewSet ,
6465 base_name = 'bookdocument_functional_suggester'
6566)
6667
68+
69+ books_ignore_index_errors = router .register (
70+ r'books-ignore-index-errors' ,
71+ BookIgnoreIndexErrorsDocumentViewSet ,
72+ base_name = 'bookdocument_ignore_index_errors'
73+ )
74+
6775books_more_like_this = router .register (
6876 r'books-more-like-this' ,
6977 BookMoreLikeThisDocumentViewSet ,
Original file line number Diff line number Diff line change 66 BookDefaultFilterLookupDocumentViewSet ,
77 BookDocumentViewSet ,
88 BookFunctionalSuggesterDocumentViewSet ,
9+ BookIgnoreIndexErrorsDocumentViewSet ,
910 BookMoreLikeThisDocumentViewSet ,
1011 BookMoreLikeThisNoOptionsDocumentViewSet ,
1112 BookMultiMatchSearchFilterBackendDocumentViewSet ,
2627 'BookDefaultFilterLookupDocumentViewSet' ,
2728 'BookDocumentViewSet' ,
2829 'BookFunctionalSuggesterDocumentViewSet' ,
30+ 'BookIgnoreIndexErrorsDocumentViewSet' ,
2931 'BookMoreLikeThisDocumentViewSet' ,
3032 'BookMoreLikeThisNoOptionsDocumentViewSet' ,
3133 'BookMultiMatchSearchFilterBackendDocumentViewSet' ,
Original file line number Diff line number Diff line change 66from .default import BookDocumentViewSet
77from .default_filter_lookup import BookDefaultFilterLookupDocumentViewSet
88from .functional_suggester import BookFunctionalSuggesterDocumentViewSet
9+ from .ignore_index_errors import BookIgnoreIndexErrorsDocumentViewSet
910from .more_like_this import (
1011 BookMoreLikeThisDocumentViewSet ,
1112 BookMoreLikeThisNoOptionsDocumentViewSet ,
Original file line number Diff line number Diff line change 1+ from .default import BookDocumentViewSet
2+
3+ __all__ = (
4+ 'BookIgnoreIndexErrorsDocumentViewSet' ,
5+ )
6+
7+
8+ class BookIgnoreIndexErrorsDocumentViewSet (BookDocumentViewSet ):
9+ """Book document view set based on compound search backend."""
10+
11+ ignore = [404 ]
Original file line number Diff line number Diff line change @@ -9,4 +9,5 @@ cat docs_src/advanced_usage_examples.rst > docs/advanced_usage_examples.rst
99cat docs_src/nested_fields_usage_examples.rst > docs/nested_fields_usage_examples.rst
1010cat docs_src/filtering_usage_examples.rst > docs/filtering_usage_examples.rst
1111cat docs_src/more_like_this.rst > docs/more_like_this.rst
12+ cat docs_src/configuration_tweaks.rst > docs/configuration_tweaks.rst
1213cat docs_src/global_aggregations.rst > docs/global_aggregations.rst
Original file line number Diff line number Diff line change 22
33from setuptools import find_packages , setup
44
5- version = '0.16.2 '
5+ version = '0.16.3 '
66
77DOCS_TRANSFORMATIONS = (
88 (
Original file line number Diff line number Diff line change 33"""
44
55__title__ = 'django-elasticsearch-dsl-drf'
6- __version__ = '0.16.2 '
6+ __version__ = '0.16.3 '
77__author__ = 'Artur Barseghyan <[email protected] >' 88__copyright__ = '2017-2018 Artur Barseghyan'
99__license__ = 'GPL 2.0/LGPL 2.1'
You can’t perform that action at this time.
0 commit comments