mirror of
https://github.com/Doodle3D/doodle3d-connect.git
synced 2024-12-25 18:13:48 +01:00
check specific alive api call
This commit is contained in:
parent
f4abaa99e7
commit
5cd5778331
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
var retrieveListInterval = 5000;
|
var retrieveListInterval = 5000;
|
||||||
var retrieveListDelay; // retry setTimout instance
|
var retrieveListDelay; // retry setTimout instance
|
||||||
var boxTimeoutTime = 300;
|
var boxTimeoutTime = 500;
|
||||||
|
|
||||||
var numBoxesChecking = 0; // count how many boxes we are checking
|
var numBoxesChecking = 0; // count how many boxes we are checking
|
||||||
var numBoxesFound = 0; // count how many boxes responded
|
var numBoxesFound = 0; // count how many boxes responded
|
||||||
@ -74,8 +74,8 @@ function updateList(boxes) {
|
|||||||
function checkBox(box) {
|
function checkBox(box) {
|
||||||
numBoxesChecking++;
|
numBoxesChecking++;
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "http://"+box.localip+"/d3dapi/network/status",
|
url: "http://"+box.localip+"/d3dapi/network/alive",
|
||||||
dataType: 'json',
|
dataType: "json",
|
||||||
timeout: boxTimeoutTime,
|
timeout: boxTimeoutTime,
|
||||||
success: function(response){
|
success: function(response){
|
||||||
if(response.status == "success") {
|
if(response.status == "success") {
|
||||||
|
Loading…
Reference in New Issue
Block a user