webee / wamp.js

The Web Application Messaging Protocol for js.
MIT License
6 stars 9 forks source link

Good job, but I have a problem #3

Closed aaerofeev closed 7 years ago

aaerofeev commented 7 years ago

I used your wamp.js with ReactNative. I have a problem:

06-02 14:17:21.913 20254 22317 I ReactNativeJS: { url: 'ws://127.0.0.1:8080',
06-02 14:17:21.913 20254 22317 I ReactNativeJS:   realm: 'taxiserver',
06-02 14:17:21.913 20254 22317 I ReactNativeJS:   authmethods: [ 'ticket' ],
06-02 14:17:21.913 20254 22317 I ReactNativeJS:   authid: 'xxx',
06-02 14:17:21.913 20254 22317 I ReactNativeJS:   credential: 'xxx',
06-02 14:17:21.913 20254 22317 I ReactNativeJS:   onchallenge: { ... }

06-02 14:17:21.923 20254 22317 I ReactNativeJS: start to open.

06-02 14:17:21.923 20254 22317 I ReactNativeJS: trying to connect.

06-02 14:17:21.923 20254 22317 I ReactNativeJS: trying to create WAMP transport of type: websocket
06-02 14:17:21.923 20254 22317 I ReactNativeJS: using WAMP transport type: websocket

06-02 14:17:22.303 20254 22317 I ReactNativeJS: 'onclose:', { code: undefined,
06-02 14:17:22.303 20254 22317 I ReactNativeJS:   reason: 'Failed to connect to /127.0.0.1:8080',
06-02 14:17:22.303 20254 22317 I ReactNativeJS:   wasClean: undefined }

When I using autobahnjs with raw nodejs, connect ok RN 0.44 Wamp.js: latest

aaerofeev commented 7 years ago

I ran connection without adb reverse tcp:8080 tcp:8080 Its my problem. If you will run ReactNative with websockets, run adb reverse tcp:8080 tcp:8080