CN101460921A - Next generation clustering - Google Patents

Next generation clustering Download PDF

Info

Publication number
CN101460921A
CN101460921A CN200780017766.9A CN200780017766A CN101460921A CN 101460921 A CN101460921 A CN 101460921A CN 200780017766 A CN200780017766 A CN 200780017766A CN 101460921 A CN101460921 A CN 101460921A
Authority
CN
China
Prior art keywords
application server
computer implemented
lease
trooping
master control
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
CN200780017766.9A
Other languages
Chinese (zh)
Other versions
CN101460921B (en
Inventor
那瑞什·瑞万努鲁
普里西拉·C·方
万凯特森·兰加那森
亚伦·菲斯克
迪安·伯纳德·雅各布斯
普拉赛德·佩达达
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.)
Oracle International Corp
Original Assignee
BEA Systems Inc
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
Priority claimed from US11/425,784 external-priority patent/US7536581B2/en
Priority claimed from US11/548,239 external-priority patent/US7661015B2/en
Priority claimed from US11/550,551 external-priority patent/US8122108B2/en
Application filed by BEA Systems Inc filed Critical BEA Systems Inc
Priority to CN201310125906.1A priority Critical patent/CN103327066B/en
Publication of CN101460921A publication Critical patent/CN101460921A/en
Application granted granted Critical
Publication of CN101460921B publication Critical patent/CN101460921B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/62Establishing a time schedule for servicing the requests

Abstract

One embodiment of the present invention comprises determining a cluster leader and using the cluster leader to set up a lease table at an application server of a cluster of application servers. The lease table can be used to maintain at least one lease for a singleton service.

Description

