How to use notify functionality?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I am working on adding Gluster CLI commands to use BD xlator patches
that I posted to Gerrit few weeks ago
(http://lists.gnu.org/archive/html/gluster-devel/2012-06/msg00090.html)

One of the gluster cli command will create a new LV by using the
following command:
# gluster bd create <vg-name>/<lvname>

This will result in creating a new lv in the given VG. But BD xlator
will not be aware of this newly created LV since all LV information is
populated when BD xlator is loaded. I was looking some notification
mechanism by which BD xlator can be told that there is a new LV and add
to list of LVs thats maintained by BD xlator.

I am not sure if I can use the 'notify' interface in xlators to achieve
the same. I looked at afr_notify function which will be invoked when
gluster cli heal volume command is issued. But I am not sure how it
reaches the notify in afr xlator.

AFAIU, glusterd_brick_op_build_payload function is invoked by
glusterd3_1_brick_op function.

glusterd_brick_op_build_payload function is responsible for setting
brick_req->op to GLUSTERD_BRICK_XLATOR_OP. But I could not follow the
code flow from there. How does notify() in afr xlator invoked? Who
decides that only notify function in afr xlator needs to be invoked
instead of other xlators notify function?

I looked for notify related documentation, but did not get anything
related to that.

Could anyone help me in understanding notify code flow?

Regards,
M. Mohan Kumar




[Index of Archives]     [Gluster Users]     [Ceph Users]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux