[sheepdog] [PATCH 2/6] sheep: use different opcodes for internal read/write I/O
Christoph Hellwig
hch at infradead.org
Wed Jul 4 06:55:48 CEST 2012
On Wed, Jul 04, 2012 at 11:23:06AM +0800, Liu Yuan wrote:
> On 07/04/2012 03:54 AM, Christoph Hellwig wrote:
> > + /* peer I/O operations */
> > [SD_OP_REMOVE_OBJ] = {
> > .type = SD_OP_TYPE_IO,
> > .process_work = store_remove_obj,
> > },
>
> For better name consistent, it's better to rename store_remove_obj as
> store_remove_peer. Or even more aggressive,
> peer_{read,write,create_and_write,remove}, because store_ prefix doesn't
> carry any meaningful implication after we abstract backend store out.
>
> And I think SD_OP_TYPE_IO -> SD_OP_TYPE_PEER would be better too.
SD_OP_REMOVE_OBJ handling will get the rename treatment next. It wasn't
needed in the first pass as we don't handle it in the gateway, but it
I have a patch in the queue to change it's opcode so that it is in the
internal command range where it belongs, at which point I'll also rename
it.
I don't like the SD_OP_TYPE_PEER name (yet) - we have a lot more commands
that also are peer commands but treated differently from the actual
I/O commands.
More information about the sheepdog
mailing list