Browse Definitions :
Definition

polling (computing)

What is polling (computing)?

In computer science, polling or a polled operation denotes the process of repeatedly sampling the status of external devices by a client program. The term polling is often used when describing input/output and referred to as software-driven I/O or polled I/O. This process can occur thousands of times a second.

Specifically, in multipoint or multidrop communication, the controlling device -- with multiple devices attached that share the same line -- sends a message to each device, one at a time, asking each whether it has anything to communicate, i.e., whether it wants to use the line.

polling vs. webhook
While the polling process sends multiple queries, a webhook only sends a message when an event occurs using HTTP POST messages to initiate action in another program when an event occurs.

What is polling in programming?

Polling is ubiquitous across computer science wherever one program waits on another for a response. For example, process A in a program may ask process C, "Do you have anything I can do?" repeatedly until it gets an answer.

Polling activity can range from a low level, such as polling the status of a wire looking for a change of voltage, to a high level as in the case of one server sending a web request to another server for information about an item.

Polling is relatively easy to implement and can be especially effective. In Unix-like systems, users may use poll() instead of select(). While the functions provide similar functionality, they differ significantly in how they handle events. For example, if the user is polling for input, then poll() returns immediately after calling the function, whereas select() waits until an event occurs before returning.

basic Unix commands
In Unix-like systems, users may perform polling using the poll() command instead of the select() command.

What are the different types of polling?

There are three main polling types:

  1. Polling cycle. A polling cycle is an interval during which each element is checked. The optimal polling cycle depends on several factors, such as the desired response speed, polling overhead and number of elements being polled.
  2. Roll-call polling. In roll-call polling, the polling message is sent out to every element in the list. When one of the elements responds, the polling loop stops, and the responding element is removed from the list. Roll-call polling uses a timing mechanism to ensure that the polling does not continue indefinitely.
  3. Hub polling. Hub polling, or token polling, is a method used to poll elements in a list. Each element polls the next one in a fixed order. When an element reaches the end of the list, it begins the process again.

What is polling rate?

Polling rate refers to how frequently a device, such as a mouse or keyboard, sends data back to the computer to which it's attached. It may be measured as rate per second or hertz (Hz).

What is keyboard polling rate?

A keyboard's polling rate is the number of times per second it checks to see if any keys have been pressed. The higher the polling rate, the better the responsiveness of the keyboard.

For example, a 1 kilohertz (kHz) polling rate means that the keyboard checks every millisecond whether any keys have been pressed; a 10 kHz polling rate means that it checks once every 10 milliseconds. Generally, a polling rate between 100 Hz and 250 Hz is good for typing; for gaming, a polling rate of 500 Hz to 1,000 Hz is preferred.

keyboard polling rate
The polling rate for a keyboard is the number of times per second the keyboard checks to see if a user has pressed any keys.

What is long polling?

Long polling is a technique used to avoid repeatedly sending requests to a remote resource, such as a Hypertext Transfer Protocol server, to retrieve updated information. Rather than requesting the same information repeatedly, the request can be sent once and held until the requested information changes.

See eight tips to optimize network bandwidth and performance.

This was last updated in February 2023

Continue Reading About polling (computing)

Networking
  • firewall as a service (FWaaS)

    Firewall as a service (FWaaS), also known as a cloud firewall, is a service that provides cloud-based network traffic analysis ...

  • private 5G

    Private 5G is a wireless network technology that delivers 5G cellular connectivity for private network use cases.

  • NFVi (network functions virtualization infrastructure)

    NFVi (network functions virtualization infrastructure) encompasses all of the networking hardware and software needed to support ...

Security
  • virus (computer virus)

    A computer virus is a type of malware that attaches itself to a program or file. A virus can replicate and spread across an ...

  • Certified Information Security Manager (CISM)

    Certified Information Security Manager (CISM) is an advanced certification that indicates that an individual possesses the ...

  • cryptography

    Cryptography is a method of protecting information and communications using codes, so that only those for whom the information is...

CIO
  • B2B (business to business)

    B2B (business-to-business) is a type of commerce involving the exchange of products, services or information between businesses, ...

  • return on investment (ROI)

    Return on investment (ROI) is a crucial financial metric investors and businesses use to evaluate an investment's efficiency or ...

  • big data as a service (BDaaS)

    Big data as a service (BDaS) is the delivery of data platforms and tools by a cloud provider to help organizations process, ...

HRSoftware
  • talent acquisition

    Talent acquisition is the strategic process an organization uses to identify, recruit and hire the people it needs to achieve its...

  • human capital management (HCM)

    Human capital management (HCM) is a comprehensive set of practices and tools used for recruiting, managing and developing ...

  • Betterworks

    Betterworks is performance management software that helps workforces and organizations to improve manager effectiveness and ...

Customer Experience
  • martech (marketing technology)

    Martech (marketing technology) refers to the integration of software tools, platforms, and applications designed to streamline ...

  • transactional marketing

    Transactional marketing is a business strategy that focuses on single, point-of-sale transactions.

  • customer profiling

    Customer profiling is the detailed and systematic process of constructing a clear portrait of a company's ideal customer by ...

Close