计算机科学与技术 外文翻译 外文文献 英文文献 J2EE在分布式环境下的应用文档格式.docx
《计算机科学与技术 外文翻译 外文文献 英文文献 J2EE在分布式环境下的应用文档格式.docx》由会员分享,可在线阅读,更多相关《计算机科学与技术 外文翻译 外文文献 英文文献 J2EE在分布式环境下的应用文档格式.docx(12页珍藏版)》请在冰豆网上搜索。
1.Introduction
Inrecentyears,wehaveseenasignificantgrowthincomponent-basedenterpriseapplicationdevelopment.TheseapplicationsaretypicallydeployedoncompanyIntranetsorontheInternetandarecharacterizedbyhightransactionvolume,largenumbersofusersandwideareaaccess.Traditionallytheyaredeployedinacentrallocation,usingserverclusteringwithloadbalancing(horizontalpartitioning)tosustainuserload.However,horizontalpartitioninghasbeenshownveryefficientonlyinreducingapplication-relatedoverheadsofuser-perceivedresponsetimes,withouthavingmucheffectonnetwork-inducedlatencies.Verticalpartitioning(e.g.,runningwebtierandbusinesstierinseparateVMs)hasbeenusedforfaultisolationandloadbalancingbutitissometimesimpracticalduetosignificantrun-timeoverheads(evenifonewouldkeepthetiersonafastlocal-areanetwork)relatedtoheavyuseofremoteinvocations.RecentworkinthecontextofJ2EEcomponentbasedapplicationshasshownviabilityofverticalpartitioninginwide-areanetworkswithoutincurringtheaforementionedoverheads.Thekeyconclusionsfromthatstudycanbesummarizedasfollows:
•Usingproperlydesignedapplications,verticaldistributionacrosswide-areanetworksimprovesuser-perceivedlatencies.
•Wide-areaverticallayeringrequiresreplicationofapplicationcomponentsandmaintainingconsistencybetweenreplicas.
•Additionalreplicasmaybedeployeddynamicallytohandlenewrequests.
•Differentreplicasmay,infact,bedifferentimplementationsofthesamecomponentbasedonusage(read-only,read-write).
•Newrequestpathsmayreusecomponentsfrompreviouslydeployedpaths.
ApplyingintelligentmonitoringandAIplanningtechniquesinconjunctionwiththeconclusionsofthatstudy,weseeapotentialfordynamicadaptationinindustry-standardJ2EEcomponent-basedapplicationsinwideareanetworks
Throughdeploymentofadditionalapplicationcomponentsdynamicallybasedonactivemonitoring.However,inordertoachievesuchdynamicadaptation,weneedaninfrastructureforautomatingJ2EEapplicationdeploymentinsuchanenvironment.ThisneedisquiteevidenttoanyonewhohasevertrieddeployingaJ2EEapplicationevenonasingleapplicationserver,whichisataskthatinvolvesagreatdealofconfigurationofboththesystemservicesandapplicationcomponents.ForexampleonehastosetupJDBCdatasources,messagingdestinationsandotherresourceadaptersbeforeapplicationcomponentscanbeconfiguredanddeployed.Inawideareadeploymentthatspansmultipleservernodes,thisprovesevenmorecomplex,sincemoresystemservicesthatfacilitateinter-nodecommunicationsneedtobeconfiguredandstartedandavarietyofconfigurationdata,likeIPaddresses,portnumbers,JNDInamesandothershavetobeconsistentlymaintainedinvariousconfigurationfilesonmultiplenodes.
Thisdistributeddeploymentinfrastructuremustbeableto:
•addressinter-componentconnectivityspecificationanddefineitseffectsoncomponentconfigurationanddeployment,
•addressapplicationcomponentdependenciesonapplicationserverservices,theirconfigurationanddeployment,
•providesimplebutexpressiveabstractionstocontroladaptationthroughdynamicdeploymentandundeploymentofcomponents,
•enablereuseofservicesandcomponentstomaintainefficientuseofnetworknodes’resources,
•providethesefacilitieswithoutincurringsignificantadditionaldesigneffortonbehalfofapplicationprogrammers.
InthispaperweproposetheinfrastructureforautomaticdynamicdeploymentofJ2EEapplications,whichaddressesalloftheaforementionedissues.Theinfrastructuredefinesarchitecturedescriptionlanguages(ADL)forcomponentandlinkdescriptionandassembly.TheComponentDescriptionLanguageisusedtodescribeapplicationcomponentsandlinks.Itprovidesclearseparationofapplicationcomponentsfromsystemcomponents.Aflexibletypesystemisusedtodefinecompatibilityofcomponentportsandlinks.Adeclarationandexpressionlanguageforconfigurablecomponentpropertiesallowsforspecificationofinter-componentdependenciesandpropagationofpropertiesbetweencomponents.TheComponent(Replica)AssemblyLanguageallowsforassemblyofreplicasofpreviouslydefinedcomponentsintoapplicationpathsbyconnectingappropriateportsvialinkreplicasandspecifyingthemappingofthesecomponentreplicasontotargetapplicationservernodes.TheComponentConfigurationProcessevaluatesanapplicationpath’scorrectness,identifiesthedependenciesofapplicationcomponentsonsystemcomponents,andconfigurescomponentreplicasfordeployment.Anattemptismadetomatchandreuseanypreviouslydeployedreplicasinthenewpathbasedontheirconfigurations.WeimplementtheinfrastructureasapartoftheJBossopensourceJavaapplicationserverandtestitonseveraltechnologysampleJ2EEapplications–JavaPetstore,RubiesandTPC-W-NYU.TheinfrastructureimplementationutilizestheJBoss’sextendablemicro-kernelarchitecture,basedontheJMXspecification.ComponentizedarchitectureofJBossallowsincrementalservicedeploymentsdependingontheneedsofdeployedapplications.Webelievethatdynamicreconfigurationofapplicationserversthroughdynamicdeploymentandundeploymentofsystemservicesisessentialtobuildingaresource-efficientframeworkfordynamicdistributeddeploymentofJ2EEapplications.Therestofthepaperisorganizedasfollows.Section2providesnecessarybackgroundforunderstandingthespecificsoftheJ2EEcomponenttechnologywhicharerelevanttothisstudy.Section3givesageneraldescriptionoftheinfrastructurearchitecture,whilesection4goesdeeperindescribingparticularlyimportantandinterestinginternalmechanismsoftheinfrastructure.Section5describestheimplementationoftheframework,andrelatedworkisdiscussedinsection6.
2.J2EEBackground
2.1Introduction
Componentframeworks.
Acomponentframeworkisamiddlewaresystemthatsupportsapplicationsconsistingofcomponentsconformingtocertainstandards.Applicationcomponentsare“plugged”intothecomponentframework,whichestablishestheirenvironmentalconditionsandregulatestheinteractionsbetweenthem.Thisisusuallydonethroughcontainers,componentholders,whichalsoprovidecommonlyrequiredsupportfornaming,security,transactions,andpersistence.Componentframeworksprovideanintegratedenvironmentforcomponentexecution,asaresultsignificantlyreducetheeffort.ittakestodesign,implement,deploy,andmaintainapplications.CurrentdayindustrycomponentframeworkstandardsarerepresentedbyObjectManagementGroup’sCORBAComponentModel,SunMicrosystems’Java2PlatformEnterpriseEdition(J2EE)andMicrosoft’s.NET,withJ2EEbeingcurrentlythemostpopularandwidelyusedcomponentframeworkintheenterprisearena.
J2EE.
Java2PlatformEnterpriseEdition(J2EE)isacomprehensivestandardfordevelopingmulti-tierenterpriseJavaapplications.TheJ2EEspecificationamongotherthingsdefinesthefollowing:
•Componentprogrammingmodel,
•Componentcontractswiththehostingserver,
•Servicesthattheplatformprovidestothesecomponents,
•Varioushumanroles,
•Compatibilitytestsuitesandcompliancetestingprocedures.
Amongthelistofservicesthatacompliantapplicationservermustprovidearemessaging,transactions,namingandothersthatcanbeusedbytheapplicationcomponents.ApplicationdevelopedusingJ2EEadheretotheclassical3-Tierarchitectures–PresentationTier,BusinessTier,andEnterpriseInformationSystem(EIS)Tier(seeFig.1).J2EEcomponentsbelongingtoeachtieraredevelopedadheringtothe
SpecificJ2EEstandards.
1.PresentationorWebtier.
Thistierisactuallysubdividedintoclientandserversides.Theclientsidehostsawebbrowser,appletsandJavaapplicationsthatcommunicatewiththeserversideofpresentationtierorthebusinesstier.TheserversidehostsJavaServletcomponents,JavaServerPages(JSPs)andstaticwebcontent.Thesecomponentsareresponsibleforpresentingbusinessdatatotheendusers.ThedataitselfistypicallyacquiredfromthebusinesstierandsometimesdirectlyfromtheEnterpriseInformationSystemtier.TheserversideofthepresentationtieristypicallyaccessedthroughHTTP(S)protocol.
2.BusinessorEJBtier.
ThistierconsistsofEnterpriseJavaBeans(EJBs)thatmodelthebusinesslogicoftheenterpriseapplication.Thesecomponentsprovidepersistencemechanismsandtransactionalsupport.ThecomponentsintheEJBtierareinvokedthroughremoteinvocations(RMI),in-JVMinvocationsorasynchronousmessagedelivery,dependingonthetypeofEJBcomponent.TheEJBspecificationdefinesseveraltypesofcomponents.Theydifferininvocationstyle(synchronousvs.asynchronous,localvs.remote)andstatefulness:
completelystateless(e.g.,Message-DrivenBean),statefulnon-persistent
(e.g.,StatefulSessionBean),statefulpersistent(e.g.,EntityBean).SynchronouslyinvocableEJBcomponentsexposethemselvesthroughaspecialfactoryproxyobject(anEJBHomeobject,whichisspecifictoagivenEJB),whichistypicallyboundinJNDIbythedeployeroftheEJB.TheEJBHomeobjectallowscreationorlocationofanEJBObject,whichisaproxytoaparticularinstanceofanEJB1.
3.EnterpriseInformationSystem(EIS)orDatatier.
Thistierreferstotheenterpriseinformationsystems,likerelationaldatabases,ERPsystems,messagingsystemsandthelike.Businessan