You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by GitBox <gi...@apache.org> on 2022/01/12 16:01:28 UTC

[GitHub] [couchdb] nickva commented on a change in pull request #3889: Handle libicu upgrades in views

nickva commented on a change in pull request #3889:
URL: https://github.com/apache/couchdb/pull/3889#discussion_r783215772



##########
File path: src/couch_mrview/src/couch_mrview_util.erl
##########
@@ -1070,16 +1077,33 @@ old_view_format(View, SI, KSI) ->
         View#mrview.options
     }.
 
-maybe_update_header(#mrheader{} = Header) ->
-    Header;
-maybe_update_header(Header) when tuple_size(Header) == 6 ->
+maybe_update_header(#mrheader{view_info = Info} = Header) when is_map(Info) ->
+    % Latest (3.2.1+) version. Note: the size of the record is the same as the
+    % legacy <2.3.1 version. The main difference is that the LogBt field is now
+    % a map. This trick also allows for easy downgrading back to version 3.2.1
+    % and then upgrading back to 3.2.1 if needed.

Review comment:
       Good catch, yeah it would be `back to 3.2.1+`. So it would allow downgrading, then upgrading again without resetting views as in the 3.0.0-3.2.1 versions that member of the header is ignored.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@couchdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org