[sheepdog] [PATCH v3 1/2] move node_to_str() and str_to_node() from sheep/cluster.h to include/internal_proto.h

Liu Yuan namei.unix at gmail.com
Wed Nov 14 10:47:19 CET 2012


On 11/14/2012 05:34 PM, Hitoshi Mitake wrote:
> 
> On my environment, I couldn't reproduce the problem of patch applying.
> Is your HEAD this:
> https://github.com/collie/sheepdog/commit/beea6156c9b730c8f3d81ee898273f2df7837cc8
> ?
> 
> I'll post the next version after determining the problem, sorry.
> 

Yes, I try to 'git am' it against beea6156c, but failed.

>>
>> To quote from internal_proto.h
>>
>> "/*
>>   * This file specified the sheepdog-internal protocol, which is
>> spoken between
>>   * sheepdog daemons, as well as between collie and sheepdog daemon
>> for internal
>>   * operations.
>>   */
>> "
>>
>> It seems that sheepkeeper shouldn't reference this header.
>>
>> By skipping through the code, it seems that sheepkeeper is deeply
>> coupled with sheep internal
>> data structure such as 'struct sd_node'.
>>
>> I initially thought sheepkeeper as a standalone cluster driver,
>> re-implement a simplified
>> zookeeper or Accord in C. But looks that the code is aware of 'sheep'
>> (have a sheep struct).
>>
>> Would you please shed some lights on the sheepkeeper internals?
>> Documenting your idea in a high level
>> view would certainly help people review your code and testify the
>> fundamental idea at the very early
>> stage.
>>
>> So basic question I want to ask is, should sheekeeper be aware of
>> 'sheep'?
>>
> 
> The answer is yes. I'm planning to implement sheepkeeper as a very
> simplifid cluster manager _only_ for sheepdog.
> 
> For simplicity, I'm trying to merge the source code into the repository
> of sheepdog. So sheepkeeper can utilize
> the internal knowledge from the header files of sheepdog.
> 

I am okay with this approach. It would be nice of you to document the
key functions in the source file as well as a high level introduction of
the ideas of sheepkeeper (how it works, pros and cons, usage, etc...).

> 
> I can write a description of sheepkeeper. After writing a first draft,
> I'll notify for you.
> # my english writing is slow, so it'll be late, sorry!
> 

Don't worry, take your time.

> BTW, your email doesn't include the sheepdog mailing list in its To: or
> Cc:. If you excluded the address unintentionally, I think we should go
> back to the list.

Ah, yes, thanks for reminding, it was unintentional.

Thanks
Yuan



More information about the sheepdog mailing list