Millions of machines and objects are connecting to the internet for the first time, challenging an architecture that was designed during the last few decades with people in mind. As a result, companies are putting more computing resources at the edge of the network, in vehicles, elevators, factory machines and the like.

“There are certain applications and use cases where you need to have real-time machine intelligence. You cannot wait for the cloud,” Michael Nilles, CDO of Schindler Group and CEO of Schindler Digital Business says.

Startups and incumbents such as Microsoft Corp. and General Electric Co. are rushing into the market for edge products and services, which is expected to grow to $6.7 billion by 2022, up from about $1.5 billion in 2017, according to research firm MarketsandMarkets.

In this new scheme, data is processed and analyzed on or near the device where it’s generated instead of first being sent to a corporate cloud or data center. This way, devices can compute and analyze data in real-time without always relying on connectivity to a corporate cloud. The new architecture also facilitates services such as personalized mobile-app promotions based on real-time analytics.

The number of devices connected to the internet is surging, and will reach 20.4 billion by 2020, up from 8.4 billion in 2017, according to Gartner Research Inc. By 2021, 40% of enterprises will have an edge computing strategy in place, up from about 1% in 2017, Gartner says.

The self-driving car illustrates the need for edge computing. It must make life-or-death decisions in real-time. Some of these computations will be done on the car itself rather than waiting for data to travel to a cloud and back, or worse, risking a loss in connectivity to the cloud.

It typically takes 150 to 200 milliseconds for data to travel from where it’s generated to a cloud provider and back, says Don Duet, president and chief operating officer of Vapor IO, a startup working with mobile infrastructure providers to build and deploy edge servers at cell towers.

Placing servers or gateways closer to devices could shorten that time to 2 to 5 milliseconds, significantly improving performance for critical applications in areas such as health care, connected cars and smart cities, he said.

In many edge computing scenarios, a piece of hardware called a gateway is located physically near the device. The gateway aggregates information from sensors, analyzes it with software, and pushes insights and data to a corporate cloud, when necessary. In other scenarios, servers and software form an “edge cloud” near the device itself.

At Schindler, sensors in elevators detect data ranging from temperature fluctuations to energy consumption and the open and close cycles of elevator doors, Mr. Nilles said. That data is streamed to an edge device near the elevator, where machine learning algorithms integrated into the hardware detect anomalies.

If the algorithm detects that a component is about to fail, it will trigger a notification to be sent over the cloud to a maintenance worker, so the problem is identified and fixed days before an actual failure occurs, Mr. Nilles said.

Without disclosing specific metrics, Mr. Nilles said Schindler has “substantially” reduced the downtime of certain elevators and increased customer satisfaction using the edge computing architecture, which was developed with several hardware and software providers such as GE and Huawei Technologies Co. Ltd.

In 2017, Schneider Electric SE began experimenting with Microsoft Corp.’s Azure IoT Edge, which connects devices in the field to gateway hardware and is an extension of its public cloud. Schneider is using the service to predict costly mechanical problems with rod pumps, which extract oil in remote locations where wireless connectivity isn’t widely available, according to Cyril Perducat, executive vice president of digital services and Internet of Things at Schneider Electric.

Royal Caribbean in 2016 began experimenting with edge computing as a way to run a customer-facing mobile app in the middle of the ocean.

The edge computing system powering the mobile app consists of a few racks of servers and software-based applications that make up a “mini cloud,” or “edge cloud” on five ships, said Eli Tsinovoi, a manager at EY’s digital and emerging technologies division and a digital consultant for Royal Caribbean.

The mobile app can offer personalized information, based on real-time analytics from the edge, for each guest while they’re on the ship.

Real-time personalization is becoming crucial for companies in the hospitality industry to stay competitive and profitable, which is why the company was interested in pursuing the edge computing experiment this year, said Michael Delgado, Royal Caribbean’s chief technology officer.

“Our ability to personalize the experience for the guest and deliver an amazing vacation for them is all contingent on our ability to leverage this technology,” he said.