Dynamic replacement of deteriorating processing elements in streaming applications
By dynamically replacing deteriorating processing elements in stream computing applications, the system addresses inefficiencies in real-time data processing, ensuring continuous operation and reducing delays.
Patent Information
- Application Number
- JP2023524742
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2020-10-30
- Filing Date
- 2021-10-12
- Publication Date
- 2025-09-10
- Estimated Expiration
- 2041-10-12
Smart Images

Figure 0007737209000001 
Figure 0007737209000002 
Figure 0007737209000003
Abstract
Description
[Technical Field]
[0001] The present invention relates generally to methods, systems, and computer program products for stream computing. More particularly, the present invention relates to methods, systems, and computer program products for dynamic replacement of processing elements in streaming applications. [Background technology]
[0002] Database systems are typically configured to separate the process of storing data from the access, manipulation, or use of the data stored in the database. In traditional static database systems, data is first stored in memory and indexed before subsequent querying and analysis. In general, such static database systems are not always well-suited for processing and analyzing streaming data in real time. For example, static database systems are sometimes unable to store, index, and analyze large amounts of streaming data efficiently or in real time.
[0003] Stream-based computing and stream-based database computing have emerged as development techniques for database systems in recent years. In stream applications, interconnected nodes in a network allow data to flow from one node to the next. Such data flows encapsulate blocks of data as "tuples." A tuple is a block of data of one or a variety of different data types, such as integer, float, Boolean, or string data. A group of tuples is transmitted as a sequence called a "stream" or "data stream." In particular, data can arrive nearly continuously as a stream of data points corresponding to ongoing or sequential events.
[0004] For example, data representing the price of a particular stock can typically fluctuate throughout the day, and a data stream management system may continuously receive updated stock prices, e.g., at uniform time intervals or whenever the price changes. Other examples of such data streams include temperature or other environmental data collected by sensors, computer network analytics, patient health data collected by a hospital, or data describing manufacturing or other business processes. Summary of the Invention
[0005] An exemplary embodiment provides for dynamic replacement of a deteriorating processing element in a streaming application. One embodiment includes monitoring a distributed computing application at runtime for the occurrence of a condition, the distributed computing application comprising a first node including a processing element (PE), the processing element (PE) receiving a first stream of tuples from an upstream processing element (PE), performing a defined process on the first stream of tuples resulting in a second stream of tuples, and sending the second stream of tuples to a downstream PE, the condition comprising the occurrence of a degradation condition in the PE. This embodiment also includes starting a first virtual PE at runtime on the second node while maintaining runtime operation of the PE, the first virtual PE receiving the first stream of tuples from the upstream PE and performing the defined process on the first stream of tuples. This embodiment also includes comparing the operation of the PE with the operation of the first virtual PE based on performance metrics associated with computing resources. This embodiment also includes connecting the first interim PE to exchange the second stream of tuples from the PE to the downstream PE with a third stream of tuples from the first interim PE to the downstream PE. Other embodiments of this aspect include corresponding computer systems, apparatus, and computer programs stored on one or more computer storage devices, each configured to perform the actions of an embodiment.
[0006] One embodiment includes a computer usable program product that includes a computer readable storage medium and program instructions stored on the storage medium.
[0007] One embodiment includes a computer system including a processor, a computer-readable memory, a computer-readable storage medium, and program instructions stored on the storage medium and executed by the processor via the memory.
[0008] The novel features believed characteristic of the invention are set forth in the appended claims, but the invention itself, its preferred mode of use, together with further objects and advantages thereof, will best be understood by reference to the following detailed description of illustrative embodiments, read in connection with the accompanying drawings. [Brief explanation of the drawings]
[0009] [Figure 1] 1 is a block diagram of a network of data processing systems in which illustrative embodiments may be implemented; [Figure 2] 1 is a block diagram of a data processing system in which illustrative embodiments may be implemented; [Figure 3] FIG. 1 is a block diagram of an exemplary stream application environment in accordance with an exemplary embodiment. [Figure 4] FIG. 2 is a block diagram of an exemplary compute node in accordance with an exemplary embodiment. [Figure 5] FIG. 1 is a block diagram of an example management system in accordance with an example embodiment. [Figure 6] FIG. 2 is a block diagram of an exemplary interim PE analysis module according to an exemplary embodiment. [Figure 7] FIG. 1 is a block diagram of an operator graph for a stream computing application in accordance with an illustrative embodiment. [Figure 8] FIG. 1 is a block diagram of an operator graph for a stream computing application having a virtual PE, according to an example embodiment. [Figure 9] 10 is a flowchart of an exemplary dynamic PE replacement process according to an exemplary embodiment. [Figure 10] 10 is a flowchart of an exemplary interim PE troubleshooting process according to an exemplary embodiment. [Figure 11] 10 is a flowchart of an exemplary interim PE troubleshooting process according to an exemplary embodiment. [Figure 12] 10 is a flowchart of an exemplary interim PE troubleshooting process according to an exemplary embodiment. DETAILED DESCRIPTION OF THE INVENTION
[0010] Stream-based computing and stream-based database computing are emerging as development techniques for database systems. Products are available that enable users to create applications that process and query streaming data before it reaches database files. Using this emerging technology, users can specify processing logic to apply to inbound data records "in flight" and make the results available in very short timescales, often less than a second. Building applications using this type of processing opens up new programming paradigms that enable the development of a wide variety of innovative applications, systems, and processes, while also presenting new challenges for application programmers and database developers.
[0011] The main components of a stream processing application include tuples, data streams, operators, PEs, and jobs. A "tuple" is an individual piece of data in a data stream. As used herein, a "data stream" refers to a running sequence of tuples. As used herein, an "operator" is a logical function that manipulates tuple data from an incoming data stream to result in the form of an output data stream. As used herein, an "operator graph" is a visual representation of operators connected by the data streams flowing through them that define an analytical application. As used herein, a "processing element" or "PE" is an executable containing a set of one or more operators running in the same process on a network node or computing resource, for example, a server, client, host, container, or other computing device such as a data processing system. As used herein, a "node" is a network node that includes any electronic device that is addressable in a computer network and capable of creating, receiving, or transmitting information, or a combination thereof, in that computer network, and may refer to an element, module, component, board, device, or system.
[0012] A stream processing job has a directed graph of PEs that send data tuples among themselves. PEs operate on incoming tuples and output output tuples. PEs are independent processing units that run on hosts. A stream platform can consist of a collection of hosts suitable for deploying PEs.
[0013] In a stream computing application, PEs are therefore connected to each other such that data flows from one PE to the next over a network connection (e.g., via a TCP / IP socket). Data flows from one stream operator to another in the form of tuples, which contain a sequence of an entity and one or more associated attributes.
[0014] Stream computing applications handle large amounts of data that need to be processed efficiently and in real time. Stream computing can achieve high streaming performance and scalability by creating executable files (i.e., PEs) and distributing applications across multiple nodes by replicating the PEs on multiple nodes and balancing the load between them. Thus, a stream computing application may continuously ingest and analyze hundreds of thousands of messages per second and petabytes of data per day. Therefore, each stream operator in a stream computing application may be required to process received tuples within fractions of a second.
[0015] The advantages of products such as IBM® Streams are their high scalability and performance. (IBM is a registered trademark of International Business Machines Corporation.) Performance advantages include improvements in being able to ingest, filter, analyze, and correlate potentially much larger continuous data streams in a given time frame than was previously possible. However, if a streaming application is "lazy" in its processing, the analysis it performs loses value; that is, the analysis is based on the past rather than the most recent data.
[0016] A streaming application can be delayed simply because one part of the application is not performing well. A streaming application can also be delayed due to failures within the application. While a streaming service provider or operating system can support high availability and application failover, failure recovery mechanisms include periods of time when data is not processed while recovery occurs. For example, the amount of time it takes for a processing element (PE) to fail and restart can be 20 to 30 seconds or even minutes, depending on several factors (e.g., whether it is a rapid failure or a gradual failure in which the PE gradually slows down before finally failing, the amount of time to create / plan new resources to host the restarted PE, the amount of time to deploy the new PE, etc.).
[0017] The longer it takes to recover from a failure, the longer the backlog of unprocessed real-time data becomes, causing the application to lag behind real-time until it "catches up" with the most recent data. When multiple failures occur, the long recovery period can result in the application being completely flooded with real-time data, causing a complete failure.
[0018] Exemplary embodiments of the present disclosure address problems and performance goals specific to stream processing by monitoring its processing elements (PEs) for degradation and replacing a deteriorating PE with a better-performing replica of itself before it fails. Some such embodiments provide one or more advantages over conventional techniques, such as proactively replacing a deteriorating PE with a healthier replica of itself before it fails, enabling switchover to a replacement PE much more quickly than going through a full failure recovery scenario, reducing or avoiding the accumulation of unprocessed real-time data during the failure recovery process, improving streaming application performance by replacing underperforming PEs, and providing a way to avoid PE failures and their associated time-consuming recovery.
[0019] In an example embodiment, a stream manager monitors a streaming application and maintains statistics describing the performance of the various PEs that comprise the streaming application. In some embodiments, the stream manager monitors the PEs for degradation and, when degradation of one or more PEs is detected, initiates a troubleshooting process or provides notification signals or data to a troubleshooting module or separate application. For example, in some embodiments, a PE monitors itself for signs of degradation and, when the PE detects degradation, sends a signal to the stream manager.
[0020] In some embodiments, the stream manager detects degradation of a PE by monitoring the PE for the occurrence of conditions that serve as indicators of degradation, which may differ from one PE to another. In some embodiments, the thresholds for indicators of degradation conditions may also differ from one PE to another. Thus, in some such embodiments, the indicators of degradation conditions are configurable for each PE.
[0021] In some embodiments, the indicators of degradation include execution conditions associated with a PE that deviate from a predefined or expected pattern. For example, in some embodiments, the indicators of degradation include an abnormal amount of waiting tuples (i.e., tuples waiting to be processed at input ports of operators on the PE), abnormal memory usage, number and types of handled exceptions, and abnormal CPU consumption.
[0022] In some embodiments, a stream manager monitors multiple PEs. In other embodiments, a stream manager only monitors a single PE. In some embodiments, the stream manager maintains statistics representing the normal or expected performance of a PE prior to degradation of the PE. In some embodiments, the stream manager records the use of such computing resources by PEs, allowing normal usage patterns to be established, thereby also allowing abnormal usage patterns to be detected.
[0023] In some embodiments, the abnormal amount of waiting tuples comprises a larger than normal amount of waiting tuples. In some embodiments, the abnormal memory usage comprises an abnormally high rate of change in memory usage. In some embodiments, the abnormal CPU consumption comprises an abnormally high rate of change in CPU consumption.
[0024] In some embodiments, when a stream manager detects a degraded PE, the stream manager performs an initial analysis on the degraded PE. In some such embodiments, the stream manager analyzes the degraded PE to determine whether symptoms that may indicate degraded performance, such as backpressure or one or more cluster computing resources reaching capacity, are actually symptoms of a problem other than degradation of the PE whose performance is degraded.
[0025] In some such embodiments, when the stream manager detects a PE degradation but no other problems, the stream manager tests the use of one or more temporary PEs as possible replacements for the deteriorating PE. In some such embodiments, the stream manager communicates with the scheduler to identify a node to host the temporary PE. In some embodiments, the scheduler searches nodes other than the node hosting the PE. In some embodiments, the scheduler also searches for nodes based on predetermined rules or criteria, such as, for example, availability of computing resources or proximity to upstream and downstream PEs. In some embodiments, once the scheduler identifies a host node, the scheduler notifies the stream manager of the selected location for the temporary PE.
[0026] In some embodiments, the stream manager launches a virtual PE on the identified node at runtime that maintains the runtime operation of the degraded PE. In some such embodiments, the stream manager connects the virtual PE to the same upstream PE from the degraded PE so that both the virtual PE and the degraded PE simultaneously receive the same stream of tuples from the same upstream PE. In some such embodiments, both the virtual PE and the degraded PE perform the same defined process on the stream of tuples, thereby allowing the stream manager to compare the performance of the degraded PE with the performance of the virtual PE. In some such embodiments, the degraded PE performs a defined process on the stream of tuples, resulting in an output stream of tuples that the degraded PE sends to downstream PEs, while the output of the virtual PE is not connected to any downstream elements.
[0027] In some embodiments, the stream manager compares the behavior of the degraded PE with the behavior of the virtual PE based on performance metrics associated with one or more computing resources. For example, in some embodiments, the stream manager compares the behavior of the degraded PE with the behavior of the virtual PE by comparing one or more of CPU usage, memory usage, and tuple throughput rate. In some such embodiments, if the stream manager determines that the virtual PE outperforms the degraded PE, the stream manager replaces the degraded PE with the virtual PE, e.g., by connecting the output of the virtual PE to a downstream PE instead of the degraded PE, and the stream manager shuts down the degraded PE. In some embodiments, the stream manager sends a notification of the replacement of the degraded PE with the virtual PE to a user via a user interface.
[0028] For clarity of explanation, and without implying any limitations thereto, the exemplary embodiments are described using several exemplary configurations. From this disclosure, one skilled in the art will recognize many variations, adaptations, and modifications of the described configurations to achieve the described objectives, which are considered to be within the scope of the exemplary embodiments.
[0029] Furthermore, simplified illustrations of data processing environments are used in the figures and exemplary embodiments. In an actual computing environment, additional structures or components not shown or described herein, or structures or components for functions different from those shown but similar to those described herein, may be present without departing from the scope of the exemplary embodiments.
[0030] Furthermore, the exemplary embodiments are described by way of example only, and with reference to particular actual or hypothetical components. The steps described by various exemplary embodiments can be adapted to provide explanations for decisions made by, for example, a machine learning classification model.
[0031] No particular manifestation of these or other similar artifacts is intended as a limitation on the present invention, and any suitable manifestation of these or other similar artifacts may be selected to fall within the scope of the exemplary embodiments.
[0032] The examples in this disclosure are used only for clarity of explanation and do not act as limitations on the example embodiments. Any advantages listed herein are merely examples and are not intended to be limitations on the example embodiments. Additional or different advantages may be realized by certain example embodiments. Furthermore, certain example embodiments may have some, all, or none of the advantages listed above.
[0033] Additionally, exemplary embodiments may be implemented with any type of data, data source, or access to a data source via a data network. Any type of data storage device may provide data to an embodiment of the present invention, either locally at a data processing system or via a data network, within the scope of the present invention. When describing an embodiment using a mobile device, any type of data storage device suitable for use with a mobile device may provide data to such an embodiment, either locally at the mobile device or via a data network, within the scope of the exemplary embodiments.
[0034] The exemplary embodiments are described using specific code, contrasting descriptions, computer-readable storage media, high-level features, historical data, designs, architectures, protocols, layouts, schematics, and tools as examples only, and are not intended to be limiting. Furthermore, the exemplary embodiments are described in some examples using specific software, tools, and data processing environments for clarity of explanation only, as examples. The exemplary embodiments may be used with other equivalent or similar purpose structures, systems, applications, or architectures. For example, other equivalent mobile devices, structures, systems, applications, or architectures thereof may be used with such embodiments of the present invention within the scope of the present invention. The exemplary embodiments may be implemented in hardware, software, or a combination thereof.
[0035] The examples in this disclosure are used for clarity of explanation only and are not intended to limit the exemplary embodiments. Additional data, operations, actions, tasks, activities, and operations are contemplated by this disclosure, and the same are contemplated within the scope of the exemplary embodiments.
[0036] Any advantages listed herein are merely examples and are not limiting of example embodiments. Additional or different advantages may be realized by particular example embodiments. Furthermore, a particular example embodiment may have some, all, or none of the above-listed advantages.
[0037] Referring now to the figures, and in particular to Figures 1 and 2, these figures are exemplary diagrams of data processing environments in which illustrative embodiments may be implemented. Figures 1 and 2 are merely examples and are not intended to assert or imply any limitation with respect to the environments in which different embodiments may be implemented. In particular implementations, many modifications to the depicted environments may be made based on the description below.
[0038] 1 illustrates a block diagram of a network of data processing systems in which exemplary embodiments may be implemented. Data processing environment 100 is a network of computers in which exemplary embodiments may be implemented. Data processing environment 100 includes network 102. Network 102 is the medium used to provide communications links between the various interconnected devices and computers within data processing environment 100. Network 102 may include connections such as wired, wireless communication links, or fiber optic cables.
[0039] Client or server are merely exemplary roles for particular data processing systems connected to network 102 and are not intended to exclude other configurations or roles of these data processing systems. Data processing system 104 is coupled to network 102. Software applications may execute on any data processing system in data processing environment 100. Any software application described as executing on processing system 104 in FIG. 1 may be similarly configured to execute on another data processing system. Any data or information stored or created on data processing system 104 in FIG. 1 may be similarly configured to be stored or created on another data processing system. A data processing system, such as data processing system 104, may contain data and may include software applications or software tools that execute computing processes thereon. In one embodiment, data processing system 104 includes memory 124, which includes application 105A, which may be configured to implement one or more of the data processor functions described herein in accordance with one or more embodiments.
[0040] Server 106 is coupled to network 102 along with storage unit 108. Storage unit 108 includes database 109 configured to store data described herein in connection with various embodiments, such as image data and attribute data. Server 106 is a conventional data processing system. In one embodiment, server 106 includes a PE of stream processing application 105B that may be configured to implement one or more of the processor functions described herein in accordance with one or more embodiments.
[0041] Clients 110, 112, and 114 are also coupled to network 102. A conventional data processing system, such as server 106 or client 110, 112, or 114, may contain data and may have software applications or tools that perform conventional computing processes thereon.
[0042] By way of example only, and without implying any limitation to such an architecture, Figure 1 illustrates certain components that may be used in an exemplary implementation of one embodiment. For example, server 106 and clients 110, 112, and 114 are shown as servers and clients by way of example only, and do not imply any limitation to a single client-server architecture. As another example, one embodiment may be distributed across a data network, as illustrated, as several data processing systems, while another embodiment may be implemented in a single data processing system within the scope of this exemplary embodiment. Conventional data processing systems 106, 110, 112, and 114 also represent exemplary nodes in clusters, partitions, and other configurations suitable for implementing embodiments.
[0043] Device 132 is an example of a conventional computing device as described herein. For example, device 132 may take the form of a smartphone, a tablet computer, a laptop computer, a stationary or portable client 110, a wearable computing device, or any other suitable device. In one embodiment, device 132 sends a request to server 106 to perform one or more data processing tasks via stream processing application 105B, such as the initial process described herein. Any software application depicted as running on another conventional data processing system in FIG. 1 may also be configured to run on device 132. Any data or information stored or created on another conventional data processing system in FIG. 1 may also be configured to be stored or created on device 132.
[0044] Server 106, storage unit 108, data processing system 104, clients 110, 112, and 114, and device 132 may be coupled to network 102 using wired connections, wireless communication protocols, or other suitable data connections. Clients 110, 112, and 114 may be, for example, personal computers or network computers.
[0045] In the example shown, server 106 may provide data such as boot files, operating system images, and applications to clients 110, 112, and 114. Clients 110, 112, and 114 may be clients to server 106 in this example. Clients 110, 112, 114, or any combination thereof, may include their own data, boot files, operating system images, and applications. Data processing environment 100 may include additional servers, clients, and other devices not shown.
[0046] In the illustrated example, memory 124 may provide data such as boot files, operating system images, and applications to processor 122. Processor 122 may include its own data, boot files, operating system images, and applications. Data processing environment 100 may include additional memory, processors, and other devices not shown.
[0047] In the depicted example, data processing environment 100 may be the Internet. Network 102 may represent a collection of networks and gateways that communicate with each other using Transmission Control Protocol / Internet Protocol (TCP / IP) and other protocols. At the heart of the Internet is a backbone of data communication links between major nodes or host computers, including thousands of commercial, government, educational, and other computer systems that route data and messages. Of course, data processing environment 100 may also be implemented as a number of different types of networks, such as, for example, an intranet, a local area network (LAN), or a wide area network (WAN). Figure 1 is intended as an example, and not as architectural limitations to different illustrative embodiments.
[0048] Among other uses, data processing environment 100 may be used to implement a client-server environment in which exemplary embodiments may be implemented. A client-server environment allows software applications and data to be distributed across a network, with applications functioning using interactivity between traditional client and server data processing systems. Data processing environment 100 may also employ a service-oriented architecture in which interoperable software components distributed across a network may be packaged together as a coherent business application. Data processing environment 100 may also take the form of a cloud and employ a cloud computing model of service delivery to enable convenient, on-demand network access to a shared pool of configurable computing resources (e.g., networks, network bandwidth, servers, processing, memory, storage, applications, virtual machines, and services) that can be rapidly provisioned and released with minimal administrative effort or interaction with a service provider.
[0049] Referring to Figure 2, this figure illustrates a block diagram of a data processing system in which exemplary embodiments may be implemented. Data processing system 200 is an example of a conventional computer, such as data processing system 104, server 106, or clients 110, 112, and 114 of Figure 1, or other type of device in which computer-usable program code or instructions implementing the processes of exemplary embodiments may be located.
[0050] Data processing system 200 also represents a conventional data processing system or configuration therein, such as conventional data processing system 132 of FIG. 1, in which computer-usable program code or instructions implementing the processes of the illustrative embodiments may be located. Data processing system 200 is described as a computer by way of example only, and without limitation. Implementations in the form of other devices, such as device 132 of FIG. 1, may modify data processing system 200, such as by adding a touch interface, or even omit certain illustrated components from data processing system 200, without departing from the general description of the operation and functionality of data processing system 200 described herein.
[0051] In the illustrated example, data processing system 200 employs a hub architecture including a north bridge and memory controller hub (NB / MCH) 202 and a south bridge and input / output (I / O) controller hub (SB / ICH) 204. A processing unit 206, a main memory 208, and a graphics processor 210 are coupled to north bridge and memory controller hub (NB / MCH) 202. Processing unit 206 may include one or more processors and may be implemented using one or more heterogeneous processor systems. Processing unit 206 may be a multi-core processor. In certain implementations, graphics processor 210 may be coupled to NB / MCH 202 via an accelerated graphics port (AGP).
[0052] In the illustrated example, a local area network (LAN) adapter 212 is coupled to a south bridge and I / O controller hub (SB / ICH) 204. An audio adapter 216, a keyboard and mouse adapter 220, a modem 222, a read-only memory (ROM) 224, a universal serial bus (USB) and other ports 232, and PCI / PCIe® devices 234 are coupled to the south bridge and I / O controller hub 204 via a bus 238. A hard disk drive (HDD) or solid state drive (SSD) 226 and a CD-ROM 230 are coupled to the south bridge and I / O controller hub 204 via a bus 240. The PCI / PCIe® devices 234 may include, for example, an Ethernet adapter, an add-in card, and a PC card for a notebook computer. PCI uses a card bus controller, while PCIe does not. ROM 224 may be, for example, a flash binary input / output system (BIOS). Hard disk drive 226 and CD-ROM 230 may use, for example, integrated drive electronics (IDE), serial advanced technology attachment (SATA) interfaces, or variations such as external SATA (eSATA) and micro-SATA (mSATA). Super I / O (SIO) device 236 may be coupled to south bridge and I / O controller hub (SB / ICH) 204 via bus 238.
[0053] Memory such as main memory 208, ROM 224, or flash memory (not shown) are some examples of computer-usable storage devices. Hard disk drives or solid state drives 226, CD-ROMs 230, and other similarly usable devices are some examples of computer-usable storage devices that include computer-usable storage media.
[0054] An operating system runs on processing unit 206. The operating system coordinates and controls various components within data processing system 200 of FIG. 2. The operating system may be a commercially available operating system for any type of computing platform, including, but not limited to, server systems, personal computers, and mobile devices. An object-oriented or other type of programming system may work in conjunction with the operating system to provide calls to the operating system from programs or applications running on data processing system 200.
[0055] 1 may be located on a storage device, such as in the form of code 226A on hard disk drive 226, and loaded into at least one of one or more memories, such as main memory 208, for execution by processing unit 206. The processing of exemplary embodiments may be performed by processing unit 206 using computer-implemented instructions, which may be located in a memory, such as main memory 208, read-only memory 224, or in one or more peripheral devices.
[0056] Additionally, in some cases, code 226A may be downloaded over network 201A from remote system 201B, where similar code 201C is stored in storage device 201D. In other cases, code 226A may be downloaded over network 201A to remote system 201B, where the downloaded code 201C is stored in storage device 201D.
[0057] The hardware in Figures 1 and 2 may vary depending on the implementation. Other internal hardware or peripheral devices, such as flash memory, equivalent non-volatile memory, or optical disk drives, may be used in addition to or in place of the hardware depicted in Figures 1 and 2. Additionally, the processing of the illustrative embodiments may be applied to multiprocessor data processing systems.
[0058] In some illustrative examples, data processing system 200 may be a personal digital assistant (PDA), which is typically configured with flash memory to provide non-volatile memory for storing operating system files and / or user-generated data. The bus system may include one or more buses, such as a system bus, an I / O bus, and a PCI bus. Of course, the bus system may be implemented using any type of communications fabric or architecture that provides for a transfer of data between various components or devices attached to the fabric or architecture.
[0059] The communications unit may include one or more devices used to transmit and receive data, such as a modem or network adapter. The memory may be, for example, main memory 208 or a cache, such as that found in north bridge and memory controller hub 202. The processing unit may include one or more processors or CPUs.
[0060] 1 and 2 and above-described examples are not meant to imply architectural limitations. For example, data processing system 200 may also be a tablet computer, a laptop computer, or a telephone device in addition to taking the form of a mobile or wearable device.
[0061] When a computer or data processing system is described as a virtual machine, virtual device, or virtual component, the virtual machine, virtual device, or virtual component operates like data processing system 200 by using virtualized representations of some or all of the components depicted within data processing system 200. For example, in a virtual machine, virtual device, or virtual component, processing unit 206 is represented as a virtualized instance of all or a portion of the hardware processing unit 206 available to the host data processing system, main memory 208 is represented as a virtualized instance of all or a portion of the main memory 208 that may be available to the host data processing system, and disk 226 is represented as a virtualized instance of all or a portion of the disk 226 that may be available to the host data processing system. The host data processing system in such a case is represented by data processing system 200.
[0062] 3, a block diagram of an exemplary streams application environment 300 according to an exemplary embodiment is shown. In one embodiment, streams application environment 300 is configured to execute a streams application, which is an example of application 105A / 105B of FIG. 1.
[0063] In an exemplary embodiment, stream application environment 300 includes management system 305 and multiple computing nodes 310A-310D (generically referred to herein as nodes 310), i.e., hosts, communicatively coupled to one another using one or more communications networks 320. In one embodiment, communications network 320 includes one or more servers, networks, or databases and uses a communications protocol to transfer data among computing nodes 310. In one embodiment, database system 315, including database 340, is communicatively coupled to network 320 for communication with computing nodes 310. In a specific embodiment, database 315 is an example of server 106 with database 109 of FIG. 1, and nodes 310A-310D are examples of data processing system 104, clients 110, 112, and 114, and devices 132 of FIG. 1.
[0064] In this exemplary embodiment, one or more compute nodes 310A-310D are configured as shown for compute node 310D, such that each compute node 310A-310D includes one or more PEs 312, each of which includes one or more operators 314. The operators 314 are the basic building blocks of stream applications, enabling stream applications to become distributed computing applications. In some embodiments, the compute nodes 310A-310D each run the Linux® operating system, each PE 312 represents a Linux process, and within each Linux process resides an operator 314 that operates one or more aspects of the stream application such that the stream application is distributed among the operators 314, PEs 312, and compute nodes 310A-310D.
[0065] In some embodiments, management system 305 includes an operator graph 332 and a stream manager 334. In some embodiments, a developer using stream computing services writes a stream application by defining an operator graph 332, which is compiled and submitted to management system 305.
[0066] Stream manager 334 places operators in operator graph 332 on one or more PEs in one or more compute nodes, which may include one or more of compute nodes 310A-310D. In some embodiments, operator graph 332 includes a description of the stream network topology, including the location, placement, connections, and functionality of various operators in nodes 310 of stream application environment 300.
[0067] A PE, such as PE 312, hosts one or more operators, such as operator(s) 314, which operate on input tuples and produce output tuples. PEs have independent processing units and run on nodes, such as any of compute nodes 310A-310D. In a stream application, PEs 312 are interconnected so that data flows from one PE to the next. Data flows from one PE to the next in the form of tuples, each tuple containing a sequence of one or more attributes associated with an entity.
[0068] In some embodiments, the stream manager 334 monitors the PEs 312 for degradation and replaces a deteriorating PE with a better-performing replica of itself before it fails. Streaming applications process potentially large amounts of data in real time. If a streaming application is "delayed" with respect to its processing, the analysis it performs may lose its value, i.e., the results of the analysis may be based on past data rather than the most recent point in time. An application may be delayed simply because a portion of the application, such as a single PE, is performing poorly. Thus, detecting and replacing a deteriorating PE before it fails, as described herein, provides significant performance and efficiency improvements for streaming applications.
[0069] 4, a block diagram of an exemplary computing node 400 according to an exemplary embodiment is shown. In one embodiment, computing node 400 is an example of computing nodes 310A-310D of FIG.
[0070] In this exemplary embodiment, compute node 400 includes one or more processors (CPUs) 402, a network interface 408, an interconnect 410, memory 412, and storage 414. Compute node 400 may also include an I / O device interface 404 used to connect I / O devices 406, such as, for example, a keyboard, a display, and a mouse device, to compute node 400. In some embodiments, the functionality described herein is distributed among multiple systems, which may include, for example, a combination of software-based systems, hardware-based systems, or both, such as application-specific integrated circuits (ASICs), computer programs, or smartphone applications.
[0071] In some embodiments, each CPU 402 retrieves and executes programming instructions stored in memory 412 or storage 414. Similarly, in some embodiments, CPU 402 stores and retrieves application data resident in memory 412. In some embodiments, interconnect 410 transmits programming instructions and application data between each CPU 402, I / O device interface 404, storage 414, network interface 408, and memory 412.
[0072] In some embodiments, one or more PEs 416 are stored in memory 412. In some such embodiments, a PE 416 includes one or more stream operators 418. In some embodiments, a PE 416 is assigned to execute by only one CPU 402, while in other embodiments, a PE 416's stream operator 418 includes one or more threads executing on two or more CPUs 402. Memory 412 is generally included as representative of random access memory, such as static random access memory (SRAM), dynamic random access memory (DRAM), or flash. Storage 414 includes a buffer 422 and is generally included as representative of non-volatile memory, such as a hard disk drive, solid state device (SSD), or removable memory card, optical storage, flash memory device, network-attached storage (NAS), or connection to a storage area network (SAN) device, or other device that may store non-volatile data.
[0073] In some embodiments, a stream application includes one or more stream operators 418 compiled into a PE 416. In some embodiments, the memory 412 includes two or more PEs 416, each PE having one or more stream operators 418. In some embodiments, each stream operator 418 includes a portion of code in a stream computing application that processes tuples flowing into a PE and outputs the tuples to other stream operators 418 on the same PE, another PE, or both the same PE and another PE. In some embodiments, a PE 416 sends tuples to other PEs on the same compute node 400 or on another compute node accessible via a communications network. For example, in one embodiment, a first PE 416 on a first compute node 400 outputs a tuple to a second PE 416 on a second compute node 400.
[0074] In some embodiments, the PE 416 includes a performance monitor 420. In some embodiments, the performance monitor 420 monitors the PE 416 for degradation and generates a notification signal or data when degradation of the PE 416 is detected. For example, in some embodiments, the performance monitor 420 signals a stream manager (e.g., stream manager 334 of FIG. 3 ) when the performance monitor 420 detects degradation in the performance of the PE 416.
[0075] In some embodiments, the performance monitor 420 detects degradation by monitoring the PE 416 for the occurrence of conditions that serve as indicators of degradation, which may vary from one PE 416 to another. In some embodiments, the thresholds for indicators of degradation conditions may vary from one PE 416 to another. Thus, in some such embodiments, indicators of degradation conditions are configurable for each PE 416. In some embodiments, indicators of degradation conditions include execution conditions associated with the PE 416 that deviate from predefined or expected patterns. For example, in some embodiments, indicators of degradation include an abnormal amount of waiting tuples (i.e., tuples waiting to be processed at input ports of operators in the PE), abnormal memory usage, the number and types of handled exceptions, and abnormal CPU consumption. In some embodiments, the performance monitor 420 monitors the PE 416 and maintains statistics that represent the normal or expected performance of the PE 416. In some embodiments, performance monitor 420 records use of such computing resources by PE 416 to allow normal usage patterns to be established, thereby also allowing abnormal usage patterns to be detected. In some embodiments, the abnormal amount of waiting tuples includes a larger than normal amount of waiting tuples. In some embodiments, the abnormal memory usage includes an abnormally high rate of change in memory usage. In some embodiments, the abnormal CPU consumption includes an abnormally high rate of change in CPU consumption.
[0076] 5, a block diagram of an exemplary management system 500 is shown in accordance with an exemplary embodiment. In one embodiment, management system 500 is an example of management system 305 of FIG.
[0077] In the illustrated embodiment, the management system 500 includes one or more processors (CPUs) 502, a network interface 508, an interconnect 510, memory 512, and storage 514. The management system 500 may also include an I / O device interface 504 that connects I / O devices 506, such as keyboards, displays, and mouse devices, to the management system 500. In some embodiments, the functionality described herein is distributed among multiple systems, which may include a combination of software-based systems, hardware-based systems, or both, such as application-specific integrated circuits (ASICs), computer programs, or smartphone applications.
[0078] In some embodiments, each CPU 502 retrieves and executes programming instructions stored in memory 512 or storage 514. Similarly, in some embodiments, each CPU 502 stores and retrieves application data resident in memory 512 or storage 514. Interconnect 510 is used to move data, such as programming instructions and application data, between CPU 502, I / O device interface 504, storage 514, network interface 508, and memory 512. Storage 514 is generally included as representative of non-volatile memory, e.g., a hard disk drive, a solid-state device (SSD), a removable memory card, optical storage, a flash memory device, network-attached storage (NAS), a connection to a storage area network (SAN) device, or the cloud. In some embodiments, network interface 508 is configured to transmit data over a communications network.
[0079] In some embodiments, memory 512 stores a stream manager 516. Additionally, in some such embodiments, storage 514 stores an operator graph 522 that defines how tuples are routed to PEs for processing. In the illustrated embodiment, stream manager 516 also includes a temporary PE analysis module 518 and a scheduler 524. In the illustrated embodiment, temporary PE analysis module 518 includes a performance monitor 520.
[0080] In some embodiments, the analysis module 518 monitors PEs for degradation and replaces a deteriorating PE with a better-performing replica of itself before it fails. Streaming applications process potentially large amounts of data in real time. If a streaming application is “delayed” with respect to its processing, the analysis it performs may lose its value, i.e., the results of the analysis may be based on historical data rather than the most recent point in time. An application may be delayed simply because a portion of the application, such as a single PE, is performing poorly. Thus, detecting and replacing a deteriorating PE before it fails, as described herein, provides significant performance and efficiency improvements for streaming applications.
[0081] In some embodiments, performance monitor 520 monitors the streaming application and maintains statistics describing the performance of the various PEs that make up the streaming application. In some embodiments, performance monitor 520 is part of stream manager 516, as shown. In other embodiments, performance monitor 520 is invoked at runtime but may be a separate entity from runtime stream manager 516.
[0082] In some embodiments, performance monitor 520 monitors PEs for degradation and generates notification signals or data when degradation of one or more PEs is detected. For example, in some embodiments, performance monitor 520 signals stream manager 516 when performance monitor 520 detects degradation in the performance of a PE.
[0083] In some embodiments, the performance monitor 520 detects degradation by monitoring the PEs for the occurrence of conditions that serve as indicators of degradation, which may vary from one PE 416 to another. In some embodiments, the thresholds for indicators of degradation conditions may vary from one PE 416 to another. Thus, in some such embodiments, indicators of degradation conditions are configurable for each PE 416. In some embodiments, indicators of degradation conditions include execution conditions associated with a PE that deviate from predefined or expected patterns. For example, in some embodiments, indicators of degradation include an abnormal amount of waiting tuples (i.e., tuples waiting to be processed at input ports of operators in the PE), abnormal memory usage, the number and types of handled exceptions, and abnormal CPU consumption. In some embodiments, the performance monitor 520 monitors the PEs and maintains statistics representing the normal or expected performance of the PEs. In some embodiments, the performance monitor 520 also enables abnormal usage patterns to be detected by recording the use of such computing resources by the PEs, allowing normal usage patterns to be established. In some embodiments, the abnormal amount of waiting tuples comprises a larger than normal amount of waiting tuples. In some embodiments, the abnormal memory usage comprises an abnormally high rate of change in memory usage. In some embodiments, the abnormal CPU consumption comprises an abnormally high rate of change in CPU consumption.
[0084] In some embodiments, analysis module 518 analyzes a PE identified by performance monitor 520 as exhibiting one or more signs of degradation. In some embodiments, analysis module 518 analyzes the PE to determine whether the signs identified by performance monitor 520 are in fact signs of a problem other than PE degradation, such as backpressure or one or more cluster computing resources reaching capacity. In some such embodiments, if analysis module 518 does not detect a problem other than PE degradation, analysis module 518 then evaluates the PE using a provisional PE. In some such embodiments, analysis module 518 uses scheduler 524 to identify a node to host the provisional PE. In some embodiments, scheduler 524 searches for nodes other than the node hosting the PE. In some embodiments, scheduler 524 also searches for nodes based on predetermined rules or criteria, such as, for example, availability of computing resources or proximity to upstream and downstream PEs.
[0085] In some embodiments, once scheduler 524 identifies a host node, analysis module 518 launches a virtual PE on the identified node at runtime while maintaining the runtime operation of the PE. In some such embodiments, the virtual PE is connected to the same upstream PE as the analyzed PE such that both the virtual PE and the analyzed PE simultaneously receive the same stream of tuples from the same upstream PE. In some such embodiments, both the virtual PE and the analyzed PE perform the same defined process on the stream of tuples. In some such embodiments, the analyzed PE performs a defined process on the stream of tuples, resulting in an output stream of tuples that the PE sends to downstream PEs, while the output of the virtual PE is not connected to any downstream elements.
[0086] In some embodiments, analysis module 518 compares the behavior of the analyzed PE with the behavior of the hypothetical PE based on performance metrics associated with one or more computing resources. In some such embodiments, if analysis module 518 determines that the hypothetical PE outperforms the analyzed PE, analysis module 518 replaces the analyzed PE with the hypothetical PE, e.g., by connecting an output of the hypothetical PE to a downstream PE instead of the analyzed PE, after which the analyzed PE is shut down.
[0087] 6, a block diagram of an exemplary interim PE analysis module 600 according to an exemplary embodiment is shown. In one embodiment, interim PE analysis module 600 is an example of interim PE analysis module 518 of FIG.
[0088] In the illustrated embodiment, the provisional PE analysis module 600 includes a performance monitor 602, an initial analysis module 604, and a provisional troubleshooter 606. In the illustrated embodiment, the provisional troubleshooter 606 includes a provisional PE generator 610, a performance comparator 612, and a system updater 614. In some embodiments, the functionality described herein is distributed among multiple systems, which may include a combination of software-based systems, hardware-based systems, or both, such as, for example, application-specific integrated circuits (ASICs), computer programs, or smartphone applications.
[0089] In the illustrated embodiment, performance monitor 602 monitors the streaming application and maintains statistics describing the performance of the various PEs that comprise the streaming application. In some embodiments, performance monitor 602 monitors the PEs for degradation and generates notification signals or data when degradation of one or more PEs is detected. For example, in some embodiments, performance monitor 602 signals initial analysis module 604 when performance monitor 602 detects degradation in the performance of a PE, such as performance-degraded PE 608 shown in FIG. 6 .
[0090] In some embodiments, the performance monitor 602 detects degradation of a degraded PE 608 by monitoring the degraded PE 608 for the occurrence of conditions that serve as indicators of degradation, which may vary from one PE to another. In some embodiments, the thresholds for indicator conditions may also vary from one PE to another. Thus, in some such embodiments, indicator conditions are configurable for each PE. In some embodiments, indicator conditions include execution conditions associated with a PE that deviate from predefined or expected patterns. For example, in some embodiments, indicators of degradation include an abnormal amount of waiting tuples (i.e., tuples waiting to be processed at input ports of operators in the PE), abnormal memory usage, the number and types of handled exceptions, and abnormal CPU consumption. In some embodiments, the performance monitor 602 monitors multiple PEs, including the degraded PE 608. In another embodiment, the performance monitor 602 monitors only the degraded PE 608. In some embodiments, the performance monitor 602 maintains statistics representing the normal or expected performance of the performance-degraded PE 608 prior to the degradation of the PE 608. In some embodiments, the performance monitor 602 also records the use of such computing resources by the performance-degraded PE 608 to allow normal usage patterns to be established, thereby enabling abnormal usage patterns to be detected. In some embodiments, the abnormal amount of waiting tuples comprises a larger than normal amount of waiting tuples. In some embodiments, the abnormal memory usage comprises an abnormally high rate of change in memory usage. In some embodiments, the abnormal CPU consumption comprises an abnormally high rate of change in CPU consumption.
[0091] In some embodiments, the initial analysis module 604 analyzes the degraded PE 608 once it is identified by the performance monitor 602 as exhibiting one or more symptoms of degradation. In some embodiments, the initial analysis module 604 analyzes the degraded PE 608 to determine whether the symptoms identified by the performance monitor 602 are in fact symptoms of a problem separate from the degradation of the degraded PE 608, such as backpressure or one or more cluster computing resources reaching capacity.
[0092] In some such embodiments, if the initial analysis module 604 does not detect a problem other than degradation in the degraded PE 608, the initial analysis module 604 notifies the provisional troubleshooter 606, which then evaluates the degraded PE 608 using a provisional PE 616. In some such embodiments, the provisional troubleshooter 606 communicates with a scheduler (e.g., scheduler 524 of FIG. 5 ) to identify a node to host the provisional PE 616. In some embodiments, the scheduler searches for a node other than the node hosting the PE. In some embodiments, the scheduler also searches for a node based on predetermined rules or criteria, such as, for example, availability of computing resources or proximity to upstream and downstream PEs. In some embodiments, once the scheduler identifies a host node, the scheduler notifies the provisional PE generator 610. The temporary PE generator 610 launches a temporary PE 616 at the identified node at runtime while maintaining the runtime operation of the performance-degraded PE 608. In some such embodiments, the temporary PE generator 610 connects the upstream side of the temporary PE 616 to the same upstream PE as the performance-degraded PE 608 so that both the temporary PE 616 and the performance-degraded PE 608 simultaneously receive the same stream of tuples from the same upstream PE. In some such embodiments, both the temporary PE 616 and the performance-degraded PE 608 perform the same defined process on the stream of tuples, thereby enabling the performance comparator 612 to compare the performance of the performance-degraded PE 608 with that of the temporary PE 616. In some such embodiments, the performance-degraded PE 608 performs a defined process on the stream of tuples, resulting in an output stream of tuples that the performance-degraded PE 608 sends to downstream PEs, while the output of the temporary PE 616 is not connected to any downstream elements.
[0093] In some embodiments, the performance comparator 612 compares the behavior of the degraded PE 608 to the behavior of the hypothetical PE 616 based on performance metrics associated with one or more computing resources. For example, in some embodiments, the performance comparator 612 compares the behavior of the degraded PE 608 to the behavior of the hypothetical PE 616 by comparing one or more of CPU usage, memory usage, and tuple throughput rate. In some such embodiments, if the performance comparator 612 determines that the hypothetical PE 616 outperforms the degraded PE 608, the performance comparator 612 notifies the system updater 614. In response to the performance comparator 612 indicating that the temporary PE 616 outperforms the degraded PE 608, the system updater 614 replaces the degraded PE 608 with the temporary PE 616, for example, by connecting the output of the temporary PE 616 to a downstream PE instead of the degraded PE 608, and the system updater 614 shuts down the degraded PE 608. In some embodiments, the system updater 614 sends a notification to a user via a user interface 618 regarding the replacement of the degraded PE 608 with the temporary PE 616.
[0094] Referring to Figure 7, this figure shows a block diagram of an operator graph 700 for a stream computing application in accordance with an exemplary embodiment. The operator graph shown in Figure 7 is shown for purposes of clarity and as a non-limiting example of a streaming application that can benefit from the disclosed embodiments.
[0095] In the illustrated embodiment, operator graph 700 is a graph for a stream computing application, starting from one or more sources 710 to one or more sinks 712, 714. This flow from source to sink may also be generally referred to herein as an execution path. While FIG. 7 is abstracted to show connected PEs PE1-PE10, operator graph 700 may include data flow between stream operators (e.g., operator 314 in FIG. 3) within the same or different PEs. Typically, PEs receive tuples from a stream and output tuples into a stream (except for sinks where a stream terminates or sources where a stream begins).
[0096] In the illustrated embodiment, operator graph 700 includes ten PEs (labeled PE1 through PE10) running on compute nodes 702, 704, 706, and 708. In some embodiments, the PEs include one or more stream operators fused together to form an independently running process with its own process ID (PID) and memory space. In embodiments where two (or more) PEs are running independently, communication between the processes can occur using a "transport," such as, for example, a network socket, a TCP / IP socket, or shared memory. However, when stream operators are fused together, the fused stream operators can use faster communication techniques to send tuples between the stream operators on each PE.
[0097] The operator graph 700 begins with a source 710 and terminates with sinks 712 and 714. The compute node 702 includes PEs PE1, PE2, and PE3. The source 710 flows into PE PE1, which then outputs tuples that are received by PE2 and PE3. For example, PE1 may split data attributes received in a tuple and send some data attributes in a new tuple to PE2 while sending other data attributes in another new tuple to PE3. As a second example, PE1 may send some received tuples to PE2 and other tuples to PE3. The tuples flowing to PE2 are processed by a stream operator included in PE2, and the resulting tuples are then output to PE4 in the compute node 704. Similarly, the tuples output by PE4 flow through PE6 to the operator in sink 712. Similarly, tuples flowing from PE3 to PE5 also reach the operator at sink 712 via PE6. Thus, in addition to being a sink for this example operator graph, PE6 may be configured to perform a join operation, combining tuples received from PE4 and PE5. This example operator graph also shows tuples flowing from PE3 to PE7 on compute node 706, which itself shows tuples flowing to PE8 and looping back to PE7. Tuples output from PE8 flow to PE9 on compute node 708, which then outputs tuples to be processed by the operator at the sink PE, e.g., sink 714 of PE10.
[0098] In some embodiments, a tuple received by a particular PE is generally not considered to be the same as a tuple output downstream because the output tuple has been modified in some manner. For example, in some embodiments, attributes or metadata may be added, removed, or modified. However, some embodiments include PEs that do not modify output tuples from input tuples in any way. In general, a particular tuple output by a PE cannot be considered the same tuple as the corresponding input tuple, even if the input tuple is not modified by the PE. However, to simplify this specification and the claims, an output tuple having the same data attributes as the corresponding input tuple may be referred to herein as the same tuple. In the illustrated embodiment, the performance monitor described herein is configured to monitor one or more of PEs PE1 through PE10 for degraded performance.
[0099] Referring to Figure 8, this figure shows a block diagram of an operator graph 800 for a stream computing application with a virtual PE, according to an example embodiment. The operator graph shown in Figure 8 is shown for purposes of clarity as a non-limiting example of a modified version of the operator graph 700 of Figure 7, starting with a source 810 and ending with sinks 812, 814, that can benefit from the disclosed embodiments.
[0100] In the illustrated embodiment, a performance monitor (e.g., performance monitor 520 of FIG. 5 or performance monitor 602 of FIG. 6) monitors PE2 and detects degradation of PE2 by detecting that execution conditions associated with PE2 deviate from a predefined or expected pattern. For example, in some embodiments, the performance monitor detects signs of degradation including an abnormal amount of waiting tuples (i.e., tuples waiting to be processed at input ports of operators in the PE), abnormal memory usage, the number and type of exceptions handled, or abnormal CPU consumption, or a combination thereof. In the illustrated example, no problems other than the degradation are detected, so a temporary PE (designated PPE in FIG. 8) is started on a different node. I.e., because PE2 is on node 802, the PPE is located on node 804, but could instead be started on node 806 or node 808.
[0101] The temporary PE is started at runtime while maintaining the runtime behavior of PE2. Initially, to compare the performance of the temporary PE with PE2, the temporary PE is connected only to PE1 from its upstream side via edge 816 so that both the temporary PE and PE2 simultaneously receive the same stream of tuples from the same upstream PE1 and perform the same defined process on the stream of tuples, thereby allowing the performance of the temporary PE to be compared with that of PE2.
[0102] In the illustrated example, a performance comparator or stream manager compares the behavior of the temporary PE with the behavior of PE2 based on one or more computing resources and associated performance metrics. For example, in some embodiments, the temporary PE and PE2 are compared based on one or more of CPU usage, memory usage, and / or tuple throughput speed. In some such embodiments, if the temporary PE outperforms PE2, the temporary PE replaces PE2, e.g., by connecting the output / downstream of the temporary PE to PE4 downstream of PE2 and closing PE2, e.g., by connecting edge 818 from the temporary PE to PE4.
[0103] 9, a flowchart of an exemplary dynamic PE replacement process 900 according to an exemplary embodiment is shown. In a particular embodiment, the interim PE analysis module 600 in FIG.
[0104] In one embodiment, at block 902, process 900 starts a stream application. Next, at block 904, process 900 monitors processing elements for degraded performance. Next, at block 906, process 900 checks whether degraded performance is detected in any processing elements. If not, process 900 returns to block 904 to continue monitoring. Otherwise, process 900 proceeds to block 908, where process 900 begins evaluating the degraded PE. At block 908, process 900 checks the degraded PE for indications that backpressure is the cause of the degraded performance, followed by block 912, where process 900 checks the operating level of the computing resources of the cluster of the node on which the degraded PE is located. If process 900 detects backpressure or a lack of available or sufficient cluster computing resources as the likely cause of the degradation of the degraded PE, the process proceeds to block 910, where the process applies other remedies known in the art to address the backpressure and / or lack of cluster computing resources. Otherwise, the process proceeds to block 914, where process 900 performs a troubleshooting process for the temporary PE, for example, according to process 1000 of FIG. 10, process 1100 of FIG. 11, process 1200 of FIG. 12, or a process that combines portions of process 1000, process 1100, or 1200, or two or more thereof.
[0105] After troubleshooting the temporary PE at block 914, process 900 returns to block 904 to continue monitoring the processing elements for degraded performance. In this exemplary embodiment, monitoring continues until another degraded PE is discovered or the streaming application is stopped, as shown at block 916, after which process 900 ends.
[0106] 10, a flowchart of an exemplary dynamic PE replacement process 1000 according to an exemplary embodiment is shown. In a specific embodiment, the temporary PE analysis module 600 in FIG. 6 performs the process 1000. In one embodiment, the process 1000 is an example of the temporary PE troubleshooting process in block 914 of FIG. 9.
[0107] In this exemplary embodiment, process 1000 tests the use of a temporary processing element as a possible replacement for a deteriorating PE. At block 1002, process 1000 determines a location for the temporary PE. In some embodiments, process 1000 uses a scheduler to identify a node on which to place the temporary PE. In some such embodiments, the scheduler determines the best node on which to operate the temporary PE. In some such embodiments, the scheduler excludes the node on which the deteriorating PE is operating when determining the best node on which to operate the temporary PE.
[0108] Next, at block 1004, process 1000 starts a temporary PE at the node selected at block 1002. In some embodiments, the temporary PE is started at runtime while maintaining the runtime operation of the deteriorating PE. In some embodiments, the temporary PE is connected only upstream to the PE immediately upstream of the deteriorating PE. As a result of this connection, both the temporary PE and the deteriorating PE receive the same stream of tuples from the same upstream PE at the same time.
[0109] Next, in block 1006, process 1000 compares the performance of the deteriorating PE with the interim PE. In some such embodiments, the interim PE performs the same defined process on the stream of tuples as the deteriorating PE, thereby enabling a performance-based comparison of the interim PE with the deteriorating PE. In some embodiments, a performance comparator or stream manager compares the behavior of the interim PE with the behavior of the deteriorating PE based on performance metrics associated with one or more computing resources. For example, in some embodiments, the interim PE and the deteriorating PE are compared based on one or more of CPU usage, memory usage, and / or tuple throughput rate.
[0110] Next, in block 1008, process 1000 determines whether the performance of the temporary PE is better than the performance of the degraded PE. In some such embodiments, if the temporary PE is performing better than the degraded PE, then in block 1010, process 1000 performs a switchover to the temporary PE as a replacement for the degrading PE, and the degrading PE is shut down. In some embodiments, this switchover includes connecting the output / downstream of the temporary PE to the PE immediately downstream of the degrading PE.
[0111] 11, a flowchart of an exemplary dynamic PE replacement process 1100 is shown in accordance with an exemplary embodiment. In a specific embodiment, the interim PE analysis module 600 in FIG. 6 performs the process 1100. In one embodiment, the process 1100 is an example of the interim PE troubleshooting process in block 914 of FIG. 9.
[0112] In an exemplary embodiment, process 1100 tests the use of multiple temporary processing elements as possible replacements for a deteriorating PE. In some embodiments, the number of temporary PEs is a fixed, predetermined value. In some embodiments, the number of temporary PEs is a user-configurable value that is initially set to a default value and is adjustable by user input. In some embodiments, process 1100 determines the number of temporary PEs to use based on implementation-specific factors, such as, for example, the type of deteriorating PE being replaced (i.e., the actions performed by one or more operators on the deteriorating PE), the size of the stream application, the number of available nodes already used by the stream application, or any other desired factor or combination thereof.
[0113] In block 1102, process 1100 determines a location for each of a plurality of interim PEs. In some embodiments, process 1100 uses a scheduler to identify nodes on which to place the interim PEs. In some such embodiments, the scheduler determines a list of best nodes on which to run the interim PEs. In some embodiments, the scheduler also determines the number of interim PEs to place based on, for example, the availability of nodes on which to place the interim PEs. In some such embodiments, the scheduler excludes nodes on which deteriorating PEs are running when determining the best nodes on which to run the interim PEs.
[0114] Next, at block 1104, process 1100 starts a temporary PE at each node selected at block 1102. In some embodiments, the temporary PEs are started at runtime while maintaining the runtime operation of the deteriorating PE. In some embodiments, the temporary PEs are only connected upstream, and are all connected to the PE immediately upstream of the deteriorating PE. As a result of this connection, both the deteriorating PE and the set of temporary PEs simultaneously receive the same stream of tuples from the same upstream PE.
[0115] Next, in block 1106, process 1100 compares the performance of the deteriorating PE and the interim PE. In some such embodiments, the interim PEs each perform the same defined process on the stream of tuples as the deteriorating PE, thereby enabling a performance-based comparison of the deteriorating PE and the interim PE. In some embodiments, a performance comparator or stream manager compares the behavior of the deteriorating PE to the behavior of the interim PE based on performance metrics associated with one or more computing resources. For example, in some embodiments, the interim PE and the deteriorating PE are compared based on one or more of CPU usage, memory usage, or tuple throughput rate, or a combination thereof.
[0116] Next, in block 1108, process 1100 determines whether any of the interim PEs perform better than the degraded PE. In some such embodiments, if any of the interim PEs perform better than the degraded PE, then in block 1110, process 1100 performs a switchover to the best-performing interim PE as a replacement for the degrading PE, and the degrading PE and the remaining interim PEs are shut down. In some embodiments, this switchover includes connecting the output / downstream of the interim PE to the PE immediately downstream of the degrading PE.
[0117] 12, a flowchart of an exemplary dynamic PE replacement process 1200 according to an exemplary embodiment is shown. In a specific embodiment, the interim PE analysis module 600 in FIG. 6 performs the process 1200. In one embodiment, the process 1200 is an example of the interim PE troubleshooting process in block 914 of FIG. 9.
[0118] In an exemplary embodiment, process 1200 tests the use of a temporary processing element as a possible replacement for a deteriorating PE. At block 1202, process 1200 determines a location for the temporary PE. In some embodiments, process 1200 uses a scheduler to identify nodes on which to place the temporary PE. In some such embodiments, the scheduler determines a list of best nodes on which to operate the temporary PE. In some embodiments, the scheduler also determines the number of temporary PEs to place based on, for example, the availability of nodes on which to place the temporary PE. In some such embodiments, the scheduler excludes the node on which the deteriorating PE is operating when determining the best nodes on which to operate the temporary PE.
[0119] Next, at block 1204, process 1200 starts a temporary PE at the node selected at block 1202. In some embodiments, the temporary PE is started at runtime while maintaining the runtime operation of the deteriorating PE. In some embodiments, the temporary PE is connected only upstream to the PE immediately upstream of the deteriorating PE. As a result of this connection, both the temporary PE and the deteriorating PE receive the same stream of tuples from the same upstream PE at the same time.
[0120] Next, at block 1206, process 1200 compares the performance of the deteriorating PE with the interim PE. In some such embodiments, the interim PE performs the same defined process on the stream of tuples as the deteriorating PE, thereby enabling a performance-based comparison of the interim PE with the deteriorating PE. In some embodiments, a performance comparator or stream manager compares the behavior of the interim PE with the behavior of the deteriorating PE based on performance metrics associated with one or more computing resources. For example, in some embodiments, the interim PE and the deteriorating PE are compared based on one or more of CPU usage, memory usage, and / or tuple throughput rate.
[0121] Next, in block 1208, process 1200 determines whether the performance of the temporary PE is better than the performance of the degraded PE. In some such embodiments, if the temporary PE does not perform better than the degraded PE, in block 1212, process 1200 determines whether the maximum number of temporary PEs have been tested. If so, the process ends. If not, the process returns to block 1202 to perform a next iteration of blocks 1202-1208 using another temporary PE in a different location (e.g., located on a node other than the node on which the degrading PE is located and other than the node(s) used for the previous iteration of blocks 1202-1208).
[0122] In some embodiments, the maximum number of temporary PEs in block 1212 is a fixed, predetermined value. In some embodiments, the maximum number of temporary PEs in block 1212 is a user-configurable value that is initially set to a default value and is adjustable by user input. In some embodiments, process 1200 determines the maximum number of temporary PEs in block 1212 based on any number of implementation-specific factors, such as, for example, the type of deteriorating PE being replaced (i.e., actions performed by one or more operators on the deteriorating PE), the size of the stream application, the number of available nodes already used by the stream application, or any other desired factor or combination thereof.
[0123] In some such embodiments, if any of the iterations in blocks 1202-1208 result in the interim PE outperforming the deteriorating PE, then in block 1210, process 1200 switches over to the interim PE as a replacement for the deteriorating PE, and the deteriorating PE is shut down. In some embodiments, this switchover includes connecting the output / downstream of the interim PE to the PE immediately downstream of the deteriorating PE.
[0124] The following definitions and abbreviations will be used in interpreting the claims and the specification. As used herein, terms such as "comprises," "comprising," "includes," "including," "has," "having," "contains," "containing," and the like, or any other variation thereof, are intended to imply a non-exclusive inclusion. For example, a composition, mixture, process, method, article, or device that comprises a list of elements is not necessarily limited to only those elements and may include other elements not expressly listed or inherent in such composition, mixture, process, method, article, or device.
[0125] Additionally, the term "exemplary" is used herein to mean serving as an example, instance, or illustration. Any embodiment or design described herein as "exemplary" is not necessarily to be construed as preferred or advantageous over other embodiments or designs. The terms "at least one" and "one or more" are understood to include any integer greater than or equal to 1, i.e., 1, 2, 3, 4, etc. The term "plurality" is understood to include any integer greater than or equal to 2, i.e., 2, 3, 4, 5, etc. The term "connected" can include both an indirect and a direct "connection."
[0126] References herein to "one embodiment," "an embodiment," "an exemplary embodiment," etc., suggest that the embodiment being described may include a particular feature, structure, or characteristic, but that not all embodiments may include that particular feature, structure, or characteristic. Furthermore, such phrases do not necessarily refer to the same embodiment. Furthermore, when a particular feature, structure, or characteristic is described in relation to one embodiment, it is understood that the impact of such feature, structure, or characteristic on other embodiments, whether or not explicitly stated, is within the knowledge of one of ordinary skill in the art.
[0127] The terms "about," "substantially," and "approximately," as well as variations thereof, are intended to include the degree of error associated with measurement of a particular quantity based on equipment available at the time of filing. For example, "about" can include a range of ±8%, 5%, or 2% of a given value.
[0128] The description of various embodiments of the present invention has been presented for illustrative purposes and is not intended to be exhaustive or limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope of the described embodiments. The terminology used herein has been selected to best explain the principles of the embodiments, practical applications, or technical improvements over techniques found in the market, or to enable those skilled in the art to understand the embodiments described herein.
[0129] Thus, computer-implemented methods, systems or apparatus, and computer program products for managing participation in online communities and other related features, functions, or operations are provided as exemplary embodiments. When an embodiment, or portions thereof, are described in terms of a type of device, the computer-implemented method, system or apparatus, computer program product, or portions thereof, is adapted or configured for use with the appropriate and equivalent term for that type of device.
[0130] While an embodiment is described as being implemented in an application, delivery of the application in a Software-as-a-Service (SaaS) model is contemplated within the scope of the exemplary embodiment. In a SaaS model, the functionality of an application implementing an embodiment is provided to users by running the application on a cloud infrastructure. Users can access the application using a variety of client devices through a thin-client interface, such as a web browser (e.g., web-based email) or other lightweight client application. Users do not manage or control the underlying cloud infrastructure, including the cloud infrastructure's network, servers, operating system, or storage. In some cases, users may not even manage or control the functionality of the SaaS application. In other cases, a SaaS implementation of an application may allow for possible exceptions to limited user-specific application configuration settings.
[0131] The present invention may be a system, method, or computer program product, or combination thereof, integrated at any possible level of technical detail. The computer program product may include a computer-readable storage medium (or media) having computer-readable program instructions thereon for causing a processor to carry out aspects of the present invention.
[0132] A computer-readable storage medium may be any tangible device capable of retaining and storing instructions for use by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electronic storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination thereof. A non-exhaustive list of more specific examples of computer-readable storage media includes portable computer diskettes, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable compact disk read-only memory (CD-ROM), digital versatile disk (DVD), memory stick®, floppy® disk, mechanically encoded devices such as punch cards or grooved ridge structures having instructions recorded thereon, and any suitable combination thereof. Computer-readable storage medium, as used herein, should not be construed as a transitory signal per se, such as, for example, radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through a waveguide or other transmission medium (e.g., light pulses passing through fiber optic cable), or electrical signals transmitted over wires.
[0133] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device or to an external computer or storage device over a network, such as the Internet, a local area network, a wide area network, or a wireless network, or a combination thereof. The network may include copper transmission cables, fiber optic transmission cables, wireless transmission cables, routers, firewalls, switches, gateway computers, or edge servers, or a combination thereof. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and transfers the computer-readable program instructions for storage in a computer-readable storage medium within the respective computing / processing device.
[0134] Computer-readable program instructions for carrying out the operations of the present invention may be source or object code written in any combination of one or more programming languages, including assembler instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, integrated circuit configuration data, or object-oriented programming languages such as Smalltalk®, C++, and procedural programming languages such as the "C" programming language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the last scenario, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or a connection may be made to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, electronic circuitry including, for example, a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be personalized by utilizing state information of the computer readable program instructions to execute the computer readable program instructions to perform aspects of the present invention.
[0135] Aspects of the present invention are described herein with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer-readable program instructions.
[0136] These computer-readable program instructions may be provided to a processor of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, executed by the processor of the computer or other programmable data processing apparatus, generate means for implementing the functions / acts specified in one or more blocks of the flowcharts and / or block diagrams. These computer-readable program instructions may also be stored on a computer-readable storage medium, directing a computer, programmable data processing apparatus, or other device, or combination thereof, to function in a particular manner, such that the computer-readable storage medium on which the instructions are stored constitutes an article of manufacture containing instructions that implement aspects of the functions / acts specified in one or more blocks of the flowcharts and / or block diagrams.
[0137] The computer-readable program instructions may also be loaded into a computer, other programmable data processing apparatus, or other device to generate a computer-implemented process that causes the computer, other programmable apparatus, or other device to perform a series of operational steps, such that the instructions, which execute on the computer, other programmable apparatus, or other device, implement the functions / operations specified in one or more blocks of the flowcharts and / or block diagrams.
[0138] The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present invention. In this regard, each block in the flowcharts or block diagrams may represent a module, segment, or portion of instructions, which includes one or more executable instructions for implementing the specified logical function(s). In some alternative implementations, the functions noted in the blocks may occur out of the order depicted. For example, depending on the functionality involved, two blocks shown in succession may in fact be executed substantially concurrently, or the blocks may possibly be executed in the reverse order. It will also be noted that each block in the block diagrams and / or flowchart diagrams, and combinations of blocks in the block diagrams and / or flowchart diagrams, can be implemented by a dedicated hardware-based system that performs the specified functions or operations or executes a combination of dedicated hardware and computer instructions.
[0139] Embodiments of the present invention can also be delivered as part of a service engagement with a client company, nonprofit organization, government agency, internal organizational structure, etc. Aspects of these embodiments may include configuring a computer system to perform and deploying software, hardware, and web services that implement some or all of the methods described herein. Aspects of these embodiments may also include analyzing a client's operations, making recommendations in response to the analysis, building a system that implements some of the recommendations, integrating the system into existing processes and infrastructure, measuring system usage, allocating costs to users of the system, and charging for system usage. Although the above-described embodiments of the present invention have been described by reference to their respective individual advantages, the present invention is not limited to any particular combination thereof. On the contrary, the embodiments may be combined in any manner and number without losing their advantageous effects, in accordance with the intended deployment of the present invention.
Claims
1. A computer-implemented method comprising: Monitoring a distributed computing application at runtime for the occurrence of a condition, comprising: The distributed computing application comprises a first node including a processing element (PE), the processing element (PE) receiving a first stream of tuples from an upstream PE, performing a defined process on the first stream of tuples resulting in a second stream of tuples, and transmitting the second stream of tuples to a downstream PE; the condition includes the occurrence of a degradation condition in the PE; said monitoring; starting a first temporary PE on a second node at runtime while maintaining runtime operation of the PE; the first interim PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; said starting; comparing the performance of the PE with the performance of the first interim PE based on performance metrics associated with computing resources; connecting the first interim PE to exchange the second stream of tuples from the PE to the downstream PE with a third stream of tuples from the first interim PE to the downstream PE; starting a second virtual PE at runtime on a third node while maintaining runtime operation of the PE; Including, the first intercepting PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples while the PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; a second interim PE receiving the first stream of tuples from the upstream PE and performing the defined process on the first stream of tuples, while the first interim PE and the PE each receive the first stream of tuples from the upstream PE and each perform the defined process on the first stream of tuples.
2. 2. The computer-implemented method of claim 1, wherein comparing the operation of the PE with the operation of the first interim PE further comprises comparing the operation of the second interim PE with the operation of the PE and the operation of the first interim PE based on the performance metrics associated with the computing resource.
3. A computer-implemented method comprising: Monitoring a distributed computing application at runtime for the occurrence of a condition, comprising: The distributed computing application comprises a first node including a processing element (PE), the processing element (PE) receiving a first stream of tuples from an upstream PE, performing a defined process on the first stream of tuples resulting in a second stream of tuples, and transmitting the second stream of tuples to a downstream PE; the condition includes the occurrence of a degradation condition in the PE; said monitoring; starting a first temporary PE on a second node at runtime while maintaining runtime operation of the PE; the first interim PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; said starting; comparing the performance of the PE with the performance of the first interim PE based on performance metrics associated with computing resources; connecting the first interim PE to exchange the second stream of tuples from the PE to the downstream PE with a third stream of tuples from the first interim PE to the downstream PE; Before starting the first temporary PE, starting a second virtual PE at runtime on a third node while maintaining runtime operation of the PE; Including, The computer-implemented method wherein the second interim PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples.
4. Before starting the first temporary PE, The computer-implemented method of claim 3 , further comprising comparing the behavior of the PE and the behavior of the second interim PE based on the performance metric associated with the computing resource.
5. 5. The computer-implemented method of claim 4, further comprising comparing the behavior of the PE with the behavior of the second interim PE, thereby identifying the behavior of the PE that exceeds the behavior of the second interim PE based on the performance metric.
6. A computer program, the computer program comprising: Monitoring a distributed computing application at runtime for the occurrence of a condition, comprising: The distributed computing application comprises a first node including a PE, the PE receiving a first stream of tuples from an upstream PE, performing a defined process on the first stream of tuples resulting in a second stream of tuples, and transmitting the second stream of tuples to a downstream PE; the condition includes the occurrence of a degradation condition in the PE; said monitoring; starting a first temporary PE on a second node at runtime while maintaining runtime operation of the PE; the first interim PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; said starting; comparing the performance of the PE with the performance of the first interim PE based on performance metrics associated with computing resources; connecting the first interim PE to exchange the second stream of tuples from the PE to the downstream PE with a third stream of tuples from the first interim PE to the downstream PE; starting a second virtual PE at runtime on a third node while maintaining runtime operation of the PE; causing a processor to perform operations including the first intercepting PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples while the PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; a second interim PE receiving the first stream of tuples from the upstream PE and performing the defined process on the first stream of tuples, while the first interim PE and the PE each receive the first stream of tuples from the upstream PE and each perform the defined process on the first stream of tuples.
7. 7. The computer program product of claim 6, wherein comparing the operation of the PE with the operation of the first interim PE further comprises comparing the operation of the second interim PE with the operation of the PE and the operation of the first interim PE based on the performance metrics associated with the computing resource.
8. A computer system comprising: a processor; and one or more computer-readable storage media, wherein program instructions are collectively stored on the one or more computer-readable storage media, and wherein the program instructions are executable by the processor; Monitoring a distributed computing application at runtime for the occurrence of a condition, comprising: The distributed computing application comprises a first node including a PE, the PE receiving a first stream of tuples from an upstream PE, performing a defined process on the first stream of tuples resulting in a second stream of tuples, and transmitting the second stream of tuples to a downstream PE; the condition includes the occurrence of a degradation condition in the PE; said monitoring; starting a first temporary PE on a second node at runtime while maintaining runtime operation of the PE; the first interim PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; said starting; comparing the performance of the PE with the performance of the first interim PE based on performance metrics associated with computing resources; connecting the first interim PE to exchange the second stream of tuples from the PE to the downstream PE with a third stream of tuples from the first interim PE to the downstream PE; starting a second virtual PE at runtime on a third node while maintaining runtime operation of the PE; causing the processor to perform operations including: the first intercepting PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples while the PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples; A computer system wherein the second interim PE receives the first stream of tuples from the upstream PE and performs the defined process on the first stream of tuples, while the first interim PE and the PE each receive the first stream of tuples from the upstream PE and each perform the defined process on the first stream of tuples.
Citation Information
Patent Citations
Performance of a streaming application by running experimental permutations
US20150142951A1
Deploying operators of a streaming application based on physical location attributes of a virtual machine
US20150256439A1