Bug 1334044 - [RFE] Eventing for Gluster
Summary: [RFE] Eventing for Gluster
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: eventsapi
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Aravinda VK
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: glusterfs-3.9.0 1351589
TreeView+ depends on / blocked
 
Reported: 2016-05-07 12:51 UTC by Aravinda VK
Modified: 2017-03-27 18:20 UTC (History)
4 users (show)

Fixed In Version: glusterfs-3.9.0
Clone Of:
: 1351589 (view as bug list)
Environment:
Last Closed: 2017-03-27 18:20:24 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Aravinda VK 2016-05-07 12:51:24 UTC
Description of problem:
Gluster Status can only be fetched by querying Gluster CLI. There should be efficient way to know the status of the Cluster without polling. All the clients/listeners should be informed immediately(near realtime)

Comment 1 Vijay Bellur 2016-05-07 13:15:20 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#1) for review on master by Aravinda VK (avishwan)

Comment 2 Vijay Bellur 2016-05-07 15:34:49 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#2) for review on master by Aravinda VK (avishwan)

Comment 3 Vijay Bellur 2016-05-07 16:05:56 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#3) for review on master by Aravinda VK (avishwan)

Comment 4 Vijay Bellur 2016-05-07 16:54:52 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#4) for review on master by Aravinda VK (avishwan)

Comment 5 Vijay Bellur 2016-05-07 20:36:49 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#5) for review on master by Aravinda VK (avishwan)

Comment 6 Vijay Bellur 2016-05-11 12:25:12 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#6) for review on master by Aravinda VK (avishwan)

Comment 7 Vijay Bellur 2016-05-24 05:48:43 UTC
REVIEW: http://review.gluster.org/14248 (eventing: Gluster Eventing Feature implementation) posted (#7) for review on master by Aravinda VK (avishwan)

Comment 8 Vijay Bellur 2016-06-07 06:54:53 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#8) for review on master by Aravinda VK (avishwan)

Comment 9 Vijay Bellur 2016-06-13 06:45:35 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#9) for review on master by Atin Mukherjee (amukherj)

Comment 10 Vijay Bellur 2016-06-20 06:34:05 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#10) for review on master by Aravinda VK (avishwan)

Comment 11 Vijay Bellur 2016-06-30 08:51:13 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#11) for review on master by Aravinda VK (avishwan)

Comment 12 Vijay Bellur 2016-07-10 16:14:23 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#12) for review on master by Aravinda VK (avishwan)

Comment 13 Vijay Bellur 2016-07-11 09:24:36 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#13) for review on master by Aravinda VK (avishwan)

Comment 14 Vijay Bellur 2016-07-14 08:11:03 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#14) for review on master by Aravinda VK (avishwan)

Comment 15 Vijay Bellur 2016-07-18 06:04:54 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#15) for review on master by Aravinda VK (avishwan)

Comment 16 Vijay Bellur 2016-07-18 08:37:30 UTC
REVIEW: http://review.gluster.org/14248 (eventsapi: Gluster Eventing Feature implementation) posted (#16) for review on master by Aravinda VK (avishwan)

