Questions tagged [polling]

Polling is actively sampling the status of an external device by a client program as a synchronous activity.

Polling is actively sampling the status of an external device by a client program as a synchronous activity.

Reference:

1451 questions
6
votes
1 answer

Is there a way for MySQL to wait for rows matching a condition to be inserted

Let's say i was writing an aplication where'd i'd need to get notifications in real time from a server, and let's say those notifications are stored on a mysql database. For me to get them i'd have to keep polling the mysql server (keep repeating…
6
votes
1 answer

Implementing long polling with retrofit and kotlin channels

I am trying to implement long polling which is lifecycle aware(in Activity/Fragment). The polling will be scoped to the fragment which sends API request to the server every fixed interval of time. However, I am unable to implement it. This is how I…
Extremis II
  • 5,185
  • 2
  • 19
  • 29
6
votes
2 answers

How can I test whether stdin has input available in julia?

I would like to detect whether there is input on stdin in a short time window, and continue execution either way, with the outcome stored in a Bool. (My real goal is to implement a pause button on a simulation that runs in the terminal. A second…
Jim Garrison
  • 4,199
  • 4
  • 25
  • 39
6
votes
2 answers

Turn basic polling into long polling

I'm developing a chat application and so far i'm polling my server for messages every two seconds. To make the chat more instant i'd like to implement long polling. I'm trying to implement this JS.info Guide for it but i keep not hitting the goal i…
Sascha Rissling
  • 253
  • 5
  • 15
6
votes
2 answers

Jenkins not building after push, but Github webhook is working

I think I've done the hard part already: the Github webhook after a push always returns a success message. I can build manually. But it never builds after the push, because "polling" never happens. Both the GitHub Hook Log and Git Polling Log…
Bret Hess
  • 407
  • 4
  • 10
6
votes
3 answers

AJAX Polling Question - Blocking Or Frequent?

I have a web application that relies on very "live" data - so it needs an update every 1 second if something has changed. I was wondering what the pros and cons of the following solutions are. Solution 1 - Poll A Lot So every 1 second, I send a…
Fenton
  • 241,084
  • 71
  • 387
  • 401
6
votes
2 answers

C# Check if socket is disconnected?

How can you check if a non-blocking socket is disconnect without using Poll?
Will
  • 10,013
  • 9
  • 45
  • 77
6
votes
4 answers

Website Monitoring Libraries

There has been some talk of Website performance monitoring tools and services on stackoverflow, however, they seem fairly expensive for what they actually do. Are there any good opensource libraries for automating checking/monitoring the…
Schmidty
  • 1,899
  • 1
  • 20
  • 18
6
votes
2 answers

How to avoid polling for time-consuming async REST requests?

The question is on how to design a REST web service which performs time-consuming jobs (order of magnitude of several seconds and minutes). The fastest solution would be to proceed as follows: client sends a POST request to server (POST /job), the…
hari
  • 144
  • 2
  • 8
6
votes
1 answer

How does polling a file for changes work?

The problem I expected the script below to print at most one event and then stop (it's written only to illustrate the problem). #!/usr/bin/env python from select import poll, POLLIN filename = "test.tmp" # make sure file exists open(filename,…
Lauritz V. Thaulow
  • 49,139
  • 12
  • 73
  • 92
6
votes
2 answers

Trigger a job by polling multiple GIT repos inside Jenkinsfile

At the Jenkinsfile with two git repositories these is an example of using multiple GIT repositories in a single Jenkins job: node { dir('RepoOne') { git url: 'https://github.com/somewhere/RepoOne.git' } dir('RepoTwo') { …
Alexander Samoylov
  • 2,358
  • 2
  • 25
  • 28
6
votes
1 answer

My simple poll() example only partially works

The program is supposed to accept telnet connections on port 8888 and then send and messages from each telnet client using poll(), send() and recv() but it doesn't quite work 100%. It seems certain connections can always send messages to anyone and…
Philluminati
  • 2,649
  • 2
  • 25
  • 32
6
votes
2 answers

Continuous polling using Tasks

This is something I've always used Threads / BackgroundWorker for, but am trying to migrate over to Task way of doing things. Let's say I have a 3rd party SDK I use to read bytes from a USB port. That read call is blocking and times out after 100…
Eternal21
  • 4,190
  • 2
  • 48
  • 63
6
votes
1 answer

Web Sockets vs Interval Polling

I'm currently looking for the best fitting solution to handle notifications. My current options are either using websockets or just do a polling (only 1 request every minute, no long polling, no permanent polling) I somehow have problems to find…
Frnak
  • 6,601
  • 5
  • 34
  • 67
6
votes
2 answers

Silverlight Polling Duplex with HTTPS

Is it possible to have Silverlight Polling Duplex WCF working with HTTPS?