jiangphcn commented on a change in pull request #1370: [5/5] Clustered Purge Implementation URL: https://github.com/apache/couchdb/pull/1370#discussion_r195009936
########## File path: src/couch_mrview/src/couch_mrview_util.erl ########## @@ -41,6 +43,27 @@ -include_lib("couch_mrview/include/couch_mrview.hrl"). +get_local_purge_doc_id(Sig) -> + Version = "v" ++ config:get("purge", "version", "1") ++ "-", + ?l2b(?LOCAL_DOC_PREFIX ++ "purge-" ++ Version ++ "mrview-" ++ Sig). + + +get_value_from_options(Key, Options) -> + case couch_util:get_value(Key, Options) of + undefined -> + Reason = binary_to_list(Key) ++ " must exist in Options.", + throw({bad_request, Reason}); + Value -> Value + end. + + +get_signature_from_filename(FileName) -> + FilePathList = filename:split(FileName), + [PureFN] = lists:nthtail(length(FilePathList) - 1, FilePathList), Review comment: Good suggestion, and changed in commit 276d4ed ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services