DE112012000693T5 - Execute a variety of instances of an application - Google Patents

Execute a variety of instances of an application Download PDF

Info

Publication number
DE112012000693T5
DE112012000693T5 DE112012000693T DE112012000693T DE112012000693T5 DE 112012000693 T5 DE112012000693 T5 DE 112012000693T5 DE 112012000693 T DE112012000693 T DE 112012000693T DE 112012000693 T DE112012000693 T DE 112012000693T DE 112012000693 T5 DE112012000693 T5 DE 112012000693T5
Authority
DE
Germany
Prior art keywords
instance
write operation
instance object
root
data storage
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
DE112012000693T
Other languages
German (de)
Other versions
DE112012000693B4 (en
Inventor
Jun Jie CAI
Heng Wang
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
International Business Machines Corp
Original Assignee
International Business Machines Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by International Business Machines Corp filed Critical International Business Machines Corp
Publication of DE112012000693T5 publication Critical patent/DE112012000693T5/en
Application granted granted Critical
Publication of DE112012000693B4 publication Critical patent/DE112012000693B4/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/485Task life-cycle, e.g. stopping, restarting, resuming execution
    • G06F9/4856Task life-cycle, e.g. stopping, restarting, resuming execution resumption being on a different machine, e.g. task migration, virtual machine migration
    • G06F9/4862Task life-cycle, e.g. stopping, restarting, resuming execution resumption being on a different machine, e.g. task migration, virtual machine migration the task being a mobile agent, i.e. specifically designed to migrate
    • G06F9/4868Task life-cycle, e.g. stopping, restarting, resuming execution resumption being on a different machine, e.g. task migration, virtual machine migration the task being a mobile agent, i.e. specifically designed to migrate with creation or replication
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5016Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements

Abstract

Die vorliegende Erfindung offenbart ein Verfahren und ein System zum Ausführen einer Vielzahl von Instanzen einer Anwendung, wobei das Verfahren aufweist: Starten eines Ausführens einer Stamminstanz der Anwendung, wobei die Stamminstanz mindestens einen Thread beinhaltet; als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, Anhalten des Ausführens aller Threads der Stamminstanz; als Reaktion auf ein Starten eines Ausführens einer Instanz der Anwendung, Replizieren des Ausführungszustandes aller Threads der Stamminstanz als den Ausführungszustand aller Threads der Instanz; und Fortfahren, alle Threads der Instanz der Anwendung auszuführen. Durch das Verfahren und das System können Programmausführungs-Datenspeicherplatz und Datenspeicherplatz in einer mandantenfähigen Cloud-Computing-Umgebung eingespart werden.The present invention discloses a method and system for executing a plurality of instances of an application, the method comprising: starting execution of a root instance of the application, the root instance including at least one thread; in response to a thread of the root instance, when executed, arriving at a predetermined freeze point in the application, stopping execution of all threads of the root instance; in response to starting execution of an instance of the application, replicating the execution state of all threads of the root instance as the execution state of all threads of the instance; and continue to run all the threads of the instance of the application. The method and system can save program execution data storage space and data storage space in a multi-tenant cloud computing environment.

Figure 00000001
Figure 00000001

Description

GEBIET DER ERFINDUNGFIELD OF THE INVENTION

Die vorliegende Erfindung betrifft allgemein ein Ausführen von Computeranwendungen und genauer ein Verfahren und ein System zum Ausführen einer Vielzahl von Instanzen einer Anwendung.The present invention relates generally to computer application execution, and more particularly to a method and system for executing a plurality of instances of an application.

BESCHREIBUNG DES STANDES DER TECHNIKDESCRIPTION OF THE PRIOR ART

Bei Cloud-Computing handelt es sich um einen aufkommenden Netzwerkdienstmodus. Ein Analysebericht von IDS hebt hervor, dass im Jahr 2009 unter den weltweiten IT-Ausgaben von 359 Milliarden $ eine Summe von 17 Milliarden $ aus Investitionen in Cloud-Computing stammt. Andere Studien weisen zudem darauf hin, dass zwei Drittel der Unternehmen vorhaben, die Nutzung öffentlicher Clouds zu erweitern.Cloud computing is an emerging network service mode. An IDS analysis report notes that in 2009, $ 359 billion of global IT spend came to $ 17 billion from investments in cloud computing. Other studies also indicate that two-thirds of companies plan to expand their use of public clouds.

Eine „mandantenfähige” (multi-tenancy) Architektur ist die verbreitetste Architektur beim Cloud-Computing, und „Mandantenfähigkeit” entlehnt und entwickelt viele Konzepte aus dem Host-Computing und führt die Konzepte in das System von x86-Servern ein und erweitert die ursprünglichen Konzepte enorm, so dass Tausende von „Mandanten” innerhalb und außerhalb von Unternehmen unterstützt werden. Bei solchen „Mandanten” kann es sich um jede beliebige Anwendung (entweder innerhalb von Unternehmen oder außerhalb von Unternehmen) in jedem beliebigen Unternehmen handeln, das seine eigenen Sicherheitsanforderungen und eine dedizierte virtuelle Datenverarbeitungsumgebung besitzt, und die Umgebung kann mehrere oder alle Ebenen der IT-Architektur des Unternehmens vom Datenspeicher bis hin zur Benutzerschnittstelle beinhalten. Tatsächlich sind alle interaktiven Anwendungen naturgemäß auf mehrere Benutzer oder „Mandantenfähigkeit” ausgerichtet.A multi-tenancy architecture is the most common architecture in cloud computing, and multi-tenancy borrowed and developed many concepts from host computing, introducing the concepts into the system of x86 servers and extending the original concepts Enormous, supporting thousands of "clients" inside and outside companies. Such "tenants" can be any application (either within or outside of companies) in any company that has its own security requirements and a dedicated virtual computing environment, and the environment can handle multiple or all levels of IT. Include enterprise architecture from data storage to the user interface. In fact, all interactive applications are naturally targeted to multiple users or "multi-tenancy".

„Mandantenfähigkeit” bedeutet kurz ausgedrückt, dass eine einzige Software-Instanz eine Vielzahl von Organisationen (oder Benutzern) bedienen kann. Eine Software, die Mandantenfähigkeit unterstützt, muss es durch ihre Gestaltung jeder die Software verwendenden Organisation ermöglichen, eine separate virtuelle Instanz zu verwenden und in der Lage zu sein, die virtuelle Instanz anzupassen. Der Vorteil von Mandantenfähigkeit liegt im Verringern der Gesamt-Inanspruchnahme von Ressourcen sowie der Kosten des Ausführens einer Anwendung durch gemeinsames Nutzen einer Software-Instanz durch eine Vielzahl von Organisationen; da zudem alle Organisationen denselben Satz von Kerncode gemeinsam nutzen, sind das Aktualisieren und die Entwicklung der Software einfacher; des Weiteren können durch Verwenden der mandantenfähigen Architektur physische Ressourcen und Softwareressourcen verringert, die Verwaltung vereinfacht und die Effizienz verbessert werden.Multi-client capability means, in short, that a single software instance can serve a variety of organizations (or users). Software that supports multi-tenant capability must, through its design, allow each organization using the software to use a separate virtual instance and be able to customize the virtual instance. The advantage of multi-tenancy is the reduction in overall resource utilization and the cost of running an application by sharing a software instance with a variety of organizations; Moreover, because all organizations share the same set of core code, updating and developing the software is easier; Furthermore, by using the multi-tenant architecture, physical resources and software resources can be reduced, management simplified, and efficiency improved.

Um den Sicherheits- und Isolationsanforderungen mehrerer Mandanten (Benutzer) zu genügen, muss der Administrator des Cloud-Computing in manchen Cloud-Computing-Umgebungen für jeden Benutzer eine separate Instanz der Anwendung erzeugen. Obwohl eine Vielzahl von Instanzen der Anwendung auf demselben grundlegenden Code ausgeführt werden, ist es derzeit schwierig, denselben grundlegenden Code zu verwenden, wodurch unnötige Inanspruchnahmen von Ressourcen verursacht werden, z. B. der aufgrund mehrmaligen Ladens desselben Codes belegte Arbeitsspeicherplatz; darüber hinaus wird bei unterschiedlichen Instanzen der Anwendung dieselbe globale Datenstruktur verwendet, wodurch wiederholte Belegung des Datenspeicherplatzes verursacht wird usw.To meet the security and isolation needs of multiple tenants (users), in some cloud computing environments, the cloud computing administrator must create a separate instance of the application for each user. Although a plurality of instances of the application execute on the same basic code, it is currently difficult to use the same basic code, causing unnecessary resource consumption, e.g. B. the memory space occupied due to multiple loading of the same code; moreover, the same global data structure is used in different instances of the application, causing repeated data space usage, and so on.

Bei der derzeitigen „mandantenfähigen” Architektur, z. B. für eine JavaTM-Anwendung, wird dieses Problem durch Replizieren der JVM gelöst. Bei diesem Verfahren wird die vorhandene JVM repliziert, um eine neue replizierte JVM erneut zu starten und die Arbeitsspeicherseiten gemeinsam zu nutzen, und eine weitere gleiche Java-Anwendung auf der replizierten JVM auszuführen. Bei diesem Verfahren erfolgt jedoch eine gemeinsame Nutzung auf Prozessebene mit einer groben Granularität der gemeinsamen Nutzung und einer begrenzten Speicherplatzeinsparung. (Java und alle auf Java gestützten Marken und Logos sind Marken oder eingetragen Marken von Oracle und/oder seinen verbundenen Unternehmen).In the current "multi-tenant" architecture, e.g. For example, for a Java application, this problem is solved by replicating the JVM. This procedure replicates the existing JVM to reboot a new replicated JVM and share the memory pages and execute another identical Java application on the replicated JVM. In this method, however, process-level sharing occurs with coarse granularity of sharing and limited memory space savings. (Java and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle and / or its affiliates).

In US 7 426 720 werden ein System und ein Verfahren zum dynamischen Vorladen von Klassen durch Klonen von Arbeitsspeicherplatz eines Haupt-Laufzeitsystemprozesses offenbart. Ein Haupt-Laufzeitsystemprozess wird ausgeführt. Eine Darstellung mindestens einer Klasse wird von einer als objektorientierter Programmcode bereitgestellten Quelldefinition bereitgestellt. Die Darstellung wird als eine Klassendefinition auf einem Arbeitsspeicherplatz des Haupt-Laufzeitsystemprozesses interpretiert und instanziiert. Der Arbeitsspeicherplatz wird als Reaktion auf eine Prozessanfrage als ein untergeordneter Laufzeitsystemprozess geklont, und der untergeordnete Laufzeitsystemprozess wird ausgeführt und erbt den Arbeitsspeicherzustand des übergeordneten Prozesses, der die Datenstrukturen und den Zustand wiedergibt, die den vorgeladenen Klassen entsprechen. (Siehe Zusammenfassung und Spalten 4 und 5, Zeilen 47 bis 6.)In US 7,426,720 discloses a system and method for dynamically preloading classes by cloning workspace of a main runtime system process. A main runtime system process is executed. A representation of at least one class is provided by a source definition provided as object-oriented program code. The representation is interpreted and instantiated as a class definition in a working memory space of the main runtime system process. The work space is cloned in response to a process request as a subordinate runtime system process, and the child runtime system process executes and inherits the memory state of the parent process that represents the data structures and state that correspond to the preloaded classes. (See abstract and columns 4 and 5, lines 47 to 6.)

In US 4 742 450 wird ein Verfahren zum Ermöglichen eines Austausches von Daten in einer UNIX*-Datei zwischen zwei gleichzeitig auf zwei virtuellen Maschinen ausgeführten UNIX-Prozessoren in einem Datenverarbeitungssystem des Typs virtueller Maschinen mit seitensegmentiertem virtuellem Arbeitsspeicher offenbart. Ein Befehl „Shared Copy-On-Write” (SCOW) wird für das Betriebssystem des UN IX-Typs erstellt, der bei Ausführen als Reaktion auf einen Systemaufruf von einem einzelnen Prozess veranlasst, die angegebene UNIX-Datei einem eindeutigen Segment des virtuellen Arbeitsspeichers zuzuordnen. Eine Zuordnungsknoten-Datenstruktur wird zum Speichern der ID des eindeutigen Segments und zum Pflegen eines Zählwertes der Anzahl von Benutzern eingerichtet, die das eindeutige Segment gemeinsam nutzen. Ein Systemaufruf zum SCOW-Befehl durch den zweiten Prozess, der dieselbe UNIX-Datei einbezieht, prüft die Zuordnungsknoten-Datenstruktur, um zu ermitteln, ob die Datei aktuell für den SCOW-Modus zugeordnet ist. Nachfolgende Anweisungen in den Anwendungsprogrammen, die parallel auf den virtuellen Maschinen ausgeführt werden, arbeiten an der Kopie der Datei im eindeutigen Segment, so dass alle Daten, die geändert, d. h. durch einen Prozess geschrieben werden, verfügbar sind, um durch den zweiten Prozess gelesen zu werden. FNT UNIX ist eine Marke von AT&T. (Siehe Zusammenfassung und Spalten 4 und 5, Zeilen 33 bis 2.) In US 4,742,450 describes a method for allowing data to be exchanged in a UNIX * file between two UNIX processors running concurrently on two virtual machines discloses a virtual page-segment virtual memory data processing system. A Shared Copy-On-Write (SCOW) command is created for the UN IX-type operating system that, when executed in response to a system call, causes a single process to map the specified UNIX file to a unique virtual memory segment , An allocation node data structure is set up to store the ID of the unique segment and to maintain a count of the number of users sharing the unique segment. A system call to the SCOW command by the second process involving the same UNIX file examines the mapping node data structure to determine if the file is currently mapped to the SCOW mode. Subsequent instructions in the application programs running in parallel on the virtual machines work on the copy of the file in the unique segment so that all data that is changed, ie written by a process, is available to be read by the second process become. FNT UNIX is a trademark of AT & T. (See abstract and columns 4 and 5, lines 33 to 2.)

In US 7 536 525 werden ein System und ein Verfahren zum Klonen während der Laufzeit (hot cloning) in einem verteilten Netzwerk offenbart. In einer Ausführungsform beinhaltet ein Verfahren zum Klonen einer virtuellen Maschine von einem Quellsystem auf ein Zielsystem ein Einfrieren von Schreibvorgängen auf eine Datenspeicherdatei mit Speicherblöcken, so dass nachfolgende Schreibvorgänge neue Speicherblöcke für die ursprüngliche virtuelle Maschine erzeugen. Das Verfahren beinhaltet weiterhin ein Einfrieren von Schreibvorgängen auf einen Arbeitsspeicherinhalt, so dass nachfolgende Schreibvorgänge in Pufferspeichern gespeichert werden. Das Verfahren beinhaltet weiterhin ein Kopieren des Arbeitsspeicherinhalts auf das Zielsystem, wobei der kopierte Arbeitsspeicherinhalt einen Klon erzeugt. Das Verfahren beinhaltet weiterhin ein Auftauen des Arbeitsspeicherinhalts durch Zusammenführen der in den Pufferspeichern gespeicherten Schreibvorgänge und Auftauen der Schreibvorgänge auf die Datenspeicherdatei, so dass nachfolgende Schreibvorgänge normal stattfinden. Das Verfahren beinhaltet weiterhin ein Konfigurieren des Klons auf der Grundlage des Zielsystems. Das Verfahren beinhaltet weiterhin ein Erzeugen eines neuen Speicherblocks für alle Schreibvorgänge auf die Datenspeicherdatei, wobei der neue Speicherblock nicht gemeinsam genutzt wird. (Siehe Zusammenfassung, Zeilen 20 bis 40 und Spalten 6 und 7, Zeilen 52 bis 3.)In US Pat. No. 7,536,525 discloses a system and method for hot cloning in a distributed network. In one embodiment, a method for cloning a virtual machine from a source system to a target system includes freezing writes to a data storage file with memory blocks such that subsequent writes create new memory blocks for the original virtual machine. The method further includes freezing writes to a memory content so that subsequent writes are stored in buffers. The method further includes copying the memory contents to the target system, wherein the copied memory contents generate a clone. The method further includes thawing the memory contents by merging the writes stored in the buffers and thawing the writes to the data store file such that subsequent writes occur normally. The method further includes configuring the clone based on the target system. The method further includes generating a new memory block for all writes to the data store file, wherein the new memory block is not shared. (See abstract, lines 20 to 40 and columns 6 and 7, lines 52 to 3.)

In US 7 657 888 wird ein Verfahren zum Steigern der Effizienz der Verarbeitung virtueller Maschinen offenbart. Eine übergeordnete virtuelle Maschine wird auf einem Host-Computer bereitgestellt. Die übergeordnete virtuelle Maschine ist zeitweise oder dauerhaft ausgesetzt. Eine untergeordnete virtuelle Maschine wird an einem neuen Ort erstellt, indem die übergeordnete virtuelle Maschine aufgespalten wird. Die untergeordnete virtuelle Maschine enthält anfänglich unter Umständen nicht alle gespeicherten Daten, die der übergeordneten virtuellen Maschine zugehörig sind. (Siehe Zusammenfassung, Spalte 4, Zeilen 44 bis 56 und Spalte 5, Zeilen 4 bis 40.)In US Pat. No. 7,657,888 For example, there is disclosed a method of increasing the efficiency of processing virtual machines. A parent virtual machine is deployed on a host computer. The parent virtual machine is suspended temporarily or permanently. A child virtual machine is created in a new location by splitting the parent virtual machine. The child virtual machine may initially not contain all the stored data associated with the parent virtual machine. (See abstract, column 4, lines 44 to 56 and column 5, lines 4 to 40.)

In WO 2007/036072 werden ein Verfahren und eine Vorrichtung zum beschleunigten Starten virtueller Maschinen (VM) in einer VM-Cluster-Umgebung offenbart. In einer Ausführungsform wird mindestens eine virtuelle Maschine innerhalb einer Host-Plattform gestartet. Nach dem Initialisieren kann eine VM einen Hyperaufruf an einen VM-Monitor (VMM) einer VM-Host-Plattform ausgeben. Als Reaktion kann der VMM ein Laufzeit-Abbild (image) der VM erfassen. In einer Ausführungsform lädt der VMM das Laufzeit-Abbild der VM innerhalb eines Knotens der Host-Plattform als eine untergeordnete VM. In einer alternativen Ausführungsform gibt der VMM einen VM-Klonbefehl an eine VMM einer nächsten Host-Plattform einschließlich des Laufzeit-Abbilds der VM aus. Als Reaktion lädt der VMM der nächsten Host-Plattform das Laufzeit-Abbild der ersten VM innerhalb eines Knotens der zweiten Host-Plattform als eine geklonte VM. (Siehe Seiten 11 und 12, Abschnitte [38 bis 41].)In WO 2007/036072 A method and apparatus for accelerated virtual machine (VM) booting in a VM cluster environment is disclosed. In one embodiment, at least one virtual machine is started within a host platform. After initialization, a VM can issue a hyper-call to a VM Monitor (VMM) of a VM Host platform. In response, the VMM may capture a runtime image of the VM. In one embodiment, the VMM loads the runtime image of the VM within a node of the host platform as a subordinate VM. In an alternative embodiment, the VMM issues a VM clone command to a VMM of a next host platform, including the runtime image of the VM. In response, the VMM of the next host platform loads the runtime image of the first VM within a node of the second host platform as a cloned VM. (See pages 11 and 12, sections [38 to 41].)

In US 2010/0223613 werden ein System und ein Verfahren zum Isolieren von innerhalb einer Datenverarbeitungseinheit ausgeführten Prozessen offenbart. Ein Prozess wird auf eine virtuelle Maschine geladen, die unter der Steuerung eines Hypervisor betrieben wird, der zum Datenaustausch mit einem Betriebssystemkernel verbunden ist. Ein Teilsatz einer Anwendungsprogrammierschnittstelle (application programming interface (API)) wird der virtuellen Maschine angeboten, wodurch der Prozess in die Lage versetzt wird, über den Teilsatz der API eine Verbindung mit dem Betriebssystemkernel herzustellen. Der Prozess wird dann auf der virtuellen Maschine ausgeführt. (Siehe Zusammenfassung und Seite 4, Abschnitte 37 und 38.)In US 2010/0223613 discloses a system and method for isolating processes executed within a computing device. A process is loaded onto a virtual machine that operates under the control of a hypervisor connected to an operating system kernel for data exchange. A subset of an application programming interface (API) is offered to the virtual machine, which enables the process to connect to the operating system kernel through the API subset. The process is then executed on the virtual machine. (See summary and page 4, sections 37 and 38.)

In US 7 421 698 werden ein System und ein Verfahren zum dynamischen und dauerhaften Verfolgen inkrementeller Profilerstellungsdaten in einer Umgebung einer Anwendung des Prozessklonens offenbart. Ein Haupt-Laufzeitsystemprozess wird ausgeführt. Ein Arbeitsspeicherplatz des Haupt-Laufzeitsystemprozesses wird als ein untergeordneter Laufzeitsystemprozess als Reaktion auf eine Prozessanfrage geklont. Der unterordnete Laufzeitsystemprozess wird ausgeführt. Für das Ausführen des untergeordneten Laufzeitsystemprozesses wird durch inkrementelles Erfassen von Profilerstellungsdaten ein Profil erstellt. Die Profile des untergeordneten Laufzeitsystemprozesses werden dem Haupt-Laufzeitsystemprozess zum Vorteil nachfolgender untergeordneter Laufzeitsystemprozesse wieder zugeführt. In einer weiteren Ausführungsform werden die Profile der untergeordneten Laufzeitsystemprozesse in einem dauerhaften Datenspeicher zur Verwendung durch den Haupt-Laufzeitsystemprozess beim nächsten Hochfahren aufbewahrt. (Siehe Zusammenfassung und Spalten 2 und 3, Zeilen 51 bis 18.) In US 7,421,698 discloses a system and method for dynamically and persistently tracking incremental profiling data in an environment of a process cloning application. A main runtime system process is executed. A working memory space of the main runtime system process is cloned as a subordinate runtime system process in response to a process request. The child runtime system process is executed. To run the child runtime system process, incrementally collect profiling data created a profile. The profiles of the child runtime system process are returned to the main runtime system process for the benefit of subsequent child runtime system processes. In another embodiment, the profiles of the subordinate runtime system processes are stored in a persistent data store for use by the main runtime system process on the next boot up. (See abstract and columns 2 and 3, lines 51 to 18.)

In „Cloneable JVM: A new approach to start isolated Java Applications Faster” von Kawachiya, Ogata, Silva, Hideaki, Nakatani und Nakatani wird ein Ansatz offenbart, bei dem der Startaufwand bei Java entbehrlich wird. (Siehe Zusammenfassung und auch Abschnitt 3.1.)In "Cloneable JVM: A New Approach to Starting Java Application Faster" by Kawachiya, Ogata, Silva, Hideaki, Nakatani and Nakatani, an approach is disclosed in which the startup effort in Java is unnecessary. (See summary and also section 3.1.)

KURZDARSTELLUNG DER ERFINDUNGBRIEF SUMMARY OF THE INVENTION

Daher werden ein neues Verfahren, ein System und ein Computerprogramm zum Ausführen einer Vielzahl von Instanzen einer Anwendung gemäß einer Ausführungsform der vorliegenden Erfindung bereitgestellt, um den durch die Anwendung belegten Datenspeicherplatz einzusparen.Therefore, a new method, system, and computer program are provided for executing a plurality of instances of an application according to an embodiment of the present invention to save the data storage space occupied by the application.

Gemäß einem Aspekt der vorliegenden Erfindung wird ein Verfahren zum Ausführen einer Vielzahl von Instanzen einer Anwendung bereitgestellt, wobei das Verfahren aufweist:
Starten eines Ausführens einer Stamminstanz der Anwendung, wobei die Stamminstanz mindestens einen Thread beinhaltet; als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, Anhalten des Ausführens aller Threads der Stamminstanz; als Reaktion auf ein Starten eines Ausführens einer Instanz der Anwendung, Replizieren des Ausführungszustandes aller Threads der Stamminstanz als den Ausführungszustand aller Threads der Instanz; und Fortfahren, alle Threads der Instanz der Anwendung auszuführen.
According to one aspect of the present invention, there is provided a method of executing a plurality of instances of an application, the method comprising:
Starting execution of a root instance of the application, wherein the root instance includes at least one thread; in response to a thread of the root instance, when executed, arriving at a predetermined freeze point in the application, stopping execution of all threads of the root instance; in response to starting execution of an instance of the application, replicating the execution state of all threads of the root instance as the execution state of all threads of the instance; and continue to run all the threads of the instance of the application.

In einer Ausführungsform beinhaltet der Ausführungszustand mindestens: den aktuellen Stapel, die Werte von Registern und die aktuelle Anweisung eines Thread.In one embodiment, the execution state includes at least: the current stack, the values of registers, and the current instruction of a thread.

In einer Ausführungsform enthält der aktuelle Stapel des Ausführungszustands eine Referenz zu einem Instanzobjekt in der Instanz, wobei die Referenz zum Instanzobjekt so initialisiert ist, dass sie auf das Stamminstanzobjekt verweist.In one embodiment, the current execution state stack contains a reference to an instance object in the instance, the reference to the instance object being initialized to point to the root instance object.

In einer Ausführungsform weist das Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung auf: Empfangen einer Schreiboperation auf ein Feld eines Instanzobjekts; als Reaktion darauf, dass eine Referenz zum Instanzobjekt auf ein Stamminstanzobjekt verweist: Zuordnen eines Datenspeicherbereichs für das Instanzobjekt; Verweisen der Referenz zum Instanzobjekt auf den Datenspeicherbereich; Ausführen der Schreiboperation in dem Datenspeicherbereich.In one embodiment, continuing to execute all threads of the instance of the application comprises: receiving a write to a field of an instance object; in response to a reference to the instance object referring to a root instance object: associating a data storage area with the instance object; Pointing the reference to the instance object to the data storage area; Perform the write operation in the data storage area.

In einer Ausführungsform weist das Verfahren weiterhin auf: als Reaktion darauf, dass die Referenz zu einem Instanzobjekt nicht auf ein Stamminstanzobjekt verweist, Ausführen der Schreiboperation im Datenspeicherbereich, auf den die Referenz zum Instanzobjekt verweist.In one embodiment, the method further comprises: in response to the reference to an instance object not referencing a root instance object, performing the write operation in the data storage area referenced by the reference to the instance object.

In einer Ausführungsform weist das Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung auf: Empfangen einer Schreiboperation auf ein Feld eines Instanzobjektes; als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat: Zuordnen eines Datenspeicherbereichs für das Feld des Instanzobjektes; Kennzeichnen des entsprechenden Feldes des Stamminstanzobjektes so, dass es eine Schreiboperation ausgeführt hat; Ausführen der Schreiboperation in dem Datenspeicherbereich.In one embodiment, continuing to execute all threads of the instance of the application comprises: receiving a write to a field of an instance object; in response to a corresponding field of a root instance object referenced by the reference to the instance object being flagged as not yet performing a write operation: allocating a data storage area for the field of the instance object; Flag the corresponding field of the root instance object so that it has performed a write operation; Perform the write operation in the data storage area.

In einer Ausführungsform weist das Verfahren weiterhin auf: als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es eine Schreiboperation ausgeführt hat, Ausführen der Schreiboperation in dem Datenspeicherbereich, der für das Feld des Instanzobjektes zugeordnet ist, das dieser Schreiboperation zugehörig ist.In one embodiment, the method further comprises: in response to a corresponding field of a root instance object referenced by the reference to the instance object being characterized as having performed a write operation, performing the write operation in the data storage area corresponding to the field associated with the instance object associated with this write operation.

In einer Ausführungsform weist das Verfahren weiterhin auf: als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, Kennzeichnen eines Attributs eines Stamminstanzobjektes als „nur lesen”.In one embodiment, the method further comprises: flagging an attribute of a root instance object as "read only" in response to a thread of the root instance executing at a predetermined freeze point in the application upon execution.

Gemäß einem weiteren Aspekt der vorliegenden Erfindung wird ein System zum Ausführen einer Vielzahl von Instanzen einer Anwendung bereitgestellt, wobei das System aufweist: ein Stamminstanz-Startmittel, das zum Starten eines Ausführens einer Stamminstanz der Anwendung eingerichtet ist, wobei die Stamminstanz mindestens einen Thread beinhaltet; ein Stamminstanz-Anhaltemittel, das eingerichtet ist, als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, das Ausführen aller Threads der Stamminstanz anzuhalten; ein Repliziermittel, das eingerichtet ist, als Reaktion auf ein Starten eines Ausführens einer Instanz der Anwendung den Ausführungszustand aller Threads der Stamminstanz als den Ausführungszustand aller Threads der Instanz zu replizieren; und ein Ausführungsfortfahrmittel, das zum Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung eingerichtet ist.According to another aspect of the present invention, there is provided a system for executing a plurality of instances of an application, the system comprising: root instance launching means arranged to start executing a root instance of the application, the root instance including at least one thread; a root instance suspending means, arranged in response to a thread of the root instance, when executed, arriving at a predetermined freezing point in the application to halt the execution of all threads of the root instance; a replicating means arranged to execute state of all the threads of the root instance as the execution state of all in response to starting execution of an instance of the application To replicate threads of the instance; and execution execution means arranged to continue to execute all the threads of the instance of the application.

In einer Ausführungsform beinhaltet der Ausführungszustand mindestens: den aktuellen Stapel, die Werte von Registern und die aktuelle Anweisung eines Thread.In one embodiment, the execution state includes at least: the current stack, the values of registers, and the current instruction of a thread.

In einer Ausführungsform enthält der aktuelle Stapel des Ausführungszustands eine Referenz zu einem Instanzobjekt in der Instanz, wobei die Referenz zum Instanzobjekt so initialisiert ist, dass sie auf ein Stamminstanzobjekt verweist.In one embodiment, the current execution state stack contains a reference to an instance object in the instance, the reference to the instance object being initialized to refer to a root instance object.

In einer Ausführungsform weist das Ausführungsfortfahrmittel auf: ein Schreiboperations-Empfangsmittel, das zum Empfangen einer Schreiboperation auf ein Feld des Instanzobjektes eingerichtet ist; ein Datenspeicher-Zuordnungsmittel, das eingerichtet ist, als Reaktion darauf, dass eine Referenz zum Instanzobjekt auf das Stamminstanzobjekt verweist, einen Datenspeicherbereich für das Instanzobjekt zuzuordnen; ein Referenzmodifizierungsmittel, das eingerichtet ist, als Reaktion darauf, dass eine durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf das Stamminstanzobjekt verweist, die Referenz zum Instanzobjekt auf den durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich verweisen zu lassen; ein Schreiboperations-Ausführungsmittel, das eingerichtet ist, als Reaktion darauf, dass die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf das Stamminstanzobjekt verweist, die Schreiboperation im durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.In one embodiment, the execution continuation means comprises: a write operation receiving means arranged to receive a write operation to a field of the instance object; data storage allocation means arranged to, in response to a reference to the instance object referencing the root instance object, allocate a data storage area for the instance object; a reference modifier configured to, in response to a reference to the instance object received by the write operation receiving means refering to the root instance object, refer the reference to the instance object to the data storage area associated with the data storage area allocation means; write operation executing means arranged in response to the reference to the instance object received by the write operation receiving means referring to the root instance object to execute the write operation in the data storage area allocated by the data storage area allocation means.

In einer Ausführungsform ist das Schreiboperations-Ausführungsmittel weiterhin eingerichtet, als Reaktion darauf, dass die durch die Schreiboperations-Empfangseinheit empfangene Referenz zum Instanzobjekt nicht auf das Stamminstanzobjekt verweist, die Schreiboperation im durch das Datenspeicherbereichs-Zuordnungsweisungsmittel zugeordneten Datenspeicherbereich auszuführen.In one embodiment, the write operation executing means is further arranged to execute the write operation in the data storage area allocated by the data storage area allocation means in response to the reference to the instance object received by the write operation receiving unit not pointing to the root instance object.

In einer Ausführungsform weist das Ausführungsfortfahrmittel auf: ein Schreiboperations-Empfangsmittel, das zum Empfangen einer Schreiboperation auf ein Feld des Instanzobjektes eingerichtet ist; ein Kennzeichnungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat das entsprechende Feld des Stamminstanzobjektes so zu kennzeichnen, dass es eine Schreiboperation ausgeführt hat; ein Datenspeicherbereichs-Zuordnungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, einen Datenspeicherbereich für das Feld des Instanzobjektes zuzuordnen; ein Schreiboperations-Ausführungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.In one embodiment, the execution continuation means comprises: a write operation receiving means arranged to receive a write operation to a field of the instance object; a flag set up in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as not yet executing a write operation, the corresponding field of the root instance object so flag that it has performed a write operation; a data storage area allocation means arranged to designate, in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object, that it has not yet performed a write operation, a data storage area for Assign the field of the instance object; a write operation executing means arranged in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as not yet executing a write operation, the write operation in the execute data storage area associated with the data storage area allocation means.

In einer Ausführungsform ist das Schreiboperations-Ausführungsmittel weiterhin eingerichtet, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es eine Schreiboperation ausgeführt hat, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.In one embodiment, the write operation executing means is further arranged in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object being executed to perform a write operation, the write operation in execute the data storage area allocated by the data storage area allocation means.

In einer Ausführungsform weist das System weiterhin auf: ein Stamminstanzobjekt-Kennzeichnungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, ein Attribut des Stamminstanzobjektes in der Stamminstanz als „nur lesen” zu kennzeichnen.In one embodiment, the system further comprises: a root instance object identifier configured to read an attribute of the root instance object in the root instance as "read only" in response to a thread of the root instance executing at a predetermined freeze point in the application upon execution "To mark.

Die Erfindung kann auch in Computersoftware realisiert werden.The invention can also be implemented in computer software.

KURZE BESCHREIBUNGEN DER ZEICHNUNGENBRIEF DESCRIPTIONS OF THE DRAWINGS

Nun werden in lediglich beispielhafter Weise und unter Bezugnahme auf die folgenden Zeichnungen Ausführungsformen der vorliegenden Erfindung beschrieben:Embodiments of the present invention will now be described by way of example only and with reference to the following drawings:

1 veranschaulicht den Prozess eines Verfahrens zum Ausführen einer Vielzahl von Instanzen einer Anwendung gemäß einer Ausführungsform der vorliegenden Erfindung; 1 illustrates the process of a method for executing a plurality of instances of an application according to an embodiment of the present invention;

2 veranschaulicht weiterhin beispielhaft das Verfahren zum Ausführen einer Vielzahl von Instanzen einer Anwendung, indem die Sprache Java als Beispiel verwendet wird; 2 further exemplifies the method of executing a plurality of instances of an application by using the language Java as an example;

3 veranschaulicht gemäß einer Ausführungsform der vorliegenden Erfindung einen Prozess, dass eine Instanz eine Schreiboperation durchführt; 3 illustrates, according to an embodiment of the present invention, a process that an instance performs a write operation;

4 veranschaulicht gemäß einer Ausführungsform der vorliegenden Erfindung einen weiteren Prozess, dass eine Instanz eine Schreiboperation durchführt; und 4 illustrates, according to an embodiment of the present invention, another process that an instance performs a write operation; and

5 veranschaulicht schematisch gemäß einer Ausführungsform der vorliegenden Erfindung ein strukturelles Blockschaubild eines Systems zum Ausführen einer Vielzahl von Instanzen einer Anwendung. 5 schematically illustrates, according to an embodiment of the present invention, a structural block diagram of a system for executing a plurality of instances of an application.

(Es ist zu beachten, dass dieselben Bezugszeichen üblicherweise dieselben Komponenten in den beispielhaften Ausführungsformen der vorliegenden Erfindung bezeichnen.)(It should be noted that the same reference numerals usually denote the same components in the exemplary embodiments of the present invention.)

DETAILLIERTE BESCHREIBUNG BEISPIELHAFTER AUSFÜHRUNGSFORMENDETAILED DESCRIPTION OF EXEMPLARY EMBODIMENTS

Bevorzugte Realisierungen der vorliegenden Erfindung werden detaillierter unter Bezugnahme auf die begleitenden Zeichnungen beschrieben, in denen die bevorzugten Ausführungsformen gezeigt sind. Die vorliegende Erfindung kann jedoch in vielfältigen Formen realisiert werden und sollte nicht als auf die hierin dargelegten Ausführungsformen beschränkt angesehen werden. Diese Ausführungsformen werden im Gegenteil bereitgestellt, um der vorliegenden Erfindung mehr Genauigkeit und Vollständigkeit zu verleihen und dem Fachmann den Umfang der vorliegenden Erfindung vollständig zu vermitteln.Preferred implementations of the present invention will be described in more detail with reference to the accompanying drawings, in which the preferred embodiments are shown. However, the present invention can be embodied in various forms and should not be construed as limited to the embodiments set forth herein. On the contrary, these embodiments are provided to give greater accuracy and completeness to the present invention and to fully convey the scope of the present invention to those skilled in the art.

Programmierer rufen üblicherweise Programme auf, die in den Computerprozessen ausgeführt werden, und jeder Prozess verfügt über seinen eigenen Arbeitsspeicherplatz. Zum Beispiel wird für ein IE-Browser-Programm jedes Mal ein IE-Browser-Fenster geöffnet, wenn ein IE-Browser-Prozess gestartet wird. Und ein Thread bezieht sich auf einen Ausführungsfluss in einem Prozess und wird manchmal auch ein Ausführungskontext genannt. Ein einzelner Prozess kann sich aus einer Vielzahl von Threads zusammensetzen, d. h., eine Vielzahl unterschiedlicher Threads können gleichzeitig in einem einzigen Prozess ausgeführt werden, und sie führen jeweils unterschiedliche Tasks aus. Wird eine Vielzahl von Threads in einem Prozess gleichzeitig ausgeführt, wird ein solcher Ausführungsmodus „paralleles Ausführen” genannt. Der Hauptunterschied zwischen einem Thread und einem Prozess liegt darin, dass jeder Prozess das Betriebssystem benötigt, um einen separaten Arbeitsspeicheradressraum dafür anzulegen, wohingegen alle Threads in einem einzelnen Prozess in demselben einen Adressraum arbeiten, und diese Threads können denselben einen Speicher und Systemressourcen gemeinsam nutzen, z. B. ein Objekt oder eine geöffnete Datei gemeinsam nutzen. Vorhandene Betriebssysteme wie beispielsweise Mac, Windows® verwenden üblicherweise das Konzept mehrfacher Threads und sehen einen Thread als grundlegende Ausführungseinheit an. (Windows ist eine Marke der Microsoft Corporation in den USA, anderen Ländern oder beidem.)Programmers typically invoke programs that run in the computer processes, and each process has its own memory space. For example, for an IE browser program, an IE browser window is opened each time an IE browser process is started. And a thread refers to an execution flow in a process and is sometimes called an execution context. A single process may be composed of a plurality of threads, that is, a plurality of different threads may be executed concurrently in a single process and each perform different tasks. When a plurality of threads are simultaneously executed in a process, such an execution mode is called "parallel execution". The main difference between a thread and a process is that each process needs the operating system to create a separate memory address space for it, whereas all the threads in a single process work in the same one address space, and these threads can share the same memory and system resources, z. For example, share an object or an open file. Existing operating systems, such as Mac, Windows® , typically use the concept of multiple threads and consider a thread as a basic execution unit. (Windows is a trademark of Microsoft Corporation in the United States, other countries, or both.)

Um für eine Anwendung wie die Sprache Java in der vorhandenen Cloud-Computing-Umgebung die mandantenfähige Architektur umzusetzen, wird eine virtuelle Maschine repliziert, und eine weitere gleiche Anwendung wird auf der virtuellen Maschine ausgeführt. Bei der virtuellen Maschine handelt es sich um einen Prozess, und der replizierte Prozess der virtuellen Maschine kann Arbeitsspeicherseiten gemeinsam mit dem ursprünglichen Prozess der virtuellen Maschine nutzen; bei Arbeitsspeicherseiten handelt es sich jedoch um große Datenspeichereinheiten im Arbeitsspeicher, so dass die Granularität einer solchen gemeinsamen Nutzung grob und der eingesparte Datenspeicherplatz begrenzt ist.To translate multi-tenant architecture to an application such as the Java language in the existing cloud computing environment, one virtual machine replicates and another similar application runs on the virtual machine. The virtual machine is a process, and the replicated virtual machine process can share memory pages with the original virtual machine process; however, memory pages are large data storage devices in memory, so the granularity of such sharing is limited and the data storage space saved is limited.

Darüber hinaus ist es in vielen Szenarien oft erforderlich, eine Vielzahl von Instanzen einer Anwendung auszuführen. Eine Instanz bezeichnet ein einziges Mal eines Ausführens einer Anwendung, z. B. bezieht sich ein Ausführen einer Vielzahl von Eclipse-Instanzen auf das mehrmalige Ausführen der Anwendung „Eclipse”; oder ein Ausführen einer Vielzahl von Instanzen einer Java-Anwendung bezieht sich auf das mehrmalige Ausführen der Anwendung „Java” im virtuellen Java-Maschinenprozess. Bei einer Instanz handelt es sich ursprünglich um ein virtuelles Konzept, und sie besitzt keine ihr entsprechende Programmentität; eine einzelne Instanz kann eine Vielzahl von Threads beinhalten; und wenn eine Vielzahl von Instanzen im selben Prozess ausgeführt werden, können die Instanzen den Arbeitsspeicherplatz gemeinsam nutzen. Jede Instanz kann eine Vielzahl von Threads beinhalten, und die derzeitigen mandantenfähigen Lösungen verfügen nur über Replizierung auf der Ebene des virtuellen Maschinenprozesses, d. h., Prozesse nutzen Arbeitsspeicherseiten gemeinsam. Eine Vielzahl von in einer Vielzahl von Instanzen enthaltenen Threads weist jedoch keine gemeinsame Nutzung zwischen ihnen auf, wohingegen die Vielzahl von Threads innerhalb der Instanzen viele Ähnlichkeiten aufweisen. Da die Datenspeicherplätze von Instanzenprozessen unabhängig sind und gemeinsame Prozessnutzung verwenden, können Arbeitsspeicherseiten üblicherweise aufgrund kleinerer Unterschiede nicht gemeinsam genutzt werden, und durch die grobe Granularität des gemeinsamen Nutzens wird viel Anwendungsausführungs-Speicherplatz verschwendet.In addition, in many scenarios, it is often necessary to run a variety of instances of an application. An instance once signifies execution of an application, e.g. For example, executing a plurality of Eclipse instances refers to running the Eclipse application multiple times; or executing a plurality of instances of a Java application refers to running the Java application multiple times in the Java virtual machine process. An instance is originally a virtual concept and does not have its own programmentality; a single instance may contain a plurality of threads; and when a plurality of instances are running in the same process, the instances can share the memory space. Each instance can contain a multitude of threads, and the current multi-tenant solutions only have replication at the virtual machine process level; h., processes share memory pages together. However, a plurality of threads included in a plurality of instances have no sharing between them, whereas the plurality of threads within the instances have many similarities. Because the datastores are independent of instance processes and share process usage, memory pages usually can not be shared because of smaller differences, and the coarse granularity of the shared benefit wastes a lot of application execution space.

Daher berücksichtigt eine Ausführungsform der vorliegenden Erfindung, dass in einer Cloud-Computing-Umgebung das Ausführen einer Vielzahl von Anwendungsinstanzen verwenden kann, um die mandantenfähige Architektur zu verwirklichen, und führt wiederholt eine gemeinsame Datennutzung für die Vielzahl von Instanzen in der Anwendung durch, um den Speicherplatz des Ausführens der Anwendung zu sparen.Therefore, an embodiment of the present invention contemplates that in a cloud Computing environment can use the execution of a variety of application instances to realize the multi-tenant architecture, and repeatedly performs a data sharing for the plurality of instances in the application to save the memory of running the application.

Die vorliegende Erfindung stellt gemäß einer Ausführungsform ein Verfahren zum Ausführen einer Vielzahl von Instanzen einer Anwendung bereit. Anhand der Beschreibung der Verfahrensprozesse erkennt der Fachmann, dass das Verfahren für alle Anwendungen anwendbar ist, die objektorientierte Sprachen verwenden und auf virtuellen Maschinen ausgeführt werden, und es gibt viele solcher Anwendungen, z. B. Anwendungen der Sprache „Java”, die auf einer virtuellen Java-Maschine (Java virtual machine (JVM)) ausgeführt werden können, Anwendungen der Sprache „Ruby”, die auf einer virtuellen Ruby-Maschine ausgeführt werden können, und Anwendungen der Sprache „C#”, die auf einer virtuellen C#-Maschine ausgeführt werden können, usw.The present invention, in one embodiment, provides a method for executing a plurality of instances of an application. From the description of the method processes, those skilled in the art will recognize that the method is applicable to all applications using object-oriented languages and executing on virtual machines, and there are many such applications, e.g. For example, Java language applications that can run on a Java virtual machine (JVM) machine, Ruby language applications that run on a Ruby virtual machine, and language applications "C #" that can be run on a C # virtual machine, etc.

1 veranschaulicht den Prozess eines Verfahrens zum Ausführen einer Vielzahl von Instanzen einer Anwendung gemäß einer Ausführungsform der vorliegenden Erfindung. Gemäß 1 wird in Schritt S101 das Ausführen einer Stamminstanz der Anwendung gestartet, und die Stamminstanz beinhaltet mindestens einen Thread. Hier kann die Stamminstanz als das erste Ausführen der Anwendung verstanden werden; in Schritt S102 wird ermittelt, ob ein Thread der Stamminstanz der Anwendung beim Ausführen zu einem Einfrierpunkt gelangt, was nachstehend detailliert erläutert wird. Falls nicht, wird weiterhin gewartet; falls ja, wird in Schritt S103 als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen an einen zuvor festgelegten Einfrierpunkt der Anwendung gelangt, das Ausführen aller Threads der Stamminstanz angehalten; vorzugsweise wird in Schritt S104 ein Attribut eines Stamminstanzobjektes in der Stamminstanz als „nur lesen” gekennzeichnet, was nur dazu dient zu verhindern, dass eine nachfolgende Schreiboperation das Stamminstanzobjekt modifiziert wird; wie anhand der nachfolgenden Abarbeitung des Verfahrens ersichtlich ist, findet im Falle, dass eine Schreiboperation betroffen ist, in der Tat keine Operation des direkten Modifizierens eines Feldes des Stamminstanzobjektes statt. Daher dient ein solches Kennzeichnen nur dazu, Fehloperationen zu verhindern, und es handelt sich um eine bevorzugte Realisierung; in Schritt S105 wird ermittelt, ob alle Threads einer Instanz der Anwendung auszuführen sind, und hier versteht sich eine Instanz als das zweite, dritte ... Ausführen der Anwendung, d. h. kein erstes Ausführen der Anwendung; falls nicht, wird weiterhin gewartet; falls ja, wird in Schritt S106 als Reaktion auf das Starten des Ausführens einer Instanz der Anwendung der Ausführungszustand aller Threads der Stamminstanz als der Ausführungszustand aller Threads der Instanz repliziert; auf der Grundlage des replizierten Ausführungszustandes aller Threads wird in Schritt S107 fortgefahren, alle Threads der Instanz der Anwendung auszuführen. 1 illustrates the process of a method for executing a plurality of instances of an application according to an embodiment of the present invention. According to 1 In step S101, the execution of a root instance of the application is started, and the root instance includes at least one thread. Here, the root instance can be understood as the first execution of the application; In step S102, it is determined whether a thread of the root instance of the application comes to a glass transition point upon execution, which will be explained in detail below. If not, will continue to wait; if so, in step S103, in response to a thread of the root instance getting to a pre-determined application freeze point upon execution, execution of all threads of the root instance is halted; preferably, in step S104, an attribute of a root instance object in the root instance is designated as "read only", which only serves to prevent a subsequent write operation from modifying the root instance object; As will be apparent from the subsequent processing of the method, in the event that a write operation is involved, in fact, no operation of directly modifying a field of the root instance object takes place. Therefore, such labeling only serves to prevent misoperation and is a preferred implementation; In step S105, it is determined whether all threads of an instance of the application are to be executed, and here an instance is understood as the second, third ... execution of the application, ie, not first executing the application; if not, will continue to wait; if yes, in step S106, in response to starting execution of an instance of the application, the execution state of all threads of the root instance is replicated as the execution state of all threads of the instance; based on the replicated execution state of all threads, in step S107, all threads of the instance of the application are executed.

Verglichen mit der Realisierung von Mandantenfähigkeit, bei welcher die JVM beim Stand der Technik repliziert wird, wird beim vorstehend beschriebenen Verfahren lediglich der Ausführungszustand aller Threads der Stamminstanz repliziert, und die Granularität der Replikation ist geringer, und die replizierten Inhalte sind weniger umfangreich, so dass mehr Programmausführungsspeicherplatz eingespart wird.Compared with the realization of multi-client capability in which the JVM is replicated in the prior art, in the method described above, only the execution state of all threads of the root instance is replicated, and the granularity of replication is lower, and the replicated contents are less extensive, so that more program execution memory space is saved.

Weiterhin veranschaulicht 2 beispielhaft das Verfahren zum Ausführen einer Vielzahl von Instanzen einer Anwendung, indem die Sprache Java als Beispiel verwendet wird. Obwohl das Verfahren unter Verwendung der Sprache Java als ein Beispiel beschrieben ist, weiß der Fachmann, dass sie durch jede beliebige andere Anwendung ersetzt werden kann, die eine objektorientierte Sprache verwendet und auf einer virtuellen Maschine ausgeführt wird. In 2 ist die gesamte Anwendung wie ein Prozess und wird auf der virtuellen Java-Maschine ausgeführt, und die JVM an sich kann viele Threads enthalten. Der JVM-Thread von 2 ist nur beispielhaft und zeigt eine Ausführungsumgebung der folgenden Anwendung. Die Anwendung findet unter der mandantenfähigen Architektur statt, und gemäß dem vorstehenden Verfahren kann das Ausführen auf der virtuellen Java-Maschine in zwei Phasen aufgeteilt werden: Bei der ersten Phase handelt es sich um das Ausführen der Stamminstanz; gemäß 2 wird angenommen, dass eine Instanz drei Threads enthält und der erste die Stamminstanz ausführt; allgemein wird eine Instanz einer Anwendung üblicherweise von einem Haupt-Thread ausgeführt. Der Haupt-Thread kann weitere Threads erzeugen (d. h. untergeordnete Threads), wobei die untergeordneten Threads ihre eigenen untergeordneten Threads erzeugen können. Das Erzeugen dieser Threads wird durch den von Programmierern geschriebenen Code gesteuert. Wenn das Ausführen bis zu einem gewissen Ausmaß erfolgt, werden alle Threads der Stamminstanz angehalten, was hier „Einfrierpunkt” genannt wird. Gemäß einer Ausführungsform der vorliegenden Erfindung gibt der Einfrierpunkt an, dass alle Objekte initialisiert wurden, die durch unterschiedliche Mandanten gemeinsam genutzt werden könnten. Die Art des Festlegens des Einfrierpunktes kann ein Aufrufen einer speziellen Anweisung oder Funktion sein, die durch die virtuelle Maschine bereitgestellt wird. Üblicherweise muss in einem Programm nur ein einziger Einfrierpunkt festgelegt sein, der nur einmal ausgeführt wird. Wenn ein Thread des Programms beim Ausführen erstmals an den Einfrierpunkt gelangt, empfängt die virtuelle Maschine das Aufrufen der speziellen Anweisung oder Funktion und beginnt dann unmittelbar, die Einfrieroperation auszuführen, d. h., das Ausführen aller Threads der Anwendung auszusetzen. Der Einfrierpunkt wird üblicherweise durch einen Programmierer entsprechend seiner Kenntnis des Programms während des Schreibens des Programms festgelegt und befindet sich innerhalb des Programms. Daher können Programme mit denselben Funktionen, die von unterschiedlichen Programmierern geschrieben wurden, aufgrund der unterschiedlichen Positionen des Einfrierpunktes unterschiedlich viel Datenspeicherplatz einsparen. In Zukunft wird mit dem Fortschreiten der Technologie und der Entwicklung der künstlichen Intelligenz der Einfrierpunkt unter Umständen bis zu einem gewissen Grad automatisch durch Programmierwerkzeuge festgelegt werden. Wenn der Einfrierpunkt automatisch festgelegt wird, können die folgenden Grundgedanken verwendet werden: am Einfrierpunkt weist die Anzahl von durch alle Threads der Stamminstanz geöffneten lokalen Handles ein Minimum auf, und die Anzahl aktiver Threads der Instanz ist minimal. Hier schließen die lokalen Handles Datei-Handles, Netzwerk-Handles usw. mit ein. Wenn die Stamminstanz beim Ausführen an den Einfrierpunkt gelangt, werden all ihre Threads nicht länger ausgeführt, und zu diesem Zeitpunkt kann ein Attribut eines Stamminstanzobjektes in der Stamminstanz vorzugsweise als „nur lesen” gekennzeichnet werden, und dann kann der Ausführungszustand aller Threads der Stamminstanz in der zweiten Phase als eine Replizierungsgrundlage für das Ausführen aller Threads anderer Instanzen verwendet werden. Es gibt viele Arten, ein Stamminstanzobjekt zu kennzeichnen, z. B. Verwenden eines Flag-Bit, wobei hierbei im Falle, dass das Flag-Bit 0 ist, die Attribute aller Objekte in der Stamminstanz „nur lesen”, andernfalls lesbar und schreibbar sind, oder Verwenden der Art des Sperrens usw. In der zweiten Phase wird ein Ausführen aller Threads anderer Instanzen gestartet; für das Ausführen aller Threads einer ersten Instanz wird zuerst der Ausführungszustand aller Threads der Stamminstanz als der Ausführungszustand aller Threads der Instanz repliziert, und der Ausführungszustand aller Threads ist die Datenstruktur aller Thread-Objekte an sich, wozu mindestens der aktuelle Stapel, die Werte von Registern und die aktuelle Anweisung eines Thread zählen. Der aktuelle Stapel eines Thread kann viele Informationen enthalten, wozu mindestens die Referenz zu einem Instanzobjekt zählt, und bei der Referenz kann es sich um einen Zeiger handeln, der beim Initialisieren auf ein Stamminstanzobjekt verwiesen wird. Auf diese Weise werden die Ausführungsumgebung und die Daten der Stamminstanz hinüberrepliziert. Offensichtlich besitzt im Vergleich mit dem Replizieren der Ausführungsumgebung einer Anwendung das Replizieren der Inhalte der Stamminstanz eine geringere Granularität und weniger umfangreiche Inhalte; darüber hinaus kann dies die Startzeit einer neuen Instanz weiter verringern. Wenn das Ausführen einer zweiten und dritten Instanz beginnt, wird somit nach wie vor der Ausführungszustand aller Threads von der Stamminstanz repliziert, und dann fahren sie mit dem Ausführen fort.Further illustrated 2 exemplifies the method of executing a plurality of instances of an application by using the language Java as an example. Although the method using the Java language is described as an example, those skilled in the art will understand that it can be replaced by any other application that uses object-oriented language and executes on a virtual machine. In 2 the whole application is like a process and runs on the Java virtual machine, and the JVM itself can contain many threads. The JVM thread of 2 is merely exemplary and shows an execution environment of the following application. The application takes place under the multi-tenant architecture, and according to the above method, the execution on the Java virtual machine can be divided into two phases: the first phase is the execution of the root instance; according to 2 assume that an instance contains three threads and the first executes the root instance; Generally, an instance of an application is typically executed by a main thread. The main thread can create additional threads (ie, child threads), allowing the child threads to create their own child threads. The creation of these threads is controlled by the code written by programmers. When the execution is to some extent, all threads of the root instance are halted, which is called a "freeze point" here. According to one embodiment of the present invention, the freeze point indicates that all objects that could be shared by different clients have been initialized. The manner of specifying the glass transition point may be to invoke a specific instruction or function provided by the virtual machine. Usually only one single point of freezing has to be defined in a program, which is executed only once. When a thread of the program first reaches the freeze point when it is executed, the virtual machine receives the Call the special statement or function and then immediately begin executing the freeze operation, that is, suspending the execution of all threads from the application. The glass transition point is usually set by a programmer according to his knowledge of the program during the writing of the program and is within the program. Therefore, programs with the same functions written by different programmers can save different amounts of data storage due to different positions of the freezing point. In the future, with the advancement of technology and the development of artificial intelligence, the freezing point may, to a certain extent, be automatically determined by programming tools. When the freeze point is set automatically, the following principles can be used: at the freeze point, the number of local handles opened by all the threads of the root instance is at a minimum, and the number of active threads of the instance is minimal. Here, the local handles include file handles, network handles, and so on. When the root instance reaches the freeze point when run, all its threads are no longer running, and at this point, an attribute of a root instance object in the root instance may be designated as read-only, and then the execution state of all threads of the root instance in the root instance second stage as a replication foundation for executing all threads of other instances. There are many ways to identify a root instance object, for example: B. using a flag bit, in which case if the flag bit is 0, the attributes of all objects in the root instance are "read only", otherwise readable and writable, or using the type of locking, etc. In the second Phase starts running all threads of other instances; for executing all threads of a first instance, first the execution state of all threads of the root instance is replicated as the execution state of all threads of the instance, and the execution state of all threads is the data structure of all thread objects per se, including at least the current stack, the values of registers and count the current statement of a thread. The current stack of a thread can contain much information, including at least the reference to an instance object, and the reference can be a pointer that is referenced to a root instance object during initialization. In this way, the execution environment and the data of the root instance are over-replicated. Obviously, replicating the contents of the root instance has less granularity and less extensive content compared to replicating the execution environment of an application; In addition, this can further reduce the start time of a new instance. Thus, when the execution of a second and third instance begins, the execution state of all threads is still replicated from the root instance, and then they continue to execute.

Während des Ausführungsprozesses aller Threads einer Instanz kann eine Zugriffsoperation, wozu eine Leseoperation und eine Schreiboperation zählen, an einem Feld eines Objekts in einem Thread durchgeführt werden, und hier wird als Erstes eine Schreiboperation betrachtet. 3 zeigt einen Prozess, dass eine Instanz eine Schreiboperation durchführt. Gemäß 3 wird in Schritt S301 eine Schreiboperation auf ein Feld eines Instanzobjektes der Anwendung empfangen; in Schritt S302 wird ermittelt, ob es sich bei der Schreiboperation um eine erste Schreiboperation auf das Instanzobjekt handelt. Da vor der ersten Schreiboperation die Referenz zum Instanzobjekt im aktuellen Stapel des Thread als auf ein Stamminstanzobjekt verweisend initialisiert ist, wird im Falle, dass sie als die erste Schreiboperation ermittelt wird, d. h. als Reaktion darauf, dass die Referenz zum Instanzobjekt auf ein Stamminstanzobjekt verweist, in Schritt S303 ein Datenspeicherbereich für das Instanzobjekt zugeordnet; in Schritt S304 wird die im aktuellen Stapel enthaltene Referenz zum Instanzobjekt auf den Datenspeicherbereich verwiesen, der für das Instanzobjekt zugeordnet ist; in Schritt S305 wird die Schreiboperation in dem Speicherbereich ausgeführt. Wenn in Schritt S302 festgestellt wird, dass es sich bei der Schreiboperation nicht um die erste Schreiboperation auf das Instanzobjekt handelt, was bedeutet, dass die im aktuellen Stapel enthaltene Referenz zum Instanzobjekt nicht länger auf ein Stamminstanzobjekt, sondern auf den für das Instanzobjekt zugeordneten Datenspeicherbereich verwiesen hat, d. h. als Reaktion darauf, dass die Referenz zum Instanzobjekt nicht auf ein Stamminstanzobjekt verweist, wird direkt zu Schritt S305 gesprungen.During the execution process of all the threads of an instance, an access operation, which includes a read operation and a write operation, may be performed on a field of an object in a thread, and here a write operation is considered first. 3 shows a process that an instance performs a write operation. According to 3 at step S301, a write operation to a field of an instance object of the application is received; In step S302, it is determined whether the write operation is a first write operation to the instance object. Because the reference to the instance object in the current stack of the thread is initialized as referencing a root instance object prior to the first write operation, if it is determined to be the first write operation, that is, in response to the reference to the instance object referencing a root instance object, in step S303, a data storage area is allocated for the instance object; in step S304, the reference to the instance object contained in the current stack is referenced to the data storage area associated with the instance object; In step S305, the write operation is executed in the memory area. If it is determined in step S302 that the write operation is not the first write operation to the instance object, which means that the reference to the instance object contained in the current stack no longer referred to a root instance object but to the data storage area associated with the instance object that is, in response to the reference to the instance object not referencing a root instance object, it jumps directly to step S305.

Eine an einem Feld eines Objekts im Thread durchgeführte Leseoperation kann direkt auf den Bereich zugreifen, auf den die im aktuellen Stapel des Ausführungszustands aller Threads der Instanz enthaltene Referenz zum Instanzobjekt verweist; wenn keine Schreiboperation durchgeführt wurde, wird der Wert des Feldes des Stamminstanzobjektes gelesen; wenn eine Schreiboperation durchgeführt wurde, wird der Wert des Feldes des Objekts im für das Instanzobjekt zugeordneten Datenspeicherbereich gelesenen.A read performed on a field of an object in the thread can directly access the area to which the reference to the instance object contained in the current state of execution of all threads of the instance refers; if no write operation has been performed, the value of the field of the root instance object is read; when a write operation has been performed, the value of the field of the object is read in the data storage area associated with the instance object.

Wie anhand der vorstehenden Lösung ersichtlich ist, wird durch Verwenden der vorstehenden Zugriffsoperation der durch Attribute eines Instanzobjektes, d. h. Daten, belegte Datenspeicherplatz weiter verringert; wenn es keine Datenaktualisierung gibt, d. h. keine Schreiboperation auf ein Attribut eines Instanzobjektes geschieht, werden alle Leseoperationen auf Attribute eines Stamminstanzobjektes gerichtet, und es besteht keine Notwendigkeit, die Attribute von Instanzobjekten zu replizieren, und der Datenspeicherplatz kann zudem weiter verringert werden.As can be seen from the above solution, by using the above access operation, the data storage space occupied by attributes of an instance object, ie data, is further reduced; if there is no data update, ie no write to an attribute of an instance object happens, all will Read operations are directed to attributes of a root instance object, and there is no need to replicate the attributes of instance objects, and the data storage space can be further reduced.

4 zeigt einen weiteren Prozess, dass eine Instanz eine Schreiboperation durchführt. Gemäß 4 wird in Schritt S401 eine Schreiboperation auf ein Feld eines Instanzobjektes empfangen; in Schritt S402 wird ermittelt, ob ein entsprechendes Feld eines Stamminstanzobjektes, auf das die Referenz zum Stamminstanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, und als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, wird in Schritt S403 ein Datenspeicherbereich für das Feld des Instanzobjektes zugeordnet, das der Schreiboperation zugehörig ist; auf diese Weise wird kein Datenspeicherbereich für ein gesamtes Objekt wie bei der in 3 gezeigten Realisierung zugeordnet, und es wird nur ein Datenspeicherbereich für das Feld zugeordnet, das im Objekt modifiziert werden muss. Das Feld im Objekt stellt nur einen kleinen Teil des Objektes dar, und der belegte Datenspeicherplatz ist weitaus geringer als der durch das Objekte belegte Datenspeicherplatz, und somit kann dies weiter den Datenspeicherplatz der Instanz einsparen; in Schritt S404 wird das entsprechende Feld des Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet, dass es eine Schreiboperation ausgeführt hat; in Schritt S405 wird die Schreiboperation im zugeordneten Datenspeicherbereich ausgeführt. Ein solches Kennzeichnen kann auf vielfältige Weise erfolgen, z. B. Verwenden unterschiedlicher Werte einer Variablen, um unterschiedliche Bedeutungen anzugeben, oder Verwenden der virtuellen Maschine zum Kennzeichnen usw. Wenn festgestellt wird, dass das entsprechende Feld des Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es eine Schreiboperation ausgeführt hat, was bedeutet, dass dem Feld des Instanzobjektes, das der Schreiboperation zugehörig ist, ein Datenspeicherbereich zugeordnet wurde, wird zu diesem Zeitpunkt in Schritt S406 als Reaktion darauf, dass das entsprechende Feld des Stamminstanzobjektes, auf das die Referenz zum Instanzobjektes verweist, so gekennzeichnet, dass es eine Schreiboperation ausgeführt hat, und die Schreiboperation wird im für das Feld des der Schreiboperation zugehörigen Instanzobjektes zugeordneten Datenspeicherbereich ausgeführt. 4 Figure 15 shows another process that an instance is performing a write operation. According to 4 at step S401, a write operation to a field of an instance object is received; In step S402, it is determined whether a corresponding field of a root instance object referenced by the reference to the root instance object is flagged as not yet performing a write operation, and in response to a corresponding field of a root instance object referenced by the reference to Instance object referenced as having not yet performed a write operation, in step S403, a data storage area for the field of the instance object associated with the write operation is assigned; In this way, no data storage area for an entire object as in the 3 associated realization, and it is assigned only a data storage area for the field that needs to be modified in the object. The field in the object represents only a small part of the object, and the occupied data storage space is much smaller than the data storage space occupied by the objects, and thus this can further save the data storage space of the instance; in step S404, the corresponding field of the root instance object referenced by the reference to the instance object is designated as having performed a write operation; In step S405, the write operation is performed in the associated data storage area. Such labeling can be done in many ways, for. For example, using different values of a variable to indicate different meanings, or using the virtual machine to identify, and so on. If the corresponding field of the root instance object referenced by the instance instance object instance is identified as performing a write operation which means that a data storage area has been assigned to the field of the instance object associated with the write operation, at this time in step S406 in response to the corresponding field of the root instance object referenced by the reference to the instance object being so marked in that it has performed a write operation, and the write operation is performed in the data storage area associated with the field of the instance object associated with the write operation.

Eine in einem Feld eines Objektes im Thread durchgeführte Leseoperation kann direkt auf den Bereich zugreifen, auf den die im aktuellen Stapel des Ausführungszustands des Thread der Instanz enthaltene Referenz zum Instanzobjekt verweist; wenn keine Schreiboperation durchgeführt wurde, wird der Wert des Feldes des Stamminstanzobjektes gelesen; wenn eine Schreiboperation durchgeführt wurde, wäre das Feld des Instanzobjektes gekennzeichnet worden, und eine solche in der virtuellen Maschine gespeicherte Information kann verwendet werden, den Wert des Feldes des Objekts im für das Feld des Instanzobjektes zugeordneten Datenspeicherbereich auszulesen.A read performed in a field of an object in the thread can directly access the area to which the reference to the instance object contained in the current state of execution of the thread of the instance refers; if no write operation has been performed, the value of the field of the root instance object is read; if a write operation has been performed, the field of the instance object would have been flagged, and such information stored in the virtual machine could be used to read out the value of the field of the object in the data storage area associated with the field of the instance object.

Offensichtlich wird bei dieser Realisierung nicht nur weiter der Datenspeicherplatz einer Instanz eingespart, sondern sie bringt auch alle Vorteile der Ausführungsform von 3 mit sich.Obviously, this realization not only further saves the data storage space of an instance, but also brings all the advantages of the embodiment of 3 with himself.

Wenn das Ausführen der Anwendung angehalten wird, wird nicht nur das Ausführen aller anderen Instanzen angehalten, um den Programmausführspeicherplatz und den durch alle Instanzen belegten Datenspeicherplatz freizumachen, sondern der durch die Stamminstanz belegte Programmausführspeicherplatz und der Datenspeicherplatz werden ebenso freigemacht.When execution of the application is halted, not only the execution of all other instances is halted to clear the program execution space and the data storage space occupied by all instances, but the executable space occupied by the root instance and the data storage space are also freed.

Unter demselben erfinderischen Konzept wird in einer Ausführungsform der vorliegenden Erfindung zudem ein System zum Ausführen einer Vielzahl von Instanzen einer Anwendung offenbart. 5 zeigt schematisch ein strukturelles Blockschaubild eines Systems zum Ausführen einer Vielzahl von Instanzen einer Anwendung. Wie in 5 gezeigt, weist das System auf: ein Stamminstanz-Startmittel 501, das zum Starten eines Ausführens einer Stamminstanz der Anwendung eingerichtet ist, wobei die Stamminstanz mindestens einen Thread beinhaltet; ein Stamminstanz-Anhaltemittel 502, das eingerichtet ist, als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, das Ausführen aller Threads der Stamminstanz anzuhalten; ein Repliziermittel 503, das eingerichtet ist, als Reaktion auf ein Starten eines Ausführens einer Instanz der Anwendung, den Ausführungszustand aller Threads der Stamminstanz als den Ausführungszustand aller Threads der Instanz zu replizieren; und ein Ausführungsfortfahrmittel 504 das zum Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung eingerichtet ist. In einer bevorzugten Ausführungsform weist das System weiterhin ein Stamminstanzobjekt-Kennzeichnungsmittel 505 auf, das eingerichtet ist, als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, ein Attribut eines Stamminstanzobjektes in der Stamminstanz als „nur lesen” zu kennzeichnen. Im System beinhaltet der Ausführungszustand des Thread mindestens den aktuellen Stapel, die Werte von Registern und die aktuelle Anweisung des Thread. Der aktuelle Stapel des Ausführungszustands eines Thread einer Systeminstanz beinhaltet eine Referenz zu einem Instanzobjekt, wobei die Referenz zur Objektinstanz als auf das Stamminstanzobjekt verweisend initialisiert wird.Under the same inventive concept, in one embodiment of the present invention, there is also disclosed a system for executing a plurality of instances of an application. 5 Fig. 12 schematically shows a structural block diagram of a system for executing a plurality of instances of an application. As in 5 the system comprises: a root instance launcher 501 that is set up to start executing a root instance of the application, the root instance including at least one thread; a root instance stopping means 502 set up, in response to a thread of the root instance, when executed, arriving at a predetermined freeze point in the application to halt the execution of all threads of the root instance; a replicating agent 503 configured to, in response to starting execution of an instance of the application, replicate the execution state of all threads of the root instance as the execution state of all the threads of the instance; and an execution continuation means 504 which is set up to continue running all the threads of the instance of the application. In a preferred embodiment, the system further comprises a root instance object identifier 505 configured to flag an attribute of a root instance object in the root instance as "read only" in response to a thread of the root instance, when executed, arriving at a predetermined freeze point in the application; In the system, the execution state of the thread includes at least the current stack, the values of registers, and the current instruction of the thread. The current batch of execution state A thread of a system instance contains a reference to an instance object, whereby the reference to the object instance is initialized as referring to the root instance object.

In einer Ausführungsform weist das Ausführungsfortfahrmittel weiterhin auf: ein Schreiboperations-Empfangsmittel, das zum Empfangen einer Schreiboperation auf ein Feld eines Instanzobjektes eingerichtet ist; ein Speicherzuordnungsmittel, das eingerichtet ist, als Reaktion darauf, dass die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf ein Stamminstanzobjekt verweist, einen Datenspeicherbereich für das Instanzobjekt zuzuordnen; ein Referenzmodifizierungsmittel, das eingerichtet ist, als Reaktion darauf, dass die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf ein Stamminstanzobjekt verweist, die Referenz zum Instanzobjekt auf den durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich verweisen zu lassen; ein Schreiboperations-Ausführungsmittel, das eingerichtet ist, als Reaktion darauf, dass die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf ein Stamminstanzobjekt verweist, die Schreiboperation im durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen. Dabei ist das Schreiboperations-Ausführungsmittel weiterhin eingerichtet als Reaktion darauf, dass die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt nicht auf das Stamminstanzobjekt verweist, die Schreiboperation im durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.In one embodiment, the execution continuation means further comprises: a write operation receiving means arranged to receive a write operation on a field of an instance object; memory allocation means arranged in response to the reference to the instance object received by the write operation receiving means referring to a root instance object to allocate a data storage area for the instance object; a reference modifier configured, in response to the reference to the instance object received by the write operation receiving means referencing a root instance object, to refer the reference to the instance object to the data storage area associated with the data storage area allocation means; write operation executing means arranged in response to the reference to the instance object received by the write operation receiving means referring to a root instance object to execute the write operation in the data storage area allocated by the data storage area allocation means. Here, the write operation executing means is further arranged in response to the reference to the instance object received by the write operation receiving means not pointing to the root instance object to execute the write operation in the data storage area allocated by the data storage area allocation means.

In einer weiteren Ausführungsform weist das Ausführungsfortfahrmittel weiterhin auf: ein Schreiboperations-Empfangsmittel, das zum Empfangen einer Schreiboperation auf ein Feld eines Instanzobjektes eingerichtet ist; ein Kennzeichnungsmittel, das eingerichtet ist, als Reaktion darauf, dass das entsprechende Feld des Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, das entsprechende Feld des Stamminstanzobjektes so zu kennzeichnen, dass es eine Schreiboperation ausgeführt hat; ein Datenspeicherbereichs-Zuordnungsmittel, das eingerichtet ist, als Reaktion darauf, dass das entsprechende Feld des Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, einen Datenspeicherbereich für das Feld des Instanzobjektes zuzuordnen; ein Schreiboperations-Ausführungsmittel, das eingerichtet ist, als Reaktion darauf, dass das entsprechende Feld des Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen. Im System ist das Schreiboperations-Ausführungsmittel weiterhin eingerichtet, als Reaktion darauf, dass das entsprechende Feld des Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es eine Schreiboperation ausgeführt hat, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.In another embodiment, the execution continuation means further comprises: a write operation receiving means arranged to receive a write operation to a field of an instance object; a flag set up, in response to the corresponding field of the root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as not yet executing a write operation, the corresponding field of the root instance object to flag that it has performed a write operation; a data storage area allocation means arranged in response to the corresponding field of the root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as having not yet performed a write operation, a data storage area for the Assign the field of the instance object; a write operation executing means arranged in response to the corresponding field of the root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as having not yet executed a write operation, the write operation in the execute data storage area associated with the data storage area allocation means. In the system, the write operation execution means is further arranged in response to the corresponding field of the root instance object to which the reference received by the write operation receiving means refers to the instance object being designated to have performed a write operation, the write operation in the execute data storage area associated with the data storage area allocation means.

Es sind hier zwar die beispielhaften Ausführungsformen der vorliegenden Erfindung unter Bezugnahme auf die begleitenden Zeichnungen beschrieben, es sollte sich jedoch verstehen, dass die vorliegende Erfindung nicht auf diese genauen Ausführungsformen beschränkt ist und der Fachmann an den Ausführungsformen vielfältige Änderungen und Modifikationen vornehmen kann, ohne vom Umfang und den Zielsetzungen der vorliegenden Erfindung abzuweichen. All diese Änderungen und Modifikationen sollen im Umfang der in den angehängten Ansprüchen festgelegten vorliegenden Erfindung enthalten sein.While the exemplary embodiments of the present invention have been described herein with reference to the accompanying drawings, it should be understood that the present invention is not limited to these precise embodiments and that those skilled in the embodiments can make various changes and modifications without departing from the scope of the invention To depart from the scope and objectives of the present invention. All such changes and modifications are intended to be included within the scope of the present invention as defined in the appended claims.

Darüber hinaus weiß der Fachmann gemäß der vorstehenden Beschreibung, dass die vorliegende Erfindung als Vorrichtungen, Verfahren oder Computerprogrammprodukte ausgebildet werden kann. Daher kann die vorliegende Erfindung insbesondere in folgenden Formen vorliegen, d. h. vollständig Hardware, vollständig Software (darunter Firmware, residente Software, Mikrocode usw.) oder eine Kombination aus Softwareteil und Hardwareteil, was hierin allgemein „Schaltung”, „Modul” oder System genannt wird. Darüber hinaus kann die vorliegende Erfindung in Form eines in jedem beliebigen gegenständlichen Ausführungsmedium ausgebildeten Computerprogrammproduktes vorliegen, in dem von Computern verwendbarer Programmcode enthalten ist.Moreover, those skilled in the art will appreciate that the present invention may be embodied as devices, methods, or computer program products. Therefore, the present invention may be particularly in the following forms, i. H. completely hardware, completely software (including firmware, resident software, microcode, etc.) or a combination of software part and hardware part, which is generally referred to herein as "circuit," "module," or system. Moreover, the present invention may be in the form of a computer program product embodied in any of the subject execution media in which computer-usable program code is included.

Jede beliebige Kombination aus einem oder mehreren computerlesbaren oder von Computern verwendbaren Medien kann verwendet werden. Bei dem computerlesbarem oder von Computern verwendbaren Medium kann es sich, ohne darauf beschränkt zu sein, um ein System, eine Vorrichtung, eine Einheit oder ein Ausbreitungsmedium elektronischer, magnetischer, optischer, elektromagnetischer oder Infrarot oder Halbleiter verwendender Art handeln. Zu spezifischeren Beispielen (nicht abschließende Liste) für das computerlesbare Medium gehört Folgendes: eine elektrische Verbindung mit einer oder mehreren Leitungen, eine transportable Computerdiskette, eine Festplatte, ein Speicher mit wahlfreiem Zugriff (random access memory (RAM)), ein Nur-Lese-Speicher (read-only memory (ROM)), ein elektrisch programmierbarer Nur-Lese-Speicher (electrically programmable read-only memory (EPROM oder Flash-Speicher), ein Lichtwellenleiter, ein transportabler Nur-Lese-Compact-Disk-Speicher (CD-ROM), eine optische Speichereinheit, ein Übertragungsmedium, welches das Internet oder ein Intranet unterstützt, oder eine magnetische Speichereinheit. Es ist zu beachten, dass es sich bei dem computerlesbaren oder durch Computer verwendbaren Medium auch um ein Papier mit darauf gedruckten Programmen oder andere geeignete Medien handeln kann, dies liegt daran, dass zum Beispiel das Programm auf eine elektrische Weise durch elektrisches Einscannen dieser Art von Papier oder anderer Medien erhalten und auf geeignete Weise kompiliert, interpretiert oder verarbeitet werden und erforderlichenfalls in einem Computerspeicher gespeichert werden kann. Im Kontext dieses Dokuments kann ein computerlesbares oder von Computern verwendbares Medium jedes Medium sein, welches Programme zur Verwendung durch oder in Verbindung mit einem System, einer Vorrichtung oder einer Einheit zur Anweisungsausführung beinhalten, speichern, liefern, senden oder übermitteln kann. Zu dem computerlesbaren Medium können Datensignale mit darin enthaltenem und in einem Basisband oder als Teil einer Trägerwelle verbreiteten computerlesbaren Programmcode zählen. Der computerlesbare Programmcode kann mittels jedweden geeigneten Mediums einschließlich, ohne darauf beschränkt zu sein, kabellose, kabelgebundene, optische Lichtwellenleiterkabel, HF etc. übertragen werden.Any combination of one or more computer-readable or computer-usable media may be used. The computer-readable or computer-usable medium may be, but is not limited to, a system, device, unit, or propagation medium of electronic, magnetic, optical, electromagnetic, or infrared or semiconductor-use type. More specific examples (non-exhaustive list) of the computer readable medium include: an electrical connection to a computer or multiple lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an electrically programmable read-only memory ( electrically programmable read-only memory (EPROM or flash memory), an optical fiber, a portable read-only compact disk (CD-ROM), an optical storage unit, a transmission medium supporting the Internet or an intranet, or It is to be noted that the computer-readable or computer-usable medium may also be a paper with programs printed thereon or other suitable media, this is because, for example, the program is electrically powered by electric power Scanning this type of paper or other media obtained and compiled, interpreted or processed in an appropriate manner and, if necessary, in ei a computer memory can be stored. In the context of this document, a computer-readable or computer-usable medium may be any medium that can contain, store, deliver, send, or transmit programs for use by or in connection with an instruction execution system, apparatus, or device. The computer readable medium may include data signals having computer readable program code contained therein and distributed in baseband or as part of a carrier wave. The computer readable program code may be transmitted by any suitable means including, but not limited to, wireless, wired, optical fiber cables, RF, etc.

Der Computerprogrammcode zum Ausführen von Operationen der vorliegenden Erfindung kann in jeder Kombination einer oder mehrerer Programmiersprachen geschrieben sein, darunter objektorientierte Programmiersprachen wie Java, Smalltalk, C++ oder ähnliche und herkömmliche prozedurale Programmiersprachen wie die Programmiersprache „C” oder ähnliche Programmiersprachen. Der Programmcode kann vollständig auf dem Computer des Benutzers, teilweise auf dem Computer des Benutzers, als eigenständiges Softwarepaket, teilweise auf dem Computer des Benutzers und teilweise auf einem entfernt angeordneten Computer oder vollständig auf einem entfernt angeordneten Computer oder Server ausgeführt werden. In letzterem Szenario kann der entfernt angeordnete Computer mit dem Computer des Benutzers über jede beliebige Art von Netzwerk, darunter ein lokales Netzwerk (local area network (LAN)) oder ein Weitverkehrsnetzwerk (wide area network (WAN)) verbunden sein, oder es kann eine Verbindung zu einem externen Computer (zum Beispiel mittels eines Internetdienstanbieters über das Internet) hergestellt werden.The computer program code for performing operations of the present invention may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, Smalltalk, C ++ or similar and conventional procedural programming languages such as the "C" programming language or similar programming languages. The program code may be executed entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on a remote computer or server. In the latter scenario, the remote computer may or 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) Connecting to an external computer (for example, via an Internet service provider via the Internet) are made.

Darüber hinaus kann jeder Block des Ablaufplans und/oder der Blockschaubilder sowie Kombinationen der Blöcke in dem Ablaufplan und/oder den Blockschaubildern der vorliegenden Erfindung durch Computerprogrammanweisungen realisiert werden. Diese Computerprogrammanweisungen können einem Prozessor eines universellen Computers, eines zweckbestimmten Computers oder einer anderen programmierbaren Datenverarbeitungsvorrichtung bereitgestellt werden, um eine Maschine so zu erzeugen, dass die Anweisungen, die über den Prozessor des Computers oder der anderen programmierbaren Datenverarbeitungsvorrichtung ausgeführt werden, ein Mittel zum Realisieren der im Block oder in den Blöcken des Ablaufplans und/oder Blockschaubilds angegebenen Funktionen/Handlungen erzeugen.Moreover, each block of the flowchart and / or block diagrams as well as combinations of blocks in the flowchart and / or block diagrams of the present invention may be implemented by computer program instructions. These computer program instructions may be provided to a general purpose computer processor, a dedicated computer, or other programmable data processing device to generate a machine such that the instructions that are executed via the processor of the computer or other programmable data processing device provide means for realizing the computer Create functions / actions specified in the block or blocks of the flowchart and / or block diagram.

Diese Computerprogrammanweisungen können auch in einem computerlesbaren Medium gespeichert sein, das einen Computer oder eine andere programmierbare Datenverarbeitungsvorrichtung anleiten kann, auf eine bestimmte Weise zu funktionieren, so dass die in dem computerlesbaren Medium gespeicherten Anweisungen einen hergestellten Artikel einschließlich eines Anweisungsmittels erzeugen, welches die im Block oder in den Blöcken in den Ablaufplänen und/oder Blockschaubildern angegebenen Funktionen/Handlungen ausführt.These computer program instructions may also be stored in a computer-readable medium that may direct a computer or other programmable computing device to function in a particular manner so that the instructions stored in the computer-readable medium produce a manufactured article including an instruction resource corresponding to that in block or performs functions / actions specified in the blocks in the flowcharts and / or block diagrams.

Die Computerprogrammanweisungen können auch auf einen Computer oder eine andere programmierbare Datenverarbeitungsvorrichtung geladen werden, um eine Reihe von auf dem Computer oder der anderen programmierbaren Vorrichtung auszuführenden Operationsschritten hervorzurufen, um einen auf dem Computer realisierten Prozess so zu erzeugen, dass die auf dem Computer oder der anderen programmierbaren Vorrichtung ausgeführten Anweisungen einen Prozess zum Realisieren der im Block oder in den Blöcken in den Ablaufplänen und/oder Blockschaubildern angegebenen Funktionen/Handlungen bereitstellen.The computer program instructions may also be loaded onto a computer or other programmable data processing device to cause a series of operations to be performed on the computer or other programmable device to generate a process implemented on the computer such as that on the computer or the other instructions provide a process for realizing the functions / actions specified in the block or in the blocks in the flowcharts and / or block diagrams.

Die Ablaufpläne und Blockschaubilder in den Figuren veranschaulichen die Architekturen, Funktionalität und die Arbeitsweisen möglicher Realisierungen von Systemen, Verfahren und Computerprogrammprodukten gemäß verschiedenen Ausführungsformen der vorliegenden Erfindung. In dieser Hinsicht kann jeder Block im Ablaufplan oder dem Blockschaubild für ein Modul, ein Segment oder einen Codeabschnitt stehen, der eine oder mehrere ausführbare Anweisungen zum Realisieren der spezifischen logischen Funktion(en) aufweist. Es soll zudem angemerkt werden, dass bei einigen alternativen Realisierungen die in den Blöcken angegebenen Funktionen in anderer Reihenfolge als der in den Figuren angegebenen auftreten können. Zum Beispiel können zwei aufeinander folgend abgebildete Blöcke tatsächlich im Wesentlichen gleichzeitig ausgeführt werden, oder die Blöcke können manchmal abhängig von der betreffenden Funktionalität in umgekehrter Reihenfolge ausgeführt werden. Es wird ebenfalls angemerkt, dass jeder Block der Blockschaubilder und/oder des Ablaufplans und Kombinationen von Blöcken in den Blockschaubildern und/oder der Abbildung von Ablaufplänen durch zweckbestimmte hardwaregestützte Systeme oder Kombinationen von zweckbestimmter Hardware und Computeranweisungen realisiert werden kann, welche die angegebenen Funktionen oder Handlungen durchführen.The flowcharts and block diagrams in the figures illustrate the architectures, functionality, and operations 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 flowchart or block diagram may represent a module, segment, or code section having one or more executable instructions for implementing the specific logical function (s). It should also be noted that in some alternative implementations, the functions specified in the blocks may occur in a different order than that indicated in the figures. For example, two consecutively mapped blocks actually be executed substantially concurrently, or the blocks may sometimes be executed in reverse order depending on the functionality involved. It is also noted that each block of the block diagrams and / or the schedule and combinations of blocks in the block diagrams and / or the mapping of schedules may be realized by dedicated hardware-based systems or combinations of dedicated hardware and computer instructions having the stated functions or acts carry out.

ZITATE ENTHALTEN IN DER BESCHREIBUNG QUOTES INCLUDE IN THE DESCRIPTION

Diese Liste der vom Anmelder aufgeführten Dokumente wurde automatisiert erzeugt und ist ausschließlich zur besseren Information des Lesers aufgenommen. Die Liste ist nicht Bestandteil der deutschen Patent- bzw. Gebrauchsmusteranmeldung. Das DPMA übernimmt keinerlei Haftung für etwaige Fehler oder Auslassungen.This list of the documents listed by the applicant has been generated automatically and is included solely for the better information of the reader. The list is not part of the German patent or utility model application. The DPMA assumes no liability for any errors or omissions.

Zitierte PatentliteraturCited patent literature

  • US 7426720 [0007] US 7426720 [0007]
  • US 4742450 [0008] US 4742450 [0008]
  • US 7536525 [0009] US 7536525 [0009]
  • US 7657888 [0010] US 7657888 [0010]
  • WO 2007/036072 [0011] WO 2007/036072 [0011]
  • US 2010/0223613 [0012] US 2010/0223613 [0012]
  • US 7421698 [0013] US 7421698 [0013]

Zitierte Nicht-PatentliteraturCited non-patent literature

  • „Cloneable JVM: A new approach to start isolated Java Applications Faster” von Kawachiya, Ogata, Silva, Hideaki, Nakatani [0014] "Cloneable JVM: A New Approach to Starting Java Applications Faster" by Kawachiya, Ogata, Silva, Hideaki, Nakatani [0014]

Claims (17)

Verfahren zum Ausführen einer Vielzahl von Instanzen einer Anwendung, wobei das Verfahren aufweist: Starten eines Ausführens einer Stamminstanz der Anwendung, wobei die Stamminstanz mindestens einen Thread beinhaltet; als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, Anhalten des Ausführens aller Threads der Stamminstanz; als Reaktion auf ein Starten eines Ausführens einer Instanz der Anwendung, Replizieren des Ausführungszustandes aller Threads der Stamminstanz als den Ausführungszustand aller Threads der Instanz; und Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung.A method of executing a plurality of instances of an application, the method comprising: Starting execution of a root instance of the application, wherein the root instance includes at least one thread; in response to a thread of the root instance, when executed, arriving at a predetermined freeze point in the application, stopping execution of all threads of the root instance; in response to starting execution of an instance of the application, replicating the execution state of all threads of the root instance as the execution state of all threads of the instance; and Continue with running all the threads of the instance of the application. Verfahren nach Anspruch 1, wobei der Ausführungszustand mindestens beinhaltet: den aktuellen Stapel, die Werte von Registern und die aktuelle Anweisung eines Thread.The method of claim 1, wherein the execution state includes at least: the current stack, the values of registers, and the current instruction of a thread. Verfahren nach Anspruch 2, wobei der aktuelle Stapel des Ausführungszustands eine Referenz zu einem Instanzobjekt in der Instanz enthält, wobei die Referenz zum Instanzobjekt so initialisiert ist, dass sie auf das Stamminstanzobjekt verweist.The method of claim 2, wherein the current state of execution of the execution state includes a reference to an instance object in the instance, wherein the reference to the instance object is initialized to refer to the root instance object. Verfahren nach Anspruch 3, wobei das Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung aufweist: Empfangen einer Schreiboperation auf ein Feld eines Instanzobjektes; als Reaktion darauf, dass eine Referenz zum Instanzobjekt auf ein Stamminstanzobjekt verweist: Zuordnen eines Datenspeicherbereichs für das Instanzobjekt; Verweisen der Referenz zum Instanzobjekt auf den Datenspeicherbereich; Ausführen der Schreiboperation in dem Datenspeicherbereich.The method of claim 3, wherein continuing to execute all threads of the instance of the application comprises: Receiving a write operation on a field of an instance object; in response to a reference to the instance object referring to a root instance object: Allocating a data storage area for the instance object; Pointing the reference to the instance object to the data storage area; Perform the write operation in the data storage area. Verfahren nach Anspruch 4, wobei das Verfahren weiterhin aufweist: als Reaktion darauf, dass die Referenz zu einem Instanzobjekt nicht auf ein Stamminstanzobjekt verweist, Ausführen der Schreiboperation in dem Datenspeicherbereich, auf den die Referenz zum Instanzobjekt verweist.The method of claim 4, wherein the method further comprises: in response to the reference to an instance object not pointing to a root instance object, performing the write operation in the data storage area referenced by the reference to the instance object. Verfahren nach Anspruch 3, wobei das Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung aufweist: Empfangen einer Schreiboperation auf ein Feld eines Instanzobjektes; als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat: Zuordnen eines Datenspeicherbereichs für das Feld des Instanzobjektes; Kennzeichnen des entsprechenden Feldes des Stamminstanzobjektes derart, dass es eine Schreiboperation ausgeführt hat; Ausführen der Schreiboperation in dem Datenspeicherbereich.The method of claim 3, wherein continuing to execute all threads of the instance of the application comprises: Receiving a write operation on a field of an instance object; in response to a corresponding field of a root instance object referenced by the reference to the instance object being flagged as not yet performing a write operation: Allocating a data storage area for the field of the instance object; Identifying the corresponding field of the root instance object to have performed a write operation; Perform the write operation in the data storage area. Verfahren nach Anspruch 6, das weiterhin aufweist: als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es eine Schreiboperation ausgeführt hat, Ausführen der Schreiboperation in dem Datenspeicherbereich, der für das Feld des Instanzobjektes zugeordnet ist, das dieser Schreiboperation zugehörig ist.The method of claim 6, further comprising: in response to a corresponding field of a root instance object referenced by the reference to the instance object being characterized as having performed a write operation, performing the write operation in the data storage area associated with the field of the instance object associated with that write operation is. Verfahren nach einem der vorhergehenden Ansprüche, das weiterhin aufweist: als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, Kennzeichnen eines Attributs eines Stamminstanzobjektes in der Stamminstanz als „nur lesen”.The method of claim 1, further comprising: in response to a thread of the root instance arriving in execution at a predetermined freeze point in the application, flagging an attribute of a root instance object in the root instance as read-only. System zum Ausführen einer Vielzahl von Instanzen einer Anwendung, wobei das System aufweist: ein Stamminstanz-Startmittel, das zum Starten eines Ausführens einer Stamminstanz der Anwendung eingerichtet ist, wobei die Stamminstanz mindestens einen Thread beinhaltet; ein Stamminstanz-Anhaltemittel, das eingerichtet ist, als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, das Ausführen aller Threads der Stamminstanz anzuhalten; ein Repliziermittel, das eingerichtet ist, als Reaktion auf das Starten des Ausführens einer Instanz der Anwendung den Ausführungszustand aller Threads der Stamminstanz als den Ausführungszustand aller Threads der Instanz zu replizieren; und ein Ausführungsfortfahrmittel, das zum Fortfahren mit dem Ausführen aller Threads der Instanz der Anwendung eingerichtet ist.A system for executing a plurality of instances of an application, the system comprising: a root instance launcher arranged to start executing a root instance of the application, the root instance including at least one thread; a root instance suspending means, arranged in response to a thread of the root instance, when executed, arriving at a predetermined freezing point in the application to halt the execution of all threads of the root instance; a replicating means arranged to replicate, in response to starting to execute an instance of the application, the execution state of all threads of the root instance as the execution state of all the threads of the instance; and execution execution means arranged to continue to execute all the threads of the instance of the application. System nach Anspruch 9, wobei der Ausführungszustand mindestens beinhaltet: den aktuellen Stapel, die Werte von Registern und die aktuelle Anweisung eines Thread.The system of claim 9, wherein the execution state includes at least: the current stack, the values of registers, and the current instruction of a thread. System nach Anspruch 10, wobei der aktuelle Stapel des Ausführungszustands eine Referenz zum Instanzobjekt in der Instanz enthält, wobei die Referenz zum Instanzobjekt so initialisiert ist, dass sie auf ein Stamminstanzobjekt verweist.The system of claim 10, wherein the current state of execution of the execution state includes a reference to the instance object in the instance, wherein the reference to the instance object is initialized to refer to a root instance object. System nach Anspruch 11, wobei das Ausführungsfortfahrmittel aufweist: ein Schreiboperations-Empfangsmittel, das zum Empfangen einer Schreiboperation auf ein Feld des Instanzobjektes eingerichtet ist; ein Datenspeicher-Zuordnungsmittel, das eingerichtet ist, als Reaktion darauf, dass eine Referenz zum Instanzobjekt auf das Stamminstanzobjekt verweist, einen Datenspeicherbereich für das Instanzobjekt zuzuordnen; ein Referenzmodifizierungsmittel, das eingerichtet ist, als Reaktion darauf, dass eine durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf das Stamminstanzobjekt verweist, die Referenz zum Instanzobjekt auf den durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich verweisen zu lassen; ein Schreiboperations-Ausführungsmittel, das eingerichtet ist, als Reaktion darauf, dass die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt auf das Stamminstanzobjekt verweist, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen. The system of claim 11, wherein the execution continuation means comprises: a write operation receiving means arranged to receive a write operation to a field of the instance object; data storage allocation means arranged to, in response to a reference to the instance object referencing the root instance object, allocate a data storage area for the instance object; a reference modifier configured to, in response to a reference to the instance object received by the write operation receiving means refering to the root instance object, refer the reference to the instance object to the data storage area associated with the data storage area allocation means; write operation executing means arranged in response to the reference to the instance object received by the write operation receiving means referring to the root instance object to execute the write operation in the data storage area allocated by the data storage area allocation means. System nach Anspruch 12, wobei das Schreiboperations-Ausführungsmittel weiterhin eingerichtet ist, als Reaktion darauf, dass die durch die Schreiboperations-Empfangseinheit empfangene Referenz zum Instanzobjekt nicht auf das Stamminstanzobjekt verweist, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.The system of claim 12, wherein the write operation executing means is further arranged, in response to the reference to the instance object received by the write operation receiving unit, not pointing to the root instance object to execute the write operation in the data storage area allocated by the data storage area allocation means. System nach Anspruch 11, wobei das Ausführungsfortfahrmittel aufweist: ein Schreiboperations-Empfangsmittel, das zum Empfangen einer Schreiboperation auf ein Feld des Instanzobjektes eingerichtet ist; ein Kennzeichnungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, das entsprechende Feld des Stamminstanzobjektes so zu kennzeichnen, dass es eine Schreiboperation ausgeführt hat; ein Datenspeicherbereichs-Zuordnungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, einen Datenspeicherbereich für das Feld des Instanzobjektes zuzuordnen; ein Schreiboperations-Ausführungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es noch keine Schreiboperation ausgeführt hat, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.The system of claim 11, wherein the execution continuation means comprises: a write operation receiving means arranged to receive a write operation on a field of the instance object; a flag set up in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as not yet executing a write operation; the corresponding field of the root instance object so to flag that it has performed a write operation; a data storage area allocation means arranged to designate, in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object, that it has not yet performed a write operation, a data storage area for Assign the field of the instance object; a write operation executing means arranged in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object being characterized as not yet executing a write operation, the write operation in the execute data storage area associated with the data storage area allocation means. System nach Anspruch 14, wobei das Schreiboperations-Ausführungsmittel weiterhin eingerichtet ist, als Reaktion darauf, dass ein entsprechendes Feld eines Stamminstanzobjektes, auf das die durch das Schreiboperations-Empfangsmittel empfangene Referenz zum Instanzobjekt verweist, so gekennzeichnet ist, dass es eine Schreiboperation ausgeführt hat, die Schreiboperation in dem durch das Datenspeicherbereichs-Zuordnungsmittel zugeordneten Datenspeicherbereich auszuführen.The system of claim 14, wherein the write operation executing means is further arranged in response to a corresponding field of a root instance object to which the reference received by the write operation receiving means refers to the instance object being designated to execute a write operation. execute the write operation in the data storage area allocated by the data storage area allocation means. System nach einem der Ansprüche 9 bis 15, wobei das System weiterhin aufweist: ein Stamminstanzobjekt-Kennzeichnungsmittel, das eingerichtet ist, als Reaktion darauf, dass ein Thread der Stamminstanz beim Ausführen zu einem zuvor festgelegten Einfrierpunkt in der Anwendung gelangt, ein Attribut des Stamminstanzobjektes in der Stamminstanz als „nur lesen” zu kennzeichnen.The system of any one of claims 9 to 15, wherein the system further comprises: a root instance object identifier arranged to flag an attribute of the root instance object in the root instance as "read only" in response to a thread of the root instance, when executed, arriving at a predetermined freeze point in the application; Computerprogramm, das Programmcodemittel aufweist, die geeignet sind, das Verfahren nach einem der Ansprüche 1 bis 8 durchzuführen, wenn das Programm auf einem Computer ausgeführt wird.A computer program comprising program code means adapted to perform the method of any one of claims 1 to 8 when the program is run on a computer.
DE112012000693.3T 2011-03-31 2012-03-06 Running multiple instances of an application Active DE112012000693B4 (en)

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN201110081183.0A CN102736945B (en) 2011-03-31 2011-03-31 A kind of method and system of the Multi-instance running application
CN201110081183.0 2011-03-31
CNCN-201110081183.0 2011-03-31
PCT/IB2012/051044 WO2012131507A1 (en) 2011-03-31 2012-03-06 Running a plurality of instances of an application

Publications (2)

Publication Number Publication Date
DE112012000693T5 true DE112012000693T5 (en) 2013-10-31
DE112012000693B4 DE112012000693B4 (en) 2024-04-25

Family

ID=46929070

Family Applications (1)

Application Number Title Priority Date Filing Date
DE112012000693.3T Active DE112012000693B4 (en) 2011-03-31 2012-03-06 Running multiple instances of an application

Country Status (5)

Country Link
US (1) US8904386B2 (en)
CN (1) CN102736945B (en)
DE (1) DE112012000693B4 (en)
GB (1) GB2502937B (en)
WO (1) WO2012131507A1 (en)

Families Citing this family (19)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9575740B2 (en) 2015-01-21 2017-02-21 Samsung Electronics Co., Ltd. Apparatus and method for running multiple instances of a same application in mobile devices
EP3048552A1 (en) * 2015-01-21 2016-07-27 Samsung Electronics Co., Ltd. Apparatus and method for running multiple instances of a same application in mobile devices
US9910697B2 (en) * 2015-10-13 2018-03-06 Palantir Technologies Inc. Fault-tolerant and highly-available configuration of distributed services
CN105718263B (en) * 2016-01-19 2018-11-13 合肥联宝信息技术有限公司 A kind of method and system for realizing distributed computer based on cloud
CN105589747B (en) * 2016-02-25 2018-10-23 深圳市创想天空科技股份有限公司 The control method and system that application program is opened more
US10444939B2 (en) * 2016-03-15 2019-10-15 Microsoft Technology Licensing, Llc Analysis of recurring processes
CN106201710B (en) * 2016-06-29 2020-08-04 宇龙计算机通信科技(深圳)有限公司 Method and device for freezing application
CN106407762A (en) * 2016-09-26 2017-02-15 东莞酷派软件技术有限公司 A setting method for application freezing configuration and a terminal apparatus
US10338135B2 (en) 2016-09-28 2019-07-02 Amazon Technologies, Inc. Extracting debug information from FPGAs in multi-tenant environments
US11099894B2 (en) * 2016-09-28 2021-08-24 Amazon Technologies, Inc. Intermediate host integrated circuit between virtual machine instance and customer programmable logic
US10162921B2 (en) 2016-09-29 2018-12-25 Amazon Technologies, Inc. Logic repository service
US10250572B2 (en) 2016-09-29 2019-04-02 Amazon Technologies, Inc. Logic repository service using encrypted configuration data
US10642492B2 (en) 2016-09-30 2020-05-05 Amazon Technologies, Inc. Controlling access to previously-stored logic in a reconfigurable logic device
CN107885748B (en) 2016-09-30 2021-10-26 华为技术有限公司 File hierarchical access method and device for virtualized instance
US10423438B2 (en) 2016-09-30 2019-09-24 Amazon Technologies, Inc. Virtual machines controlling separate subsets of programmable hardware
US11115293B2 (en) 2016-11-17 2021-09-07 Amazon Technologies, Inc. Networked programmable logic service provider
CN109597689B (en) * 2018-12-10 2022-06-10 浪潮(北京)电子信息产业有限公司 Distributed file system memory optimization method, device, equipment and medium
CN110262871B (en) * 2019-05-17 2024-01-23 平安科技(深圳)有限公司 Container instance start-stop method and device for container application, computer equipment and storage medium
US20220269244A1 (en) * 2021-02-23 2022-08-25 Changxin Memory Technologies, Inc. Control method, apparatus, system, device and medium for production equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4742450A (en) 1986-01-16 1988-05-03 International Business Machines Corporation Method to share copy on write segment for mapped files
WO2007036072A1 (en) 2005-09-29 2007-04-05 Intel Corporation Apparatus and method for expedited virtual machine (vm) launch in vm cluster environment
US7421698B2 (en) 2003-12-22 2008-09-02 Sun Microsystems, Inc. System and method for dynamically and persistently tracking incremental profiling data in a process cloning application environment
US7426720B1 (en) 2003-12-22 2008-09-16 Sun Microsystems, Inc. System and method for dynamic preloading of classes through memory space cloning of a master runtime system process
US7536525B2 (en) 2004-11-09 2009-05-19 Dell Products L.P. Virtual machine hot cloning including freezing and unfreezing memory in a distributed network
US7657888B2 (en) 2002-07-11 2010-02-02 Microsoft Corporation Method for forking or migrating a virtual machine
US20100223613A1 (en) 2009-02-27 2010-09-02 Schneider James P Per process virtual machines

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100247951B1 (en) * 1997-04-11 2000-03-15 윤종용 Program modification method of PDA
US20020046230A1 (en) * 1998-04-29 2002-04-18 Daniel J. Dieterich Method for scheduling thread execution on a limited number of operating system threads
US6567974B1 (en) * 2000-02-25 2003-05-20 Sun Microsystems, Inc. Small memory footprint system and method for separating applications within a single virtual machine
US7363474B2 (en) * 2001-12-31 2008-04-22 Intel Corporation Method and apparatus for suspending execution of a thread until a specified memory access occurs
US20030187911A1 (en) * 2002-04-01 2003-10-02 Michael Abd-El-Malek Method and apparatus to facilitate recovering a thread from a checkpoint
JP4639609B2 (en) 2004-03-09 2011-02-23 東洋製罐株式会社 Film-like lid with excellent piercing and opening properties
US7587721B2 (en) * 2004-05-20 2009-09-08 Sap Ag Sharing objects in runtime systems
GB0416259D0 (en) * 2004-07-21 2004-08-25 Ibm A method and system for enabling a server application to be executed in the same virtual machine as a client application using direct object oriented
JP2006146678A (en) * 2004-11-22 2006-06-08 Hitachi Ltd Method for controlling program in information processor, information processor and program
JP2007066265A (en) * 2005-09-02 2007-03-15 Hitachi Ltd Computer device and virtual machine providing method
US20110283277A1 (en) 2010-05-11 2011-11-17 International Business Machines Corporation Virtualization and dynamic resource allocation aware storage level reordering
US8443365B2 (en) * 2010-11-03 2013-05-14 Hewlett-Packard Development Company, L.P. Methods and systems to clone a virtual machine instance

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4742450A (en) 1986-01-16 1988-05-03 International Business Machines Corporation Method to share copy on write segment for mapped files
US7657888B2 (en) 2002-07-11 2010-02-02 Microsoft Corporation Method for forking or migrating a virtual machine
US7421698B2 (en) 2003-12-22 2008-09-02 Sun Microsystems, Inc. System and method for dynamically and persistently tracking incremental profiling data in a process cloning application environment
US7426720B1 (en) 2003-12-22 2008-09-16 Sun Microsystems, Inc. System and method for dynamic preloading of classes through memory space cloning of a master runtime system process
US7536525B2 (en) 2004-11-09 2009-05-19 Dell Products L.P. Virtual machine hot cloning including freezing and unfreezing memory in a distributed network
WO2007036072A1 (en) 2005-09-29 2007-04-05 Intel Corporation Apparatus and method for expedited virtual machine (vm) launch in vm cluster environment
US20100223613A1 (en) 2009-02-27 2010-09-02 Schneider James P Per process virtual machines

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"Cloneable JVM: A new approach to start isolated Java Applications Faster" von Kawachiya, Ogata, Silva, Hideaki, Nakatani

Also Published As

Publication number Publication date
GB201318013D0 (en) 2013-11-27
CN102736945A (en) 2012-10-17
US8904386B2 (en) 2014-12-02
CN102736945B (en) 2016-05-18
US20120254885A1 (en) 2012-10-04
WO2012131507A1 (en) 2012-10-04
GB2502937A (en) 2013-12-11
DE112012000693B4 (en) 2024-04-25
GB2502937B (en) 2014-03-26

Similar Documents

Publication Publication Date Title
DE112012000693B4 (en) Running multiple instances of an application
DE112016003120B4 (en) Redirect a copy on write
DE112011103829B4 (en) Method and system for creating a virtual machine based on templates
DE112013001421B4 (en) Policy-based management of storage capabilities in data replication environments
DE112020000558T5 (en) DYNAMIC CHANGING AN INSULATION OF A CONTAINERIZED WORKLOAD IN RESPONSE TO A DETERMINATION OF A RELEVANT FACTOR
DE112010003554B4 (en) Symmetrical direct migration of virtual machines
DE112012004099T5 (en) Transaction processing system, procedures and program
DE112010004784T5 (en) Efficient loading of data into the memory of a computer system
DE112011100094T5 (en) Method and system for abstracting a non-functional requirement based use of virtual machines
DE102016105589A1 (en) Apply firmware updates in a zero-downtime system by selectively turning off and on hardware using a hypervisor layer
DE112013001711T5 (en) Optimize subroutine calls based on the architectural level of a called subroutine
DE112018005898T5 (en) DYNAMIC PROVISION OF SOFTWARE FUNCTIONS
DE112018006769B4 (en) EXTENDED CACHE ALLOCATION BASED ON NODE VIRTUAL RESOURCES
DE112010004160T5 (en) Port virtual images between platforms
DE112013000369T5 (en) Managing threads within a computing environment
DE112013000656T5 (en) System and method for reducing memory usage by optimally placing virtual machines in a virtualized data center
DE112011101929T5 (en) Enable control of a hypervisor in a cloud computing environment
DE112012005209T5 (en) Bridge function between virtual machine monitor and bare-metal boot process
DE112020000912T5 (en) MANAGING SOFTWARE PROGRAMS
DE102016119298A1 (en) SCHEDULE COPYING WITH CLONING CHAINS
DE112015004564T5 (en) Event-driven reoptimization of a logically partitioned power management environment
DE102021125630A1 (en) DATA SYNCHRONIZATION IN A DATA ANALYSIS SYSTEM
DE112019001821T5 (en) METHOD AND DEVICE FOR REPLAYING AN ACTIVATION FRAMEWORK FOR UNINTERRUPTED MEMORY CLEANING (PAUSE-LESS GARBAGE COLLECTION)
DE112017005015T5 (en) Processing Subling Calls (SIBLING CALLS)
DE112016005868T5 (en) Start application processors of a virtual machine

Legal Events

Date Code Title Description
R012 Request for examination validly filed
R082 Change of representative

Representative=s name: RICHARDT PATENTANWAELTE GBR, DE

Representative=s name: RICHARDT PATENTANWAELTE PART GMBB, DE

Representative=s name: RICHARDT PATENTANWAELTE PARTG MBB, DE

R016 Response to examination communication
R018 Grant decision by examination section/examining division
R084 Declaration of willingness to licence