Next generation clustering
Copyright statement
The part of patent document openly comprises material protected by copyright.As patent file or patent disclosure appeared in the patent document of patent and trademark office or the record, the copyright owner did not refuse anyone system of opening up to it, yet is but keeping all copyright rights whatsoever of sample whatsoever aspect other.
Priority request
U.S. Provisional Patent Application number 60/747,364, title is " Next GenerationClustering ", submits [attorney docket BEAS-01937US0] on May 16th, 2006 by people such as Naresh Revanuru.
Application No. 11/425,784, title are " Automatic MigratableServices ", submit [attorney docket BEAS-02030US0] on June 22nd, 2006 by Aaron Fiske.
Application No. 11/548,239, title are " Job Scheduler ", submit [attorney docket BEAS-02031US0] on October 10th, 2006 by people such as NareshRevanuru.
Application No. 11/550,551, title are " Database-Less Leasing ", submit [attorney docket BEAS-02029US0] on October 18th, 2006 by people such as Naresh Revanuru.
Background technology
A large amount of mutual in order to handle, enterprise software is used can use application server, for example as from San Jose, and the BEA Systems of California, the available WebLogic Server of Inc. TMSuch J2EE application server.These application servers can be used on can be mutual mutually troop.
Some service of application server is called single example service, should only operate on the application server of trooping.These single routine services can comprise JMS server, transaction recovery service or any other software that should only move with single instance.
Description of drawings
Fig. 1 shows the leasing system based on database.
Fig. 2 shows the leasing system in the no datat storehouse of one embodiment of the present of invention.
Fig. 3 A and 3B show the leasing system in the no datat storehouse of one embodiment of the present of invention.
Fig. 4 A shows the automatic transportable service system of one embodiment of the present of invention to 4C.
Fig. 5 A and 5B show the job scheduler system.
Embodiment
The lease in no datat storehouse
Fig. 1 shows the example of the leasing system of using database 102.In this example, troop 110 application server 104,106 and 108 can rely on database that visit to lease table 102 is provided.Lease at lease table 102 place can be used for indicating any application server should move single example service.These leases can be upgraded by the application server of this list example service of operation.The collapse situation under, lease will no longer be updated and will become invalid.This can make one of 110 the application server of trooping can take over once at the collapse of control leasing system or the application server of isolation.
In some cases, the needs to high availability (HA) database that is used to lease are avoided in expectation.Embodiments of the invention comprise the leasing system in no datat storehouse.
One embodiment of the present of invention are 202 the computer implemented methods of trooping that comprise application server 204,206,208 and 210.Method can comprise determines to troop leader 202, uses the leader 212 that troops to locate to set up lease table 214 at one of application server, and uses lease table 214 to keep at least one lease 216 that is used for single routine service 218.
Because the lease table is stored in the application server place, so do not need database.In one embodiment, each the application server place in trooping keeps the copy of lease table, makes that the copy of lease table is available under the situation of collapse or isolation.
The lease table can be used for allowing the Autonomic Migration Framework of single example service.The state of application server during node manager can be used for determining to troop.Node manager can be the software program that moves on application server host.Node manager can be used for beginning and stopping the example of application server.
The application server of early start becomes the leader that troops in can selecting to troop.In one embodiment, select the leader that troops by a kind of competition.Each server in trooping can periodically attempt becoming the leader that troops.For example, each server in trooping can be attempted becoming trooping the leader once every 30 seconds.The leader exists if troop, and their trial is rejected.If currently do not have a leader that troops, then first trial server of becoming it becomes the leader that troops, and any one becomes the leader that troops thereby stop other.In this mode, the application server of early start becomes the leader that troops in can selecting to troop.As the candidate, system can be designed to make and can select to troop the leader by other method.
The leader 212 that troops can tie up other application server that live (heartbeat) troops.Troop leader 212 can be in 202 other application server of trooping the copy of storage lease table, under the one or more application servers collapses or the situation of isolating, to operate.In one embodiment, if current Cluster Server 212 fails to tie up other application server of living, then other application server can be selected another leader that troops.
What one embodiment of the present of invention comprised application server 204,206,208 and 210 troops 202.Select to troop the leader based on the application server that at first starts.The leader 212 that troops is used for setting up lease table 214 at application server 204 places.
One embodiment of the present of invention comprise computer implemented system, wherein keep lease table 214 at 202 application server 204 places of trooping of application server.Other application server of trooping can use lease table 214 to keep to be used at least one lease 216 of single example service 218.
Fig. 3 A shows the leader that troops and provides data for other application server of trooping.It is selected that Fig. 3 B shows under the situation of the application server collapse that becomes the current leader of trooping another leader that troops.Fig. 3 C shows in Network Isolation and makes under the disabled situation of the application server of winning another leader that troops selected.
Automatic transportable service
One embodiment of the present of invention are computer implemented systems, and it comprises first application server 402 of the single example service 406 of operation in 404 of trooping.First application server 102 is kept the lease 408 that is used for single example service 406 at lease table 410 place.Will single example service 406 if migration master control 412 checks that the lease tables 410 and first application server 402 fail to keep lease 408 redistribute to trooping 404 second application server 414.Lease table 410 can be kept in database, perhaps keeps by the lease of using aforesaid no datat storehouse.
Because the collapse of first application server 402, first application server can fail to renew the lease, and as shown in Fig. 4 B, perhaps because first application server 402 is isolated from the lease table, first application server 402 can fail to renew the lease, as shown in Fig. 4 C.First application server 402 can be tieed up lease 408 alive to keep the control to single example service 406.Single routine service can be JMS server, timer master control or should be with any other software of single instance operation.
Before obtaining single example service, second application server 414 can move predetermined startup script.After abandoning single example service, first application server 402 can move predetermined inactive script.Migration master control 412 can select next application server to move single example service, for example by selecting next application server.
In one embodiment, if singly the example service is Java message transfer service (JMS) service then can has special rule.If single example service is the JMS service, can attempt restarting on first application server in migration manager before any migration.
An embodiment is computer implemented method or computer-readable medium, and this medium comprises code is used for the lease 408 of single example service with table 410 place that renews the lease step.At first application server, 402 places, check lease table 410 with migration master control 412.In addition, if first application server is not kept lease 408, single example service 406 is redistributed to second application server.
Job scheduler
One embodiment of the present of invention are in the timer master control 502 at 506 application server 504 places of trooping.Timer master control 502 is given other application server 508,510 and 512 of trooping with the job assignment of being dispatched.Application server 504 is kept the lease that is used for the timer master control 514 from lease table 516.The job information 520 of institute's schedule job is stored in timer master control 502 in database.Under the situation of application server 504 collapse, can distribute to 506 the Another Application server 510 of trooping and to use job information to distribute the timer master control 502 of institute's schedule job.
Institute's schedule job can comprise report, for example database report.This report can need lot of data storehouse visit and thereby take a large amount of system resource.Institute's schedule job can thereby be scheduling in the non-peak hours operation so that do not reduce the performance of other application.The lease table can perhaps can use the leasing system in no datat storehouse as the candidate in database.Timer master control 502 can be single example service.Timer master control 502 can be distributed to application server 510 by the migration master control.Other application server can be from timer master control 502 request jobs.
One embodiment of the present of invention are computer implemented systems, and it is included in the timer master control 502 at application server 504 places of trooping.Timer master control 502 can be assigned to institute's schedule job 506 other application server 508,510 and 512 of trooping.Under the situation of application server 504 collapse, can distribute the timer master control that can distribute institute's schedule job to 506 the Another Application server 510 of trooping.
One embodiment of the present of invention are 506 the application servers 504 of trooping, and it distributes to 504 other application server of trooping with institute's schedule job.Under the situation of application server 504 collapses, distribute timer master control 502 to Another Application server 510.Use timer master control 502 at Another Application server 510 places distribute institute schedule job thereafter.
Embodiment
The details of an example embodiment is described below.These details provided how to realize a desired example of the present invention and do not mean that limit the scope of the invention or dwindle require in any one scope.
But troop feature operating lease and the lease management of the advanced person as automatic serving device and services migrating, cluster-wide list example and lock manager.During lease can guarantee to troop only member in certain time period that can postpone, obtain the entitlement of lease.Know that it has the exclusive entitlement of lease, the lease owner can carry out some privileged operation then, as the server of migration failure.How this instructions can realize the lease and the monarch-type function of trooping if having been described, and need not to depend on the so outside arbitrator of image height availability databases.
Can use the lease manager to obtain lease by subsystem, but be registered in the interest that the lease time spent obtains lease, find out the current owner of lease etc.A class lease basis that is used for the automatic serving device migration needs the existence of high availability (HA) database.In other words, the lease table always is hosted by in the database and database should be highly available for trooping, to inquire about and to renew the lease.
The lease table can live with in one of server in trooping and not in database.This means that making cluster member can elect the server that will hold place lease table and become the leader that troops.The leader that troops that this is elected can be responsible for distributing lease, renews the lease to show and atomically renewal is copied to troop.It is important duplicating for the fault purposes.The leader becomes unavailable and does not send heartbeat to group and claims its existence if troop, and then the member can begin another ballot of taking turns and elects the new master control of trooping.The master control of new election can obtain the entitlement of lease table.Except obtaining entitlement and appearance place lease table, the master control of trooping also can be carried out the automatic serving device migration of fault cluster node.
In one embodiment, can satisfy following requirement based on the lease of desirable (consensus):
1. at any given time point place the master control of trooping will be arranged at the most.This means never to have the more than one master control of trooping, but may in of short duration period, troop the master control of not trooping.
2. just after the startup of trooping, when not trooping master control, will there be of short duration period.The exponent number that may be minute period.
3. when the current master control of trooping is die, the election of the master control of newly trooping time that can spend equal the following and:
1. heartbeat timeout (next polling hours).This is that making cluster member does not receive time period from any heartbeat of the master control of trooping betwixt.Giving tacit consent to this period is 30 seconds.
2. algorithm is to reach the desirable time that spends.
4. but user's mark wherein can produce the subclass of trooping of the master control of trooping.Because the existence that redundant network connects etc., this subclass is suitable for participating in desirable better.But this means,, troop so the master control of not trooping if all members in the desirable tabulation die.The desirable tabulation of strong suggestion belongs to the machine of separation.
Can serve as the making cluster member of trooping master control and participating in desirable algorithm and can come mark with the special-purpose ConsensusProcessIdentifier among the config.xml.This identifier can be unique round values.This can be the attribute about ServerMBean.Server and product that the client should mark can serve as the master control of trooping should generate identifier automatically.Can have another attribute about ClusterMBean, it specifies desirable participant's total number.In one embodiment, this attribute is called ConsensusParticipants.It can be the total that has the server of CunsensusProcessIdentifier in trooping.
Whom reaches will be that troop leader's agreement can be time-consuming process.In case elected the leader that troops, can by troop the leader directly arbitration and needn't take turns desirable for the request of lease through one.To renew the lease table and renewal copied to all other members in the desirable tabulation of the leader that troops.This can be different from the database lease.In database lease, comprise that all leases of the leader's that is used for trooping lease can be kept on an equal basis at database.With the basis of desirable lease, the leader's lease of trooping can be used for granting apace other lease.
It is possible selecting the lease basis of acquiescence.Desirable lease basis can be the setting of acquiescence.Consumer's availability database lease basis covers acquiescence, if they want like this.Value may command acquiescence such as ClusterMBean.setMigrationBasis ().
Control desk can allow which cluster node of customer selecting to serve as to troop master control and generate desirable procedure identifier automatically.It also can be based on the number value of setting ClusterMBean.setConsensusParticipants () of the server of selecting in trooping.
Desirable lease basis as the realization of all other LeasingBasis interface, can hide subsystem and external user.Subsystem can be by realizing the weblogic.cluster.singleton.SingletonService interface and registering single example service of asking to the SingletonService manager then.Lock manager also can be implemented on the lease.
When transportable service was unavailable owing to any reason (bugs in the service code, server failing, Network Isolation) becomes, it can be deactivated and enable on new server in its current location.If there is fault when enabling on new server, it can be stopped using on this server and migration once more.Acquiescently, we can attempt on each candidate server in trooping beginning and have begun or on each till the failure up to it.If it is failed on each candidate server, but its misregistration and allow it stop using.
The activity of service can be confirmed by keeping of lease.Survival has the server of service can be responsible for keeping the lease survival via heartbeat mechanism on it.Server failing can cause leasing overtime naturally.In one embodiment, only there is a lease in each transportable target.All services on this target can be shared this lease.In one embodiment, can think that on the target all serve some and interdepend.(perhaps at least, the user should tolerate that the service of a failure on the target causes whole target migration).In one embodiment, management server need be not movable for Autonomic Migration Framework.
Migration master control (MM) can be followed the tracks of and should keep all services of surviving.Information can obtain from configuration.This is useful, because if service is unleased, it will be in not being present in the table that will monitor so.All services during leap is trooped, configuration can be identical.
Server can be in independent (MSI) pattern of manager service and still participate in Autonomic Migration Framework.Unique restriction is to begin new service.In one embodiment, if they are deployed to individual server, do not have the management server dispense configurations to change, service will can be by Autonomic Migration Framework.When management server begins and during everyone configuration synchronously, the service that can be any new interpolation enable migration (even and management server shut down subsequently, move sustainable).
If lease is lost (for example, Web publishing can cause lease to lose), server its service of can stopping using.MM can begin service in other somewhere.If still notice that at MM lease recovers before overtime after network is connected and stops using, this can cause redundant inactive calling, and is idempotent but stop using.
Yet if serve is unsound disconnection as yet, and it will and tell it to surrender of lease to transportable target reception and registration.MM will note lease disappear/overtime, and will move it.
Following method can be added MigratableTarget to:
/**
* when the Migratable class detects fault and need stop and beginning on different server, called by them.The unrecoverable failure that should only be used for transportable object.If shutdownServer is true (as it will be for JTA), therefore server will shut down and serve and stop using so.*/public void failedService(String serviceName,Boolean shutdownServer)
The processing of fence can be different from the situation of JTA.Take a long time if stop using, then can't guarantee before next server is attempted enabling service, to stop using it.In this case, if the time ratio lease period of graceful shutdown cost is longer, server can withdraw from immediately and suddenly.Its service can be by taking over for the new family of selecting of transportable service and recovering.
The migration master control can begin migration when noticing the expiration lease.It can be provided with the sign that note has begun to move for specific service.This can prevent to notice again that in the centre of migration before expiration is leased and migration once more.(same mechanism is used in the server migration.)
The current location itself of can stopping using of service (available) if it is still.Reposition can call enabling on the target then.This can be with original transportable service in identical code path.Yet, can introduce other step.
When target just was activated, its first action can be the requirement lease.This can make the migration master control stop to check frequently its activity.It also can provide the atom lock about operation; Hold when lease when this target, do not have other one can enable.
Next, service can check whether be that it has specified the node master control (MM) of naming to move script in advance.Then, it can check the existence of node manager on the current machine.If not at that, still there is the script of appointment in node manager, it can stop migration.If node manager is at that, it can check see node manager whether executed the pre-migration script of appointment.If node manager is the off-duty script still, it can tell the pre-migration of node manager operation script.Extra sign can be delivered to this script, does some different thing to allow when we positive transfer JTA, JMS or diverse some thing script.For example, can provide the placeholder script, but not need to finish specific tlog migration.
In one embodiment, respond for certain before it has moved pre-migration script, enable and can not continue at node manager.The trial that we can carry out repetition moves pre-migration script.If not success for some reason, migration will stop, and we will allow the migration master control that we are moved to new server.
At this moment, we call the activate () method of transportable service successively.If they all move not unusual, migration is finished now.
If there is mistake between time suitable to moulding, we can stop and entering shutdown mode.
Stopping using is the reverse side of enabling in essence.At first, inactive server can specified order call stopping using in all services.With recording exceptional, but do not take action.
Stop using in case all services have been called, we will carry out another node master control inspection.Service will check whether be to move script after it has specified the node master control of naming.Then, it can check the existence of node pipe master control on the current machine.If node manager is at that, check see node manager whether executed the back migration script of appointment.If node manager is the off-duty script still, tell node manager operation back migration script.Additional markers can be delivered to this script, does some different thing to allow when we positive transfer JTA, JMS or diverse some thing script.For example in one embodiment, we can provide the placeholder script, but can't finish specific tlog migration.
If the failure of back migration script is killed script with operation, if available words.If kill the script failure, enable and to continue as usual.In the worst case, when dealing with problems, we can stop using throughout and allow the manager reenable it.At last, when the Script section when being complete, service will surrender of lease.Script will be moved during manual migration, if specify.
In one embodiment, there is not automatic Restoration Mechanism.Acquiescently, service can be lived at its reposition forever.The keeper can be at any time with they before the same manner of being done come manual (under the situation of recovery automatically, being old perhaps) server that target is moved to newly.
If services migrating is to each server and never successfully enable, it can be deactivated.The optional may command that is provided with about MigratableTargetMBean will be carried out the how many times trial according to the complete number of cycles of trooping.Notice that existing transportable target limit still can be used: if the designate candidate server, with the server of only attempting in the candidate server tabulation.
AdditionalMigrationAttempts can be defaulted as zero.We will attempt crossing over the number of times of each server migration service in (perhaps candidate server tabulation is if specify) of trooping its may command.For example, if troop 3 members are arranged, and AdditionalMigrationAttempts is set to 2, we can attempt beginning it on each server in trooping, suspend then, reattempt, and suspend, and attempt last.In this example, this means that each server can have 3 chances successfully to enable service.
Time-out between migration is attempted can be controlled by the value such as MillisToSleepBetweenAttempts.In one embodiment, so this only controls the time-out that takes place when service is failed to enable us on any server and returned at first and attempt once more.When normally moving, do not need to exist to postpone.
<Migratable Target
Cluster=”mycluster”
ConstrainedCandidateServers=”server1,server2”
Name=”MIG-TAR-1”
UserPreferredServer=”server1”
AdditionalMigrationAttempts=”2”
MillisToSleepBetweenAttempts=”12000”
AutoMigratable=”true”
/>
Following method can be added MigratableTargetMBean to:
/*
* transportable service can fail to enable on the server of each possible configuration.This property control is failed after at least one time on each server in service, also should attempt how many times.Notice that each trial of appointment here is illustrated in all another complete flow processs that are configured the migration between the server.So for 3 servers troop and value is 2 situation, will attempt 4 other migrations altogether.(original server never is effective aim ground) */
get/setAdditionalMigrationAttempts()
/**
* be controlled between the migration trial of describing among the getAdditionalMigrationAttempts () time-out how long should be arranged.Notice that this delay only takes place when service all fails to enable on each server.It can not cause the delay of any kind between other migration trials.*/
get/setMillisToSleepBetweenAttempts()
JMS should restart itself, and (for the problem of discussing, for the performance purpose, moving completely will be to lose time and needn't stand actual migration.For their purpose, add method to migration manager, this method will ask the service of specified services is restarted, perhaps stopping using and reactivating on same server; Do not have resource to be released or obtain.Request ' soft migration '.The transportable service of appointment will be stopped using and be reactivated on identical server then.The node manager script will not be called.Rely on this transportable service and also will restart restartMigratable (Migratable m).After satisfying certain threshold value, the repetition on a server, restart trial fast and will be interpreted as mistake, and target will be moved.Because this is only to be designed for the inner method of using, do not need to provide the exterior arrangement of threshold value.Hiding get/set method may command on the ServerMBean can be carried out the how many times trial and how long the period is.(for example, it can be set in 12 hour period to allow restart for maximum 3 times.) get/setAllowedRestartedAttempts () is controlled in the interval of appointment among the getIntervalForRestartAttemptThrottling () service and can restarts how many times.GetIntervalForRestartAttemptThrottling () control is used for throttling with interval how long and restarts trial.Referring to getAllowedRestartAttempts (), get/setIntervalForRestartAttemptThrottling ().
The migration master control can be the service that is similar to the master control of trooping.It can be the single example of light weight, and is stateless, and keeps by the lease competition in the mode identical with the master control of trooping.Each server can be registered obtaining the permanent interest of migration master control lease.No matter server is current is held what, and it can be carried out the beginning of migration task and stop.If current migration master control collapse or shutdown will be selected one of waiting for server to take over lease by lease infrastructure, thereby become new migration master control.The migration master control needn't be arranged side by side with the master control of trooping and be put.
The migration master control can be the storage vault of migration information.It can keep the record (destination name, source server, destination server, timestamp) of its completed all migration.If management server can be used, it can show for control desk/JMX/WLST to management server report migration.
When migration takes place, can add non-debugging level record to provide information to the user.Can write down enabling and stopping using of target on the server.Current migration master control can be write down the details of migration: source, purpose, destination name, time.It also can write down each migration be by or the failure.The migration of failure can be recorded as warning, but not mistake.If service can not successfully begin on any server, we are with misregistration.
Can there be new interface, SingletonService.MigratableTarget can be revised as expansion SingletonService.MigratableTarget can survive some current service on MigratableTarget required pre-/after enable script mode other function is provided.Notice that some serves attainable Migratable interface is not SingletonService.Migratable only means that class can be at MigratableTarget.In fact be MigratableTarget itself by code operation.Target can begin/stop the Migratable class according to circumstances, as they always.
The SingletonService interface can be realized by client or the internal user of seeking light weight cluster-wide list example.It does not have and the as many feature of MigratableTarget (it will support script, candidate's machine etc.), but is easier to configuration and establishment.
SingletonService can ask to move immediately by itself being called stop using.MM will note the lease that disappears and will arrive reposition to services migrating.
Interface SingletonService
/*
* this is called when server begins and during the stage of enabling of migration.It should obtain any system resource and start SingletonService to begin the required any service of services request.
*/
public void activate()
/*
* this is called when server shuts down and during the disable phase of migration.It should be released in when enabling any resource that obtains, and stop should only can any service that the supplier obtains from troop.
*/
public void deactivate()
MigratableTargetMBean can have additionally, optional attribute.PreScript, PostScript and AutoMigratable.
<MigratableTarget
Cluster=”mycluster”
ConstrainedCandidateServers=”server1,server2”
Name=”MIG-TAR-1”
UserPreferredServer=”server1”
PreScript=”../scriptdir/runMeBeforeActivation”
PostScript=”../scriptdir/runMeAfterDeactivation”
KillScript=”../anotherscriptdir/runMeInCaseOfFailure”
AutoMigratable=”true”
/>
Following method can be added MigratableTargetMBean to
/**
*, automatic transportable value is set.If transportable target is transportable automatically, then it will be by Autonomic Migration Framework when its current server shutdown that survives in or fault.
*/
Get/setAutoMigratable()
/**
* be arranged on the actual script of operation before that is activated of transportable target.Before enabling target, if having the script of appointment and available node manager, we are with Run Script.In that being set under the situation that does not have available node manager, script will cause mistake in when migration.If script is failed or can not be found, migration will can not proceeded on current server, and will be attempted on next suitable server.(next server in the candidate server tabulation is not if having candidate list then be next server in trooping.)
*/
get/setPreScriptFileName()
/**
* be arranged on the script that moves after the transportable target of stopping using fully.After the target of stopping using, if having the script of appointment and available node manager, we are with Run Script.In that being set under the situation that does not have available node manager, script will cause mistake in when migration.If script is failed or can not be found, migration will still be proceeded.
*/
get/setPostScriptFileName()
/**
* be arranged on the script that moves under the situation of back script failure of transportable target.Do not have to be provided with under the situation of available node manager script and will cause mistake when migration.If script is failed or can not be found, migration will be proceeded.
*/
Get/setKillScriptFileName()
The transportable page object of control desk can need extra check box to allow to make it possible to carry out Autonomic Migration Framework.Do not need pre-script and back script, if but they exist and will be performed.The control desk page that is used for transportable target can have these options that can be provided with.
Under situation about exist relying on, can specify the order that they enable at a plurality of transportable service of a transportable target.Automatic transportable target does not need to be relevant to each other to sort.Whether service order will be transportable automatically relevant for target still.
Ordering does not need to be exposed to the consumer.Transportable target infrastructure only is inner usually.
Can allow transportable service to specify in deployment order among their MBean.Behavior modeling on the deployment order.Can there be the value that is called ' Order ' of accepting integer.(comprise negative value.) when request target was enabled its Component service, it can the order from minimum Order to maximum Order so be done.If do not specify Order, but the specify default value.For consistance, this can be to dispose the same acquiescence that uses in order: 100.If two services have identical Order number, do not guarantee that their order of enabling is relevant to each other.
When request target was stopped using its Component service, it can the order from maximum Order to minimum Order so be done.Notice that if two services have identical Order number, the inactive order that does not guarantee them is that they enable the opposite of order.
Order can be a dynamic value.The currency of Order is always used.This means, if Order enable and stop using between change, sequence may not be each other accurately opposite.
The situation that failure is enabled can be followed and normally enable and stop using identical rule.The service of successfully enabling stop using can be opposite occur in sequence, unless Order number is the same.In this case, inactive order can not be enable order opposite.
The Weblogic.cluster.migration.Migratable interface can have the method for following interpolation:
/**
* return the sequence valve that is used for this specific transportable object.This controls this object and is relevant to other transportable object of being deployed on the transportable target and will will enable in proper order and stop using with which.
*/
public int getOrder()
Available other setOrder method expands realization and MBeans, to allow user's configuration of this value.Yet this is optional.It depends on that each single implementor judges whether they want order configurable.
The ordinal variable of acquiescence can be in base interface: provide among the DEFAULT_ORDER.Acquiescently, all current realization classes will be called from getOrder () it will be returned.This can guarantee that current behavior will can not change, till people have carried out ordering that specific effort changes them.
Job scheduler can make timer know to troop and the ability of carrying out them in trooping Anywhere is provided.Timer no longer relies on the server of creating them.
The purpose of this instructions is:
1. making timer know troops.Timer should be carried out in trooping and fault transfer (failover) on demand Anywhere.
2. be provided at the demons homework type of the execution in the application server cluster.The user should specify picture " this operation of the local execution of some in trooping repeatedly.If there is the member of at least one operation in trooping, operation should move." the same thing.Server to the actual creation timer does not rely on.It is to cross over the load of the balance of trooping and can fault transfer to another operation member under the situation of fault that timer is carried out.
Existence is based on two different class timers of their life cycle.
Local timer
Local timer can be dispatched in server JAVA virtual machine (JVM) and survival forever in identical JVM.As long as the JVM survival, the timer operation, and timer is die when JVM withdraws from.Application need reschedules timer when startup of server subsequently.
The timer of cluster-wide
The timer of cluster-wide know the part that forms same cluster other server JVM and can load balance and fault shift.The timer life cycle is not tied to the server of creating it but is tied to the life cycle of trooping.As long as at least one making cluster member survival, timer can be carried out.This timer can survive complete trooping and restart.The timer of cluster-wide is created and is handled by job scheduler.
Every type of merits and demerits with it.Local timer can millisecond exponent number cycle of handling graininess.Job scheduler can not be with the cycle that needs as timer to be handled graininess by the precision that continues.The timer of cluster-wide is worked finely with several seconds or bigger exponent number with the interval of coarseness.Job scheduler can be used for schedule job, as every day or when finishing weekly operational report.Even it is important creating the no longer available also running job of its server.Other making cluster member can guarantee that operation continues to carry out.
Job scheduler can satisfy following requirement:
1. use the database of client's configuration to continue timer and make they for whole troop available.Job scheduler be depend on database and can have it and work.Support Oracle, DB2, Informix, MySQL, Sybase, MSSQL.
2. in one embodiment, job scheduler will be only in the middle work of trooping.
3. the operation of being submitted to can operation Anywhere in trooping.Two continuous execution of operation can move on the same server or on the different server.Only a server can be carried out operation at any given time point.
4. job scheduler depends on lease.Need lease support to elect the timer master control.But each server before carrying out operation also operating lease come the entitlement of requirement to operation.
5. job scheduler can use and server migration and the identical lease basis of single example service.
6. job scheduler can use the title of good definition to be tied in the overall JNDI tree of each server.The JNDI name can be " weblogic.JobScheduler ".The user can be commonj.timers.TimerManager and use its method to create operation the object of being searched transition.
7. job scheduler is only accepted serializable operation.Non-serializable operation can use IllegalArgumentException to refuse.
8.ClusterMBean can expose the attribute that is called DataSourceForJobScheduler, this attribute will be used for accessing database.In one embodiment, the job scheduler function only can obtain under the situation of disposition data source.
9. in one embodiment, job scheduler will only be supported the function with the fixed delay scheduling.Two continuous operations are carried out by separating ' at interval ' period.
10. only support in one embodiment, the repeated loading balance of operation.The timer master control (it only is another making cluster member) of will periodically voting of each making cluster member is used for the ready operation that will carry out.The timer master control will be used for to the fragment that each member provides total ready operation carrying out.
Job scheduler can need database to be used for continuing timer.All databases that the server migration function is supported also can be by the job scheduler support.Job scheduler can use ClusterMBean.getDataSourceForJobScheduler () accessing database.User creatable is called the table of " weblogic_timers ", and it has following field:
Title Type
————————— —————————
TIMER_ID NUMBER
TIMER_INFO VARchar2(100)
TIMER_MANAGER_NAME VARchar2(100)
CLUSTER_NAME VARchar2(100)
DOMAIN_NAME VARchar2(100)
TIMER_LISTENER BLOB
NEXT_EXECUTION_TIME NUMBER
INTERVAL NUMBER
In one embodiment, job scheduler is only in the middle work of trooping.All cluster node can participate in carrying out operation and be as broad as long.In one embodiment, only when DataSourceForJobScheduler ClusterMBean attribute is set to valid data source among the config.xml, will open job scheduler.Here be example:
<domain>
...
<cluster>
<name>Cluster-0</name>
<multicast-address>239.192.0.0</multicast-address>
<multi-port>7466</multicast-port>
<data-source-for-job-scheduler>JDBC Data Source-0</data-source-for-
job-scheduler>
</cluster>
...
<jdbc-system-resource>
<name>JDBC Data Source-0</name>
<target>myserver,server-0</target>
<description-file-name>jdbc/JDBC_Data_Source-0-3407-jdbc.xml</
description-file-name>
</jdbc-system-resource>
</domain>
Can use JNDI name " weblogic.JobScheduler " to search job scheduler and will be commonj.timers.TimerManager its transition.Here be example:
InitialContext ic=new InitialContext();
commonj.timers.TimerManager
jobScheduler=(common.timers.TimerManager)ic.lookup(“weblogic.JobScheduler”);
Commonj.timers.TimerListener timeListener=new
MySerializableTimerListener();
JobScheduler.schedule (timerListener, 0,30*1000); // carried out this work every 30 seconds
Already
...
...
private static class MySerializableTimerListener implements
commonj.timers.TimerListener,java.io.Serializable{
public void timerExpired(Timer timer){...}
}
Job scheduler can the operating lease function be come the single timer of requirement before carrying out entitlement, and select the timer master control.The timer master control can move on a making cluster member fully and be responsible for timer is assigned to individual server.The lease basis can be dependent on ClusterMBean.getLeasingBasising () attribute.If LeasingBasis is set to database, the configuration that is associated with the database lease can be just as being provided with in server migration so.If LeasingBasis is set to " desirable ", do not need the database support for lease so.
Control desk can provide option that ClusterMBean.setDataSourceForJobScheduler () is set.Data source can be inherited from server migration during shutting down or conversation continuity.If client configuration is used for one data source, they should be also can for the job scheduler function reuse it.
Can use according to the conventional general special digital computer or the microprocessor of disclosure instruction programming and realize an embodiment, as will being tangible for the computer realm technician.Can be easily prepare the appropriate software coding based on instruction of the present disclosure, as will being tangible for the software field technician by skilled programmer.The present invention also can realize by prepared integrated circuit or by the suitable network of the conventional assembly circuit that interconnects, as being easy to for those skilled in the art significantly.
Embodiment comprises the computer program as storage medium (medium), and described storage medium has been stored thereon/wherein and can be used for programmed computer to carry out the instruction of any feature given here.Storage medium can include but not limited to the disk of any kind, comprise the flash memory of floppy disk, CD, DVD, CD-ROM, microdrive and magneto-optic disk, ROM, RAM, EPROM, EEPROM, DRAM, medium or be suitable for being stored in any computer-readable medium (medium) and go up the instruction of storage and/or the equipment of data, the present invention can comprise hardware or the microprocessor that is used to control general/specialized computer, and is used to make computing machine or microprocessor or to utilize the result's of the present invention mutual software of other mechanism with human user.This software can include but not limited to that device drives, operating system, execution environments/containers and user use.
Embodiments of the invention can comprise the code that is provided for realizing process of the present invention.This provides and can comprise by any way code is offered the user.For example, provide and to comprise to the user and send the digital signal comprise code; Provide code on the physical medium to the user; Perhaps make the available any other method of code.
Embodiments of the invention can comprise the computer implemented method that is used to send code, and this code can be carried out on computers to carry out any process of the embodiment of the invention.Transmission can comprise any part by network, for example the Internet; By cable, air or space; Perhaps the transmission by any other type transmits.Transmission can comprise initiates the code transmission; Perhaps make code enter any zone or country from another regional or national transmission.For example, send comprise make as before the result of addressing the part of code by network transmitted and will comprise that the data of code send to the user.Can comprise by the user in any zone or the country to user's transmission receiving any transmission, no matter where transmission is from sending.
Embodiments of the invention can comprise and comprise the signal that can carry out on computers with the code of any process of carrying out the embodiment of the invention.Signal can pass through network, for example the Internet; By cable, air or space; Perhaps the transmission by any other type sends.Do not need whole signals simultaneously in transit.Signal can in time be expanded along with its transmission cycle.Signal is not considered for the snapshot in the current transportation.
The aforementioned description of the preferred embodiments of the present invention is provided for the purpose of illustration and description.That it is not intended to limit or limit the invention to disclosed precise forms.For the those of ordinary skill in the relevant field, many modifications and variations will be tangible.For example, the step of carrying out in the disclosed embodiment of the invention can be carried out by alternating sequence, can omit some step, and can add other step.Select and describe embodiment so that principle of the present invention and practical application thereof are described best, the present invention who makes others skilled in the art to understand thus to be used for various embodiment and to have various modifications, described modification is suitable for the expection of specific use.Being intended to scope of the present invention is defined by claim and equivalent thereof.

Claims (27)

1. computer implemented method comprises:
The place of trooping at application server determines the leader that troops;
Use the described leader of trooping to locate to set up the lease table at one of described application server;
Use described lease table to keep and be used at least one lease that single example is served.
2. computer implemented method according to claim 1, wherein said lease table are used to allow the Autonomic Migration Framework of described single example service.
3. computer implemented method according to claim 1, the wherein said leader of trooping selects in competition.
4. computer implemented method according to claim 1, wherein each application server periodically attempts becoming the described leader of trooping.
5. computer implemented method according to claim 1, wherein said determining step comprise the described application server of selecting early start.
6. computer implemented method according to claim 1, the wherein said leader of trooping ties up described other application server of trooping of living.
7. computer-readable medium according to claim 6, wherein, if the described leader of trooping fails live described other application server then described other application server is selected another leader that troops of dimension.
8. computer implemented medium according to claim 1, wherein said lease table is set up at the application server place identical with described lease leader.
9. computer implemented system comprises:
Be used to move first application server of single example service in trooping, described first application server is that lease is kept in described single example service at lease table place; With
The migration master control is redistributed second application server of trooping to described if it checks that described lease table and described first application server fail to keep described lease with described single example service.
10. computer implemented system according to claim 9, wherein said to redistribute described single example service be because the collapse of described first application server.
11. computer implemented system according to claim 9, wherein said to redistribute described single example service be because described first application server is isolated from described lease table.
12. computer implemented system according to claim 9, wherein said first application server dimension live described lease to keep the control to described single example service.
13. computer implemented system according to claim 9, wherein said single example service is the JMS server.
14. computer implemented system according to claim 9, wherein said single example service is the transaction recovery service.
15. computer implemented system according to claim 9, wherein said single example service is the timer master control.
16. computer implemented system according to claim 9, wherein said second application server moves the predetermined script of enabling.
17. computer implemented system according to claim 9, the predetermined inactive script of wherein said first application server operation.
18. computer implemented system according to claim 9, wherein said migration master control selects described next application server to move described single example service.
19. computer implemented system according to claim 9, wherein said single example service is the JMS service and wherein attempts restarting on described first application server in described migration manager before any migration.
20. a computer implemented system comprises:
Timer master control at the application server place of trooping, described timer master control is assigned to described other application server of trooping with institute's schedule job; Described application server is kept the lease that is used for described timer master control from the lease table; The job information of institute's schedule job is stored in described timer master control on database, wherein under the situation of described application server collapse, described Another Application server of trooping has been assigned with described timer master control and has used described job information to distribute institute's schedule job.
21. computer implemented system according to claim 20, wherein institute's schedule job comprises report.
22. computer implemented system according to claim 21, wherein said report is a database report.
23. computer implemented system according to claim 20, wherein said lease table is in described database.
24. computer implemented system according to claim 20, wherein said timer master control is single example service.
25. computer implemented system according to claim 24, wherein said timer master control is distributed to the Another Application server by the migration master control.
26. computer implemented system according to claim 20, wherein said other application server is from described timer master control request job.
27. computer implemented system according to claim 20, wherein said operation is scheduled as in non-peak hours place's operation.
CN200780017766.9A 2006-05-16 2007-01-04 Next generation clustering Active CN101460921B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310125906.1A CN103327066B (en) 2006-05-16 2007-01-04 Method and system for schedule job in cluster

Applications Claiming Priority (9)

Application Number Priority Date Filing Date Title
US74736406P 2006-05-16 2006-05-16
US60/747,364 2006-05-16
US11/425,784 US7536581B2 (en) 2006-05-16 2006-06-22 Automatic migratable services
US11/425,784 2006-06-22
US11/548,239 US7661015B2 (en) 2006-05-16 2006-10-10 Job scheduler
US11/548,239 2006-10-10
US11/550,551 2006-10-18
US11/550,551 US8122108B2 (en) 2006-05-16 2006-10-18 Database-less leasing
PCT/US2007/060102 WO2007136883A2 (en) 2006-05-16 2007-01-04 Next generation clustering

Related Child Applications (1)

Application Number Title Priority Date Filing Date
CN201310125906.1A Division CN103327066B (en) 2006-05-16 2007-01-04 Method and system for schedule job in cluster

Publications (2)

Publication Number Publication Date
CN101460921A true CN101460921A (en) 2009-06-17
CN101460921B CN101460921B (en) 2013-05-22

Family

ID=38725393

Family Applications (2)

Application Number Title Priority Date Filing Date
CN201310125906.1A Active CN103327066B (en) 2006-05-16 2007-01-04 Method and system for schedule job in cluster
CN200780017766.9A Active CN101460921B (en) 2006-05-16 2007-01-04 Next generation clustering

Family Applications Before (1)

Application Number Title Priority Date Filing Date
CN201310125906.1A Active CN103327066B (en) 2006-05-16 2007-01-04 Method and system for schedule job in cluster

Country Status (5)

Country Link
EP (1) EP2021910A4 (en)
CN (2) CN103327066B (en)
AU (1) AU2007254088A1 (en)
CA (1) CA2652147A1 (en)
WO (1) WO2007136883A2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117033092A (en) * 2023-10-10 2023-11-10 北京大道云行科技有限公司 Single-instance service failover method and system, electronic equipment and storage medium

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2505229B (en) * 2012-08-23 2019-10-16 Metaswitch Networks Ltd Upgrading nodes
US9411628B2 (en) 2014-11-13 2016-08-09 Microsoft Technology Licensing, Llc Virtual machine cluster backup in a multi-node environment

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1568467B (en) * 2001-09-06 2010-06-16 Bea系统公司 Exactly once cache framework
US7403996B2 (en) * 2002-02-21 2008-07-22 Bea Systems, Inc. Systems and methods for migratable services
US6944788B2 (en) * 2002-03-12 2005-09-13 Sun Microsystems, Inc. System and method for enabling failover for an application server cluster
CN1151635C (en) * 2002-07-09 2004-05-26 华中科技大学 General dispatching system based on content adaptive for colony network service
US20040153558A1 (en) * 2002-10-31 2004-08-05 Mesut Gunduc System and method for providing java based high availability clustering framework
CN100452797C (en) * 2005-07-15 2009-01-14 清华大学 High-available distributed boundary gateway protocol system based on cluster router structure

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117033092A (en) * 2023-10-10 2023-11-10 北京大道云行科技有限公司 Single-instance service failover method and system, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN101460921B (en) 2013-05-22
WO2007136883A2 (en) 2007-11-29
WO2007136883A3 (en) 2008-04-24
AU2007254088A1 (en) 2007-11-29
CN103327066A (en) 2013-09-25
CN103327066B (en) 2016-08-17
EP2021910A2 (en) 2009-02-11
EP2021910A4 (en) 2015-05-06
CA2652147A1 (en) 2007-11-29

Similar Documents

Publication Publication Date Title
US7536581B2 (en) Automatic migratable services
US8122108B2 (en) Database-less leasing
US7661015B2 (en) Job scheduler
US20230023262A1 (en) System and method for supporting patching in a multitenant application server environment
US7380155B2 (en) System for highly available transaction recovery for transaction processing systems
US20190347089A1 (en) System and method for supporting patching in a multitenant application server environment
US8412790B2 (en) Method, system and computer readable recording medium for determining major group under split-brain syndrome
JP6615796B2 (en) System and method for partition migration in a multi-tenant application server environment
US20060146877A1 (en) Multipool using automatically maintained active connection pool list
CN102763102B (en) For data environment from service configuration
JP6047564B2 (en) System and method for providing improved session affinity and connectivity in a clustered database environment
US20030177150A1 (en) Method for highly available transaction recovery for transaction processing systems
CN100524223C (en) Method and system for concurrent handler execution in a SMI and PMI-based dispatch-execution framework
US9384103B2 (en) EJB cluster timer
US7480816B1 (en) Failure chain detection and recovery in a group of cooperating systems
CN102656565A (en) Failover and recovery for replicated data instances
JP2001518660A (en) Method of sequentially and reliably starting and / or reloading multiprocessor nodes in a multinode cluster
CN101460921B (en) Next generation clustering
CA2498064C (en) A data processing system adapted to integrating non-homogeneous processes
US7660879B2 (en) System and method for application deployment service
WO2006073865A2 (en) Multipool manager
WO2003073281A1 (en) Highly available transaction recovery for transaction processing systems
JP2017211709A (en) Virtual machine management method and virtual machine management system
JPH07311745A (en) Distributed processing system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
ASS Succession or assignment of patent right

Owner name: ORACLE INT CORP

Free format text: FORMER OWNER: BEA SYSTEMS CORP.

Effective date: 20110330

C41 Transfer of patent application or patent right or utility model
TA01 Transfer of patent application right

Effective date of registration: 20110330

Address after: American California

Applicant after: Oracle Int Corp

Address before: American California

Applicant before: Bea Systems Corp.

C14 Grant of patent or utility model
GR01 Patent grant