From: Konstantin Osipov <kostja@tarantool.org>
To: tarantool-patches@freelists.org
Subject: [tarantool-patches] Re: [PATCH 1/2] swim: introduce broadcast tasks
Date: Thu, 11 Apr 2019 15:57:53 +0300 [thread overview]
Message-ID: <20190411125753.GA2123@chai> (raw)
In-Reply-To: <e74513fc0f8d01fc5298cfc7658d59bd657184d1.1554918303.git.v.shpilevoy@tarantool.org>
* Vladislav Shpilevoy <v.shpilevoy@tarantool.org> [19/04/10 21:01]:
> When a cluster is just created, no one knows anyone. Broadcast
> helps to establish some initial relationships between members.
>
> This commit introduces only an interface to create broadcast
> tasks from SWIM code. The next commit uses this interface to
> implement ping broadcast.
> +/**
> + * Broadcast task. Besides usual task fields, stores a list of
> + * interfaces available for broadcast packets. The task works
> + * multiple times, each time sending a packet to one interface.
> + * After completion it is self-deleted.
> + */
> +struct swim_bcast_task {
Please explain in the comment why you need a task - you may
only broadcast when a socket is writable, so use a generic way to
interact with the transport. Please mention why you create a
single task, not multiple - no particular reason, just to
create fewer tasks and do less error checking for failed
resources. Please mention in a comment to swim_broadcast that
we send a broadcast message to all interfaces which are
support IP protocol and broadcast messages.
Otherwise the patch is OK to push.
--
Konstantin Osipov, Moscow, Russia, +7 903 626 22 32
http://tarantool.io - www.twitter.com/kostja_osipov
next prev parent reply other threads:[~2019-04-11 12:57 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-10 17:45 [tarantool-patches] [PATCH 0/2] swim broadcast Vladislav Shpilevoy
2019-04-10 17:45 ` [tarantool-patches] [PATCH 1/2] swim: introduce broadcast tasks Vladislav Shpilevoy
2019-04-11 12:57 ` Konstantin Osipov [this message]
2019-04-11 13:46 ` [tarantool-patches] " Vladislav Shpilevoy
2019-04-10 17:45 ` [tarantool-patches] [PATCH 2/2] swim: expose ping broadcast API Vladislav Shpilevoy
2019-04-11 13:00 ` [tarantool-patches] " Konstantin Osipov
2019-04-11 13:00 ` Konstantin Osipov
2019-04-11 13:47 ` Vladislav Shpilevoy
2019-04-10 18:11 ` [tarantool-patches] Re: [PATCH 0/2] swim broadcast Konstantin Osipov
2019-04-10 18:13 ` Vladislav Shpilevoy
2019-04-10 22:13 ` Vladislav Shpilevoy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190411125753.GA2123@chai \
--to=kostja@tarantool.org \
--cc=tarantool-patches@freelists.org \
--subject='[tarantool-patches] Re: [PATCH 1/2] swim: introduce broadcast tasks' \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox