diff mbox

libceph: advertise support for keepalive2

Message ID 1442238695-13809-1-git-send-email-idryomov@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Ilya Dryomov Sept. 14, 2015, 1:51 p.m. UTC
We are the client, but advertise keepalive2 anyway - for consistency,
if nothing else.  In the future the server might want to know whether
its clients support keepalive2.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
---
 include/linux/ceph/ceph_features.h | 1 +
 1 file changed, 1 insertion(+)

Comments

Yan, Zheng Sept. 16, 2015, 6:28 a.m. UTC | #1
On Mon, Sep 14, 2015 at 9:51 PM, Ilya Dryomov <idryomov@gmail.com> wrote:
> We are the client, but advertise keepalive2 anyway - for consistency,
> if nothing else.  In the future the server might want to know whether
> its clients support keepalive2.

the kernel code still does fully support KEEPALIVE2 (it does not
recognize CEPH_MSGR_TAG_KEEPALIVE2 tag). I think it's better to not
advertise support for keepalive2.

Regards
Yan, Zheng

>
> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
> ---
>  include/linux/ceph/ceph_features.h | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/include/linux/ceph/ceph_features.h b/include/linux/ceph/ceph_features.h
> index 4763ad64e832..f89b31d45cc8 100644
> --- a/include/linux/ceph/ceph_features.h
> +++ b/include/linux/ceph/ceph_features.h
> @@ -107,6 +107,7 @@ static inline u64 ceph_sanitize_features(u64 features)
>          CEPH_FEATURE_OSDMAP_ENC |              \
>          CEPH_FEATURE_CRUSH_TUNABLES3 |         \
>          CEPH_FEATURE_OSD_PRIMARY_AFFINITY |    \
> +        CEPH_FEATURE_MSGR_KEEPALIVE2 |         \
>          CEPH_FEATURE_CRUSH_V4)
>
>  #define CEPH_FEATURES_REQUIRED_DEFAULT   \
> --
> 1.9.3
>
> --
> To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Ilya Dryomov Sept. 16, 2015, 7:39 a.m. UTC | #2
On Wed, Sep 16, 2015 at 9:28 AM, Yan, Zheng <ukernel@gmail.com> wrote:
> On Mon, Sep 14, 2015 at 9:51 PM, Ilya Dryomov <idryomov@gmail.com> wrote:
>> We are the client, but advertise keepalive2 anyway - for consistency,
>> if nothing else.  In the future the server might want to know whether
>> its clients support keepalive2.
>
> the kernel code still does fully support KEEPALIVE2 (it does not
> recognize CEPH_MSGR_TAG_KEEPALIVE2 tag). I think it's better to not
> advertise support for keepalive2.

I guess by "does not recognize" you mean the kernel client knows how to
write TAG_KEEPALIVE2, but not how to read it?  The same is true about
TAG_KEEPALIVE tag and the reverse (we can read, but can't write) is
true about TAG_KEEPALIVE2_ACK.

What I'm getting at is the kernel client is the client, and so it
doesn't need to know how to read keepalive bytes or write keepalive
acks.  The server however might want to know if its clients can send
keepalive2 bytes and handle keepalive2 acks.  Does this make sense?

Thanks,

                Ilya
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Yan, Zheng Sept. 16, 2015, 7:51 a.m. UTC | #3
On Wed, Sep 16, 2015 at 3:39 PM, Ilya Dryomov <idryomov@gmail.com> wrote:
> On Wed, Sep 16, 2015 at 9:28 AM, Yan, Zheng <ukernel@gmail.com> wrote:
>> On Mon, Sep 14, 2015 at 9:51 PM, Ilya Dryomov <idryomov@gmail.com> wrote:
>>> We are the client, but advertise keepalive2 anyway - for consistency,
>>> if nothing else.  In the future the server might want to know whether
>>> its clients support keepalive2.
>>
>> the kernel code still does fully support KEEPALIVE2 (it does not
>> recognize CEPH_MSGR_TAG_KEEPALIVE2 tag). I think it's better to not
>> advertise support for keepalive2.
>
> I guess by "does not recognize" you mean the kernel client knows how to
> write TAG_KEEPALIVE2, but not how to read it?  The same is true about
> TAG_KEEPALIVE tag and the reverse (we can read, but can't write) is
> true about TAG_KEEPALIVE2_ACK.
>
> What I'm getting at is the kernel client is the client, and so it
> doesn't need to know how to read keepalive bytes or write keepalive
> acks.  The server however might want to know if its clients can send
> keepalive2 bytes and handle keepalive2 acks.  Does this make sense?
>

Ok, it makes sense. thank you for explaination

Reviewed-by: Yan, Zheng <zyan@redhat.com>

> Thanks,
>
>                 Ilya
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/include/linux/ceph/ceph_features.h b/include/linux/ceph/ceph_features.h
index 4763ad64e832..f89b31d45cc8 100644
--- a/include/linux/ceph/ceph_features.h
+++ b/include/linux/ceph/ceph_features.h
@@ -107,6 +107,7 @@  static inline u64 ceph_sanitize_features(u64 features)
 	 CEPH_FEATURE_OSDMAP_ENC |		\
 	 CEPH_FEATURE_CRUSH_TUNABLES3 |		\
 	 CEPH_FEATURE_OSD_PRIMARY_AFFINITY |	\
+	 CEPH_FEATURE_MSGR_KEEPALIVE2 |		\
 	 CEPH_FEATURE_CRUSH_V4)
 
 #define CEPH_FEATURES_REQUIRED_DEFAULT   \