Bug 1453151

Summary: [RFE] glusterfind: add --end-time and --field-separator options
Product: [Community] GlusterFS Reporter: Milind Changire <mchangir>
Component: glusterfindAssignee: Milind Changire <mchangir>
Status: CLOSED CURRENTRELEASE QA Contact: bugs <bugs>
Severity: urgent Docs Contact:
Priority: urgent    
Version: mainlineCC: amukherj, ashah, avishwan, bugs, khiremat, knakai, mchangir, rhinduja, rhs-bugs, storage-qa-internal, wenshi
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: glusterfs-3.12.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1450722 Environment:
Last Closed: 2017-09-05 17:31:32 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1450722    

Comment 1 Milind Changire 2017-05-22 09:31:25 UTC
NEW file2
RENAME file1 file2

and 

RENAME file1 file2
NEW file2

are not acceptable output sequences.

Only the "RENAME file1 file2" should be seen in the output.

Comment 2 Worker Ant 2017-05-22 09:35:22 UTC
REVIEW: https://review.gluster.org/17355 (tools/glusterfind: sanitize NEW and RENAME op sequence) posted (#1) for review on master by Milind Changire (mchangir)

Comment 3 Worker Ant 2017-05-22 12:38:22 UTC
REVIEW: https://review.gluster.org/17355 (tools/glusterfind: sanitize NEW and RENAME op sequence) posted (#2) for review on master by Milind Changire (mchangir)

Comment 4 Worker Ant 2017-05-22 12:47:59 UTC
REVIEW: https://review.gluster.org/17355 (tools/glusterfind: sanitize NEW and RENAME op sequence) posted (#3) for review on master by Milind Changire (mchangir)

Comment 5 Worker Ant 2017-05-26 03:35:39 UTC
REVIEW: https://review.gluster.org/17355 (tools/glusterfind: sanitize NEW and RENAME op sequence) posted (#4) for review on master by Milind Changire (mchangir)

Comment 6 Worker Ant 2017-06-01 10:00:18 UTC
REVIEW: https://review.gluster.org/17439 (tools/glusterfind: add --end-time option) posted (#1) for review on master by Milind Changire (mchangir)

Comment 7 Worker Ant 2017-06-06 10:33:05 UTC
REVIEW: https://review.gluster.org/17439 (tools/glusterfind: add --end-time option) posted (#2) for review on master by Milind Changire (mchangir)

Comment 8 Worker Ant 2017-06-06 18:16:06 UTC
REVIEW: https://review.gluster.org/17481 (tools/glusterfind: add --field-separator option) posted (#1) for review on master by Milind Changire (mchangir)

Comment 9 Worker Ant 2017-06-12 04:48:59 UTC
COMMIT: https://review.gluster.org/17481 committed in master by Aravinda VK (avishwan) 
------
commit 64588d4f6d69ce6e9b82335d12fa6c42794c38fa
Author: Milind Changire <mchangir>
Date:   Tue Jun 6 23:43:54 2017 +0530

    tools/glusterfind: add --field-separator option
    
    Problem:
    Default field separator is a space character.
    This gets in the way if the file name itself has embedded spaces.
    
    Solution:
    Add --field-separator option to "pre" and "query" commands.
    The field separator string will be used to separate strings in the
    output lines that get written to the output file.
    
    eg.
    old output:
    NEW file1.txt
    RENAME file2 Copy.txt file3.txt
    
    with --field-separator as "==="
    new output:
    NEW===file1.txt
    RENAME===file2 Copy.txt===file3.txt
    
    Change-Id: I71e878fed58ba1113d97044ac9f6404ee66227c7
    BUG: 1453151
    Signed-off-by: Milind Changire <mchangir>
    Reviewed-on: https://review.gluster.org/17481
    Smoke: Gluster Build System <jenkins.org>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.org>
    Reviewed-by: Aravinda VK <avishwan>

Comment 10 Worker Ant 2017-06-12 05:14:12 UTC
COMMIT: https://review.gluster.org/17439 committed in master by Aravinda VK (avishwan) 
------
commit dbdf56ae3f87fc2765ad9cb528c1cfbadfde96ec
Author: Milind Changire <mchangir>
Date:   Tue Jun 6 12:27:28 2017 +0530

    tools/glusterfind: add --end-time option
    
    Add optional --end-time argument to be used with --since-time
    when using the "query" command.
    
    "start" and "end" times are passed in the command-line to
    changelog.py only if --full has not been specified on command-line.
    -1 is passed to changelog.py as end time if user has not supplied
    --end-time on command-line.
    
    brickfind.py:
    Remove unused "start" command-line argument.
    
    Also:
    Minor indentation changes to keep flake8-2.7 happy.
    
    Change-Id: I063ef5459916f711503881ade5c4fc32374edad0
    BUG: 1453151
    Signed-off-by: Milind Changire <mchangir>
    Reviewed-on: https://review.gluster.org/17439
    Smoke: Gluster Build System <jenkins.org>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.org>
    Reviewed-by: Aravinda VK <avishwan>

Comment 11 Shyamsundar 2017-09-05 17:31:32 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.12.0, please open a new bug report.

glusterfs-3.12.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://lists.gluster.org/pipermail/announce/2017-September/000082.html
[2] https://www.gluster.org/pipermail/gluster-users/