[PATCH] CTDB log message improvements

Amitay Isaacs amitay at gmail.com
Tue Jul 5 04:24:21 UTC 2016


On Tue, Jul 5, 2016 at 2:14 PM, Richard Sharpe <realrichardsharpe at gmail.com>
wrote:

> On Mon, Jul 4, 2016 at 12:00 AM, Amitay Isaacs <amitay at gmail.com> wrote:
> > Hi,
> >
> > Here are two changes to log messages.
> >
> > Please review and push.
> >
> > Amitay.
>
> I am confused by the wording in this hunk:
>
> @@ -1606,12 +1606,14 @@ int32_t ctdb_control_set_recmaster(struct
> ctdb_context *
> ctdb, uint32_t opcode, T
>
>   if (ctdb->pnn != new_recmaster && ctdb->recovery_master == ctdb->pnn) {
>   DEBUG(DEBUG_NOTICE,
> -      ("This node (%u) is no longer the recovery master\n", ctdb
> ->pnn));
> +      ("Local node %u is now the recovery master\n",
> +       new_recmaster));
>   }
>
>   if (ctdb->pnn == new_recmaster && ctdb->recovery_master != new_recmaster
> ) {
>   DEBUG(DEBUG_NOTICE,
> -      ("This node (%u) is now the recovery master\n", ctdb->pnn)
> );
> +      ("Remote node %u is now the recovery master\n",
> +       ctdb->pnn));
>   }
>
>   ctdb->recovery_master = new_recmaster;
>
> What local node are you referring to? The one the log is printed on?
>
> Wouldn't it be better to say: "This node (%u) is now the recovery master"?
>

Oops.  I switched the two log messages around.

"Local" and "Remote" were late additions just to distinguish between the
two cases.  The original message sounds much better.

Here are the updated patches.

Amitay.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ctdb.patches
Type: application/octet-stream
Size: 2199 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20160705/193cfc3f/ctdb.obj>


More information about the samba-technical mailing list