CN108733589A - The implementation method and device of distributed transaction heat deployment - Google Patents

The implementation method and device of distributed transaction heat deployment Download PDF

Info

Publication number
CN108733589A
CN108733589A CN201810326355.8A CN201810326355A CN108733589A CN 108733589 A CN108733589 A CN 108733589A CN 201810326355 A CN201810326355 A CN 201810326355A CN 108733589 A CN108733589 A CN 108733589A
Authority
CN
China
Prior art keywords
branch
transaction component
script
bean
transaction
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
CN201810326355.8A
Other languages
Chinese (zh)
Other versions
CN108733589B (en
Inventor
湛滨瑜
于君泽
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.)
Advanced New Technologies Co Ltd
Advantageous New Technologies Co Ltd
Original Assignee
Alibaba Group Holding Ltd
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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201810326355.8A priority Critical patent/CN108733589B/en
Publication of CN108733589A publication Critical patent/CN108733589A/en
Application granted granted Critical
Publication of CN108733589B publication Critical patent/CN108733589B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/10Program control for peripheral devices
    • G06F13/102Program control for peripheral devices where the programme performs an interfacing function, e.g. device driver
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/382Information transfer, e.g. on bus using universal interface adapter

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

This specification provides a kind of implementation method of distributed transaction heat deployment, applied to promoter, the promoter includes at least one branch's transaction component, each branch transaction component corresponds at least one participant of the distributed transaction, for calling the service interface of corresponding participant's publication, the method includes:Obtain some updated script of branch's transaction component;New branch's transaction component is generated according to updated script, replaces original branch's transaction component;Participant's service interface corresponding with branch's transaction component is called using replaced branch's transaction component.

Description

