2015-07-03 2 views
2

Это мой журнал я вызов всегда заканчивается тайм-аутSinch JS SDk не звонить

Я использую angularjs и так, что я делаю, начиная sinchClient (с завода) в приложении. JS и добавив onIncoming Слушатель, наконец, совершать звонки в контроллере (с завода)

GET http://localhost:63342/chatome/www/cordova.js 
i {sinch: f, eventListeners: Array[0], callBuffert: Object, localMediaStream: undefined, incomingCallCustomStream: undefined…} 
Notification {progress: 0, message: "Get authentication token", object: undefined} 
Notification {progress: 0.2, message: "Get instance using auth token", object: undefined} 
Notification {progress: 0.4, message: "Get MXP configuration", object: undefined} 
Notification {progress: 0.6, message: "Create MXP object", object: undefined} 
Notification {progress: 0.8, message: "Will start active connection", object: undefined} 
Notification {progress: 0.8, message: "Manually starting active connection", object: undefined} 
Notification {progress: 0, message: "SinchClient started", object: undefined} 
Notification {progress: 1, message: "Successfully started SinchClient", object: undefined} 
Notification {progress: 0, message: "CallUser method called", object: "brenty"} 
Notification {progress: 0, message: "Will retrieve new Mic for stream", object: undefined} 
Notification {progress: 0, message: "Call was muted using mute().", object: undefined} 
Notification {progress: 0, message: "Call PROGRESSING timeout. Will hangup call.", object: g}message: "Call PROGRESSING timeout. Will hangup call."object: gactiveInstance: undefinedautoAnswer: falseautoHangup: falsecallDomain: "data"callEndCause: 1callId: "bf5d5c3a-9b08-47ed-9275-5d03eb1447ed"callOutbound: truecallState: 3clientMap: Objectvirtual: Objectfs: "29987351-7351-4835-86c1-179ad669a45eS"fu: "brenty"__proto__: Object__proto__: Object__defineGetter__: __defineGetter__() { [native code] }__defineSetter__: __defineSetter__() { [native code] }__lookupGetter__: __lookupGetter__() { [native code] }__lookupSetter__: __lookupSetter__() { [native code] }constructor: Object() { [native code] }hasOwnProperty: hasOwnProperty() { [native code] }isPrototypeOf: isPrototypeOf() { [native code] }propertyIsEnumerable: propertyIsEnumerable() { [native code] }toLocaleString: toLocaleString() { [native code] }toString: toString() { [native code] }valueOf: valueOf() { [native code] }get __proto__: __proto__() { [native code] }set __proto__: __proto__() { [native code] }customHeaders: Objecttype: "voice"__proto__: ObjectdataChannels: Object__proto__: Objecterror: nulleventListeners: Array[3]0: Object1: Object2: Objectlength: 3__proto__: Array[0]fromId: "triniwiz"hangupRetries: 6iceMapRx: Object__proto__: ObjecticeMapTx: Array[0]length: 0__proto__: Array[0]incomingStream: undefinedincomingStreamURL: undefinedjoinBuffer: Object__proto__: ObjectoutgoingOffer: RTCSessionDescriptionsdp: "v=0 
↵o=- 2486728347566751432 2 IN IP4 127.0.0.1 
↵s=- 
↵t=0 0 
↵a=group:BUNDLE audio video 
↵a=msid-semantic: WMS nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG 
↵m=audio 9 RTP/SAVPF 111 103 104 9 0 8 106 105 13 126 
↵c=IN IP4 0.0.0.0 
↵a=rtcp:9 IN IP4 0.0.0.0 
↵a=ice-ufrag:9XgGQPNJQUYrwuC3 
↵a=ice-pwd:7Y30gM1zjN0Vnt5y6IoOoNYD 
↵a=fingerprint:sha-256 99:E8:0A:BB:55:9A:5F:C6:21:01:06:32:4B:5A:5E:B7:F0:A7:87:49:68:0A:20:4E:5C:AA:ED:66:87:6E:A3:AB 
↵a=setup:actpass 
↵a=mid:audio 
↵a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level 
↵a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time 
↵a=sendrecv 
↵a=rtcp-mux 
↵a=rtpmap:111 opus/48000/2 
↵a=fmtp:111 minptime=10; useinbandfec=1 
↵a=rtpmap:103 ISAC/16000 
↵a=rtpmap:104 ISAC/32000 
↵a=rtpmap:9 G722/8000 
↵a=rtpmap:0 PCMU/8000 
↵a=rtpmap:8 PCMA/8000 
↵a=rtpmap:106 CN/32000 
↵a=rtpmap:105 CN/16000 
↵a=rtpmap:13 CN/8000 
↵a=rtpmap:126 telephone-event/8000 
↵a=maxptime:60 
↵a=ssrc:885316323 cname:joI6MrZklmLX+lvZ 
↵a=ssrc:885316323 msid:nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG a7565e73-846b-495a-b50a-42aff6d70d06 
↵a=ssrc:885316323 mslabel:nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG 
↵a=ssrc:885316323 label:a7565e73-846b-495a-b50a-42aff6d70d06 
↵m=video 9 RTP/SAVPF 100 116 117 96 
↵c=IN IP4 0.0.0.0 
↵a=rtcp:9 IN IP4 0.0.0.0 
↵a=ice-ufrag:9XgGQPNJQUYrwuC3 
↵a=ice-pwd:7Y30gM1zjN0Vnt5y6IoOoNYD 
↵a=fingerprint:sha-256 99:E8:0A:BB:55:9A:5F:C6:21:01:06:32:4B:5A:5E:B7:F0:A7:87:49:68:0A:20:4E:5C:AA:ED:66:87:6E:A3:AB 
↵a=setup:actpass 
↵a=mid:video 
↵a=extmap:2 urn:ietf:params:rtp-hdrext:toffset 
↵a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time 
↵a=extmap:4 urn:3gpp:video-orientation 
↵a=sendrecv 
↵a=rtcp-mux 
↵a=rtpmap:100 VP8/90000 
↵a=rtcp-fb:100 ccm fir 
↵a=rtcp-fb:100 nack 
↵a=rtcp-fb:100 nack pli 
↵a=rtcp-fb:100 goog-remb 
↵a=rtpmap:116 red/90000 
↵a=rtpmap:117 ulpfec/90000 
↵a=rtpmap:96 rtx/90000 
↵a=fmtp:96 apt=100 
↵a=ssrc-group:FID 3499157865 1266786744 
↵a=ssrc:3499157865 cname:joI6MrZklmLX+lvZ 
↵a=ssrc:3499157865 msid:nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG c62982b1-d511-4e38-99dc-f212c2f334bc 
↵a=ssrc:3499157865 mslabel:nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG 
↵a=ssrc:3499157865 label:c62982b1-d511-4e38-99dc-f212c2f334bc 
↵a=ssrc:1266786744 cname:joI6MrZklmLX+lvZ 
↵a=ssrc:1266786744 msid:nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG c62982b1-d511-4e38-99dc-f212c2f334bc 
↵a=ssrc:1266786744 mslabel:nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG 
↵a=ssrc:1266786744 label:c62982b1-d511-4e38-99dc-f212c2f334bc 
↵"type: "offer"__proto__: RTCSessionDescriptionoutgoingStream: MediaStreamactive: trueended: falseid: "nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG"label: "nMB73xPU5jOnbz5Aek3wP4ASqlrk2Vl3cgHG"onactive: nullonaddtrack: nullonended: nulloninactive: nullonremovetrack: null__proto__: MediaStreamoutgoingStreamURL: "blob:http%3A//localhost%3A63342/72a45df9-ae1f-4098-b7e3-743589f5cc74"pcMap: ObjectproxyUrl: "audio:ISAC/0.0.0.0/0/81.19.110.135:23526"sdpAnswerBuffer: ObjectsdpMap: Objectsinch: fPAPI: Object_appKey: "appKey"_appSecret: undefined_autoStartMxp: true_customStream: undefined_expiresIn: 86400_logHandler: (message) {_logMxpHandler:(){}_multiCall: true_onlineCapability: true_sessionId: "91cf12c2-2b03-47f9-b02f-1ebcdfb97e04"_sessionSecret: "M1sdRn5z2UCTYVMGrAc6FQ=="_subInstanceId: 2586157107_supportVideo: true_url: ObjectapplicationKey: "appKey"authenticate:() { [native code] }authenticateNumber:() { [native code] }authenticateUsername:() { [native code] }callClient: icallData:() { [native code] }callPSTN:() { [native code] }callReporting:() { [native code] }capabilities: ObjectchangePassword:() { [native code] }confirmUserSMS:() { [native code] }createUser:() { [native code] }firefox: falsegetConfiguration:() { [native code] }getInstance:() { [native code] }getInstances:() { [native code] }getServerTime:() { [native code] }getTransportById:() { [native code] }getTransportByParticipants:() { [native code] }getUserProfile:() { [native code] }messageReporting:() { [native code] }mxp: ppostMedia:() { [native code] }pushMessage:() { [native code] }renewInstance:() { [native code] }renewSecret:() { [native code] }started: truetimeDelta: -252updateUser:() { [native code] }user: nverifyUserSMS:() { [native code] }__proto__: ftimeEnded: Thu Jul 02 2015 22:08:18 GMT-0400 (AST)__proto__: Invalid DatetimeEstablished: nulltimeProgressing: nulltoId: "brenty"videoSupport: truewebRtcConfig: ObjecticeServers: Array[2]0: Objecturl: "stun:23.21.150.121"__proto__: Object1: Objectlength: 2__proto__: Array[0]__proto__: Object__proto__: gprogress: 0__proto__: Notification 
Notification {progress: 0, message: "Can not hang up call at this time. Will try again in 0.5 seconds (max five retries).", object: undefined} 
Notification {progress: 0, message: "Can not hang up call at this time. Will try again in 0.5 seconds (max five retries).", object: undefined} 
Notification {progress: 0, message: "Can not hang up call at this time. Will try again in 0.5 seconds (max five retries).", object: undefined} 
Notification {progress: 0, message: "Can not hang up call at this time. Will try again in 0.5 seconds (max five retries).", object: undefined} 
Notification {progress: 0, message: "Can not hang up call at this time. Will try again in 0.5 seconds (max five retries).", object: undefined} 
Notification {progress: 0, message: "Call HANGUP Received", object: undefined} 
Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user's experience. For more help, check http://xhr.spec.whatwg.org/. 
TIMEOUT 
MXPLog {message: "Added meta data to MXP message", object: q}message: "Added meta data to MXP message"object: q__proto__: MXPLog 
TypeError: Cannot read property 'key' of undefined 
    at p.17.p.identifyEnKey (sinch.min.js:6) 
    at d (sinch.min.js:4) 
    at 8.p.then.l.nextTick.h.promiseDispatch.j (sinch.min.js:4) 
    at p.8.d.promiseDispatch (sinch.min.js:4) 
    at sinch.min.js:4 
    at Array.a (sinch.min.js:4) 
    at d (sinch.min.js:4) 
