资源描述:
《使用eclipse远程调试java应用程序》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、外文翻译,网上搜索所得DebugJavaapplicationsremotelywithEclipseUsethepoweroftheEclipseIDEtospreadaroundyourJavaapplicationdebuggingLevel:IntermediateCharlesLu(charleslu@tw.ibm.com),SoftwareEngineer,IBM09Dec2008Youdon'tneedtodebugJava™applicationsonjustyourlocaldesktop.Learnhow
2、tospreadaroundyourdebuggingusingdifferentconnectiontypesthatmakeupremotedebugging.Thisarticleexplainsthefeaturesandexamplesthatshowhowtosetupremoteapplicationdebugging.Remotedebuggingcanbeusefulforapplicationdevelopment,suchasdevelopingaprogramforalow-endmachinetha
3、tcannothostthedevelopmentplatform,ordebuggingprogramsondedicatedmachineslikeWebservers,whoseservicescannotbeshutdown.OtherexamplesincludeJavaapplicationsrunningwithlimitedmemoryorCPUpower,suchasmobiledevices,ordeveloperswantingtoseparatetheapplicationanddevelopment
4、environments,etc.PrerequisitesLaunch-configurationtypeAlaunchconfigurationkeepsasetofattributesthatcanbeusedtolaunchaprogram.Thelaunch-configurationtypeisauniquetypeofprogramthatcanbelaunchedintheEclipseplatform.Ifyoudon'thaveitalready,downloadEclipseV3.4(Ganymede)
5、.InGanymede,thesocketlisteningconnectorhasbeenaddedtotheRemoteJavaApplicationlaunch-configurationtype.Eclipse'snewsocketlisteningconnectorallowsyoutostarttheJavadebugger,whichlistensforaconnectiononaspecificsocket.Theprogrambeingdebuggedcanthenbestartedwithcommand-
6、lineoptionstoconnecttothedebugger.PriortotheGanymederelease,onlyasocket-attachingconnectorwasprovided,andtheprogrambeingdebuggedhadtobeadebughostthatwasconnectedbythedebugger.ItisimpracticalformobiledevicestobeahostduetoinsufficientmemoryandCPUpower.Touseremotedebu
7、gging,JavaVirtualMachine(JVM)V5.0orlatermustbeused,suchasIBM®J9orSunMicrosystems'JavaSEDevelopmentKit(JDK).Inthisarticle,wefocusonremotedebugging,ratherthandetaileachofEclipse'sdebuggingfeatures.SeeResourcesformoreinformationaboutdebuggingwithEclipseandwheretofindt
8、heaforementionedsoftware.JPDAintroductionFrequentlyusedacronyms·JDI—JavaDebugInterface·JDT—JavaDevelopmentTools·JDWP—JavaDebugWireProtocol·JPDA—J