The implementation method and device of distributed transaction heat deployment
Technical field
This specification be related to network communication technology field more particularly to a kind of implementation method of distributed transaction heat deployment and Device.
Background technology
Affairs refer to the sequence of operations (branch's affairs) or completely execute that single logical unit of work executes, and It does not execute all.Issued transaction may insure that all branch's affairs in transaction context all succeed, and otherwise will not update Data.The flow of Fault recovery can be simplified by affairs, and the operation of program can be made more reliable and more stable.
When the promoter, participant, Service Manager of affairs are located on different system nodes, which is distribution Formula affairs.One distributed transaction is initiated by promoter, and each branch's affairs of affairs are executed respectively by participant, transaction management It all submits or all stops or person is responsible for all branch's affairs.
Participant usually issues provided branch's Transaction Service in a manner of service interface, and (i.e. the participant is carried out Business operation), for needing the promoter for carrying out this branch affairs to call.In many application scenarios, need often to change ginseng The service interface provided with person is changed with the business for adapting to continue generation, the how flexible quickly adaptation services interface of promoter Variation becomes the challenge that distributed transaction is realized.
Invention content
In view of this, this specification provides a kind of implementation method of distributed transaction heat deployment, it is applied to promoter, it is described Promoter includes at least one branch's transaction component, and each branch's transaction component corresponds at least one of the distributed transaction Participant, for calling the service interface of corresponding participant's publication, the method includes:
Obtain some updated script of branch's transaction component;
New branch's transaction component is generated according to updated script, replaces original branch's transaction component;
Participant's service corresponding with branch's transaction component is called to connect using replaced branch's transaction component Mouthful.
This specification additionally provides a kind of realization device of distributed transaction heat deployment, is applied to promoter, the initiation Person includes at least one branch's transaction component, and each branch's transaction component corresponds at least one participation of the distributed transaction Person, for calling the service interface of corresponding participant's publication, described device to include:
More new script acquiring unit, for obtaining some updated script of branch's transaction component;
Component replacement unit is replaced original for generating new branch's transaction component according to updated script Branch's transaction component;
Component call unit, for being called and branch's transaction component pair using replaced branch's transaction component The participant's service interface answered.
A kind of computer equipment that this specification provides, including:Memory and processor;Being stored on the memory can The computer program run by processor;When the processor runs the computer program, above application is executed in promoter Distributed transaction heat deployment implementation method described in step.
A kind of computer readable storage medium that this specification provides, is stored thereon with computer program, the computer When program is run by processor, step of the above application described in the implementation method of the distributed transaction heat deployment of promoter is executed Suddenly.
By above technical scheme as it can be seen that in the embodiment of this specification, called by branch's transaction component on promoter The service interface of corresponding participant, after the script update of some branch's transaction component, to be generated according to script after update New branch's transaction component replaces original branch's transaction component, so as to update branch in the operational process of promoter Transaction component can be adapted to new when the modification of the service interface of participant by the corresponding branch's transaction component script of modification Service interface reduces development amount without changing the code of promoter while accelerating adaptation speed.
Description of the drawings
Fig. 1 is a kind of stream of the implementation method of distributed transaction heat deployment applied to promoter in this specification embodiment Cheng Tu;
Fig. 2 is a kind of operational process schematic diagram of promoter in this specification application example;
Fig. 3 is a kind of hardware structure diagram for the equipment for running this specification embodiment;
Fig. 4 is that the realization device of distributed transaction heat deployment applied to promoter a kind of is patrolled in this specification embodiment Collect structure chart.
Specific implementation mode
The embodiment of this specification proposes a kind of implementation method of new distributed transaction heat deployment, by promoter to participating in The calling of person's service interface is realized by branch's transaction component, by updating branch's transaction set in the operational process of promoter The script of part replaces original branch's transaction component with new branch's transaction component, realizes the online liter of branch's transaction component Grade is upgraded point in this way when the service interface of participant change using the branch's transaction component script for matching new demand servicing interface Branch transaction component, you can the adaptability update for completing promoter accelerates the speed of matching business demand variation, reduces exploitation The work of personnel.
In the embodiment of this specification, using TCC, (Try/Confirm/Cancel, trial/confirmation/take distributed transaction Disappear) pattern.In TCC patterns, each participant realize a stage Try method of a certain branch's affairs, two-stage Confirm and Two-stage Cancel method is issued in the form of service interface, is called for promoter and Service Manager.
Promoter registers to Service Manager after opening a distributed transaction and realizes each of distributed transaction point The participant of branch affairs, and the service interface that each participant is respectively adopted calls the stage of the participant to service;It is each Participant executes a stage Try method of promoter branch affairs, and a stage whether successful implementing result is returned to initiation Person;If the stage implementing result of each participant is success, promoter notifies Service Manager to submit the distribution thing Business, Service Manager call the two-stage Confirm method of distributed transaction participant;Otherwise promoter notifies transaction management Person's rollback distributed transaction, Service Manager call the two-stage Cancel method of distributed transaction participant.
The embodiment of this specification is applied to the promoter in distributed transaction TCC patterns.In this specification embodiment Promoter may operate in any equipment with calculating and storage capacity, such as mobile phone, tablet computer, PC (Personal Computer, PC), notebook, the equipment such as server;It can also be by operating in the logics of two or more equipment Node realizes the various functions of promoter in this specification embodiment.
In the embodiment of this specification, the flow of the implementation method of the upper distributed transaction heat deployment of promoter is as shown in Figure 1.
Step 110, some updated script of branch's transaction component is obtained.
In the embodiment of this specification, on promoter to the calling of the service interface of participant's publication using component come real Existing, component is that by the software unit of certain function, and the concrete form of component can be according to the software of practical application scene The factors such as system environments, programming language determine, do not limit.Such as component can be class, object, software package etc..
On promoter, by calling participant's service interface to be known as branch's transaction set to carry out the component of distributed transaction Part.Promoter includes one and arrives multiple branch's transaction components, and each branch's transaction component corresponds to one and arrives multiple participants, real Now to the calling of corresponding participant's service interface.Branch's transaction component needs the service interface for being matched with corresponding participant, The stage service that the energy normal use participant provides.
Promoter is when starting operation, using the script load branch transaction set of included each branch's transaction component Part.In the process of running, after the script of branch's transaction component updates, promoter obtains updated component script.
The concrete mode of branch's transaction component script can be according to the specific of practical application scene after promoter's acquisition update It realizes to determine, does not limit.For example, the script of each branch's transaction component in promoter can be preserved to predetermined storage position It sets, whether has script update by promoter's timing inquiry, if there is then reading newer branch's transaction component script.
In one implementation, each branch's transaction component script of promoter can be registered to DRM On (Distributed Resource Manager, distributed resource management) server, promoter subscribes to this to DRM server A little branches transaction component script, when any one in these branch's transaction component scripts updates, promoter can connect Receive the updated script of branch's transaction component of DRM server push.DRM server can by branch transaction component mark, And script is pushed to promoter after the update of branch's transaction component with the mark.
Step 120, new branch's transaction component is generated according to updated script, replaces original branch's transaction set Part.
Promoter can generate new branch's transaction component based on mechanism is provided in the prior art and replace original Branch's transaction component, can also voluntarily realize, not limit.
For example, in whether promoter's timing inquiry has the newer application scenarios of script, promoter can read some point After the updated script of branch transaction component, compiles updated script and obtain updated branch's transaction component, it will be updated In branch's transaction component dynamic loading to the running environment of promoter, replace original same branch's transaction component, completes to divide The upgrading of branch transaction component.
For another example, the promoter realized to being based on Java Spring (a kind of Java Development Frameworks of open source code), each Branch's transaction component can be a Java Bean (a kind of Reusable Module of Java language).Spring applies journey in operation It can monitor and detect the change to dynamic language script when sequence, and by the Bean automatic reloadings being modified to application program In context.Specifically, after Spring containers detect that some Bean script updates, after compiling updated script The new Bean generated, new Bean is assembled in the context of promoter, to replace the original identified with identical Bean There is Bean.
In one example, it can be promoter or be that each branch's transaction component setting script refreshes and comes into force the period, Script refreshing comes into force the period then, (script refreshing is arranged for promoter to come into force if there is update occurs for branch's transaction component script In the case of period) or this branch transaction component script update occurs and (script is set for each branch's transaction component refreshes and come into force In the case of period), the new branch's transaction component generated after updated script is compiled, new branch's transaction set is loaded Part is to replace original branch's transaction component.
It can be based on Groovy (a kind of development language based on Java Virtual Machine) and the combination of Spring was last to realize Example.Branch's transaction component script is written as Groovy Bean scripts with Groovy language, and is branch's transaction component Groovy Bean's<lang:groovy>Element adds refresh-check-delay attributes, by refresh-check- The script refreshing that the attribute value of delay is set as branch's transaction component comes into force the period.Rewrite the ScriptSource of Spring Interface enables revised ScriptSource interfaces to obtain the script of the Groovy Bean write with Groovy language;Change The ScriptFactoryPostProcessor interfaces (interface for carrying out script replacement) for writing Spring, make revised ScriptFactoryPostProcessor interfaces can support Groovy Bean (to use Groovy Bean to carry out script to replace It changes).
The period is come into force when the script of refresh-check-delay attributes setting refreshes then, if Spring containers are examined The script for measuring some Groovy Bean updates, then Spring containers are connect using the ScriptSource of support Groovy Mouthful, obtain script after the update of the changed Groovy Bean marks of script and the Groovy Bean with the mark; Using the ScriptFactoryPostProcessor interfaces for supporting Groovy Bean, with updated script have and be somebody's turn to do The load and initialization of the Groovy Bean of mark.
Step 130, the clothes of participant corresponding with branch's transaction component are called using replaced branch's transaction component Business interface.
After completing branch's transaction component and replacing, during follow-up operation, promoter is calling and branch's transaction set When the service interface of the corresponding participant of part, it will be carried out by updated branch's transaction component.
After application the present embodiment, by the update of branch's transaction component, it can both be connect in the service of corresponding participant Mouth is adapted to new service interface when changing, and can also change the call parameters to corresponding participant's service interface, thus Change the executive mode of branch's affairs in distributed transaction in promoter's operational process.
For example, when the service interface increase provided on participant, reducing or changing the ginseng transmitted by the service interface When number, the branch's transaction component script for being matched with new demand servicing interface can be supplied to promoter, correspond to the participant in this way Branch's transaction component after completing script and replacing, when calling the service interface of the participant, by increase, reduction or change logical The parameter of service interface transmission is crossed, realizes the heat deployment of branch's transaction component.
For another example, it is assumed that the parameter that the service interface of some participant transmits includes being used to specify the specific business mistake of branch's affairs The different values of the business operation code of journey, business operation code correspond to the different business procession of branch's affairs.It is updating Corresponding to the participant branch's transaction component script when, business operation code can be changed to another by a value and taken Value, in this way after completing branch's transaction component and replacing, replaced branch's transaction component can use and original branch's transaction component Different business operation code value, to call the service interface of the participant, to change the business processing mistake of branch's affairs Journey.
As it can be seen that in the embodiment of this specification, promoter is passed through into branch's transaction set to the calling of participant's service interface Part is realized, after the script update of some branch's transaction component, is replaced with the branch's transaction component generated by script after update Original branch's transaction component realizes the online upgrading of branch's transaction component, when the modification of the service interface of participant, uses It matches branch's transaction component script of new demand servicing interface and interface adaptation can be completed to upgrade corresponding branch's transaction component, be not necessarily to The code for changing promoter, reduces development amount while accelerating adaptation speed.
It is above-mentioned that this specification specific embodiment is described.Other embodiments are in the scope of the appended claims It is interior.In some cases, the action recorded in detail in the claims or step can be come according to different from the sequence in embodiment It executes and desired result still may be implemented.In addition, the process described in the accompanying drawings not necessarily require show it is specific suitable Sequence or consecutive order could realize desired result.In some embodiments, multitasking and parallel processing be also can With or it may be advantageous.
In an application example of this specification, a distributed system carries out distributed transaction using TCC patterns. The distributed system includes promoter, Service Manager and several participants.On promoter, each participant's service is connect Mouthful calling realized with branch transaction component Groovy Bean.
The promoter based on Java Spring frames realize, by rewrite Spring ScriptSource interfaces and ScriptFactoryPostProcessor interfaces enable revised ScriptSource interfaces to read with Groovy language The component script write enables ScriptFactoryPostProcessor interfaces after rewriting to being write with Groovy language Component script carries out script replacement, even if revised ScriptSource interfaces and ScriptFactoryPostProcessor Interface supports the script of Groovy Bean to obtain and replace.For each branch's transaction component Groovy Bean's<lang: groovy>Element adds refresh-check-delay attributes, and the attribute value of refresh-check-delay is set as 5 points Clock (the script refreshing of branch's transaction component comes into force the period).
The script of each branch transaction component Groovy Bean is registered to DRM server, and promoter is to DRM server Subscribe to each branch's transaction component Groovy Bean scripts.
A kind of operational process of promoter is as shown in Figure 2.
Step 205, promoter opens the local matter of the distributed transaction, is the execution distribution thing in local cache Each participant of business creates proxy class.After proxy class creates successfully, a stage action blocker is added for each proxy class, One stage action blocker is used for the stage service execution result that the corresponding participant of Receiving Agent class returns.
Step 210, each proxy class of promoter is respectively that the participant respectively acted on behalf of carries out second order to task manager Section service registration.Service Manager receives registration, records all participants of the distributed transaction.
Promoter is called and is corresponded to by the branch transaction component Groovy Bean being assemblied in its application context Each participant service interface, so that participant is executed stage service, and by one of the proxy class corresponding to the participant Stage action blocker receives a stage service execution result of participant return.If all ginsengs of a distributed transaction The stage implementing result returned with person is all success, and promoter submits the local matter of the distributed transaction, Service Manager After learning that promoter submits local matter, the two-stage of all participants of the distributed transaction is called to submit service;If there is The stage implementing result that participant returns is failure, the local matter of promoter's rollback distributed transaction, Service Manager After learning promoter's rollback local matter, the two-stage rollback service of all participants of the distributed transaction is called.Above-mentioned mistake Journey is that the flow of distributed transaction is executed on promoter, is not shown in fig. 2.
While promoter executes distributed transaction, step 215, when some branch transaction component Groovy Bean's Script refreshing comes into force the period then, and Spring containers detect the foot of the transaction component branch of branch transaction component Groovy Bean This update status.
After promoter subscribes to the script of branch transaction component Groovy Bean to DRM server, when subscribed branch thing When the script of business component Groovy Bean has update, DRM server can by the mark for having newer Groovy Bean and more Groovy Bean after new are pushed to the promoter.
Step 220, judge whether the script of branch transaction component Groovy Bean has update.Each branch can be enabled The script of transaction component Groovy Bean carries its version number, can also be according to some branch's transaction component Groovy Bean foot This last receiving time does not limit to judge whether script has update.If there is update, step 225 is executed, is otherwise turned Step 215.
Step 225, it is changed to obtain script using the ScriptSource interfaces for supporting Groovy for Spring containers Script after the update of Groovy Bean marks and the Groovy Bean with the mark.
Step 230, Spring containers are connect using the ScriptFactoryPostProcessor of support Groovy Bean Mouthful, the load and initialization of the Groovy Bean with the mark are carried out with updated script, are replaced original with the mark The Groovy Bean of knowledge.
The updated Groovy Bean of script are being loaded into the context of promoter and are completing Groovy Bean's After initialization, promoter is the service interface for starting to call corresponding participant using replaced Groovy Bean, to carry out Distributed transaction.
Corresponding with the realization of above-mentioned flow, the embodiment of this specification additionally provides a kind of distributed thing applied to promoter The realization device for heat deployment of being engaged in.The device can also pass through hardware or the side of software and hardware combining by software realization Formula is realized.For implemented in software, as the device on logical meaning, CPU (the Central Process of equipment where being Unit, central processing unit) corresponding computer program instructions are read in memory what operation was formed.For hardware view, Other than CPU shown in Fig. 3, memory and memory, it is applied to the realization device of the distributed transaction heat deployment of promoter The equipment at place also typically includes other hardware such as the chip for carrying out wireless signal transmitting-receiving, and/or logical for realizing network Other hardware such as board of telecommunication function.
Fig. 4 show a kind of realization device of distributed transaction heat deployment of this specification embodiment offer, is applied to hair Person is played, the promoter includes at least one branch's transaction component, and each branch's transaction component corresponds to the distributed transaction At least one participant, include the acquisition of more new script for calling the service interface of corresponding participant publication, described device Unit, component replacement unit and component call unit, wherein:More new script acquiring unit is for obtaining some branch's transaction component Updated script;Component replacement unit is used to generate new branch's transaction component according to updated script, replaces former The branch's transaction component having;Component call unit is used to call and described point using replaced branch's transaction component The corresponding participant's service interface of branch transaction component.
Optionally, the more new script acquiring unit is specifically used for:Receive the push of distributed resource management DRM server The updated script of branch's transaction component.
Optionally, branch's transaction component is Java Bean;The component replacement unit is specifically used for:In Spring After container detects that some Bean script updates, the new Bean generated after updated script is compiled, it will be new The Bean is assembled in the context of promoter, replaces original Bean with identical Bean marks.
In one example, the component replacement unit is specifically used for:The period is come into force in script refreshing then, if branch's thing Business component script updates, and compiles the branch's transaction component newly generated after updated script, loads new described Branch's transaction component is to replace original branch's transaction component.
In above-mentioned example, the Bean is Groovy Bean;The Groovy Bean's<lang:groovy>Element Refresh-check-delay attribute values are that script refreshing comes into force the period;The component replacement unit compiles updated script The new branch's transaction component generated afterwards, loads new branch's transaction component to replace original branch's affairs Component, including:By Spring containers using the ScriptFactoryPostProcessor components for supporting Groovy Bean, obtain Script after the update of script changed Groovy Bean marks and the Groovy Bean with the mark is taken, with more Script after new carries out the load and initialization of the Groovy Bean with the mark.
Optionally, replaced branch's transaction component increases, subtracts when calling the service interface of the participant Less or change the parameter transmitted by the service interface.
The embodiment of this specification provides a kind of computer equipment, which includes memory and processor. Wherein, the computer program that can be run by processor is stored on memory;Computer program of the processor in operation storage When, execute each step for the implementation method for being applied to the distributed transaction heat deployment of promoter in this specification embodiment.It is right The detailed description of each step of the implementation method of distributed transaction heat deployment applied to promoter refer to before content, It is not repeated.
The embodiment of this specification provides a kind of computer readable storage medium, and computer is stored on the storage medium Program, these computer programs execute the distribution for being applied to promoter in this specification embodiment when being run by processor Each step of the implementation method of affairs heat deployment.To each of the implementation method of the distributed transaction heat deployment applied to promoter The detailed description of a step refer to before content, be not repeated.
The foregoing is merely the preferred embodiments of this specification, all the application's not to limit the application Within spirit and principle, any modification, equivalent substitution, improvement and etc. done should be included within the scope of the application protection.
In a typical configuration, computing device includes one or more processors (CPU), input/output interface, net Network interface and memory.
Memory may include computer-readable medium in volatile memory, random access memory (RAM) and/or The forms such as Nonvolatile memory, such as read-only memory (ROM) or flash memory (flash RAM).Memory is computer-readable medium Example.
Computer-readable medium includes permanent and non-permanent, removable and non-removable media can be by any method Or technology realizes information storage.Information can be computer-readable instruction, data structure, the module of program or other data. The example of the storage medium of computer includes, but are not limited to phase transition internal memory (PRAM), static RAM (SRAM), moves State random access memory (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electric erasable Programmable read only memory (EEPROM), fast flash memory bank or other memory techniques, read-only disc read only memory (CD-ROM) (CD-ROM), Digital versatile disc (DVD) or other optical storages, magnetic tape cassette, tape magnetic disk storage or other magnetic storage apparatus Or any other non-transmission medium, it can be used for storage and can be accessed by a computing device information.As defined in this article, it calculates Machine readable medium does not include temporary computer readable media (transitory media), such as data-signal and carrier wave of modulation.
It should also be noted that, the terms "include", "comprise" or its any other variant are intended to nonexcludability Including so that process, method, commodity or equipment including a series of elements include not only those elements, but also wrap Include other elements that are not explicitly listed, or further include for this process, method, commodity or equipment intrinsic want Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that wanted including described There is also other identical elements in the process of element, method, commodity or equipment.
It will be understood by those skilled in the art that the embodiment of this specification can be provided as method, system or computer program production Product.Therefore, the embodiment of this specification can be used complete hardware embodiment, complete software embodiment or combine software and hardware side The form of the embodiment in face.Moreover, it wherein includes that computer is available that the embodiment of this specification, which can be used in one or more, It is real in the computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) of program code The form for the computer program product applied.

Claims (14)

1. a kind of implementation method of distributed transaction heat deployment is applied to promoter, the promoter includes at least one branch Transaction component, each branch's transaction component corresponds at least one participant of the distributed transaction, corresponding for calling The service interface of participant's publication, the method includes:
Obtain some updated script of branch's transaction component;
New branch's transaction component is generated according to updated script, replaces original branch's transaction component;
Participant's service interface corresponding with branch's transaction component is called using replaced branch's transaction component.
2. according to the method described in claim 1, described some updated script of branch's transaction component of acquisition, including:It receives The updated script of branch's transaction component of distributed resource management DRM server push.
3. according to the method described in claim 1, branch's transaction component is Java Bean;
It is described that new branch's transaction component is generated according to updated script, original branch's transaction component is replaced, Including:After Spring containers detect that some Bean script updates, the new institute generated after updated script is compiled Bean is stated, the new Bean is assembled in the context of promoter, replaces original Bean with identical Bean marks.
4. according to the method described in claim 1, described generate new branch's transaction component according to updated script, replace Original branch's transaction component is changed, including:The period is come into force in script refreshing then, if branch's transaction component script occurs Update compiles the new branch's transaction component generated after updated script, load new branch's transaction component with Replace original branch's transaction component.
5. according to the method described in claim 4, the Bean is Groovy Bean;The Groovy Bean's<lang: groovy>The refresh-check-delay attribute values of element are that script refreshing comes into force the period;
The new branch's transaction component generated after the updated script of compiling, loads new branch's transaction component To replace original branch's transaction component, including:It is connect using the ScriptSource of support Groovy by Spring containers Mouthful, obtain the changed Groovy Bean marks of script and the update rear foot of the Groovy Bean with the mark This;Using the ScriptFactoryPostProcessor interfaces for supporting Groovy Bean, had with updated script The load and initialization of the Groovy Bean of the mark.
6. according to the method described in claim 1, replaced branch's transaction component is in the service for calling the participant When interface, increase, reduce or change the parameter transmitted by the service interface.
7. a kind of realization device of distributed transaction heat deployment is applied to promoter, the promoter includes at least one branch Transaction component, each branch's transaction component corresponds at least one participant of the distributed transaction, corresponding for calling The service interface of participant's publication, described device include:
More new script acquiring unit, for obtaining some updated script of branch's transaction component;
Component replacement unit is replaced original described for generating new branch's transaction component according to updated script Branch's transaction component;
Component call unit, it is corresponding with branch's transaction component for being called using replaced branch's transaction component Participant's service interface.
8. device according to claim 7, the more new script acquiring unit is specifically used for:Receive distributed resource management The updated script of branch's transaction component of DRM server push.
9. device according to claim 7, branch's transaction component is Java Bean;
The component replacement unit is specifically used for:After Spring containers detect that some Bean script updates, compiling is more The new Bean generated after script after new, the new Bean is assembled in the context of promoter, replacement has Original Bean of identical Bean marks.
10. device according to claim 7, the component replacement unit is specifically used for:It is arrived in script refreshing period of coming into force When, if branch's transaction component script updates, the new branch's transaction component generated after updated script is compiled, The new branch's transaction component of load is to replace original branch's transaction component.
11. device according to claim 10, the Bean is Groovy Bean;The Groovy Bean's<lang: groovy>The refresh-check-delay attribute values of element are that script refreshing comes into force the period;
The component replacement unit compiles the new branch's transaction component generated after updated script, loads new described Branch's transaction component to replace original branch's transaction component, including:By Spring containers using support Groovy's ScriptSource interfaces obtain the changed Groovy Bean marks of script and the Groovy with the mark Script after the update of Bean;Using the ScriptFactoryPostProcessor interfaces for supporting Groovy Bean, after update Script carry out the load and initialization of the Groovy Bean with the mark.
12. device according to claim 7, replaced branch's transaction component is in the service for calling the participant When interface, increase, reduce or change the parameter transmitted by the service interface.
13. a kind of computer equipment, including:Memory and processor;Being stored on the memory can be run by processor Computer program;When the processor runs the computer program, the step as described in claim 1 to 6 any one is executed Suddenly.
14. a kind of computer readable storage medium, is stored thereon with computer program, the computer program is run by processor When, execute the step as described in claim 1 to 6 any one.
CN201810326355.8A 2018-04-12 2018-04-12 Method and device for realizing distributed transaction hot deployment Active CN108733589B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810326355.8A CN108733589B (en) 2018-04-12 2018-04-12 Method and device for realizing distributed transaction hot deployment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810326355.8A CN108733589B (en) 2018-04-12 2018-04-12 Method and device for realizing distributed transaction hot deployment

Publications (2)

Publication Number Publication Date
CN108733589A true CN108733589A (en) 2018-11-02
CN108733589B CN108733589B (en) 2021-11-02

Family

ID=63941380

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810326355.8A Active CN108733589B (en) 2018-04-12 2018-04-12 Method and device for realizing distributed transaction hot deployment

Country Status (1)

Country Link
CN (1) CN108733589B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109634655A (en) * 2018-12-10 2019-04-16 江苏满运软件科技有限公司 Variable configuration method based on heat deployment, device, electronic equipment, storage medium
CN110321181A (en) * 2019-06-28 2019-10-11 阿里巴巴集团控股有限公司 Event production method and its device under SOA system
CN111984294A (en) * 2020-08-20 2020-11-24 中国银行股份有限公司 Service system updating method and device based on Groovy dynamic loading technology
CN112765126A (en) * 2020-12-31 2021-05-07 金蝶软件(中国)有限公司 Database transaction management method and device, computer equipment and storage medium
CN112995304A (en) * 2021-02-08 2021-06-18 中国工商银行股份有限公司 Method and device for processing routing service node by two-stage distributed transaction

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1677361A (en) * 2004-03-31 2005-10-05 华为技术有限公司 Distributed test assembly frame system and test assembly transparent transmission method
CN103617037A (en) * 2013-11-27 2014-03-05 张洁 Developing method for web development system and web development system
CN104866341A (en) * 2015-05-07 2015-08-26 北京金山安全软件有限公司 Component upgrading method and device and terminal
CN105740019A (en) * 2016-01-29 2016-07-06 公安部交通管理科学研究所 Automatic upgrading and releasing system and method for application software in distributed network environment
CN105843638A (en) * 2016-03-18 2016-08-10 浪潮软件集团有限公司 Upgrading and reconstruction method for Spring old version framework
CN106227554A (en) * 2016-07-08 2016-12-14 百度在线网络技术(北京)有限公司 A kind of method and apparatus carrying out applying heat renewal in ios system
US20170249141A1 (en) * 2016-02-26 2017-08-31 Red Hat, Inc. Hot deployment in a distributed cluster system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1677361A (en) * 2004-03-31 2005-10-05 华为技术有限公司 Distributed test assembly frame system and test assembly transparent transmission method
CN103617037A (en) * 2013-11-27 2014-03-05 张洁 Developing method for web development system and web development system
CN104866341A (en) * 2015-05-07 2015-08-26 北京金山安全软件有限公司 Component upgrading method and device and terminal
CN105740019A (en) * 2016-01-29 2016-07-06 公安部交通管理科学研究所 Automatic upgrading and releasing system and method for application software in distributed network environment
US20170249141A1 (en) * 2016-02-26 2017-08-31 Red Hat, Inc. Hot deployment in a distributed cluster system
CN105843638A (en) * 2016-03-18 2016-08-10 浪潮软件集团有限公司 Upgrading and reconstruction method for Spring old version framework
CN106227554A (en) * 2016-07-08 2016-12-14 百度在线网络技术(北京)有限公司 A kind of method and apparatus carrying out applying heat renewal in ios system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
程序园: "《http://www.voidcn.com/article/p-prewphki-wz.html》", 17 January 2013 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109634655A (en) * 2018-12-10 2019-04-16 江苏满运软件科技有限公司 Variable configuration method based on heat deployment, device, electronic equipment, storage medium
CN110321181A (en) * 2019-06-28 2019-10-11 阿里巴巴集团控股有限公司 Event production method and its device under SOA system
CN111984294A (en) * 2020-08-20 2020-11-24 中国银行股份有限公司 Service system updating method and device based on Groovy dynamic loading technology
CN111984294B (en) * 2020-08-20 2024-04-16 中国银行股份有限公司 Service system updating method and device based on Groovy dynamic loading technology
CN112765126A (en) * 2020-12-31 2021-05-07 金蝶软件(中国)有限公司 Database transaction management method and device, computer equipment and storage medium
CN112995304A (en) * 2021-02-08 2021-06-18 中国工商银行股份有限公司 Method and device for processing routing service node by two-stage distributed transaction
CN112995304B (en) * 2021-02-08 2022-09-23 中国工商银行股份有限公司 Method and device for processing routing service node by two-stage distributed transaction

Also Published As

Publication number Publication date
CN108733589B (en) 2021-11-02

Similar Documents

Publication Publication Date Title
CN108733589A (en) The implementation method and device of distributed transaction heat deployment
CN108958796B (en) Service request processing method and device and service request processing system
Seifzadeh et al. A survey of dynamic software updating
CN108418851B (en) Policy issuing system, method, device and equipment
CN109117169A (en) Method and apparatus for repairing kernel loophole
CN106796522A (en) System and method for updating source code file
US9971672B2 (en) Using emulation to disassociate verification from stimulus in functional test
CN111399853A (en) Templated deployment method of machine learning model and custom operator
US7613953B2 (en) Method of converting a regression test script of an automated testing tool into a function
US11630650B2 (en) Systems and methods for creating enterprise software
CN108427551A (en) MVC assembly type program development frames create system and method
CN109739526A (en) Code update method and device
US10990507B2 (en) System and method for provisioning a virtual machine test environment
CN115309398A (en) Multi-application micro front end implementation method based on software development framework derivation
CN111159040A (en) Test data generation method, device, equipment and storage medium
Bauer et al. Reusing system states by active learning algorithms
US10146664B2 (en) Virtual test environment for webpages with automation features
CN110018831B (en) Program processing method, program processing apparatus, and computer-readable storage medium
CN111722597B (en) Method and system for preparing engineering data for an industrial control system
CN114358936A (en) Intelligent contract operation method based on micro-service block chain
CN105393216B (en) Run-time memory is adjusted
CN113867776A (en) Method and device for publishing middle station application, electronic equipment and storage medium
US8887125B1 (en) Systems and methods for dynamic artefact substitution
CN112114857B (en) Front-end service management method, front-end server and website server
CN109388401A (en) A kind of delivery of services method and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20201022

Address after: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant after: Innovative advanced technology Co.,Ltd.

Address before: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant before: Advanced innovation technology Co.,Ltd.

Effective date of registration: 20201022

Address after: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant after: Advanced innovation technology Co.,Ltd.

Address before: A four-storey 847 mailbox in Grand Cayman Capital Building, British Cayman Islands

Applicant before: Alibaba Group Holding Ltd.

GR01 Patent grant
GR01 Patent grant