TypeError: Cannot read property 'key' of undefined 
    at p.17.p.identifyEnKey (http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:6:27539) 
    at d (http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:4:9844) 
    at 8.p.then.l.nextTick.h.promiseDispatch.j (http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:4:10117) 
    at p.8.d.promiseDispatch (http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:4:4377) 
    at http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:4:3382 
    at Array.a (http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:4:7540) 
    at d (http://localhost:63342/chatome/www/lib/sinch-rtc/sinch.min.js:4:836) 
Notification {progress: 0, message: "Successfully initiated call, waiting for MXP signalling.", object: Object} 

ответ

1

почему вызов API для инициирования данных-вызова, кажется, не было правильно сделано, это может быть связано к тому, как вы интегрировали SDK, ошибку в SDK или другую проблему. Образцы приложений (поставляются вместе с SDK) работают с вашим ключом приложения в вашей среде?

Кроме того, вы можете убедиться (смотря на вкладку «Сети» в хроме при совершении вызова), что запрос на инициирование вызова правильно сделан и нет ошибки.

Если вы можете, вы могли бы поделиться более подробной информацией о своей настройке и/или коде?

Редактировать: Я ищу такой запрос; enter image description here

0

Я также получал сообщение консоли Notification {progress: 0, message: "Will retrieve new Mic for stream", object: undefined} После борьбы с этим в течение некоторого времени, я нашел решение, что решить это для меня. В принципе, Sinch требует, чтобы на странице присутствовали элементы аудио HTML5. Посмотрите в ваших onCallProgressing и onCallEstablished обработчики событий, и вы увидите строки, которые выглядят следующим образом:

'onCallProgressing': function (TheSinchCall) { 

    $('#SinchRingtone').trigger("play"); 
}, 

'onCallEstablished': function (TheSinchCall) { 

    $('#SinchIncoming').attr('src', TheSinchCall['incomingStreamURL']); 
    $('#SinchRingtone').trigger('pause'); 
}, 

Когда $('#SinchRingtone') и $('#SinchIncoming') не возвращают элемент JQuery, потому что HTML-теги не на странице, то Sinch не будет работать.

Смежные вопросы