mesos / mesos-go

Go language bindings for Apache Mesos
Apache License 2.0
544 stars 146 forks source link

Error using master operator api for events subscribe #342

Closed kkrishna closed 6 years ago

kkrishna commented 6 years ago

I'm trying to run sample code for subscribing events. Running into following error: mesos master version is 1.1.0

LM-SJN-21000951:mwatch kkrishna$ go run mwatch.go -master=10.180.72.121 
panic: proto: required field "recovered" not set

goroutine 1 [running]:
panic(0x5764e0, 0xc420c01820)
    /usr/local/go/src/runtime/panic.go:500 +0x1a1
main.main()
    /Users/kkrishna/work/golang/src/github.com/mesos/mesos-go/api/v1/cmd/mwatch/mwatch.go:35 +0x312
exit status 2

Is this issue likely due to generated protobuf? any pointers appreciated. thanks.

jdef commented 6 years ago

Off the top of my head... the master branch has protos generated for mesos 1.4 so you might run into some problems trying to execute the sample apps against mesos 1.1

kkrishna commented 6 years ago

Its supposed to be backward compatible, right? can anyone point me to the mesos proto files that would work with mesos 1.2.3. I want to generate protobuf binding and try that out.

{
    "get_master": {
        "master_info": {
            "address": {
                "hostname": "10.180.52.56",
                "ip": "10.180.52.56",
                "port": 5050
            },
            "hostname": "10.180.52.56",
            "id": "5c34cd38-ecaf-4d22-a3bc-d844c43d39f6",
            "ip": 942978058,
            "pid": "master@10.180.52.56:5050",
            "port": 5050,
            "version": "1.2.3"
        }
    },
    "type": "GET_MASTER"
}
jdef commented 6 years ago

I've been trying to tag master w/ the mesos version that the protos were generated from. For example: https://github.com/mesos/mesos-go/tree/mesos-1.2.x

On Thu, Feb 8, 2018 at 12:24 PM, kkrishna notifications@github.com wrote:

Its supposed to be backward compatible, right? can anyone point me to the mesos proto files that would work with mesos 1.2.3. I want to generate protobuf binding and try that out.

{ "get_master": { "master_info": { "address": { "hostname": "10.180.52.56", "ip": "10.180.52.56", "port": 5050 }, "hostname": "10.180.52.56", "id": "5c34cd38-ecaf-4d22-a3bc-d844c43d39f6", "ip": 942978058, "pid": "master@10.180.52.56:5050", "port": 5050, "version": "1.2.3" } }, "type": "GET_MASTER" }

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/mesos/mesos-go/issues/342#issuecomment-364185509, or mute the thread https://github.com/notifications/unsubscribe-auth/ACPVLHvc0K5AhqTGpsbPBw1XJukqVRt4ks5tSy3GgaJpZM4R9jIX .

jdef commented 6 years ago

AFAIK Mesos strives for proto compatibility within 1 point release. 1.1 --> 1.4 is a big jump and not guaranteed to be cross-compat.

jdef commented 6 years ago

Closing this out, please re-open if you're still having problems.