Comment 17 Vijay Bellur 2016-07-18 20:52:24 UTC
COMMIT: http://review.gluster.org/14248 committed in master by Jeff Darcy (jdarcy) 
------
commit 5ed781ecf531b7916e51c174426e222dab717fb8
Author: Aravinda VK <avishwan>
Date:   Thu May 5 18:34:41 2016 +0530

    eventsapi: Gluster Eventing Feature implementation
    
    [Depends on http://review.gluster.org/14627]
    
    Design is available in `glusterfs-specs`, A change from the design
    is support of webhook instead of Websockets as discussed in the design
    
    http://review.gluster.org/13115
    
    Since Websocket support depends on REST APIs, I will add Websocket support
    once REST APIs patch gets merged
    
    Usage:
    Run following command to start/stop Eventsapi server in all Peers,
    which will collect the notifications from any Gluster daemon and emits
    to configured client.
    
        gluster-eventsapi start|stop|restart|reload
    
    Status of running services can be checked using,
    
        gluster-eventsapi status
    
    Events listener is a HTTP(S) server which listens to events emited by
    the Gluster. Create a HTTP Server to listen on POST and register that
    URL using,
    
        gluster-eventsapi webhook-add <URL> [--bearer-token <TOKEN>]
    
    For example, if HTTP Server running in `http://192.168.122.188:9000`
    then add that URL using,
    
        gluster-eventsapi webhook-add http://192.168.122.188:9000
    
    If it expects a Token then specify it using `--bearer-token` or `-t`
    
    We can also test Webhook if all peer nodes can send message or not
    using,
    
        gluster-eventsapi webhook-test <URL> [--bearer-token <TOKEN>]
    
    Configurations can be viewed/updated using,
    
        gluster-eventsapi config-get [--name]
        gluster-eventsapi config-set <NAME> <VALUE>
        gluster-eventsapi config-reset <NAME|all>
    
    If any one peer node was down during config-set/reset or webhook
    modifications, Run sync command from good node when a peer node comes
    back. Automatic update is not yet implemented.
    
        gluster-eventsapi sync
    
    Basic Events Client(HTTP Server) is included with the code, Start
    running the client with required port and start listening to the
    events.
    
        /usr/share/glusterfs/scripts/eventsdash.py --port 8080
    
    Default port is 9000, if no port is specified, once it started running
    then configure gluster-eventsapi to send events to that client.
    
    Eventsapi Client can be outside of the Cluster, it can be run event on
    Windows. But only requirement is the client URL should be accessible
    by all peer nodes.(Or ngrok(https://ngrok.com) like tools can be used)
    
    Events implemented with this patch,
    - Volume Create
    - Volume Start
    - Volume Stop
    - Volume Delete
    - Peer Attach
    - Peer Detach
    
    It is easy to add/support more events, since it touches Gluster cmd
    code and to avoid merge conflicts I will add support for more events
    once this patch merges.
    
    BUG: 1334044
    Change-Id: I316827ac9dd1443454df7deffe4f54835f7f6a08
    Signed-off-by: Aravinda VK <avishwan>
    Reviewed-on: http://review.gluster.org/14248
    Smoke: Gluster Build System <jenkins.org>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.org>
    Reviewed-by: Jeff Darcy <jdarcy>

Comment 18 Niels de Vos 2016-08-05 11:19:56 UTC
The date in the %changelog in the glusterfs.spec.in is invalid. I'm sending a fix for that now.

Comment 19 Vijay Bellur 2016-08-05 11:27:55 UTC
REVIEW: http://review.gluster.org/15099 (build: correct date in the %changelog) posted (#1) for review on master by Niels de Vos (ndevos)

Comment 20 Vijay Bellur 2016-08-05 19:22:18 UTC
COMMIT: http://review.gluster.org/15099 committed in master by Niels de Vos (ndevos) 
------
commit 7ce77ea61f184d5ddae4bce4ca672fd439089eaf
Author: Niels de Vos <ndevos>
Date:   Fri Aug 5 13:27:26 2016 +0200

    build: correct date in the %changelog
    
    Building RPMs failed for me because of an incorrect date in the
    %changelog in the .spec. It seems that rpmlint identifies is as well:
    
       $ rpmlint glusterfs.spec
       ... (snipped non critical errors)
       glusterfs.spec: E: specfile-error warning: bogus date in %changelog: Wed Jul 15 2016 Aravinda VK <avishwan>
    
    Changed the date in the .spec to the date of the latest version (v16) of
    the patch that adds eventing (commit 5ed781ecf).
    
    BUG: 1334044
    Change-Id: I5ef5003e227a83479f24103fc67139d7287fbc39
    Signed-off-by: Niels de Vos <ndevos>
    Reviewed-on: http://review.gluster.org/15099
    Reviewed-by: Kaleb KEITHLEY <kkeithle>
    Smoke: Gluster Build System <jenkins.org>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.org>

Comment 21 Worker Ant 2016-08-30 12:36:42 UTC
REVIEW: http://review.gluster.org/15351 (eventsapi: declare all the identified events at one go) posted (#1) for review on master by Atin Mukherjee (amukherj)

Comment 22 Worker Ant 2016-08-30 13:36:53 UTC
REVIEW: http://review.gluster.org/15351 (eventsapi: declare all the identified events at one go) posted (#2) for review on master by Avra Sengupta (asengupt)

Comment 23 Worker Ant 2016-08-31 11:19:39 UTC
COMMIT: http://review.gluster.org/15351 committed in master by Aravinda VK (avishwan) 
------
commit 513bf9b72fddbd1f69ce4b31b16e0611c84a9378
Author: Atin Mukherjee <amukherj>
Date:   Tue Aug 30 18:05:11 2016 +0530

    eventsapi: declare all the identified events at one go
    
    This patch ensures we don't get into merge conflicts
    everytime a single eventing patch is merged which
    changes eventskeygen.py. I've collected all the identified
    events from the patches posted in gerrit for reviews and
    consolidated at one place.
    
    Change-Id: I5a5983d5c8db7c4a223fa02b4f99ec41c6fa9c35
    BUG: 1334044
    Signed-off-by: Atin Mukherjee <amukherj>
    Reviewed-on: http://review.gluster.org/15351
    Tested-by: Prasanna Kumar Kalever <pkalever>
    Reviewed-by: Avra Sengupta <asengupt>
    Smoke: Gluster Build System <jenkins.org>
    Reviewed-by: Aravinda VK <avishwan>
    Reviewed-by: Saravanakumar Arumugam <sarumuga>
    CentOS-regression: Gluster Build System <jenkins.org>
    NetBSD-regression: NetBSD Build System <jenkins.org>

Comment 24 Shyamsundar 2017-03-27 18:20:24 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.9.0, please open a new bug report.

glusterfs-3.9.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/gluster-users/2016-November/029281.html
[2] https://www.gluster.org/pipermail/gluster-users/


Note You need to log in before you can comment on or make changes to this bug.