{"action":"created","issue":{"url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4","repository_url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT","labels_url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4/comments","events_url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4/events","html_url":"https://github.com/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4","id":324896416,"number":4,"title":"Monitor with websocket","user":{"login":"jkancio","id":1507010,"avatar_url":"https://avatars3.githubusercontent.com/u/1507010?v=4","gravatar_id":"","url":"https://api.github.com/users/jkancio","html_url":"https://github.com/jkancio","followers_url":"https://api.github.com/users/jkancio/followers","following_url":"https://api.github.com/users/jkancio/following{/other_user}","gists_url":"https://api.github.com/users/jkancio/gists{/gist_id}","starred_url":"https://api.github.com/users/jkancio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkancio/subscriptions","organizations_url":"https://api.github.com/users/jkancio/orgs","repos_url":"https://api.github.com/users/jkancio/repos","events_url":"https://api.github.com/users/jkancio/events{/privacy}","received_events_url":"https://api.github.com/users/jkancio/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-05-21T12:21:42Z","updated_at":"2018-05-22T07:29:55Z","closed_at":null,"author_association":"NONE","body":"I started the Monitor using **http://{{base_url}}/api/data-sets/{{dataset-id}}/monitor**\r\nand I used a HTML javascript code...\r\n\r\nws = new WebSocket(url); \r\nurl = signalr:http://localhost:8080\r\n\r\nand I´ve got\r\nUncaught DOMException: Failed to construct 'WebSocket': The URL's scheme must be either 'ws' or 'wss'. '**signalr**' is not allowed.\r\n\r\nDo you have an exemple of javascript code to receive monitored data?\r\n\r\nThanks.\r\n"},"comment":{"url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/comments/390890855","html_url":"https://github.com/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4#issuecomment-390890855","issue_url":"https://api.github.com/repos/OPCUAUniCT/OPCUAWebPlatformUniCT/issues/4","id":390890855,"user":{"login":"marcostefanoscroppo","id":22190697,"avatar_url":"https://avatars1.githubusercontent.com/u/22190697?v=4","gravatar_id":"","url":"https://api.github.com/users/marcostefanoscroppo","html_url":"https://github.com/marcostefanoscroppo","followers_url":"https://api.github.com/users/marcostefanoscroppo/followers","following_url":"https://api.github.com/users/marcostefanoscroppo/following{/other_user}","gists_url":"https://api.github.com/users/marcostefanoscroppo/gists{/gist_id}","starred_url":"https://api.github.com/users/marcostefanoscroppo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcostefanoscroppo/subscriptions","organizations_url":"https://api.github.com/users/marcostefanoscroppo/orgs","repos_url":"https://api.github.com/users/marcostefanoscroppo/repos","events_url":"https://api.github.com/users/marcostefanoscroppo/events{/privacy}","received_events_url":"https://api.github.com/users/marcostefanoscroppo/received_events","type":"User","site_admin":false},"created_at":"2018-05-22T07:29:55Z","updated_at":"2018-05-22T07:29:55Z","author_association":"COLLABORATOR","body":"Hi @jkancio, there is a misconception. The Monitor Service is used to publish information on a MQTT Broker or a SignalR Hub. Both are not included in the platform and must be externally implemented. The URL you provided as parameter of the Monitor Request (\"signalr:http://localhost:8080\") is used internally by the platform and shall be the URL of your Broker (for MQTT) or Hub (for SignalR).\r\n\r\nSo that, if you want to receive published data from the Platform, the only thing you have to do from Javascript is connect to the Broker/Hub and subscribe to the right Topic/Group.\r\n\r\nI suggest you to start with MQTT for testing Monitor Service. For MQTT you can use Mosquitto or Mosca Broker.  For a javascript client from a browser i suggest you [this](http://www.steves-internet-guide.com/using-javascript-mqtt-client-websockets/\r\n) guide.\r\n\r\nIn the following, if you want to try SignalR i suggest you [this](https://docs.microsoft.com/en-gb/aspnet/signalr/overview/guide-to-the-api/) official guide by Microsoft.\r\n"}}
{"actor":{"display_login":"marcostefanoscroppo"}}