{"action":"created","issue":{"url":"https://api.github.com/repos/ably/ably-java/issues/112","repository_url":"https://api.github.com/repos/ably/ably-java","labels_url":"https://api.github.com/repos/ably/ably-java/issues/112/labels{/name}","comments_url":"https://api.github.com/repos/ably/ably-java/issues/112/comments","events_url":"https://api.github.com/repos/ably/ably-java/issues/112/events","html_url":"https://github.com/ably/ably-java/issues/112","id":137648765,"number":112,"title":"Library doesn't seem to serialise Map objects properly","user":{"login":"stannedelchev","id":590590,"avatar_url":"https://avatars.githubusercontent.com/u/590590?v=3","gravatar_id":"","url":"https://api.github.com/users/stannedelchev","html_url":"https://github.com/stannedelchev","followers_url":"https://api.github.com/users/stannedelchev/followers","following_url":"https://api.github.com/users/stannedelchev/following{/other_user}","gists_url":"https://api.github.com/users/stannedelchev/gists{/gist_id}","starred_url":"https://api.github.com/users/stannedelchev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stannedelchev/subscriptions","organizations_url":"https://api.github.com/users/stannedelchev/orgs","repos_url":"https://api.github.com/users/stannedelchev/repos","events_url":"https://api.github.com/users/stannedelchev/events{/privacy}","received_events_url":"https://api.github.com/users/stannedelchev/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":15,"created_at":"2016-03-01T18:20:18Z","updated_at":"2016-08-04T14:57:40Z","closed_at":null,"body":"I'm using the following code to send a presence update:\r\n\r\n    Map<String,Boolean> payload = new HashMap<>();\r\n    payload.put(\"isTyping\",false);\r\n    try {\r\n        sessionChannel.presence.update(payload,null);\r\n    } catch (AblyException e) {\r\n        e.printStackTrace();\r\n    }\r\n\r\nThis translates to the following MsgPack hex:\r\n`89A6616374696F6E0EA26964AD4D3754536F6A4A5A35532D3331A5636F756E7415A76368616E6E656CAB6D6F62696C653A63686174AD6368616E6E656C53657269616CB0396335333838303037353736313A3733AC636F6E6E656374696F6E4964AA4D3754536F6A4A5A3553B0636F6E6E656374696F6E53657269616C2CA974696D657374616D70CF000001533354B1D2A870726573656E63659184A8636C69656E744964A573616E6479AC636F6E6E656374696F6E4964AA4D3754536F6A4A5A3553A6616374696F6E04A464617461B07B6973547970696E673D66616C73657D`\r\n\r\nWhich translates to:\r\n`{\"action\":14,\"id\":\"M7TSojJZ5S-31\",\"count\":21,\"channel\":\"mobile:chat\",\"channelSerial\":\"9c53880075761:73\",\"connectionId\":\"M7TSojJZ5S\",\"connectionSerial\":44,\"timestamp\":null,\"presence\":[{\"clientId\":\"sandy\",\"connectionId\":\"M7TSojJZ5S\",\"action\":4,\"data\":\"{isTyping=false}\"}]}\r\n`.\r\n\r\nHowever, when ably.js does a similar thing (I'm testing via the Heroku app), the MsgPack hex is:\r\n\r\n`89A6616374696F6E0EA26964AD6E554158777A664E33522D3232A5636F756E7412A76368616E6E656CAB6D6F62696C653A63686174AD6368616E6E656C53657269616CB0396335333838303037353736313A3737AC636F6E6E656374696F6E4964AA6E554158777A664E3352B0636F6E6E656374696F6E53657269616C30A974696D657374616D70CF000001533359AAE1A870726573656E63659185A8636C69656E744964A27363AC636F6E6E656374696F6E4964AA6E554158777A664E3352A6616374696F6E04A8656E636F64696E67A46A736F6EA464617461B27B226973547970696E67223A66616C73657D`\r\n\r\nWhich translates to:\r\n`{\"action\":14,\"id\":\"nUAXwzfN3R-22\",\"count\":18,\"channel\":\"mobile:chat\",\"channelSerial\":\"9c53880075761:77\",\"connectionId\":\"nUAXwzfN3R\",\"connectionSerial\":48,\"timestamp\":null,\"presence\":[{\"clientId\":\"sc\",\"connectionId\":\"nUAXwzfN3R\",\"action\":4,\"encoding\":\"json\",\"data\":\"{\\\"isTyping\\\":false}\"}]}\r\n`\r\n\r\nThe Java lib doesn't seem to create a valid JSON (IIRC JSON doesn't contain equals signs), that the JS lib can successfully parse. I set breakpoints in the JS presence handler and they do not trigger.\r\nAs a consequence of these differences, the Cordova sample app does not recognise presence messages sent from the Android sample app. \r\nThe inverse is true - the Android lib successfully parses and displays \"isTyping\" presence updates coming from JS.\r\n\r\n@mattheworiordan @paddybyers @gokhanbarisaker "},"comment":{"url":"https://api.github.com/repos/ably/ably-java/issues/comments/237579322","html_url":"https://github.com/ably/ably-java/issues/112#issuecomment-237579322","issue_url":"https://api.github.com/repos/ably/ably-java/issues/112","id":237579322,"user":{"login":"tcard","id":727422,"avatar_url":"https://avatars.githubusercontent.com/u/727422?v=3","gravatar_id":"","url":"https://api.github.com/users/tcard","html_url":"https://github.com/tcard","followers_url":"https://api.github.com/users/tcard/followers","following_url":"https://api.github.com/users/tcard/following{/other_user}","gists_url":"https://api.github.com/users/tcard/gists{/gist_id}","starred_url":"https://api.github.com/users/tcard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tcard/subscriptions","organizations_url":"https://api.github.com/users/tcard/orgs","repos_url":"https://api.github.com/users/tcard/repos","events_url":"https://api.github.com/users/tcard/events{/privacy}","received_events_url":"https://api.github.com/users/tcard/received_events","type":"User","site_admin":false},"created_at":"2016-08-04T14:57:40Z","updated_at":"2016-08-04T14:57:40Z","body":"@mattheworiordan Yep, I'll give it a try."}}
{"actor":{"display_login":"tcard"}}