Apache_Hadoop_YARN_Client_3.1.2.xml 134 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947
  1. <?xml version="1.0" encoding="iso-8859-1" standalone="no"?>
  2. <!-- Generated by the JDiff Javadoc doclet -->
  3. <!-- (http://www.jdiff.org) -->
  4. <!-- on Tue Jan 29 03:57:04 UTC 2019 -->
  5. <api
  6. xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
  7. xsi:noNamespaceSchemaLocation='api.xsd'
  8. name="Apache Hadoop YARN Client 3.1.2"
  9. jdversion="1.0.9">
  10. <!-- Command line arguments = -doclet org.apache.hadoop.classification.tools.IncludePublicAnnotationsJDiffDoclet -docletpath /build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/target/hadoop-annotations.jar:/build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/target/jdiff.jar -verbose -classpath /build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/target/classes:/build/source/hadoop-common-project/hadoop-common/target/hadoop-common-3.1.2.jar:/maven/org/apache/commons/commons-math3/3.1.1/commons-math3-3.1.1.jar:/maven/org/apache/httpcomponents/httpclient/4.5.2/httpclient-4.5.2.jar:/maven/org/apache/httpcomponents/httpcore/4.4.4/httpcore-4.4.4.jar:/maven/commons-codec/commons-codec/1.11/commons-codec-1.11.jar:/maven/commons-io/commons-io/2.5/commons-io-2.5.jar:/maven/commons-net/commons-net/3.6/commons-net-3.6.jar:/maven/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar:/maven/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0.jar:/maven/org/eclipse/jetty/jetty-server/9.3.24.v20180605/jetty-server-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-http/9.3.24.v20180605/jetty-http-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-io/9.3.24.v20180605/jetty-io-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-util/9.3.24.v20180605/jetty-util-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-servlet/9.3.24.v20180605/jetty-servlet-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-security/9.3.24.v20180605/jetty-security-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-webapp/9.3.24.v20180605/jetty-webapp-9.3.24.v20180605.jar:/maven/org/eclipse/jetty/jetty-xml/9.3.24.v20180605/jetty-xml-9.3.24.v20180605.jar:/maven/javax/servlet/jsp/jsp-api/2.1/jsp-api-2.1.jar:/maven/com/sun/jersey/jersey-core/1.19/jersey-core-1.19.jar:/maven/javax/ws/rs/jsr311-api/1.1.1/jsr311-api-1.1.1.jar:/maven/com/sun/jersey/jersey-servlet/1.19/jersey-servlet-1.19.jar:/maven/com/sun/jersey/jersey-json/1.19/jersey-json-1.19.jar:/maven/com/sun/xml/bind/jaxb-impl/2.2.3-1/jaxb-impl-2.2.3-1.jar:/maven/org/codehaus/jackson/jackson-core-asl/1.9.13/jackson-core-asl-1.9.13.jar:/maven/org/codehaus/jackson/jackson-mapper-asl/1.9.13/jackson-mapper-asl-1.9.13.jar:/maven/org/codehaus/jackson/jackson-jaxrs/1.9.13/jackson-jaxrs-1.9.13.jar:/maven/org/codehaus/jackson/jackson-xc/1.9.13/jackson-xc-1.9.13.jar:/maven/com/sun/jersey/jersey-server/1.19/jersey-server-1.19.jar:/maven/commons-beanutils/commons-beanutils/1.9.3/commons-beanutils-1.9.3.jar:/maven/org/apache/commons/commons-configuration2/2.1.1/commons-configuration2-2.1.1.jar:/maven/org/apache/commons/commons-lang3/3.4/commons-lang3-3.4.jar:/maven/org/slf4j/slf4j-api/1.7.25/slf4j-api-1.7.25.jar:/maven/org/slf4j/slf4j-log4j12/1.7.25/slf4j-log4j12-1.7.25.jar:/maven/org/apache/avro/avro/1.7.7/avro-1.7.7.jar:/maven/com/thoughtworks/paranamer/paranamer/2.3/paranamer-2.3.jar:/maven/org/xerial/snappy/snappy-java/1.0.5/snappy-java-1.0.5.jar:/maven/com/google/re2j/re2j/1.1/re2j-1.1.jar:/maven/com/google/protobuf/protobuf-java/2.5.0/protobuf-java-2.5.0.jar:/maven/com/google/code/gson/gson/2.2.4/gson-2.2.4.jar:/build/source/hadoop-common-project/hadoop-auth/target/hadoop-auth-3.1.2.jar:/maven/com/nimbusds/nimbus-jose-jwt/4.41.1/nimbus-jose-jwt-4.41.1.jar:/maven/com/github/stephenc/jcip/jcip-annotations/1.0-1/jcip-annotations-1.0-1.jar:/maven/net/minidev/json-smart/2.3/json-smart-2.3.jar:/maven/net/minidev/accessors-smart/1.2/accessors-smart-1.2.jar:/maven/org/ow2/asm/asm/5.0.4/asm-5.0.4.jar:/maven/org/apache/curator/curator-framework/2.13.0/curator-framework-2.13.0.jar:/maven/com/jcraft/jsch/0.1.54/jsch-0.1.54.jar:/maven/org/apache/curator/curator-client/2.13.0/curator-client-2.13.0.jar:/maven/org/apache/curator/curator-recipes/2.13.0/curator-recipes-2.13.0.jar:/maven/com/google/code/findbugs/jsr305/3.0.0/jsr305-3.0.0.jar:/maven/org/apache/htrace/htrace-core4/4.1.0-incubating/htrace-core4-4.1.0-incubating.jar:/maven/org/apache/zookeeper/zookeeper/3.4.13/zookeeper-3.4.13.jar:/maven/org/apache/commons/commons-compress/1.18/commons-compress-1.18.jar:/maven/org/apache/kerby/kerb-simplekdc/1.0.1/kerb-simplekdc-1.0.1.jar:/maven/org/apache/kerby/kerb-client/1.0.1/kerb-client-1.0.1.jar:/maven/org/apache/kerby/kerby-config/1.0.1/kerby-config-1.0.1.jar:/maven/org/apache/kerby/kerb-core/1.0.1/kerb-core-1.0.1.jar:/maven/org/apache/kerby/kerby-pkix/1.0.1/kerby-pkix-1.0.1.jar:/maven/org/apache/kerby/kerby-asn1/1.0.1/kerby-asn1-1.0.1.jar:/maven/org/apache/kerby/kerby-util/1.0.1/kerby-util-1.0.1.jar:/maven/org/apache/kerby/kerb-common/1.0.1/kerb-common-1.0.1.jar:/maven/org/apache/kerby/kerb-crypto/1.0.1/kerb-crypto-1.0.1.jar:/maven/org/apache/kerby/kerb-util/1.0.1/kerb-util-1.0.1.jar:/maven/org/apache/kerby/token-provider/1.0.1/token-provider-1.0.1.jar:/maven/org/apache/kerby/kerb-admin/1.0.1/kerb-admin-1.0.1.jar:/maven/org/apache/kerby/kerb-server/1.0.1/kerb-server-1.0.1.jar:/maven/org/apache/kerby/kerb-identity/1.0.1/kerb-identity-1.0.1.jar:/maven/org/apache/kerby/kerby-xdr/1.0.1/kerby-xdr-1.0.1.jar:/maven/com/fasterxml/jackson/core/jackson-databind/2.7.8/jackson-databind-2.7.8.jar:/maven/org/codehaus/woodstox/stax2-api/3.1.4/stax2-api-3.1.4.jar:/maven/com/fasterxml/woodstox/woodstox-core/5.0.3/woodstox-core-5.0.3.jar:/maven/com/google/guava/guava/11.0.2/guava-11.0.2.jar:/maven/commons-logging/commons-logging/1.1.3/commons-logging-1.1.3.jar:/maven/commons-lang/commons-lang/2.6/commons-lang-2.6.jar:/maven/commons-cli/commons-cli/1.2/commons-cli-1.2.jar:/maven/log4j/log4j/1.2.17/log4j-1.2.17.jar:/build/source/hadoop-common-project/hadoop-annotations/target/hadoop-annotations-3.1.2.jar:/usr/lib/jvm/java-8-openjdk-amd64/lib/tools.jar:/maven/org/apache/yetus/audience-annotations/0.5.0/audience-annotations-0.5.0.jar:/maven/io/netty/netty/3.10.5.Final/netty-3.10.5.Final.jar:/build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/target/hadoop-yarn-api-3.1.2.jar:/maven/javax/xml/bind/jaxb-api/2.2.11/jaxb-api-2.2.11.jar:/maven/com/fasterxml/jackson/core/jackson-annotations/2.7.8/jackson-annotations-2.7.8.jar:/build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/target/hadoop-yarn-common-3.1.2.jar:/maven/com/sun/jersey/jersey-client/1.19/jersey-client-1.19.jar:/maven/com/google/inject/extensions/guice-servlet/4.0/guice-servlet-4.0.jar:/maven/com/google/inject/guice/4.0/guice-4.0.jar:/maven/javax/inject/javax.inject/1/javax.inject-1.jar:/maven/aopalliance/aopalliance/1.0/aopalliance-1.0.jar:/maven/com/sun/jersey/contribs/jersey-guice/1.19/jersey-guice-1.19.jar:/maven/com/fasterxml/jackson/core/jackson-core/2.7.8/jackson-core-2.7.8.jar:/maven/com/fasterxml/jackson/module/jackson-module-jaxb-annotations/2.7.8/jackson-module-jaxb-annotations-2.7.8.jar:/maven/com/fasterxml/jackson/jaxrs/jackson-jaxrs-json-provider/2.7.8/jackson-jaxrs-json-provider-2.7.8.jar:/maven/com/fasterxml/jackson/jaxrs/jackson-jaxrs-base/2.7.8/jackson-jaxrs-base-2.7.8.jar:/maven/org/codehaus/jettison/jettison/1.1/jettison-1.1.jar:/maven/xerces/xercesImpl/2.11.0/xercesImpl-2.11.0.jar:/maven/xml-apis/xml-apis/1.4.01/xml-apis-1.4.01.jar -sourcepath /build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/src/main/java -doclet org.apache.hadoop.classification.tools.IncludePublicAnnotationsJDiffDoclet -docletpath /build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/target/hadoop-annotations.jar:/build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/target/jdiff.jar -apidir /build/source/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client/target/site/jdiff/xml -apiname Apache Hadoop YARN Client 3.1.2 -->
  11. <package name="org.apache.hadoop.yarn.client">
  12. </package>
  13. <package name="org.apache.hadoop.yarn.client.api">
  14. <!-- start class org.apache.hadoop.yarn.client.api.AHSClient -->
  15. <class name="AHSClient" extends="org.apache.hadoop.service.AbstractService"
  16. abstract="true"
  17. static="false" final="false" visibility="public"
  18. deprecated="not deprecated">
  19. <constructor name="AHSClient" type="java.lang.String"
  20. static="false" final="false" visibility="public"
  21. deprecated="not deprecated">
  22. </constructor>
  23. <method name="createAHSClient" return="org.apache.hadoop.yarn.client.api.AHSClient"
  24. abstract="false" native="false" synchronized="false"
  25. static="true" final="false" visibility="public"
  26. deprecated="not deprecated">
  27. <doc>
  28. <![CDATA[Create a new instance of AHSClient.]]>
  29. </doc>
  30. </method>
  31. <method name="createAHSv2Client" return="org.apache.hadoop.yarn.client.api.AHSClient"
  32. abstract="false" native="false" synchronized="false"
  33. static="true" final="false" visibility="public"
  34. deprecated="not deprecated">
  35. </method>
  36. <method name="getApplicationReport" return="org.apache.hadoop.yarn.api.records.ApplicationReport"
  37. abstract="true" native="false" synchronized="false"
  38. static="false" final="false" visibility="public"
  39. deprecated="not deprecated">
  40. <param name="appId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  41. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  42. <exception name="IOException" type="java.io.IOException"/>
  43. <doc>
  44. <![CDATA[Get a report of the given Application.
  45. <p>
  46. In secure mode, <code>YARN</code> verifies access to the application, queue
  47. etc. before accepting the request.
  48. <p>
  49. If the user does not have <code>VIEW_APP</code> access then the following
  50. fields in the report will be set to stubbed values:
  51. <ul>
  52. <li>host - set to "N/A"</li>
  53. <li>RPC port - set to -1</li>
  54. <li>client token - set to "N/A"</li>
  55. <li>diagnostics - set to "N/A"</li>
  56. <li>tracking URL - set to "N/A"</li>
  57. <li>original tracking URL - set to "N/A"</li>
  58. <li>resource usage report - all values are -1</li>
  59. </ul>
  60. @param appId
  61. {@link ApplicationId} of the application that needs a report
  62. @return application report
  63. @throws YarnException
  64. @throws IOException]]>
  65. </doc>
  66. </method>
  67. <method name="getApplications" return="java.util.List"
  68. abstract="true" native="false" synchronized="false"
  69. static="false" final="false" visibility="public"
  70. deprecated="not deprecated">
  71. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  72. <exception name="IOException" type="java.io.IOException"/>
  73. <doc>
  74. <![CDATA[<p>
  75. Get a report (ApplicationReport) of all Applications in the cluster.
  76. </p>
  77. <p>
  78. If the user does not have <code>VIEW_APP</code> access for an application
  79. then the corresponding report will be filtered as described in
  80. {@link #getApplicationReport(ApplicationId)}.
  81. </p>
  82. @return a list of reports for all applications
  83. @throws YarnException
  84. @throws IOException]]>
  85. </doc>
  86. </method>
  87. <method name="getApplicationAttemptReport" return="org.apache.hadoop.yarn.api.records.ApplicationAttemptReport"
  88. abstract="true" native="false" synchronized="false"
  89. static="false" final="false" visibility="public"
  90. deprecated="not deprecated">
  91. <param name="applicationAttemptId" type="org.apache.hadoop.yarn.api.records.ApplicationAttemptId"/>
  92. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  93. <exception name="IOException" type="java.io.IOException"/>
  94. <doc>
  95. <![CDATA[<p>
  96. Get a report of the given ApplicationAttempt.
  97. </p>
  98. <p>
  99. In secure mode, <code>YARN</code> verifies access to the application, queue
  100. etc. before accepting the request.
  101. </p>
  102. @param applicationAttemptId
  103. {@link ApplicationAttemptId} of the application attempt that needs
  104. a report
  105. @return application attempt report
  106. @throws YarnException
  107. @throws ApplicationAttemptNotFoundException if application attempt
  108. not found
  109. @throws IOException]]>
  110. </doc>
  111. </method>
  112. <method name="getApplicationAttempts" return="java.util.List"
  113. abstract="true" native="false" synchronized="false"
  114. static="false" final="false" visibility="public"
  115. deprecated="not deprecated">
  116. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  117. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  118. <exception name="IOException" type="java.io.IOException"/>
  119. <doc>
  120. <![CDATA[<p>
  121. Get a report of all (ApplicationAttempts) of Application in the cluster.
  122. </p>
  123. @param applicationId
  124. @return a list of reports for all application attempts for specified
  125. application
  126. @throws YarnException
  127. @throws IOException]]>
  128. </doc>
  129. </method>
  130. <method name="getContainerReport" return="org.apache.hadoop.yarn.api.records.ContainerReport"
  131. abstract="true" native="false" synchronized="false"
  132. static="false" final="false" visibility="public"
  133. deprecated="not deprecated">
  134. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  135. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  136. <exception name="IOException" type="java.io.IOException"/>
  137. <doc>
  138. <![CDATA[<p>
  139. Get a report of the given Container.
  140. </p>
  141. <p>
  142. In secure mode, <code>YARN</code> verifies access to the application, queue
  143. etc. before accepting the request.
  144. </p>
  145. @param containerId
  146. {@link ContainerId} of the container that needs a report
  147. @return container report
  148. @throws YarnException
  149. @throws ContainerNotFoundException if container not found
  150. @throws IOException]]>
  151. </doc>
  152. </method>
  153. <method name="getContainers" return="java.util.List"
  154. abstract="true" native="false" synchronized="false"
  155. static="false" final="false" visibility="public"
  156. deprecated="not deprecated">
  157. <param name="applicationAttemptId" type="org.apache.hadoop.yarn.api.records.ApplicationAttemptId"/>
  158. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  159. <exception name="IOException" type="java.io.IOException"/>
  160. <doc>
  161. <![CDATA[<p>
  162. Get a report of all (Containers) of ApplicationAttempt in the cluster.
  163. </p>
  164. @param applicationAttemptId
  165. @return a list of reports of all containers for specified application
  166. attempt
  167. @throws YarnException
  168. @throws IOException]]>
  169. </doc>
  170. </method>
  171. </class>
  172. <!-- end class org.apache.hadoop.yarn.client.api.AHSClient -->
  173. <!-- start class org.apache.hadoop.yarn.client.api.AMRMClient -->
  174. <class name="AMRMClient" extends="org.apache.hadoop.service.AbstractService"
  175. abstract="true"
  176. static="false" final="false" visibility="public"
  177. deprecated="not deprecated">
  178. <constructor name="AMRMClient" type="java.lang.String"
  179. static="false" final="false" visibility="protected"
  180. deprecated="not deprecated">
  181. </constructor>
  182. <method name="createAMRMClient" return="org.apache.hadoop.yarn.client.api.AMRMClient"
  183. abstract="false" native="false" synchronized="false"
  184. static="true" final="false" visibility="public"
  185. deprecated="not deprecated">
  186. <doc>
  187. <![CDATA[Create a new instance of AMRMClient.
  188. For usage:
  189. <pre>
  190. {@code
  191. AMRMClient.<T>createAMRMClientContainerRequest()
  192. }</pre>
  193. @return the newly create AMRMClient instance.]]>
  194. </doc>
  195. </method>
  196. <method name="addSchedulingRequests"
  197. abstract="false" native="false" synchronized="false"
  198. static="false" final="false" visibility="public"
  199. deprecated="not deprecated">
  200. <param name="schedulingRequests" type="java.util.Collection"/>
  201. <doc>
  202. <![CDATA[Add a Collection of SchedulingRequests. The AMRMClient will ensure that
  203. all requests in the same batch are sent in the same allocate call.
  204. @param schedulingRequests Collection of Scheduling Requests.]]>
  205. </doc>
  206. </method>
  207. <method name="registerApplicationMaster" return="org.apache.hadoop.yarn.api.protocolrecords.RegisterApplicationMasterResponse"
  208. abstract="true" native="false" synchronized="false"
  209. static="false" final="false" visibility="public"
  210. deprecated="not deprecated">
  211. <param name="appHostName" type="java.lang.String"/>
  212. <param name="appHostPort" type="int"/>
  213. <param name="appTrackingUrl" type="java.lang.String"/>
  214. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  215. <exception name="IOException" type="java.io.IOException"/>
  216. <doc>
  217. <![CDATA[Register the application master. This must be called before any
  218. other interaction
  219. @param appHostName Name of the host on which master is running
  220. @param appHostPort Port master is listening on
  221. @param appTrackingUrl URL at which the master info can be seen
  222. @return <code>RegisterApplicationMasterResponse</code>
  223. @throws YarnException
  224. @throws IOException]]>
  225. </doc>
  226. </method>
  227. <method name="registerApplicationMaster" return="org.apache.hadoop.yarn.api.protocolrecords.RegisterApplicationMasterResponse"
  228. abstract="false" native="false" synchronized="false"
  229. static="false" final="false" visibility="public"
  230. deprecated="not deprecated">
  231. <param name="appHostName" type="java.lang.String"/>
  232. <param name="appHostPort" type="int"/>
  233. <param name="appTrackingUrl" type="java.lang.String"/>
  234. <param name="placementConstraints" type="java.util.Map"/>
  235. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  236. <exception name="IOException" type="java.io.IOException"/>
  237. <doc>
  238. <![CDATA[Register the application master. This must be called before any
  239. other interaction
  240. @param appHostName Name of the host on which master is running
  241. @param appHostPort Port master is listening on
  242. @param appTrackingUrl URL at which the master info can be seen
  243. @param placementConstraints Placement Constraints mappings.
  244. @return <code>RegisterApplicationMasterResponse</code>
  245. @throws YarnException
  246. @throws IOException]]>
  247. </doc>
  248. </method>
  249. <method name="allocate" return="org.apache.hadoop.yarn.api.protocolrecords.AllocateResponse"
  250. abstract="true" native="false" synchronized="false"
  251. static="false" final="false" visibility="public"
  252. deprecated="not deprecated">
  253. <param name="progressIndicator" type="float"/>
  254. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  255. <exception name="IOException" type="java.io.IOException"/>
  256. <doc>
  257. <![CDATA[Request additional containers and receive new container allocations.
  258. Requests made via <code>addContainerRequest</code> are sent to the
  259. <code>ResourceManager</code>. New containers assigned to the master are
  260. retrieved. Status of completed containers and node health updates are also
  261. retrieved. This also doubles up as a heartbeat to the ResourceManager and
  262. must be made periodically. The call may not always return any new
  263. allocations of containers. App should not make concurrent allocate
  264. requests. May cause request loss.
  265. <p>
  266. Note : If the user has not removed container requests that have already
  267. been satisfied, then the re-register may end up sending the entire
  268. container requests to the RM (including matched requests). Which would mean
  269. the RM could end up giving it a lot of new allocated containers.
  270. </p>
  271. @param progressIndicator Indicates progress made by the master
  272. @return the response of the allocate request
  273. @throws YarnException
  274. @throws IOException]]>
  275. </doc>
  276. </method>
  277. <method name="unregisterApplicationMaster"
  278. abstract="true" native="false" synchronized="false"
  279. static="false" final="false" visibility="public"
  280. deprecated="not deprecated">
  281. <param name="appStatus" type="org.apache.hadoop.yarn.api.records.FinalApplicationStatus"/>
  282. <param name="appMessage" type="java.lang.String"/>
  283. <param name="appTrackingUrl" type="java.lang.String"/>
  284. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  285. <exception name="IOException" type="java.io.IOException"/>
  286. <doc>
  287. <![CDATA[Unregister the application master. This must be called in the end.
  288. @param appStatus Success/Failure status of the master
  289. @param appMessage Diagnostics message on failure
  290. @param appTrackingUrl New URL to get master info
  291. @throws YarnException
  292. @throws IOException]]>
  293. </doc>
  294. </method>
  295. <method name="addContainerRequest"
  296. abstract="true" native="false" synchronized="false"
  297. static="false" final="false" visibility="public"
  298. deprecated="not deprecated">
  299. <param name="req" type="T"/>
  300. <doc>
  301. <![CDATA[Request containers for resources before calling <code>allocate</code>
  302. @param req Resource request]]>
  303. </doc>
  304. </method>
  305. <method name="removeContainerRequest"
  306. abstract="true" native="false" synchronized="false"
  307. static="false" final="false" visibility="public"
  308. deprecated="not deprecated">
  309. <param name="req" type="T"/>
  310. <doc>
  311. <![CDATA[Remove previous container request. The previous container request may have
  312. already been sent to the ResourceManager. So even after the remove request
  313. the app must be prepared to receive an allocation for the previous request
  314. even after the remove request
  315. @param req Resource request]]>
  316. </doc>
  317. </method>
  318. <method name="requestContainerResourceChange"
  319. abstract="false" native="false" synchronized="false"
  320. static="false" final="false" visibility="public"
  321. deprecated="use
  322. {@link #requestContainerUpdate(Container, UpdateContainerRequest)}">
  323. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  324. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  325. <doc>
  326. <![CDATA[Request container resource change before calling <code>allocate</code>.
  327. Any previous pending resource change request of the same container will be
  328. removed.
  329. Application that calls this method is expected to maintain the
  330. <code>Container</code>s that are returned from previous successful
  331. allocations or resource changes. By passing in the existing container and a
  332. target resource capability to this method, the application requests the
  333. ResourceManager to change the existing resource allocation to the target
  334. resource allocation.
  335. @deprecated use
  336. {@link #requestContainerUpdate(Container, UpdateContainerRequest)}
  337. @param container The container returned from the last successful resource
  338. allocation or resource change
  339. @param capability The target resource capability of the container]]>
  340. </doc>
  341. </method>
  342. <method name="requestContainerUpdate"
  343. abstract="true" native="false" synchronized="false"
  344. static="false" final="false" visibility="public"
  345. deprecated="not deprecated">
  346. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  347. <param name="updateContainerRequest" type="org.apache.hadoop.yarn.api.records.UpdateContainerRequest"/>
  348. <doc>
  349. <![CDATA[Request a container update before calling <code>allocate</code>.
  350. Any previous pending update request of the same container will be
  351. removed.
  352. @param container The container returned from the last successful resource
  353. allocation or update
  354. @param updateContainerRequest The <code>UpdateContainerRequest</code>.]]>
  355. </doc>
  356. </method>
  357. <method name="releaseAssignedContainer"
  358. abstract="true" native="false" synchronized="false"
  359. static="false" final="false" visibility="public"
  360. deprecated="not deprecated">
  361. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  362. <doc>
  363. <![CDATA[Release containers assigned by the Resource Manager. If the app cannot use
  364. the container or wants to give up the container then it can release them.
  365. The app needs to make new requests for the released resource capability if
  366. it still needs it. eg. it released non-local resources
  367. @param containerId]]>
  368. </doc>
  369. </method>
  370. <method name="getAvailableResources" return="org.apache.hadoop.yarn.api.records.Resource"
  371. abstract="true" native="false" synchronized="false"
  372. static="false" final="false" visibility="public"
  373. deprecated="not deprecated">
  374. <doc>
  375. <![CDATA[Get the currently available resources in the cluster.
  376. A valid value is available after a call to allocate has been made
  377. @return Currently available resources]]>
  378. </doc>
  379. </method>
  380. <method name="getClusterNodeCount" return="int"
  381. abstract="true" native="false" synchronized="false"
  382. static="false" final="false" visibility="public"
  383. deprecated="not deprecated">
  384. <doc>
  385. <![CDATA[Get the current number of nodes in the cluster.
  386. A valid values is available after a call to allocate has been made
  387. @return Current number of nodes in the cluster]]>
  388. </doc>
  389. </method>
  390. <method name="getMatchingRequests" return="java.util.List"
  391. abstract="true" native="false" synchronized="false"
  392. static="false" final="false" visibility="public"
  393. deprecated="not deprecated">
  394. <param name="priority" type="org.apache.hadoop.yarn.api.records.Priority"/>
  395. <param name="resourceName" type="java.lang.String"/>
  396. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  397. <doc>
  398. <![CDATA[Get outstanding <code>ContainerRequest</code>s matching the given
  399. parameters. These ContainerRequests should have been added via
  400. <code>addContainerRequest</code> earlier in the lifecycle. For performance,
  401. the AMRMClient may return its internal collection directly without creating
  402. a copy. Users should not perform mutable operations on the return value.
  403. Each collection in the list contains requests with identical
  404. <code>Resource</code> size that fit in the given capability. In a
  405. collection, requests will be returned in the same order as they were added.
  406. NOTE: This API only matches Container requests that were created by the
  407. client WITHOUT the allocationRequestId being set.
  408. @return Collection of request matching the parameters]]>
  409. </doc>
  410. </method>
  411. <method name="getMatchingRequests" return="java.util.List"
  412. abstract="false" native="false" synchronized="false"
  413. static="false" final="false" visibility="public"
  414. deprecated="not deprecated">
  415. <param name="priority" type="org.apache.hadoop.yarn.api.records.Priority"/>
  416. <param name="resourceName" type="java.lang.String"/>
  417. <param name="executionType" type="org.apache.hadoop.yarn.api.records.ExecutionType"/>
  418. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  419. <doc>
  420. <![CDATA[Get outstanding <code>ContainerRequest</code>s matching the given
  421. parameters. These ContainerRequests should have been added via
  422. <code>addContainerRequest</code> earlier in the lifecycle. For performance,
  423. the AMRMClient may return its internal collection directly without creating
  424. a copy. Users should not perform mutable operations on the return value.
  425. Each collection in the list contains requests with identical
  426. <code>Resource</code> size that fit in the given capability. In a
  427. collection, requests will be returned in the same order as they were added.
  428. specify an <code>ExecutionType</code>.
  429. NOTE: This API only matches Container requests that were created by the
  430. client WITHOUT the allocationRequestId being set.
  431. @param priority Priority
  432. @param resourceName Location
  433. @param executionType ExecutionType
  434. @param capability Capability
  435. @return Collection of request matching the parameters]]>
  436. </doc>
  437. </method>
  438. <method name="getMatchingRequests" return="java.util.List"
  439. abstract="false" native="false" synchronized="false"
  440. static="false" final="false" visibility="public"
  441. deprecated="not deprecated">
  442. <param name="priority" type="org.apache.hadoop.yarn.api.records.Priority"/>
  443. <param name="resourceName" type="java.lang.String"/>
  444. <param name="executionType" type="org.apache.hadoop.yarn.api.records.ExecutionType"/>
  445. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  446. <param name="profile" type="java.lang.String"/>
  447. </method>
  448. <method name="getMatchingRequests" return="java.util.Collection"
  449. abstract="true" native="false" synchronized="false"
  450. static="false" final="false" visibility="public"
  451. deprecated="not deprecated">
  452. <param name="allocationRequestId" type="long"/>
  453. <doc>
  454. <![CDATA[Get outstanding <code>ContainerRequest</code>s matching the given
  455. allocationRequestId. These ContainerRequests should have been added via
  456. <code>addContainerRequest</code> earlier in the lifecycle. For performance,
  457. the AMRMClient may return its internal collection directly without creating
  458. a copy. Users should not perform mutable operations on the return value.
  459. NOTE: This API only matches Container requests that were created by the
  460. client WITH the allocationRequestId being set to a non-default value.
  461. @param allocationRequestId Allocation Request Id
  462. @return Collection of request matching the parameters]]>
  463. </doc>
  464. </method>
  465. <method name="updateBlacklist"
  466. abstract="true" native="false" synchronized="false"
  467. static="false" final="false" visibility="public"
  468. deprecated="not deprecated">
  469. <param name="blacklistAdditions" type="java.util.List"/>
  470. <param name="blacklistRemovals" type="java.util.List"/>
  471. <doc>
  472. <![CDATA[Update application's blacklist with addition or removal resources.
  473. @param blacklistAdditions list of resources which should be added to the
  474. application blacklist
  475. @param blacklistRemovals list of resources which should be removed from the
  476. application blacklist]]>
  477. </doc>
  478. </method>
  479. <method name="setNMTokenCache"
  480. abstract="false" native="false" synchronized="false"
  481. static="false" final="false" visibility="public"
  482. deprecated="not deprecated">
  483. <param name="nmTokenCache" type="org.apache.hadoop.yarn.client.api.NMTokenCache"/>
  484. <doc>
  485. <![CDATA[Set the NM token cache for the <code>AMRMClient</code>. This cache must
  486. be shared with the {@link NMClient} used to manage containers for the
  487. <code>AMRMClient</code>
  488. <p>
  489. If a NM token cache is not set, the {@link NMTokenCache#getSingleton()}
  490. singleton instance will be used.
  491. @param nmTokenCache the NM token cache to use.]]>
  492. </doc>
  493. </method>
  494. <method name="getNMTokenCache" return="org.apache.hadoop.yarn.client.api.NMTokenCache"
  495. abstract="false" native="false" synchronized="false"
  496. static="false" final="false" visibility="public"
  497. deprecated="not deprecated">
  498. <doc>
  499. <![CDATA[Get the NM token cache of the <code>AMRMClient</code>. This cache must be
  500. shared with the {@link NMClient} used to manage containers for the
  501. <code>AMRMClient</code>.
  502. <p>
  503. If a NM token cache is not set, the {@link NMTokenCache#getSingleton()}
  504. singleton instance will be used.
  505. @return the NM token cache.]]>
  506. </doc>
  507. </method>
  508. <method name="registerTimelineV2Client"
  509. abstract="false" native="false" synchronized="false"
  510. static="false" final="false" visibility="public"
  511. deprecated="not deprecated">
  512. <param name="client" type="org.apache.hadoop.yarn.client.api.TimelineV2Client"/>
  513. <doc>
  514. <![CDATA[Register TimelineV2Client to AMRMClient. Writer's address for the timeline
  515. V2 client will be updated dynamically if registered.
  516. @param client the timeline v2 client to register]]>
  517. </doc>
  518. </method>
  519. <method name="getRegisteredTimelineV2Client" return="org.apache.hadoop.yarn.client.api.TimelineV2Client"
  520. abstract="false" native="false" synchronized="false"
  521. static="false" final="false" visibility="public"
  522. deprecated="not deprecated">
  523. <doc>
  524. <![CDATA[Get registered timeline v2 client.
  525. @return the registered timeline v2 client]]>
  526. </doc>
  527. </method>
  528. <method name="updateTrackingUrl"
  529. abstract="false" native="false" synchronized="false"
  530. static="false" final="false" visibility="public"
  531. deprecated="not deprecated">
  532. <param name="trackingUrl" type="java.lang.String"/>
  533. <doc>
  534. <![CDATA[Update application's tracking url on next heartbeat.
  535. @param trackingUrl new tracking url for this application]]>
  536. </doc>
  537. </method>
  538. <method name="waitFor"
  539. abstract="false" native="false" synchronized="false"
  540. static="false" final="false" visibility="public"
  541. deprecated="not deprecated">
  542. <param name="check" type="java.util.function.Supplier"/>
  543. <exception name="InterruptedException" type="java.lang.InterruptedException"/>
  544. <doc>
  545. <![CDATA[Wait for <code>check</code> to return true for each 1000 ms.
  546. See also {@link #waitFor(java.util.function.Supplier, int)}
  547. and {@link #waitFor(java.util.function.Supplier, int, int)}
  548. @param check the condition for which it should wait]]>
  549. </doc>
  550. </method>
  551. <method name="waitFor"
  552. abstract="false" native="false" synchronized="false"
  553. static="false" final="false" visibility="public"
  554. deprecated="not deprecated">
  555. <param name="check" type="java.util.function.Supplier"/>
  556. <param name="checkEveryMillis" type="int"/>
  557. <exception name="InterruptedException" type="java.lang.InterruptedException"/>
  558. <doc>
  559. <![CDATA[Wait for <code>check</code> to return true for each
  560. <code>checkEveryMillis</code> ms.
  561. See also {@link #waitFor(java.util.function.Supplier, int, int)}
  562. @param check user defined checker
  563. @param checkEveryMillis interval to call <code>check</code>]]>
  564. </doc>
  565. </method>
  566. <method name="waitFor"
  567. abstract="false" native="false" synchronized="false"
  568. static="false" final="false" visibility="public"
  569. deprecated="not deprecated">
  570. <param name="check" type="java.util.function.Supplier"/>
  571. <param name="checkEveryMillis" type="int"/>
  572. <param name="logInterval" type="int"/>
  573. <exception name="InterruptedException" type="java.lang.InterruptedException"/>
  574. <doc>
  575. <![CDATA[Wait for <code>check</code> to return true for each
  576. <code>checkEveryMillis</code> ms. In the main loop, this method will log
  577. the message "waiting in main loop" for each <code>logInterval</code> times
  578. iteration to confirm the thread is alive.
  579. @param check user defined checker
  580. @param checkEveryMillis interval to call <code>check</code>
  581. @param logInterval interval to log for each]]>
  582. </doc>
  583. </method>
  584. </class>
  585. <!-- end class org.apache.hadoop.yarn.client.api.AMRMClient -->
  586. <!-- start class org.apache.hadoop.yarn.client.api.NMClient -->
  587. <class name="NMClient" extends="org.apache.hadoop.service.AbstractService"
  588. abstract="true"
  589. static="false" final="false" visibility="public"
  590. deprecated="not deprecated">
  591. <constructor name="NMClient" type="java.lang.String"
  592. static="false" final="false" visibility="protected"
  593. deprecated="not deprecated">
  594. </constructor>
  595. <method name="createNMClient" return="org.apache.hadoop.yarn.client.api.NMClient"
  596. abstract="false" native="false" synchronized="false"
  597. static="true" final="false" visibility="public"
  598. deprecated="not deprecated">
  599. <doc>
  600. <![CDATA[Create a new instance of NMClient.]]>
  601. </doc>
  602. </method>
  603. <method name="createNMClient" return="org.apache.hadoop.yarn.client.api.NMClient"
  604. abstract="false" native="false" synchronized="false"
  605. static="true" final="false" visibility="public"
  606. deprecated="not deprecated">
  607. <param name="name" type="java.lang.String"/>
  608. <doc>
  609. <![CDATA[Create a new instance of NMClient.]]>
  610. </doc>
  611. </method>
  612. <method name="startContainer" return="java.util.Map"
  613. abstract="true" native="false" synchronized="false"
  614. static="false" final="false" visibility="public"
  615. deprecated="not deprecated">
  616. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  617. <param name="containerLaunchContext" type="org.apache.hadoop.yarn.api.records.ContainerLaunchContext"/>
  618. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  619. <exception name="IOException" type="java.io.IOException"/>
  620. <doc>
  621. <![CDATA[<p>Start an allocated container.</p>
  622. <p>The <code>ApplicationMaster</code> or other applications that use the
  623. client must provide the details of the allocated container, including the
  624. Id, the assigned node's Id and the token via {@link Container}. In
  625. addition, the AM needs to provide the {@link ContainerLaunchContext} as
  626. well.</p>
  627. @param container the allocated container
  628. @param containerLaunchContext the context information needed by the
  629. <code>NodeManager</code> to launch the
  630. container
  631. @return a map between the auxiliary service names and their outputs
  632. @throws YarnException YarnException.
  633. @throws IOException IOException.]]>
  634. </doc>
  635. </method>
  636. <method name="increaseContainerResource"
  637. abstract="true" native="false" synchronized="false"
  638. static="false" final="false" visibility="public"
  639. deprecated="not deprecated">
  640. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  641. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  642. <exception name="IOException" type="java.io.IOException"/>
  643. <doc>
  644. <![CDATA[<p>Increase the resource of a container.</p>
  645. <p>The <code>ApplicationMaster</code> or other applications that use the
  646. client must provide the details of the container, including the Id and
  647. the target resource encapsulated in the updated container token via
  648. {@link Container}.
  649. </p>
  650. @param container the container with updated token.
  651. @throws YarnException YarnException.
  652. @throws IOException IOException.]]>
  653. </doc>
  654. </method>
  655. <method name="updateContainerResource"
  656. abstract="true" native="false" synchronized="false"
  657. static="false" final="false" visibility="public"
  658. deprecated="not deprecated">
  659. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  660. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  661. <exception name="IOException" type="java.io.IOException"/>
  662. <doc>
  663. <![CDATA[<p>Update the resources of a container.</p>
  664. <p>The <code>ApplicationMaster</code> or other applications that use the
  665. client must provide the details of the container, including the Id and
  666. the target resource encapsulated in the updated container token via
  667. {@link Container}.
  668. </p>
  669. @param container the container with updated token.
  670. @throws YarnException YarnException.
  671. @throws IOException IOException.]]>
  672. </doc>
  673. </method>
  674. <method name="stopContainer"
  675. abstract="true" native="false" synchronized="false"
  676. static="false" final="false" visibility="public"
  677. deprecated="not deprecated">
  678. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  679. <param name="nodeId" type="org.apache.hadoop.yarn.api.records.NodeId"/>
  680. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  681. <exception name="IOException" type="java.io.IOException"/>
  682. <doc>
  683. <![CDATA[<p>Stop an started container.</p>
  684. @param containerId the Id of the started container
  685. @param nodeId the Id of the <code>NodeManager</code>
  686. @throws YarnException YarnException.
  687. @throws IOException IOException.]]>
  688. </doc>
  689. </method>
  690. <method name="getContainerStatus" return="org.apache.hadoop.yarn.api.records.ContainerStatus"
  691. abstract="true" native="false" synchronized="false"
  692. static="false" final="false" visibility="public"
  693. deprecated="not deprecated">
  694. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  695. <param name="nodeId" type="org.apache.hadoop.yarn.api.records.NodeId"/>
  696. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  697. <exception name="IOException" type="java.io.IOException"/>
  698. <doc>
  699. <![CDATA[<p>Query the status of a container.</p>
  700. @param containerId the Id of the started container
  701. @param nodeId the Id of the <code>NodeManager</code>
  702. @return the status of a container.
  703. @throws YarnException YarnException.
  704. @throws IOException IOException.]]>
  705. </doc>
  706. </method>
  707. <method name="reInitializeContainer"
  708. abstract="true" native="false" synchronized="false"
  709. static="false" final="false" visibility="public"
  710. deprecated="not deprecated">
  711. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  712. <param name="containerLaunchContex" type="org.apache.hadoop.yarn.api.records.ContainerLaunchContext"/>
  713. <param name="autoCommit" type="boolean"/>
  714. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  715. <exception name="IOException" type="java.io.IOException"/>
  716. <doc>
  717. <![CDATA[<p>Re-Initialize the Container.</p>
  718. @param containerId the Id of the container to Re-Initialize.
  719. @param containerLaunchContex the updated ContainerLaunchContext.
  720. @param autoCommit commit re-initialization automatically ?
  721. @throws YarnException YarnException.
  722. @throws IOException IOException.]]>
  723. </doc>
  724. </method>
  725. <method name="restartContainer"
  726. abstract="true" native="false" synchronized="false"
  727. static="false" final="false" visibility="public"
  728. deprecated="not deprecated">
  729. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  730. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  731. <exception name="IOException" type="java.io.IOException"/>
  732. <doc>
  733. <![CDATA[<p>Restart the specified container.</p>
  734. @param containerId the Id of the container to restart.
  735. @throws YarnException YarnException.
  736. @throws IOException IOException.]]>
  737. </doc>
  738. </method>
  739. <method name="rollbackLastReInitialization"
  740. abstract="true" native="false" synchronized="false"
  741. static="false" final="false" visibility="public"
  742. deprecated="not deprecated">
  743. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  744. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  745. <exception name="IOException" type="java.io.IOException"/>
  746. <doc>
  747. <![CDATA[<p>Rollback last reInitialization of the specified container.</p>
  748. @param containerId the Id of the container to restart.
  749. @throws YarnException YarnException.
  750. @throws IOException IOException.]]>
  751. </doc>
  752. </method>
  753. <method name="commitLastReInitialization"
  754. abstract="true" native="false" synchronized="false"
  755. static="false" final="false" visibility="public"
  756. deprecated="not deprecated">
  757. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  758. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  759. <exception name="IOException" type="java.io.IOException"/>
  760. <doc>
  761. <![CDATA[<p>Commit last reInitialization of the specified container.</p>
  762. @param containerId the Id of the container to commit reInitialize.
  763. @throws YarnException YarnException.
  764. @throws IOException IOException.]]>
  765. </doc>
  766. </method>
  767. <method name="cleanupRunningContainersOnStop"
  768. abstract="true" native="false" synchronized="false"
  769. static="false" final="false" visibility="public"
  770. deprecated="not deprecated">
  771. <param name="enabled" type="boolean"/>
  772. <doc>
  773. <![CDATA[<p>Set whether the containers that are started by this client, and are
  774. still running should be stopped when the client stops. By default, the
  775. feature should be enabled.</p> However, containers will be stopped only
  776. when service is stopped. i.e. after {@link NMClient#stop()}.
  777. @param enabled whether the feature is enabled or not]]>
  778. </doc>
  779. </method>
  780. <method name="setNMTokenCache"
  781. abstract="false" native="false" synchronized="false"
  782. static="false" final="false" visibility="public"
  783. deprecated="not deprecated">
  784. <param name="nmTokenCache" type="org.apache.hadoop.yarn.client.api.NMTokenCache"/>
  785. <doc>
  786. <![CDATA[Set the NM Token cache of the <code>NMClient</code>. This cache must be
  787. shared with the {@link AMRMClient} that requested the containers managed
  788. by this <code>NMClient</code>
  789. <p>
  790. If a NM token cache is not set, the {@link NMTokenCache#getSingleton()}
  791. singleton instance will be used.
  792. @param nmTokenCache the NM token cache to use.]]>
  793. </doc>
  794. </method>
  795. <method name="getNMTokenCache" return="org.apache.hadoop.yarn.client.api.NMTokenCache"
  796. abstract="false" native="false" synchronized="false"
  797. static="false" final="false" visibility="public"
  798. deprecated="not deprecated">
  799. <doc>
  800. <![CDATA[Get the NM token cache of the <code>NMClient</code>. This cache must be
  801. shared with the {@link AMRMClient} that requested the containers managed
  802. by this <code>NMClient</code>
  803. <p>
  804. If a NM token cache is not set, the {@link NMTokenCache#getSingleton()}
  805. singleton instance will be used.
  806. @return the NM token cache]]>
  807. </doc>
  808. </method>
  809. <method name="getNodeIdOfStartedContainer" return="org.apache.hadoop.yarn.api.records.NodeId"
  810. abstract="false" native="false" synchronized="false"
  811. static="false" final="false" visibility="public"
  812. deprecated="not deprecated">
  813. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  814. <doc>
  815. <![CDATA[Get the NodeId of the node on which container is running. It returns
  816. null if the container if container is not found or if it is not running.
  817. @param containerId Container Id of the container.
  818. @return NodeId of the container on which it is running.]]>
  819. </doc>
  820. </method>
  821. </class>
  822. <!-- end class org.apache.hadoop.yarn.client.api.NMClient -->
  823. <!-- start class org.apache.hadoop.yarn.client.api.NMTokenCache -->
  824. <class name="NMTokenCache" extends="java.lang.Object"
  825. abstract="false"
  826. static="false" final="false" visibility="public"
  827. deprecated="not deprecated">
  828. <constructor name="NMTokenCache"
  829. static="false" final="false" visibility="public"
  830. deprecated="not deprecated">
  831. <doc>
  832. <![CDATA[Creates a NM token cache instance.]]>
  833. </doc>
  834. </constructor>
  835. <method name="getSingleton" return="org.apache.hadoop.yarn.client.api.NMTokenCache"
  836. abstract="false" native="false" synchronized="false"
  837. static="true" final="false" visibility="public"
  838. deprecated="not deprecated">
  839. <doc>
  840. <![CDATA[Returns the singleton NM token cache.
  841. @return the singleton NM token cache.]]>
  842. </doc>
  843. </method>
  844. <method name="getNMToken" return="org.apache.hadoop.yarn.api.records.Token"
  845. abstract="false" native="false" synchronized="false"
  846. static="true" final="false" visibility="public"
  847. deprecated="not deprecated">
  848. <param name="nodeAddr" type="java.lang.String"/>
  849. <doc>
  850. <![CDATA[Returns NMToken, null if absent. Only the singleton obtained from
  851. {@link #getSingleton()} is looked at for the tokens. If you are using your
  852. own NMTokenCache that is different from the singleton, use
  853. {@link #getToken(String) }
  854. @param nodeAddr
  855. @return {@link Token} NMToken required for communicating with node manager]]>
  856. </doc>
  857. </method>
  858. <method name="setNMToken"
  859. abstract="false" native="false" synchronized="false"
  860. static="true" final="false" visibility="public"
  861. deprecated="not deprecated">
  862. <param name="nodeAddr" type="java.lang.String"/>
  863. <param name="token" type="org.apache.hadoop.yarn.api.records.Token"/>
  864. <doc>
  865. <![CDATA[Sets the NMToken for node address only in the singleton obtained from
  866. {@link #getSingleton()}. If you are using your own NMTokenCache that is
  867. different from the singleton, use {@link #setToken(String, Token) }
  868. @param nodeAddr
  869. node address (host:port)
  870. @param token
  871. NMToken]]>
  872. </doc>
  873. </method>
  874. <method name="getToken" return="org.apache.hadoop.yarn.api.records.Token"
  875. abstract="false" native="false" synchronized="false"
  876. static="false" final="false" visibility="public"
  877. deprecated="not deprecated">
  878. <param name="nodeAddr" type="java.lang.String"/>
  879. <doc>
  880. <![CDATA[Returns NMToken, null if absent
  881. @param nodeAddr
  882. @return {@link Token} NMToken required for communicating with node
  883. manager]]>
  884. </doc>
  885. </method>
  886. <method name="setToken"
  887. abstract="false" native="false" synchronized="false"
  888. static="false" final="false" visibility="public"
  889. deprecated="not deprecated">
  890. <param name="nodeAddr" type="java.lang.String"/>
  891. <param name="token" type="org.apache.hadoop.yarn.api.records.Token"/>
  892. <doc>
  893. <![CDATA[Sets the NMToken for node address
  894. @param nodeAddr node address (host:port)
  895. @param token NMToken]]>
  896. </doc>
  897. </method>
  898. <doc>
  899. <![CDATA[NMTokenCache manages NMTokens required for an Application Master
  900. communicating with individual NodeManagers.
  901. <p>
  902. By default YARN client libraries {@link AMRMClient} and {@link NMClient} use
  903. {@link #getSingleton()} instance of the cache.
  904. <ul>
  905. <li>
  906. Using the singleton instance of the cache is appropriate when running a
  907. single ApplicationMaster in the same JVM.
  908. </li>
  909. <li>
  910. When using the singleton, users don't need to do anything special,
  911. {@link AMRMClient} and {@link NMClient} are already set up to use the
  912. default singleton {@link NMTokenCache}
  913. </li>
  914. </ul>
  915. If running multiple Application Masters in the same JVM, a different cache
  916. instance should be used for each Application Master.
  917. <ul>
  918. <li>
  919. If using the {@link AMRMClient} and the {@link NMClient}, setting up
  920. and using an instance cache is as follows:
  921. <pre>
  922. NMTokenCache nmTokenCache = new NMTokenCache();
  923. AMRMClient rmClient = AMRMClient.createAMRMClient();
  924. NMClient nmClient = NMClient.createNMClient();
  925. nmClient.setNMTokenCache(nmTokenCache);
  926. ...
  927. </pre>
  928. </li>
  929. <li>
  930. If using the {@link AMRMClientAsync} and the {@link NMClientAsync},
  931. setting up and using an instance cache is as follows:
  932. <pre>
  933. NMTokenCache nmTokenCache = new NMTokenCache();
  934. AMRMClient rmClient = AMRMClient.createAMRMClient();
  935. NMClient nmClient = NMClient.createNMClient();
  936. nmClient.setNMTokenCache(nmTokenCache);
  937. AMRMClientAsync rmClientAsync = new AMRMClientAsync(rmClient, 1000, [AMRM_CALLBACK]);
  938. NMClientAsync nmClientAsync = new NMClientAsync("nmClient", nmClient, [NM_CALLBACK]);
  939. ...
  940. </pre>
  941. </li>
  942. <li>
  943. If using {@link ApplicationMasterProtocol} and
  944. {@link ContainerManagementProtocol} directly, setting up and using an
  945. instance cache is as follows:
  946. <pre>
  947. NMTokenCache nmTokenCache = new NMTokenCache();
  948. ...
  949. ApplicationMasterProtocol amPro = ClientRMProxy.createRMProxy(conf, ApplicationMasterProtocol.class);
  950. ...
  951. AllocateRequest allocateRequest = ...
  952. ...
  953. AllocateResponse allocateResponse = rmClient.allocate(allocateRequest);
  954. for (NMToken token : allocateResponse.getNMTokens()) {
  955. nmTokenCache.setToken(token.getNodeId().toString(), token.getToken());
  956. }
  957. ...
  958. ContainerManagementProtocolProxy nmPro = ContainerManagementProtocolProxy(conf, nmTokenCache);
  959. ...
  960. nmPro.startContainer(container, containerContext);
  961. ...
  962. </pre>
  963. </li>
  964. </ul>
  965. It is also possible to mix the usage of a client ({@code AMRMClient} or
  966. {@code NMClient}, or the async versions of them) with a protocol proxy
  967. ({@code ContainerManagementProtocolProxy} or
  968. {@code ApplicationMasterProtocol}).]]>
  969. </doc>
  970. </class>
  971. <!-- end class org.apache.hadoop.yarn.client.api.NMTokenCache -->
  972. <!-- start class org.apache.hadoop.yarn.client.api.SharedCacheClient -->
  973. <class name="SharedCacheClient" extends="org.apache.hadoop.service.AbstractService"
  974. abstract="true"
  975. static="false" final="false" visibility="public"
  976. deprecated="not deprecated">
  977. <constructor name="SharedCacheClient" type="java.lang.String"
  978. static="false" final="false" visibility="public"
  979. deprecated="not deprecated">
  980. </constructor>
  981. <method name="createSharedCacheClient" return="org.apache.hadoop.yarn.client.api.SharedCacheClient"
  982. abstract="false" native="false" synchronized="false"
  983. static="true" final="false" visibility="public"
  984. deprecated="not deprecated">
  985. </method>
  986. <method name="use" return="org.apache.hadoop.yarn.api.records.URL"
  987. abstract="true" native="false" synchronized="false"
  988. static="false" final="false" visibility="public"
  989. deprecated="not deprecated">
  990. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  991. <param name="resourceKey" type="java.lang.String"/>
  992. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  993. <doc>
  994. <![CDATA[<p>
  995. The method to claim a resource with the <code>SharedCacheManager.</code>
  996. The client uses a checksum to identify the resource and an
  997. {@link ApplicationId} to identify which application will be using the
  998. resource.
  999. </p>
  1000. <p>
  1001. The <code>SharedCacheManager</code> responds with whether or not the
  1002. resource exists in the cache. If the resource exists, a <code>URL</code> to
  1003. the resource in the shared cache is returned. If the resource does not
  1004. exist, null is returned instead.
  1005. </p>
  1006. <p>
  1007. Once a URL has been returned for a resource, that URL is safe to use for
  1008. the lifetime of the application that corresponds to the provided
  1009. ApplicationId.
  1010. </p>
  1011. @param applicationId ApplicationId of the application using the resource
  1012. @param resourceKey the key (i.e. checksum) that identifies the resource
  1013. @return URL to the resource, or null if it does not exist]]>
  1014. </doc>
  1015. </method>
  1016. <method name="release"
  1017. abstract="true" native="false" synchronized="false"
  1018. static="false" final="false" visibility="public"
  1019. deprecated="not deprecated">
  1020. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1021. <param name="resourceKey" type="java.lang.String"/>
  1022. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1023. <doc>
  1024. <![CDATA[<p>
  1025. The method to release a resource with the <code>SharedCacheManager.</code>
  1026. This method is called once an application is no longer using a claimed
  1027. resource in the shared cache. The client uses a checksum to identify the
  1028. resource and an {@link ApplicationId} to identify which application is
  1029. releasing the resource.
  1030. </p>
  1031. <p>
  1032. Note: This method is an optimization and the client is not required to call
  1033. it for correctness.
  1034. </p>
  1035. @param applicationId ApplicationId of the application releasing the
  1036. resource
  1037. @param resourceKey the key (i.e. checksum) that identifies the resource]]>
  1038. </doc>
  1039. </method>
  1040. <method name="getFileChecksum" return="java.lang.String"
  1041. abstract="true" native="false" synchronized="false"
  1042. static="false" final="false" visibility="public"
  1043. deprecated="not deprecated">
  1044. <param name="sourceFile" type="org.apache.hadoop.fs.Path"/>
  1045. <exception name="IOException" type="java.io.IOException"/>
  1046. <doc>
  1047. <![CDATA[A convenience method to calculate the checksum of a specified file.
  1048. @param sourceFile A path to the input file
  1049. @return A hex string containing the checksum digest
  1050. @throws IOException]]>
  1051. </doc>
  1052. </method>
  1053. <doc>
  1054. <![CDATA[This is the client for YARN's shared cache.]]>
  1055. </doc>
  1056. </class>
  1057. <!-- end class org.apache.hadoop.yarn.client.api.SharedCacheClient -->
  1058. <!-- start class org.apache.hadoop.yarn.client.api.YarnClient -->
  1059. <class name="YarnClient" extends="org.apache.hadoop.service.AbstractService"
  1060. abstract="true"
  1061. static="false" final="false" visibility="public"
  1062. deprecated="not deprecated">
  1063. <constructor name="YarnClient" type="java.lang.String"
  1064. static="false" final="false" visibility="protected"
  1065. deprecated="not deprecated">
  1066. </constructor>
  1067. <method name="createYarnClient" return="org.apache.hadoop.yarn.client.api.YarnClient"
  1068. abstract="false" native="false" synchronized="false"
  1069. static="true" final="false" visibility="public"
  1070. deprecated="not deprecated">
  1071. <doc>
  1072. <![CDATA[Create a new instance of YarnClient.]]>
  1073. </doc>
  1074. </method>
  1075. <method name="createApplication" return="org.apache.hadoop.yarn.client.api.YarnClientApplication"
  1076. abstract="true" native="false" synchronized="false"
  1077. static="false" final="false" visibility="public"
  1078. deprecated="not deprecated">
  1079. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1080. <exception name="IOException" type="java.io.IOException"/>
  1081. <doc>
  1082. <![CDATA[<p>
  1083. Obtain a {@link YarnClientApplication} for a new application,
  1084. which in turn contains the {@link ApplicationSubmissionContext} and
  1085. {@link org.apache.hadoop.yarn.api.protocolrecords.GetNewApplicationResponse}
  1086. objects.
  1087. </p>
  1088. @return {@link YarnClientApplication} built for a new application
  1089. @throws YarnException
  1090. @throws IOException]]>
  1091. </doc>
  1092. </method>
  1093. <method name="submitApplication" return="org.apache.hadoop.yarn.api.records.ApplicationId"
  1094. abstract="true" native="false" synchronized="false"
  1095. static="false" final="false" visibility="public"
  1096. deprecated="not deprecated">
  1097. <param name="appContext" type="org.apache.hadoop.yarn.api.records.ApplicationSubmissionContext"/>
  1098. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1099. <exception name="IOException" type="java.io.IOException"/>
  1100. <doc>
  1101. <![CDATA[<p>
  1102. Submit a new application to <code>YARN.</code> It is a blocking call - it
  1103. will not return {@link ApplicationId} until the submitted application is
  1104. submitted successfully and accepted by the ResourceManager.
  1105. </p>
  1106. <p>
  1107. Users should provide an {@link ApplicationId} as part of the parameter
  1108. {@link ApplicationSubmissionContext} when submitting a new application,
  1109. otherwise it will throw the {@link ApplicationIdNotProvidedException}.
  1110. </p>
  1111. <p>This internally calls {@link ApplicationClientProtocol#submitApplication
  1112. (SubmitApplicationRequest)}, and after that, it internally invokes
  1113. {@link ApplicationClientProtocol#getApplicationReport
  1114. (GetApplicationReportRequest)} and waits till it can make sure that the
  1115. application gets properly submitted. If RM fails over or RM restart
  1116. happens before ResourceManager saves the application's state,
  1117. {@link ApplicationClientProtocol
  1118. #getApplicationReport(GetApplicationReportRequest)} will throw
  1119. the {@link ApplicationNotFoundException}. This API automatically resubmits
  1120. the application with the same {@link ApplicationSubmissionContext} when it
  1121. catches the {@link ApplicationNotFoundException}</p>
  1122. @param appContext
  1123. {@link ApplicationSubmissionContext} containing all the details
  1124. needed to submit a new application
  1125. @return {@link ApplicationId} of the accepted application
  1126. @throws YarnException
  1127. @throws IOException
  1128. @see #createApplication()]]>
  1129. </doc>
  1130. </method>
  1131. <method name="failApplicationAttempt"
  1132. abstract="true" native="false" synchronized="false"
  1133. static="false" final="false" visibility="public"
  1134. deprecated="not deprecated">
  1135. <param name="applicationAttemptId" type="org.apache.hadoop.yarn.api.records.ApplicationAttemptId"/>
  1136. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1137. <exception name="IOException" type="java.io.IOException"/>
  1138. <doc>
  1139. <![CDATA[<p>
  1140. Fail an application attempt identified by given ID.
  1141. </p>
  1142. @param applicationAttemptId
  1143. {@link ApplicationAttemptId} of the attempt to fail.
  1144. @throws YarnException
  1145. in case of errors or if YARN rejects the request due to
  1146. access-control restrictions.
  1147. @throws IOException
  1148. @see #getQueueAclsInfo()]]>
  1149. </doc>
  1150. </method>
  1151. <method name="killApplication"
  1152. abstract="true" native="false" synchronized="false"
  1153. static="false" final="false" visibility="public"
  1154. deprecated="not deprecated">
  1155. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1156. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1157. <exception name="IOException" type="java.io.IOException"/>
  1158. <doc>
  1159. <![CDATA[<p>
  1160. Kill an application identified by given ID.
  1161. </p>
  1162. @param applicationId
  1163. {@link ApplicationId} of the application that needs to be killed
  1164. @throws YarnException
  1165. in case of errors or if YARN rejects the request due to
  1166. access-control restrictions.
  1167. @throws IOException
  1168. @see #getQueueAclsInfo()]]>
  1169. </doc>
  1170. </method>
  1171. <method name="killApplication"
  1172. abstract="true" native="false" synchronized="false"
  1173. static="false" final="false" visibility="public"
  1174. deprecated="not deprecated">
  1175. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1176. <param name="diagnostics" type="java.lang.String"/>
  1177. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1178. <exception name="IOException" type="java.io.IOException"/>
  1179. <doc>
  1180. <![CDATA[<p>
  1181. Kill an application identified by given ID.
  1182. </p>
  1183. @param applicationId {@link ApplicationId} of the application that needs to
  1184. be killed
  1185. @param diagnostics for killing an application.
  1186. @throws YarnException in case of errors or if YARN rejects the request due
  1187. to access-control restrictions.
  1188. @throws IOException]]>
  1189. </doc>
  1190. </method>
  1191. <method name="getApplicationReport" return="org.apache.hadoop.yarn.api.records.ApplicationReport"
  1192. abstract="true" native="false" synchronized="false"
  1193. static="false" final="false" visibility="public"
  1194. deprecated="not deprecated">
  1195. <param name="appId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1196. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1197. <exception name="IOException" type="java.io.IOException"/>
  1198. <doc>
  1199. <![CDATA[<p>
  1200. Get a report of the given Application.
  1201. </p>
  1202. <p>
  1203. In secure mode, <code>YARN</code> verifies access to the application, queue
  1204. etc. before accepting the request.
  1205. </p>
  1206. <p>
  1207. If the user does not have <code>VIEW_APP</code> access then the following
  1208. fields in the report will be set to stubbed values:
  1209. <ul>
  1210. <li>host - set to "N/A"</li>
  1211. <li>RPC port - set to -1</li>
  1212. <li>client token - set to "N/A"</li>
  1213. <li>diagnostics - set to "N/A"</li>
  1214. <li>tracking URL - set to "N/A"</li>
  1215. <li>original tracking URL - set to "N/A"</li>
  1216. <li>resource usage report - all values are -1</li>
  1217. </ul>
  1218. @param appId
  1219. {@link ApplicationId} of the application that needs a report
  1220. @return application report
  1221. @throws YarnException
  1222. @throws IOException]]>
  1223. </doc>
  1224. </method>
  1225. <method name="getAMRMToken" return="org.apache.hadoop.security.token.Token"
  1226. abstract="true" native="false" synchronized="false"
  1227. static="false" final="false" visibility="public"
  1228. deprecated="not deprecated">
  1229. <param name="appId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1230. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1231. <exception name="IOException" type="java.io.IOException"/>
  1232. <doc>
  1233. <![CDATA[Get the AMRM token of the application.
  1234. <p>
  1235. The AMRM token is required for AM to RM scheduling operations. For
  1236. managed Application Masters YARN takes care of injecting it. For unmanaged
  1237. Applications Masters, the token must be obtained via this method and set
  1238. in the {@link org.apache.hadoop.security.UserGroupInformation} of the
  1239. current user.
  1240. <p>
  1241. The AMRM token will be returned only if all the following conditions are
  1242. met:
  1243. <ul>
  1244. <li>the requester is the owner of the ApplicationMaster</li>
  1245. <li>the application master is an unmanaged ApplicationMaster</li>
  1246. <li>the application master is in ACCEPTED state</li>
  1247. </ul>
  1248. Else this method returns NULL.
  1249. @param appId {@link ApplicationId} of the application to get the AMRM token
  1250. @return the AMRM token if available
  1251. @throws YarnException
  1252. @throws IOException]]>
  1253. </doc>
  1254. </method>
  1255. <method name="getApplications" return="java.util.List"
  1256. abstract="true" native="false" synchronized="false"
  1257. static="false" final="false" visibility="public"
  1258. deprecated="not deprecated">
  1259. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1260. <exception name="IOException" type="java.io.IOException"/>
  1261. <doc>
  1262. <![CDATA[<p>
  1263. Get a report (ApplicationReport) of all Applications in the cluster.
  1264. </p>
  1265. <p>
  1266. If the user does not have <code>VIEW_APP</code> access for an application
  1267. then the corresponding report will be filtered as described in
  1268. {@link #getApplicationReport(ApplicationId)}.
  1269. </p>
  1270. @return a list of reports of all running applications
  1271. @throws YarnException
  1272. @throws IOException]]>
  1273. </doc>
  1274. </method>
  1275. <method name="getApplications" return="java.util.List"
  1276. abstract="true" native="false" synchronized="false"
  1277. static="false" final="false" visibility="public"
  1278. deprecated="not deprecated">
  1279. <param name="applicationTypes" type="java.util.Set"/>
  1280. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1281. <exception name="IOException" type="java.io.IOException"/>
  1282. <doc>
  1283. <![CDATA[<p>
  1284. Get a report (ApplicationReport) of Applications
  1285. matching the given application types in the cluster.
  1286. </p>
  1287. <p>
  1288. If the user does not have <code>VIEW_APP</code> access for an application
  1289. then the corresponding report will be filtered as described in
  1290. {@link #getApplicationReport(ApplicationId)}.
  1291. </p>
  1292. @param applicationTypes set of application types you are interested in
  1293. @return a list of reports of applications
  1294. @throws YarnException
  1295. @throws IOException]]>
  1296. </doc>
  1297. </method>
  1298. <method name="getApplications" return="java.util.List"
  1299. abstract="true" native="false" synchronized="false"
  1300. static="false" final="false" visibility="public"
  1301. deprecated="not deprecated">
  1302. <param name="applicationStates" type="java.util.EnumSet"/>
  1303. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1304. <exception name="IOException" type="java.io.IOException"/>
  1305. <doc>
  1306. <![CDATA[<p>
  1307. Get a report (ApplicationReport) of Applications matching the given
  1308. application states in the cluster.
  1309. </p>
  1310. <p>
  1311. If the user does not have <code>VIEW_APP</code> access for an application
  1312. then the corresponding report will be filtered as described in
  1313. {@link #getApplicationReport(ApplicationId)}.
  1314. </p>
  1315. @param applicationStates set of application states you are interested in
  1316. @return a list of reports of applications
  1317. @throws YarnException
  1318. @throws IOException]]>
  1319. </doc>
  1320. </method>
  1321. <method name="getApplications" return="java.util.List"
  1322. abstract="true" native="false" synchronized="false"
  1323. static="false" final="false" visibility="public"
  1324. deprecated="not deprecated">
  1325. <param name="applicationTypes" type="java.util.Set"/>
  1326. <param name="applicationStates" type="java.util.EnumSet"/>
  1327. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1328. <exception name="IOException" type="java.io.IOException"/>
  1329. <doc>
  1330. <![CDATA[<p>
  1331. Get a report (ApplicationReport) of Applications matching the given
  1332. application types and application states in the cluster.
  1333. </p>
  1334. <p>
  1335. If the user does not have <code>VIEW_APP</code> access for an application
  1336. then the corresponding report will be filtered as described in
  1337. {@link #getApplicationReport(ApplicationId)}.
  1338. </p>
  1339. @param applicationTypes set of application types you are interested in
  1340. @param applicationStates set of application states you are interested in
  1341. @return a list of reports of applications
  1342. @throws YarnException
  1343. @throws IOException]]>
  1344. </doc>
  1345. </method>
  1346. <method name="getApplications" return="java.util.List"
  1347. abstract="true" native="false" synchronized="false"
  1348. static="false" final="false" visibility="public"
  1349. deprecated="not deprecated">
  1350. <param name="applicationTypes" type="java.util.Set"/>
  1351. <param name="applicationStates" type="java.util.EnumSet"/>
  1352. <param name="applicationTags" type="java.util.Set"/>
  1353. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1354. <exception name="IOException" type="java.io.IOException"/>
  1355. <doc>
  1356. <![CDATA[<p>
  1357. Get a report (ApplicationReport) of Applications matching the given
  1358. application types, application states and application tags in the cluster.
  1359. </p>
  1360. <p>
  1361. If the user does not have <code>VIEW_APP</code> access for an application
  1362. then the corresponding report will be filtered as described in
  1363. {@link #getApplicationReport(ApplicationId)}.
  1364. </p>
  1365. @param applicationTypes set of application types you are interested in
  1366. @param applicationStates set of application states you are interested in
  1367. @param applicationTags set of application tags you are interested in
  1368. @return a list of reports of applications
  1369. @throws YarnException
  1370. @throws IOException]]>
  1371. </doc>
  1372. </method>
  1373. <method name="getApplications" return="java.util.List"
  1374. abstract="true" native="false" synchronized="false"
  1375. static="false" final="false" visibility="public"
  1376. deprecated="not deprecated">
  1377. <param name="queues" type="java.util.Set"/>
  1378. <param name="users" type="java.util.Set"/>
  1379. <param name="applicationTypes" type="java.util.Set"/>
  1380. <param name="applicationStates" type="java.util.EnumSet"/>
  1381. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1382. <exception name="IOException" type="java.io.IOException"/>
  1383. <doc>
  1384. <![CDATA[<p>
  1385. Get a report (ApplicationReport) of Applications matching the given users,
  1386. queues, application types and application states in the cluster. If any of
  1387. the params is set to null, it is not used when filtering.
  1388. </p>
  1389. <p>
  1390. If the user does not have <code>VIEW_APP</code> access for an application
  1391. then the corresponding report will be filtered as described in
  1392. {@link #getApplicationReport(ApplicationId)}.
  1393. </p>
  1394. @param queues set of queues you are interested in
  1395. @param users set of users you are interested in
  1396. @param applicationTypes set of application types you are interested in
  1397. @param applicationStates set of application states you are interested in
  1398. @return a list of reports of applications
  1399. @throws YarnException
  1400. @throws IOException]]>
  1401. </doc>
  1402. </method>
  1403. <method name="getApplications" return="java.util.List"
  1404. abstract="false" native="false" synchronized="false"
  1405. static="false" final="false" visibility="public"
  1406. deprecated="not deprecated">
  1407. <param name="request" type="org.apache.hadoop.yarn.api.protocolrecords.GetApplicationsRequest"/>
  1408. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1409. <exception name="IOException" type="java.io.IOException"/>
  1410. <doc>
  1411. <![CDATA[<p>
  1412. Get a list of ApplicationReports that match the given
  1413. {@link GetApplicationsRequest}.
  1414. </p>
  1415. <p>
  1416. If the user does not have <code>VIEW_APP</code> access for an application
  1417. then the corresponding report will be filtered as described in
  1418. {@link #getApplicationReport(ApplicationId)}.
  1419. </p>
  1420. @param request the request object to get the list of applications.
  1421. @return The list of ApplicationReports that match the request
  1422. @throws YarnException Exception specific to YARN.
  1423. @throws IOException Exception mostly related to connection errors.]]>
  1424. </doc>
  1425. </method>
  1426. <method name="getYarnClusterMetrics" return="org.apache.hadoop.yarn.api.records.YarnClusterMetrics"
  1427. abstract="true" native="false" synchronized="false"
  1428. static="false" final="false" visibility="public"
  1429. deprecated="not deprecated">
  1430. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1431. <exception name="IOException" type="java.io.IOException"/>
  1432. <doc>
  1433. <![CDATA[<p>
  1434. Get metrics ({@link YarnClusterMetrics}) about the cluster.
  1435. </p>
  1436. @return cluster metrics
  1437. @throws YarnException
  1438. @throws IOException]]>
  1439. </doc>
  1440. </method>
  1441. <method name="getNodeReports" return="java.util.List"
  1442. abstract="true" native="false" synchronized="false"
  1443. static="false" final="false" visibility="public"
  1444. deprecated="not deprecated">
  1445. <param name="states" type="org.apache.hadoop.yarn.api.records.NodeState[]"/>
  1446. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1447. <exception name="IOException" type="java.io.IOException"/>
  1448. <doc>
  1449. <![CDATA[<p>
  1450. Get a report of nodes ({@link NodeReport}) in the cluster.
  1451. </p>
  1452. @param states The {@link NodeState}s to filter on. If no filter states are
  1453. given, nodes in all states will be returned.
  1454. @return A list of node reports
  1455. @throws YarnException
  1456. @throws IOException]]>
  1457. </doc>
  1458. </method>
  1459. <method name="getRMDelegationToken" return="org.apache.hadoop.yarn.api.records.Token"
  1460. abstract="true" native="false" synchronized="false"
  1461. static="false" final="false" visibility="public"
  1462. deprecated="not deprecated">
  1463. <param name="renewer" type="org.apache.hadoop.io.Text"/>
  1464. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1465. <exception name="IOException" type="java.io.IOException"/>
  1466. <doc>
  1467. <![CDATA[<p>
  1468. Get a delegation token so as to be able to talk to YARN using those tokens.
  1469. @param renewer
  1470. Address of the renewer who can renew these tokens when needed by
  1471. securely talking to YARN.
  1472. @return a delegation token ({@link Token}) that can be used to
  1473. talk to YARN
  1474. @throws YarnException
  1475. @throws IOException]]>
  1476. </doc>
  1477. </method>
  1478. <method name="getQueueInfo" return="org.apache.hadoop.yarn.api.records.QueueInfo"
  1479. abstract="true" native="false" synchronized="false"
  1480. static="false" final="false" visibility="public"
  1481. deprecated="not deprecated">
  1482. <param name="queueName" type="java.lang.String"/>
  1483. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1484. <exception name="IOException" type="java.io.IOException"/>
  1485. <doc>
  1486. <![CDATA[<p>
  1487. Get information ({@link QueueInfo}) about a given <em>queue</em>.
  1488. </p>
  1489. @param queueName
  1490. Name of the queue whose information is needed
  1491. @return queue information
  1492. @throws YarnException
  1493. in case of errors or if YARN rejects the request due to
  1494. access-control restrictions.
  1495. @throws IOException]]>
  1496. </doc>
  1497. </method>
  1498. <method name="getAllQueues" return="java.util.List"
  1499. abstract="true" native="false" synchronized="false"
  1500. static="false" final="false" visibility="public"
  1501. deprecated="not deprecated">
  1502. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1503. <exception name="IOException" type="java.io.IOException"/>
  1504. <doc>
  1505. <![CDATA[<p>
  1506. Get information ({@link QueueInfo}) about all queues, recursively if there
  1507. is a hierarchy
  1508. </p>
  1509. @return a list of queue-information for all queues
  1510. @throws YarnException
  1511. @throws IOException]]>
  1512. </doc>
  1513. </method>
  1514. <method name="getRootQueueInfos" return="java.util.List"
  1515. abstract="true" native="false" synchronized="false"
  1516. static="false" final="false" visibility="public"
  1517. deprecated="not deprecated">
  1518. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1519. <exception name="IOException" type="java.io.IOException"/>
  1520. <doc>
  1521. <![CDATA[<p>
  1522. Get information ({@link QueueInfo}) about top level queues.
  1523. </p>
  1524. @return a list of queue-information for all the top-level queues
  1525. @throws YarnException
  1526. @throws IOException]]>
  1527. </doc>
  1528. </method>
  1529. <method name="getChildQueueInfos" return="java.util.List"
  1530. abstract="true" native="false" synchronized="false"
  1531. static="false" final="false" visibility="public"
  1532. deprecated="not deprecated">
  1533. <param name="parent" type="java.lang.String"/>
  1534. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1535. <exception name="IOException" type="java.io.IOException"/>
  1536. <doc>
  1537. <![CDATA[<p>
  1538. Get information ({@link QueueInfo}) about all the immediate children queues
  1539. of the given queue
  1540. </p>
  1541. @param parent
  1542. Name of the queue whose child-queues' information is needed
  1543. @return a list of queue-information for all queues who are direct children
  1544. of the given parent queue.
  1545. @throws YarnException
  1546. @throws IOException]]>
  1547. </doc>
  1548. </method>
  1549. <method name="getQueueAclsInfo" return="java.util.List"
  1550. abstract="true" native="false" synchronized="false"
  1551. static="false" final="false" visibility="public"
  1552. deprecated="not deprecated">
  1553. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1554. <exception name="IOException" type="java.io.IOException"/>
  1555. <doc>
  1556. <![CDATA[<p>
  1557. Get information about <em>acls</em> for <em>current user</em> on all the
  1558. existing queues.
  1559. </p>
  1560. @return a list of queue acls ({@link QueueUserACLInfo}) for
  1561. <em>current user</em>
  1562. @throws YarnException
  1563. @throws IOException]]>
  1564. </doc>
  1565. </method>
  1566. <method name="getApplicationAttemptReport" return="org.apache.hadoop.yarn.api.records.ApplicationAttemptReport"
  1567. abstract="true" native="false" synchronized="false"
  1568. static="false" final="false" visibility="public"
  1569. deprecated="not deprecated">
  1570. <param name="applicationAttemptId" type="org.apache.hadoop.yarn.api.records.ApplicationAttemptId"/>
  1571. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1572. <exception name="IOException" type="java.io.IOException"/>
  1573. <doc>
  1574. <![CDATA[<p>
  1575. Get a report of the given ApplicationAttempt.
  1576. </p>
  1577. <p>
  1578. In secure mode, <code>YARN</code> verifies access to the application, queue
  1579. etc. before accepting the request.
  1580. </p>
  1581. @param applicationAttemptId
  1582. {@link ApplicationAttemptId} of the application attempt that needs
  1583. a report
  1584. @return application attempt report
  1585. @throws YarnException
  1586. @throws ApplicationAttemptNotFoundException if application attempt
  1587. not found
  1588. @throws IOException]]>
  1589. </doc>
  1590. </method>
  1591. <method name="getApplicationAttempts" return="java.util.List"
  1592. abstract="true" native="false" synchronized="false"
  1593. static="false" final="false" visibility="public"
  1594. deprecated="not deprecated">
  1595. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1596. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1597. <exception name="IOException" type="java.io.IOException"/>
  1598. <doc>
  1599. <![CDATA[<p>
  1600. Get a report of all (ApplicationAttempts) of Application in the cluster.
  1601. </p>
  1602. @param applicationId application id of the app
  1603. @return a list of reports for all application attempts for specified
  1604. application.
  1605. @throws YarnException
  1606. @throws IOException]]>
  1607. </doc>
  1608. </method>
  1609. <method name="getContainerReport" return="org.apache.hadoop.yarn.api.records.ContainerReport"
  1610. abstract="true" native="false" synchronized="false"
  1611. static="false" final="false" visibility="public"
  1612. deprecated="not deprecated">
  1613. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  1614. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1615. <exception name="IOException" type="java.io.IOException"/>
  1616. <doc>
  1617. <![CDATA[<p>
  1618. Get a report of the given Container.
  1619. </p>
  1620. <p>
  1621. In secure mode, <code>YARN</code> verifies access to the application, queue
  1622. etc. before accepting the request.
  1623. </p>
  1624. @param containerId
  1625. {@link ContainerId} of the container that needs a report
  1626. @return container report
  1627. @throws YarnException
  1628. @throws ContainerNotFoundException if container not found.
  1629. @throws IOException]]>
  1630. </doc>
  1631. </method>
  1632. <method name="getContainers" return="java.util.List"
  1633. abstract="true" native="false" synchronized="false"
  1634. static="false" final="false" visibility="public"
  1635. deprecated="not deprecated">
  1636. <param name="applicationAttemptId" type="org.apache.hadoop.yarn.api.records.ApplicationAttemptId"/>
  1637. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1638. <exception name="IOException" type="java.io.IOException"/>
  1639. <doc>
  1640. <![CDATA[<p>
  1641. Get a report of all (Containers) of ApplicationAttempt in the cluster.
  1642. </p>
  1643. @param applicationAttemptId application attempt id
  1644. @return a list of reports of all containers for specified application
  1645. attempts
  1646. @throws YarnException
  1647. @throws IOException]]>
  1648. </doc>
  1649. </method>
  1650. <method name="moveApplicationAcrossQueues"
  1651. abstract="true" native="false" synchronized="false"
  1652. static="false" final="false" visibility="public"
  1653. deprecated="not deprecated">
  1654. <param name="appId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1655. <param name="queue" type="java.lang.String"/>
  1656. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1657. <exception name="IOException" type="java.io.IOException"/>
  1658. <doc>
  1659. <![CDATA[<p>
  1660. Attempts to move the given application to the given queue.
  1661. </p>
  1662. @param appId
  1663. Application to move.
  1664. @param queue
  1665. Queue to place it in to.
  1666. @throws YarnException
  1667. @throws IOException]]>
  1668. </doc>
  1669. </method>
  1670. <method name="createReservation" return="org.apache.hadoop.yarn.api.protocolrecords.GetNewReservationResponse"
  1671. abstract="true" native="false" synchronized="false"
  1672. static="false" final="false" visibility="public"
  1673. deprecated="not deprecated">
  1674. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1675. <exception name="IOException" type="java.io.IOException"/>
  1676. <doc>
  1677. <![CDATA[<p>
  1678. Obtain a {@link GetNewReservationResponse} for a new reservation,
  1679. which contains the {@link ReservationId} object.
  1680. </p>
  1681. @return The {@link GetNewReservationResponse} containing a new
  1682. {@link ReservationId} object.
  1683. @throws YarnException if reservation cannot be created.
  1684. @throws IOException if reservation cannot be created.]]>
  1685. </doc>
  1686. </method>
  1687. <method name="submitReservation" return="org.apache.hadoop.yarn.api.protocolrecords.ReservationSubmissionResponse"
  1688. abstract="true" native="false" synchronized="false"
  1689. static="false" final="false" visibility="public"
  1690. deprecated="not deprecated">
  1691. <param name="request" type="org.apache.hadoop.yarn.api.protocolrecords.ReservationSubmissionRequest"/>
  1692. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1693. <exception name="IOException" type="java.io.IOException"/>
  1694. <doc>
  1695. <![CDATA[<p>
  1696. The interface used by clients to submit a new reservation to the
  1697. {@code ResourceManager}.
  1698. </p>
  1699. <p>
  1700. The client packages all details of its request in a
  1701. {@link ReservationSubmissionRequest} object. This contains information
  1702. about the amount of capacity, temporal constraints, and gang needs.
  1703. Furthermore, the reservation might be composed of multiple stages, with
  1704. ordering dependencies among them.
  1705. </p>
  1706. <p>
  1707. In order to respond, a new admission control component in the
  1708. {@code ResourceManager} performs an analysis of the resources that have
  1709. been committed over the period of time the user is requesting, verify that
  1710. the user requests can be fulfilled, and that it respect a sharing policy
  1711. (e.g., {@code CapacityOverTimePolicy}). Once it has positively determined
  1712. that the ReservationRequest is satisfiable the {@code ResourceManager}
  1713. answers with a {@link ReservationSubmissionResponse} that includes a
  1714. {@link ReservationId}. Upon failure to find a valid allocation the response
  1715. is an exception with the message detailing the reason of failure.
  1716. </p>
  1717. <p>
  1718. The semantics guarantees that the {@link ReservationId} returned,
  1719. corresponds to a valid reservation existing in the time-range request by
  1720. the user. The amount of capacity dedicated to such reservation can vary
  1721. overtime, depending of the allocation that has been determined. But it is
  1722. guaranteed to satisfy all the constraint expressed by the user in the
  1723. {@link ReservationDefinition}
  1724. </p>
  1725. @param request request to submit a new Reservation
  1726. @return response contains the {@link ReservationId} on accepting the
  1727. submission
  1728. @throws YarnException if the reservation cannot be created successfully
  1729. @throws IOException]]>
  1730. </doc>
  1731. </method>
  1732. <method name="updateReservation" return="org.apache.hadoop.yarn.api.protocolrecords.ReservationUpdateResponse"
  1733. abstract="true" native="false" synchronized="false"
  1734. static="false" final="false" visibility="public"
  1735. deprecated="not deprecated">
  1736. <param name="request" type="org.apache.hadoop.yarn.api.protocolrecords.ReservationUpdateRequest"/>
  1737. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1738. <exception name="IOException" type="java.io.IOException"/>
  1739. <doc>
  1740. <![CDATA[<p>
  1741. The interface used by clients to update an existing Reservation. This is
  1742. referred to as a re-negotiation process, in which a user that has
  1743. previously submitted a Reservation.
  1744. </p>
  1745. <p>
  1746. The allocation is attempted by virtually substituting all previous
  1747. allocations related to this Reservation with new ones, that satisfy the new
  1748. {@link ReservationDefinition}. Upon success the previous allocation is
  1749. atomically substituted by the new one, and on failure (i.e., if the system
  1750. cannot find a valid allocation for the updated request), the previous
  1751. allocation remains valid.
  1752. </p>
  1753. @param request to update an existing Reservation (the
  1754. {@link ReservationUpdateRequest} should refer to an existing valid
  1755. {@link ReservationId})
  1756. @return response empty on successfully updating the existing reservation
  1757. @throws YarnException if the request is invalid or reservation cannot be
  1758. updated successfully
  1759. @throws IOException]]>
  1760. </doc>
  1761. </method>
  1762. <method name="deleteReservation" return="org.apache.hadoop.yarn.api.protocolrecords.ReservationDeleteResponse"
  1763. abstract="true" native="false" synchronized="false"
  1764. static="false" final="false" visibility="public"
  1765. deprecated="not deprecated">
  1766. <param name="request" type="org.apache.hadoop.yarn.api.protocolrecords.ReservationDeleteRequest"/>
  1767. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1768. <exception name="IOException" type="java.io.IOException"/>
  1769. <doc>
  1770. <![CDATA[<p>
  1771. The interface used by clients to remove an existing Reservation.
  1772. </p>
  1773. @param request to remove an existing Reservation (the
  1774. {@link ReservationDeleteRequest} should refer to an existing valid
  1775. {@link ReservationId})
  1776. @return response empty on successfully deleting the existing reservation
  1777. @throws YarnException if the request is invalid or reservation cannot be
  1778. deleted successfully
  1779. @throws IOException]]>
  1780. </doc>
  1781. </method>
  1782. <method name="listReservations" return="org.apache.hadoop.yarn.api.protocolrecords.ReservationListResponse"
  1783. abstract="true" native="false" synchronized="false"
  1784. static="false" final="false" visibility="public"
  1785. deprecated="not deprecated">
  1786. <param name="request" type="org.apache.hadoop.yarn.api.protocolrecords.ReservationListRequest"/>
  1787. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1788. <exception name="IOException" type="java.io.IOException"/>
  1789. <doc>
  1790. <![CDATA[<p>
  1791. The interface used by clients to get the list of reservations in a plan.
  1792. The reservationId will be used to search for reservations to list if it is
  1793. provided. Otherwise, it will select active reservations within the
  1794. startTime and endTime (inclusive).
  1795. </p>
  1796. @param request to list reservations in a plan. Contains fields to select
  1797. String queue, ReservationId reservationId, long startTime,
  1798. long endTime, and a bool includeReservationAllocations.
  1799. queue: Required. Cannot be null or empty. Refers to the
  1800. reservable queue in the scheduler that was selected when
  1801. creating a reservation submission
  1802. {@link ReservationSubmissionRequest}.
  1803. reservationId: Optional. If provided, other fields will
  1804. be ignored.
  1805. startTime: Optional. If provided, only reservations that
  1806. end after the startTime will be selected. This defaults
  1807. to 0 if an invalid number is used.
  1808. endTime: Optional. If provided, only reservations that
  1809. start on or before endTime will be selected. This defaults
  1810. to Long.MAX_VALUE if an invalid number is used.
  1811. includeReservationAllocations: Optional. Flag that
  1812. determines whether the entire reservation allocations are
  1813. to be returned. Reservation allocations are subject to
  1814. change in the event of re-planning as described by
  1815. {@link ReservationDefinition}.
  1816. @return response that contains information about reservations that are
  1817. being searched for.
  1818. @throws YarnException if the request is invalid
  1819. @throws IOException if the request failed otherwise]]>
  1820. </doc>
  1821. </method>
  1822. <method name="getNodeToLabels" return="java.util.Map"
  1823. abstract="true" native="false" synchronized="false"
  1824. static="false" final="false" visibility="public"
  1825. deprecated="not deprecated">
  1826. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1827. <exception name="IOException" type="java.io.IOException"/>
  1828. <doc>
  1829. <![CDATA[<p>
  1830. The interface used by client to get node to labels mappings in existing cluster
  1831. </p>
  1832. @return node to labels mappings
  1833. @throws YarnException
  1834. @throws IOException]]>
  1835. </doc>
  1836. </method>
  1837. <method name="getLabelsToNodes" return="java.util.Map"
  1838. abstract="true" native="false" synchronized="false"
  1839. static="false" final="false" visibility="public"
  1840. deprecated="not deprecated">
  1841. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1842. <exception name="IOException" type="java.io.IOException"/>
  1843. <doc>
  1844. <![CDATA[<p>
  1845. The interface used by client to get labels to nodes mapping
  1846. in existing cluster
  1847. </p>
  1848. @return node to labels mappings
  1849. @throws YarnException
  1850. @throws IOException]]>
  1851. </doc>
  1852. </method>
  1853. <method name="getLabelsToNodes" return="java.util.Map"
  1854. abstract="true" native="false" synchronized="false"
  1855. static="false" final="false" visibility="public"
  1856. deprecated="not deprecated">
  1857. <param name="labels" type="java.util.Set"/>
  1858. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1859. <exception name="IOException" type="java.io.IOException"/>
  1860. <doc>
  1861. <![CDATA[<p>
  1862. The interface used by client to get labels to nodes mapping
  1863. for specified labels in existing cluster
  1864. </p>
  1865. @param labels labels for which labels to nodes mapping has to be retrieved
  1866. @return labels to nodes mappings for specific labels
  1867. @throws YarnException
  1868. @throws IOException]]>
  1869. </doc>
  1870. </method>
  1871. <method name="getClusterNodeLabels" return="java.util.List"
  1872. abstract="true" native="false" synchronized="false"
  1873. static="false" final="false" visibility="public"
  1874. deprecated="not deprecated">
  1875. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1876. <exception name="IOException" type="java.io.IOException"/>
  1877. <doc>
  1878. <![CDATA[<p>
  1879. The interface used by client to get node labels in the cluster
  1880. </p>
  1881. @return cluster node labels collection
  1882. @throws YarnException when there is a failure in
  1883. {@link ApplicationClientProtocol}
  1884. @throws IOException when there is a failure in
  1885. {@link ApplicationClientProtocol}]]>
  1886. </doc>
  1887. </method>
  1888. <method name="updateApplicationPriority" return="org.apache.hadoop.yarn.api.records.Priority"
  1889. abstract="true" native="false" synchronized="false"
  1890. static="false" final="false" visibility="public"
  1891. deprecated="not deprecated">
  1892. <param name="applicationId" type="org.apache.hadoop.yarn.api.records.ApplicationId"/>
  1893. <param name="priority" type="org.apache.hadoop.yarn.api.records.Priority"/>
  1894. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1895. <exception name="IOException" type="java.io.IOException"/>
  1896. <doc>
  1897. <![CDATA[<p>
  1898. The interface used by client to set priority of an application
  1899. </p>
  1900. @param applicationId
  1901. @param priority
  1902. @return updated priority of an application.
  1903. @throws YarnException
  1904. @throws IOException]]>
  1905. </doc>
  1906. </method>
  1907. <method name="signalToContainer"
  1908. abstract="true" native="false" synchronized="false"
  1909. static="false" final="false" visibility="public"
  1910. deprecated="not deprecated">
  1911. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  1912. <param name="command" type="org.apache.hadoop.yarn.api.records.SignalContainerCommand"/>
  1913. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1914. <exception name="IOException" type="java.io.IOException"/>
  1915. <doc>
  1916. <![CDATA[<p>
  1917. Signal a container identified by given ID.
  1918. </p>
  1919. @param containerId
  1920. {@link ContainerId} of the container that needs to be signaled
  1921. @param command the signal container command
  1922. @throws YarnException
  1923. @throws IOException]]>
  1924. </doc>
  1925. </method>
  1926. <method name="updateApplicationTimeouts" return="org.apache.hadoop.yarn.api.protocolrecords.UpdateApplicationTimeoutsResponse"
  1927. abstract="false" native="false" synchronized="false"
  1928. static="false" final="false" visibility="public"
  1929. deprecated="not deprecated">
  1930. <param name="request" type="org.apache.hadoop.yarn.api.protocolrecords.UpdateApplicationTimeoutsRequest"/>
  1931. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1932. <exception name="IOException" type="java.io.IOException"/>
  1933. </method>
  1934. <method name="getResourceProfiles" return="java.util.Map"
  1935. abstract="true" native="false" synchronized="false"
  1936. static="false" final="false" visibility="public"
  1937. deprecated="not deprecated">
  1938. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1939. <exception name="IOException" type="java.io.IOException"/>
  1940. <doc>
  1941. <![CDATA[<p>
  1942. Get the resource profiles available in the RM.
  1943. </p>
  1944. @return a Map of the resource profile names to their capabilities
  1945. @throws YARNFeatureNotEnabledException if resource-profile is disabled
  1946. @throws YarnException if any error happens inside YARN
  1947. @throws IOException in case of other errors]]>
  1948. </doc>
  1949. </method>
  1950. <method name="getResourceProfile" return="org.apache.hadoop.yarn.api.records.Resource"
  1951. abstract="true" native="false" synchronized="false"
  1952. static="false" final="false" visibility="public"
  1953. deprecated="not deprecated">
  1954. <param name="profile" type="java.lang.String"/>
  1955. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1956. <exception name="IOException" type="java.io.IOException"/>
  1957. <doc>
  1958. <![CDATA[<p>
  1959. Get the details of a specific resource profile from the RM.
  1960. </p>
  1961. @param profile the profile name
  1962. @return resource profile name with its capabilities
  1963. @throws YARNFeatureNotEnabledException if resource-profile is disabled
  1964. @throws YarnException if any error happens inside YARN
  1965. @throws IOException in case of other others]]>
  1966. </doc>
  1967. </method>
  1968. <method name="getResourceTypeInfo" return="java.util.List"
  1969. abstract="true" native="false" synchronized="false"
  1970. static="false" final="false" visibility="public"
  1971. deprecated="not deprecated">
  1972. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  1973. <exception name="IOException" type="java.io.IOException"/>
  1974. <doc>
  1975. <![CDATA[<p>
  1976. Get available resource types supported by RM.
  1977. </p>
  1978. @return list of supported resource types with detailed information
  1979. @throws YarnException if any issue happens inside YARN
  1980. @throws IOException in case of other others]]>
  1981. </doc>
  1982. </method>
  1983. </class>
  1984. <!-- end class org.apache.hadoop.yarn.client.api.YarnClient -->
  1985. <!-- start class org.apache.hadoop.yarn.client.api.YarnClientApplication -->
  1986. <class name="YarnClientApplication" extends="java.lang.Object"
  1987. abstract="false"
  1988. static="false" final="false" visibility="public"
  1989. deprecated="not deprecated">
  1990. <constructor name="YarnClientApplication" type="org.apache.hadoop.yarn.api.protocolrecords.GetNewApplicationResponse, org.apache.hadoop.yarn.api.records.ApplicationSubmissionContext"
  1991. static="false" final="false" visibility="public"
  1992. deprecated="not deprecated">
  1993. </constructor>
  1994. <method name="getNewApplicationResponse" return="org.apache.hadoop.yarn.api.protocolrecords.GetNewApplicationResponse"
  1995. abstract="false" native="false" synchronized="false"
  1996. static="false" final="false" visibility="public"
  1997. deprecated="not deprecated">
  1998. </method>
  1999. <method name="getApplicationSubmissionContext" return="org.apache.hadoop.yarn.api.records.ApplicationSubmissionContext"
  2000. abstract="false" native="false" synchronized="false"
  2001. static="false" final="false" visibility="public"
  2002. deprecated="not deprecated">
  2003. </method>
  2004. </class>
  2005. <!-- end class org.apache.hadoop.yarn.client.api.YarnClientApplication -->
  2006. </package>
  2007. <package name="org.apache.hadoop.yarn.client.api.async">
  2008. <!-- start class org.apache.hadoop.yarn.client.api.async.AMRMClientAsync -->
  2009. <class name="AMRMClientAsync" extends="org.apache.hadoop.service.AbstractService"
  2010. abstract="true"
  2011. static="false" final="false" visibility="public"
  2012. deprecated="not deprecated">
  2013. <constructor name="AMRMClientAsync" type="int, org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.AbstractCallbackHandler"
  2014. static="false" final="false" visibility="protected"
  2015. deprecated="not deprecated">
  2016. </constructor>
  2017. <constructor name="AMRMClientAsync" type="org.apache.hadoop.yarn.client.api.AMRMClient, int, org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.AbstractCallbackHandler"
  2018. static="false" final="false" visibility="protected"
  2019. deprecated="not deprecated">
  2020. </constructor>
  2021. <constructor name="AMRMClientAsync" type="int, org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.CallbackHandler"
  2022. static="false" final="false" visibility="protected"
  2023. deprecated="not deprecated">
  2024. </constructor>
  2025. <constructor name="AMRMClientAsync" type="org.apache.hadoop.yarn.client.api.AMRMClient, int, org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.CallbackHandler"
  2026. static="false" final="false" visibility="protected"
  2027. deprecated="not deprecated">
  2028. </constructor>
  2029. <method name="createAMRMClientAsync" return="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync"
  2030. abstract="false" native="false" synchronized="false"
  2031. static="true" final="false" visibility="public"
  2032. deprecated="not deprecated">
  2033. <param name="intervalMs" type="int"/>
  2034. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.AbstractCallbackHandler"/>
  2035. <doc>
  2036. <![CDATA[<p>Create a new instance of AMRMClientAsync.</p>
  2037. @param intervalMs heartbeat interval in milliseconds between AM and RM
  2038. @param callbackHandler callback handler that processes responses from
  2039. the <code>ResourceManager</code>]]>
  2040. </doc>
  2041. </method>
  2042. <method name="createAMRMClientAsync" return="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync"
  2043. abstract="false" native="false" synchronized="false"
  2044. static="true" final="false" visibility="public"
  2045. deprecated="not deprecated">
  2046. <param name="client" type="org.apache.hadoop.yarn.client.api.AMRMClient"/>
  2047. <param name="intervalMs" type="int"/>
  2048. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.AbstractCallbackHandler"/>
  2049. <doc>
  2050. <![CDATA[<p>Create a new instance of AMRMClientAsync.</p>
  2051. @param client the AMRMClient instance
  2052. @param intervalMs heartbeat interval in milliseconds between AM and RM
  2053. @param callbackHandler callback handler that processes responses from
  2054. the <code>ResourceManager</code>]]>
  2055. </doc>
  2056. </method>
  2057. <method name="createAMRMClientAsync" return="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync"
  2058. abstract="false" native="false" synchronized="false"
  2059. static="true" final="false" visibility="public"
  2060. deprecated="Use {@link #createAMRMClientAsync(int,
  2061. AMRMClientAsync.AbstractCallbackHandler)} instead.">
  2062. <param name="intervalMs" type="int"/>
  2063. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.CallbackHandler"/>
  2064. <doc>
  2065. <![CDATA[@deprecated Use {@link #createAMRMClientAsync(int,
  2066. AMRMClientAsync.AbstractCallbackHandler)} instead.]]>
  2067. </doc>
  2068. </method>
  2069. <method name="createAMRMClientAsync" return="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync"
  2070. abstract="false" native="false" synchronized="false"
  2071. static="true" final="false" visibility="public"
  2072. deprecated="Use {@link #createAMRMClientAsync(AMRMClient,
  2073. int, AMRMClientAsync.AbstractCallbackHandler)} instead.">
  2074. <param name="client" type="org.apache.hadoop.yarn.client.api.AMRMClient"/>
  2075. <param name="intervalMs" type="int"/>
  2076. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.CallbackHandler"/>
  2077. <doc>
  2078. <![CDATA[@deprecated Use {@link #createAMRMClientAsync(AMRMClient,
  2079. int, AMRMClientAsync.AbstractCallbackHandler)} instead.]]>
  2080. </doc>
  2081. </method>
  2082. <method name="setHeartbeatInterval"
  2083. abstract="false" native="false" synchronized="false"
  2084. static="false" final="false" visibility="public"
  2085. deprecated="not deprecated">
  2086. <param name="interval" type="int"/>
  2087. </method>
  2088. <method name="getMatchingRequests" return="java.util.List"
  2089. abstract="true" native="false" synchronized="false"
  2090. static="false" final="false" visibility="public"
  2091. deprecated="not deprecated">
  2092. <param name="priority" type="org.apache.hadoop.yarn.api.records.Priority"/>
  2093. <param name="resourceName" type="java.lang.String"/>
  2094. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  2095. </method>
  2096. <method name="addSchedulingRequests"
  2097. abstract="false" native="false" synchronized="false"
  2098. static="false" final="false" visibility="public"
  2099. deprecated="not deprecated">
  2100. <param name="schedulingRequests" type="java.util.Collection"/>
  2101. <doc>
  2102. <![CDATA[Add a Collection of SchedulingRequests. The AMRMClient will ensure that
  2103. all requests in the same batch are sent in the same allocate call.
  2104. @param schedulingRequests Collection of Scheduling Requests.]]>
  2105. </doc>
  2106. </method>
  2107. <method name="getMatchingRequests" return="java.util.List"
  2108. abstract="false" native="false" synchronized="false"
  2109. static="false" final="false" visibility="public"
  2110. deprecated="not deprecated">
  2111. <param name="priority" type="org.apache.hadoop.yarn.api.records.Priority"/>
  2112. <param name="resourceName" type="java.lang.String"/>
  2113. <param name="executionType" type="org.apache.hadoop.yarn.api.records.ExecutionType"/>
  2114. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  2115. <doc>
  2116. <![CDATA[Returns all matching ContainerRequests that match the given Priority,
  2117. ResourceName, ExecutionType and Capability.
  2118. NOTE: This matches only requests that were made by the client WITHOUT the
  2119. allocationRequestId specified.
  2120. @param priority Priority.
  2121. @param resourceName Location.
  2122. @param executionType ExecutionType.
  2123. @param capability Capability.
  2124. @return All matching ContainerRequests]]>
  2125. </doc>
  2126. </method>
  2127. <method name="getMatchingRequests" return="java.util.Collection"
  2128. abstract="false" native="false" synchronized="false"
  2129. static="false" final="false" visibility="public"
  2130. deprecated="not deprecated">
  2131. <param name="allocationRequestId" type="long"/>
  2132. <doc>
  2133. <![CDATA[Returns all matching ContainerRequests that match the given
  2134. AllocationRequestId.
  2135. NOTE: This matches only requests that were made by the client WITH the
  2136. allocationRequestId specified.
  2137. @param allocationRequestId AllocationRequestId.
  2138. @return All matching ContainerRequests]]>
  2139. </doc>
  2140. </method>
  2141. <method name="registerApplicationMaster" return="org.apache.hadoop.yarn.api.protocolrecords.RegisterApplicationMasterResponse"
  2142. abstract="true" native="false" synchronized="false"
  2143. static="false" final="false" visibility="public"
  2144. deprecated="not deprecated">
  2145. <param name="appHostName" type="java.lang.String"/>
  2146. <param name="appHostPort" type="int"/>
  2147. <param name="appTrackingUrl" type="java.lang.String"/>
  2148. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  2149. <exception name="IOException" type="java.io.IOException"/>
  2150. <doc>
  2151. <![CDATA[Registers this application master with the resource manager. On successful
  2152. registration, starts the heartbeating thread.
  2153. @throws YarnException
  2154. @throws IOException]]>
  2155. </doc>
  2156. </method>
  2157. <method name="registerApplicationMaster" return="org.apache.hadoop.yarn.api.protocolrecords.RegisterApplicationMasterResponse"
  2158. abstract="false" native="false" synchronized="false"
  2159. static="false" final="false" visibility="public"
  2160. deprecated="not deprecated">
  2161. <param name="appHostName" type="java.lang.String"/>
  2162. <param name="appHostPort" type="int"/>
  2163. <param name="appTrackingUrl" type="java.lang.String"/>
  2164. <param name="placementConstraints" type="java.util.Map"/>
  2165. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  2166. <exception name="IOException" type="java.io.IOException"/>
  2167. <doc>
  2168. <![CDATA[Register the application master. This must be called before any
  2169. other interaction
  2170. @param appHostName Name of the host on which master is running
  2171. @param appHostPort Port master is listening on
  2172. @param appTrackingUrl URL at which the master info can be seen
  2173. @param placementConstraints Placement Constraints mappings.
  2174. @return <code>RegisterApplicationMasterResponse</code>
  2175. @throws YarnException
  2176. @throws IOException]]>
  2177. </doc>
  2178. </method>
  2179. <method name="unregisterApplicationMaster"
  2180. abstract="true" native="false" synchronized="false"
  2181. static="false" final="false" visibility="public"
  2182. deprecated="not deprecated">
  2183. <param name="appStatus" type="org.apache.hadoop.yarn.api.records.FinalApplicationStatus"/>
  2184. <param name="appMessage" type="java.lang.String"/>
  2185. <param name="appTrackingUrl" type="java.lang.String"/>
  2186. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  2187. <exception name="IOException" type="java.io.IOException"/>
  2188. <doc>
  2189. <![CDATA[Unregister the application master. This must be called in the end.
  2190. @param appStatus Success/Failure status of the master
  2191. @param appMessage Diagnostics message on failure
  2192. @param appTrackingUrl New URL to get master info
  2193. @throws YarnException
  2194. @throws IOException]]>
  2195. </doc>
  2196. </method>
  2197. <method name="addContainerRequest"
  2198. abstract="true" native="false" synchronized="false"
  2199. static="false" final="false" visibility="public"
  2200. deprecated="not deprecated">
  2201. <param name="req" type="T"/>
  2202. <doc>
  2203. <![CDATA[Request containers for resources before calling <code>allocate</code>
  2204. @param req Resource request]]>
  2205. </doc>
  2206. </method>
  2207. <method name="removeContainerRequest"
  2208. abstract="true" native="false" synchronized="false"
  2209. static="false" final="false" visibility="public"
  2210. deprecated="not deprecated">
  2211. <param name="req" type="T"/>
  2212. <doc>
  2213. <![CDATA[Remove previous container request. The previous container request may have
  2214. already been sent to the ResourceManager. So even after the remove request
  2215. the app must be prepared to receive an allocation for the previous request
  2216. even after the remove request
  2217. @param req Resource request]]>
  2218. </doc>
  2219. </method>
  2220. <method name="requestContainerResourceChange"
  2221. abstract="false" native="false" synchronized="false"
  2222. static="false" final="false" visibility="public"
  2223. deprecated="use
  2224. {@link #requestContainerUpdate(Container, UpdateContainerRequest)}">
  2225. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  2226. <param name="capability" type="org.apache.hadoop.yarn.api.records.Resource"/>
  2227. <doc>
  2228. <![CDATA[Request container resource change before calling <code>allocate</code>.
  2229. Any previous pending resource change request of the same container will be
  2230. removed.
  2231. Application that calls this method is expected to maintain the
  2232. <code>Container</code>s that are returned from previous successful
  2233. allocations or resource changes. By passing in the existing container and a
  2234. target resource capability to this method, the application requests the
  2235. ResourceManager to change the existing resource allocation to the target
  2236. resource allocation.
  2237. @deprecated use
  2238. {@link #requestContainerUpdate(Container, UpdateContainerRequest)}
  2239. @param container The container returned from the last successful resource
  2240. allocation or resource change
  2241. @param capability The target resource capability of the container]]>
  2242. </doc>
  2243. </method>
  2244. <method name="requestContainerUpdate"
  2245. abstract="true" native="false" synchronized="false"
  2246. static="false" final="false" visibility="public"
  2247. deprecated="not deprecated">
  2248. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  2249. <param name="updateContainerRequest" type="org.apache.hadoop.yarn.api.records.UpdateContainerRequest"/>
  2250. <doc>
  2251. <![CDATA[Request a container update before calling <code>allocate</code>.
  2252. Any previous pending update request of the same container will be
  2253. removed.
  2254. @param container The container returned from the last successful resource
  2255. allocation or update
  2256. @param updateContainerRequest The <code>UpdateContainerRequest</code>.]]>
  2257. </doc>
  2258. </method>
  2259. <method name="releaseAssignedContainer"
  2260. abstract="true" native="false" synchronized="false"
  2261. static="false" final="false" visibility="public"
  2262. deprecated="not deprecated">
  2263. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2264. <doc>
  2265. <![CDATA[Release containers assigned by the Resource Manager. If the app cannot use
  2266. the container or wants to give up the container then it can release them.
  2267. The app needs to make new requests for the released resource capability if
  2268. it still needs it. eg. it released non-local resources
  2269. @param containerId]]>
  2270. </doc>
  2271. </method>
  2272. <method name="getAvailableResources" return="org.apache.hadoop.yarn.api.records.Resource"
  2273. abstract="true" native="false" synchronized="false"
  2274. static="false" final="false" visibility="public"
  2275. deprecated="not deprecated">
  2276. <doc>
  2277. <![CDATA[Get the currently available resources in the cluster.
  2278. A valid value is available after a call to allocate has been made
  2279. @return Currently available resources]]>
  2280. </doc>
  2281. </method>
  2282. <method name="getClusterNodeCount" return="int"
  2283. abstract="true" native="false" synchronized="false"
  2284. static="false" final="false" visibility="public"
  2285. deprecated="not deprecated">
  2286. <doc>
  2287. <![CDATA[Get the current number of nodes in the cluster.
  2288. A valid values is available after a call to allocate has been made
  2289. @return Current number of nodes in the cluster]]>
  2290. </doc>
  2291. </method>
  2292. <method name="registerTimelineV2Client"
  2293. abstract="false" native="false" synchronized="false"
  2294. static="false" final="false" visibility="public"
  2295. deprecated="not deprecated">
  2296. <param name="timelineClient" type="org.apache.hadoop.yarn.client.api.TimelineV2Client"/>
  2297. <exception name="YarnException" type="org.apache.hadoop.yarn.exceptions.YarnException"/>
  2298. <doc>
  2299. <![CDATA[Register TimelineClient to AMRMClient.
  2300. @param timelineClient
  2301. @throws YarnException when this method is invoked even when ATS V2 is not
  2302. configured.]]>
  2303. </doc>
  2304. </method>
  2305. <method name="getRegisteredTimelineV2Client" return="org.apache.hadoop.yarn.client.api.TimelineV2Client"
  2306. abstract="false" native="false" synchronized="false"
  2307. static="false" final="false" visibility="public"
  2308. deprecated="not deprecated">
  2309. <doc>
  2310. <![CDATA[Get registered timeline client.
  2311. @return the registered timeline client]]>
  2312. </doc>
  2313. </method>
  2314. <method name="updateBlacklist"
  2315. abstract="true" native="false" synchronized="false"
  2316. static="false" final="false" visibility="public"
  2317. deprecated="not deprecated">
  2318. <param name="blacklistAdditions" type="java.util.List"/>
  2319. <param name="blacklistRemovals" type="java.util.List"/>
  2320. <doc>
  2321. <![CDATA[Update application's blacklist with addition or removal resources.
  2322. @param blacklistAdditions list of resources which should be added to the
  2323. application blacklist
  2324. @param blacklistRemovals list of resources which should be removed from the
  2325. application blacklist]]>
  2326. </doc>
  2327. </method>
  2328. <method name="updateTrackingUrl"
  2329. abstract="false" native="false" synchronized="false"
  2330. static="false" final="false" visibility="public"
  2331. deprecated="not deprecated">
  2332. <param name="trackingUrl" type="java.lang.String"/>
  2333. <doc>
  2334. <![CDATA[Update application's tracking url on next heartbeat.
  2335. @param trackingUrl new tracking url for this application]]>
  2336. </doc>
  2337. </method>
  2338. <method name="waitFor"
  2339. abstract="false" native="false" synchronized="false"
  2340. static="false" final="false" visibility="public"
  2341. deprecated="not deprecated">
  2342. <param name="check" type="java.util.function.Supplier"/>
  2343. <exception name="InterruptedException" type="java.lang.InterruptedException"/>
  2344. <doc>
  2345. <![CDATA[Wait for <code>check</code> to return true for each 1000 ms.
  2346. See also {@link #waitFor(java.util.function.Supplier, int)}
  2347. and {@link #waitFor(java.util.function.Supplier, int, int)}
  2348. @param check the condition for which it should wait]]>
  2349. </doc>
  2350. </method>
  2351. <method name="waitFor"
  2352. abstract="false" native="false" synchronized="false"
  2353. static="false" final="false" visibility="public"
  2354. deprecated="not deprecated">
  2355. <param name="check" type="java.util.function.Supplier"/>
  2356. <param name="checkEveryMillis" type="int"/>
  2357. <exception name="InterruptedException" type="java.lang.InterruptedException"/>
  2358. <doc>
  2359. <![CDATA[Wait for <code>check</code> to return true for each
  2360. <code>checkEveryMillis</code> ms.
  2361. See also {@link #waitFor(java.util.function.Supplier, int, int)}
  2362. @param check user defined checker
  2363. @param checkEveryMillis interval to call <code>check</code>]]>
  2364. </doc>
  2365. </method>
  2366. <method name="waitFor"
  2367. abstract="false" native="false" synchronized="false"
  2368. static="false" final="false" visibility="public"
  2369. deprecated="not deprecated">
  2370. <param name="check" type="java.util.function.Supplier"/>
  2371. <param name="checkEveryMillis" type="int"/>
  2372. <param name="logInterval" type="int"/>
  2373. <exception name="InterruptedException" type="java.lang.InterruptedException"/>
  2374. <doc>
  2375. <![CDATA[Wait for <code>check</code> to return true for each
  2376. <code>checkEveryMillis</code> ms. In the main loop, this method will log
  2377. the message "waiting in main loop" for each <code>logInterval</code> times
  2378. iteration to confirm the thread is alive.
  2379. @param check user defined checker
  2380. @param checkEveryMillis interval to call <code>check</code>
  2381. @param logInterval interval to log for each]]>
  2382. </doc>
  2383. </method>
  2384. <field name="client" type="org.apache.hadoop.yarn.client.api.AMRMClient"
  2385. transient="false" volatile="false"
  2386. static="false" final="true" visibility="protected"
  2387. deprecated="not deprecated">
  2388. </field>
  2389. <field name="handler" type="org.apache.hadoop.yarn.client.api.async.AMRMClientAsync.CallbackHandler"
  2390. transient="false" volatile="false"
  2391. static="false" final="true" visibility="protected"
  2392. deprecated="not deprecated">
  2393. </field>
  2394. <field name="heartbeatIntervalMs" type="java.util.concurrent.atomic.AtomicInteger"
  2395. transient="false" volatile="false"
  2396. static="false" final="true" visibility="protected"
  2397. deprecated="not deprecated">
  2398. </field>
  2399. <doc>
  2400. <![CDATA[<code>AMRMClientAsync</code> handles communication with the ResourceManager
  2401. and provides asynchronous updates on events such as container allocations and
  2402. completions. It contains a thread that sends periodic heartbeats to the
  2403. ResourceManager.
  2404. It should be used by implementing a CallbackHandler:
  2405. <pre>
  2406. {@code
  2407. class MyCallbackHandler extends AMRMClientAsync.AbstractCallbackHandler {
  2408. public void onContainersAllocated(List<Container> containers) {
  2409. [run tasks on the containers]
  2410. }
  2411. public void onContainersUpdated(List<Container> containers) {
  2412. [determine if resource allocation of containers have been increased in
  2413. the ResourceManager, and if so, inform the NodeManagers to increase the
  2414. resource monitor/enforcement on the containers]
  2415. }
  2416. public void onContainersCompleted(List<ContainerStatus> statuses) {
  2417. [update progress, check whether app is done]
  2418. }
  2419. public void onNodesUpdated(List<NodeReport> updated) {}
  2420. public void onReboot() {}
  2421. }
  2422. }
  2423. </pre>
  2424. The client's lifecycle should be managed similarly to the following:
  2425. <pre>
  2426. {@code
  2427. AMRMClientAsync asyncClient =
  2428. createAMRMClientAsync(appAttId, 1000, new MyCallbackhandler());
  2429. asyncClient.init(conf);
  2430. asyncClient.start();
  2431. RegisterApplicationMasterResponse response = asyncClient
  2432. .registerApplicationMaster(appMasterHostname, appMasterRpcPort,
  2433. appMasterTrackingUrl);
  2434. asyncClient.addContainerRequest(containerRequest);
  2435. [... wait for application to complete]
  2436. asyncClient.unregisterApplicationMaster(status, appMsg, trackingUrl);
  2437. asyncClient.stop();
  2438. }
  2439. </pre>]]>
  2440. </doc>
  2441. </class>
  2442. <!-- end class org.apache.hadoop.yarn.client.api.async.AMRMClientAsync -->
  2443. <!-- start class org.apache.hadoop.yarn.client.api.async.NMClientAsync -->
  2444. <class name="NMClientAsync" extends="org.apache.hadoop.service.AbstractService"
  2445. abstract="true"
  2446. static="false" final="false" visibility="public"
  2447. deprecated="not deprecated">
  2448. <constructor name="NMClientAsync" type="org.apache.hadoop.yarn.client.api.async.NMClientAsync.AbstractCallbackHandler"
  2449. static="false" final="false" visibility="protected"
  2450. deprecated="not deprecated">
  2451. </constructor>
  2452. <constructor name="NMClientAsync" type="java.lang.String, org.apache.hadoop.yarn.client.api.async.NMClientAsync.AbstractCallbackHandler"
  2453. static="false" final="false" visibility="protected"
  2454. deprecated="not deprecated">
  2455. </constructor>
  2456. <constructor name="NMClientAsync" type="java.lang.String, org.apache.hadoop.yarn.client.api.NMClient, org.apache.hadoop.yarn.client.api.async.NMClientAsync.AbstractCallbackHandler"
  2457. static="false" final="false" visibility="protected"
  2458. deprecated="not deprecated">
  2459. </constructor>
  2460. <constructor name="NMClientAsync" type="org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"
  2461. static="false" final="false" visibility="protected"
  2462. deprecated="Use {@link #NMClientAsync(AbstractCallbackHandler)}
  2463. instead.">
  2464. <doc>
  2465. <![CDATA[@deprecated Use {@link #NMClientAsync(AbstractCallbackHandler)}
  2466. instead.]]>
  2467. </doc>
  2468. </constructor>
  2469. <constructor name="NMClientAsync" type="java.lang.String, org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"
  2470. static="false" final="false" visibility="protected"
  2471. deprecated="Use {@link #NMClientAsync(String, AbstractCallbackHandler)}
  2472. instead.">
  2473. <doc>
  2474. <![CDATA[@deprecated Use {@link #NMClientAsync(String, AbstractCallbackHandler)}
  2475. instead.]]>
  2476. </doc>
  2477. </constructor>
  2478. <constructor name="NMClientAsync" type="java.lang.String, org.apache.hadoop.yarn.client.api.NMClient, org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"
  2479. static="false" final="false" visibility="protected"
  2480. deprecated="not deprecated">
  2481. </constructor>
  2482. <method name="createNMClientAsync" return="org.apache.hadoop.yarn.client.api.async.NMClientAsync"
  2483. abstract="false" native="false" synchronized="false"
  2484. static="true" final="false" visibility="public"
  2485. deprecated="not deprecated">
  2486. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.NMClientAsync.AbstractCallbackHandler"/>
  2487. </method>
  2488. <method name="createNMClientAsync" return="org.apache.hadoop.yarn.client.api.async.NMClientAsync"
  2489. abstract="false" native="false" synchronized="false"
  2490. static="true" final="false" visibility="public"
  2491. deprecated="Use {@link #createNMClientAsync(AbstractCallbackHandler)}
  2492. instead.">
  2493. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"/>
  2494. <doc>
  2495. <![CDATA[@deprecated Use {@link #createNMClientAsync(AbstractCallbackHandler)}
  2496. instead.]]>
  2497. </doc>
  2498. </method>
  2499. <method name="startContainerAsync"
  2500. abstract="true" native="false" synchronized="false"
  2501. static="false" final="false" visibility="public"
  2502. deprecated="not deprecated">
  2503. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  2504. <param name="containerLaunchContext" type="org.apache.hadoop.yarn.api.records.ContainerLaunchContext"/>
  2505. </method>
  2506. <method name="increaseContainerResourceAsync"
  2507. abstract="true" native="false" synchronized="false"
  2508. static="false" final="false" visibility="public"
  2509. deprecated="not deprecated">
  2510. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  2511. </method>
  2512. <method name="updateContainerResourceAsync"
  2513. abstract="true" native="false" synchronized="false"
  2514. static="false" final="false" visibility="public"
  2515. deprecated="not deprecated">
  2516. <param name="container" type="org.apache.hadoop.yarn.api.records.Container"/>
  2517. <doc>
  2518. <![CDATA[<p>Update the resources of a container.</p>
  2519. <p>The <code>ApplicationMaster</code> or other applications that use the
  2520. client must provide the details of the container, including the Id and
  2521. the target resource encapsulated in the updated container token via
  2522. {@link Container}.
  2523. </p>
  2524. @param container the container with updated token.]]>
  2525. </doc>
  2526. </method>
  2527. <method name="reInitializeContainerAsync"
  2528. abstract="true" native="false" synchronized="false"
  2529. static="false" final="false" visibility="public"
  2530. deprecated="not deprecated">
  2531. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2532. <param name="containerLaunchContex" type="org.apache.hadoop.yarn.api.records.ContainerLaunchContext"/>
  2533. <param name="autoCommit" type="boolean"/>
  2534. <doc>
  2535. <![CDATA[<p>Re-Initialize the Container.</p>
  2536. @param containerId the Id of the container to Re-Initialize.
  2537. @param containerLaunchContex the updated ContainerLaunchContext.
  2538. @param autoCommit commit re-initialization automatically ?]]>
  2539. </doc>
  2540. </method>
  2541. <method name="restartContainerAsync"
  2542. abstract="true" native="false" synchronized="false"
  2543. static="false" final="false" visibility="public"
  2544. deprecated="not deprecated">
  2545. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2546. <doc>
  2547. <![CDATA[<p>Restart the specified container.</p>
  2548. @param containerId the Id of the container to restart.]]>
  2549. </doc>
  2550. </method>
  2551. <method name="rollbackLastReInitializationAsync"
  2552. abstract="true" native="false" synchronized="false"
  2553. static="false" final="false" visibility="public"
  2554. deprecated="not deprecated">
  2555. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2556. <doc>
  2557. <![CDATA[<p>Rollback last reInitialization of the specified container.</p>
  2558. @param containerId the Id of the container to restart.]]>
  2559. </doc>
  2560. </method>
  2561. <method name="commitLastReInitializationAsync"
  2562. abstract="true" native="false" synchronized="false"
  2563. static="false" final="false" visibility="public"
  2564. deprecated="not deprecated">
  2565. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2566. <doc>
  2567. <![CDATA[<p>Commit last reInitialization of the specified container.</p>
  2568. @param containerId the Id of the container to commit reInitialize.]]>
  2569. </doc>
  2570. </method>
  2571. <method name="stopContainerAsync"
  2572. abstract="true" native="false" synchronized="false"
  2573. static="false" final="false" visibility="public"
  2574. deprecated="not deprecated">
  2575. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2576. <param name="nodeId" type="org.apache.hadoop.yarn.api.records.NodeId"/>
  2577. </method>
  2578. <method name="getContainerStatusAsync"
  2579. abstract="true" native="false" synchronized="false"
  2580. static="false" final="false" visibility="public"
  2581. deprecated="not deprecated">
  2582. <param name="containerId" type="org.apache.hadoop.yarn.api.records.ContainerId"/>
  2583. <param name="nodeId" type="org.apache.hadoop.yarn.api.records.NodeId"/>
  2584. </method>
  2585. <method name="getClient" return="org.apache.hadoop.yarn.client.api.NMClient"
  2586. abstract="false" native="false" synchronized="false"
  2587. static="false" final="false" visibility="public"
  2588. deprecated="not deprecated">
  2589. </method>
  2590. <method name="setClient"
  2591. abstract="false" native="false" synchronized="false"
  2592. static="false" final="false" visibility="public"
  2593. deprecated="not deprecated">
  2594. <param name="client" type="org.apache.hadoop.yarn.client.api.NMClient"/>
  2595. </method>
  2596. <method name="getCallbackHandler" return="org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"
  2597. abstract="false" native="false" synchronized="false"
  2598. static="false" final="false" visibility="public"
  2599. deprecated="not deprecated">
  2600. </method>
  2601. <method name="setCallbackHandler"
  2602. abstract="false" native="false" synchronized="false"
  2603. static="false" final="false" visibility="public"
  2604. deprecated="not deprecated">
  2605. <param name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"/>
  2606. </method>
  2607. <field name="client" type="org.apache.hadoop.yarn.client.api.NMClient"
  2608. transient="false" volatile="false"
  2609. static="false" final="false" visibility="protected"
  2610. deprecated="not deprecated">
  2611. </field>
  2612. <field name="callbackHandler" type="org.apache.hadoop.yarn.client.api.async.NMClientAsync.CallbackHandler"
  2613. transient="false" volatile="false"
  2614. static="false" final="false" visibility="protected"
  2615. deprecated="not deprecated">
  2616. </field>
  2617. <doc>
  2618. <![CDATA[<code>NMClientAsync</code> handles communication with all the NodeManagers
  2619. and provides asynchronous updates on getting responses from them. It
  2620. maintains a thread pool to communicate with individual NMs where a number of
  2621. worker threads process requests to NMs by using {@link NMClientImpl}. The max
  2622. size of the thread pool is configurable through
  2623. {@link YarnConfiguration#NM_CLIENT_ASYNC_THREAD_POOL_MAX_SIZE}.
  2624. It should be used in conjunction with a CallbackHandler. For example
  2625. <pre>
  2626. {@code
  2627. class MyCallbackHandler extends NMClientAsync.AbstractCallbackHandler {
  2628. public void onContainerStarted(ContainerId containerId,
  2629. Map<String, ByteBuffer> allServiceResponse) {
  2630. [post process after the container is started, process the response]
  2631. }
  2632. public void onContainerResourceIncreased(ContainerId containerId,
  2633. Resource resource) {
  2634. [post process after the container resource is increased]
  2635. }
  2636. public void onContainerStatusReceived(ContainerId containerId,
  2637. ContainerStatus containerStatus) {
  2638. [make use of the status of the container]
  2639. }
  2640. public void onContainerStopped(ContainerId containerId) {
  2641. [post process after the container is stopped]
  2642. }
  2643. public void onStartContainerError(
  2644. ContainerId containerId, Throwable t) {
  2645. [handle the raised exception]
  2646. }
  2647. public void onGetContainerStatusError(
  2648. ContainerId containerId, Throwable t) {
  2649. [handle the raised exception]
  2650. }
  2651. public void onStopContainerError(
  2652. ContainerId containerId, Throwable t) {
  2653. [handle the raised exception]
  2654. }
  2655. }
  2656. }
  2657. </pre>
  2658. The client's life-cycle should be managed like the following:
  2659. <pre>
  2660. {@code
  2661. NMClientAsync asyncClient =
  2662. NMClientAsync.createNMClientAsync(new MyCallbackhandler());
  2663. asyncClient.init(conf);
  2664. asyncClient.start();
  2665. asyncClient.startContainer(container, containerLaunchContext);
  2666. [... wait for container being started]
  2667. asyncClient.getContainerStatus(container.getId(), container.getNodeId(),
  2668. container.getContainerToken());
  2669. [... handle the status in the callback instance]
  2670. asyncClient.stopContainer(container.getId(), container.getNodeId(),
  2671. container.getContainerToken());
  2672. [... wait for container being stopped]
  2673. asyncClient.stop();
  2674. }
  2675. </pre>]]>
  2676. </doc>
  2677. </class>
  2678. <!-- end class org.apache.hadoop.yarn.client.api.async.NMClientAsync -->
  2679. </package>
  2680. <package name="org.apache.hadoop.yarn.client.api.async.impl">
  2681. </package>
  2682. <package name="org.apache.hadoop.yarn.client.api.impl">
  2683. </package>
  2684. <package name="org.apache.hadoop.yarn.client.cli">
  2685. <!-- start class org.apache.hadoop.yarn.client.cli.LogsCLI -->
  2686. <class name="LogsCLI" extends="org.apache.hadoop.conf.Configured"
  2687. abstract="false"
  2688. static="false" final="false" visibility="public"
  2689. deprecated="not deprecated">
  2690. <implements name="org.apache.hadoop.util.Tool"/>
  2691. <constructor name="LogsCLI"
  2692. static="false" final="false" visibility="public"
  2693. deprecated="not deprecated">
  2694. </constructor>
  2695. <method name="run" return="int"
  2696. abstract="false" native="false" synchronized="false"
  2697. static="false" final="false" visibility="public"
  2698. deprecated="not deprecated">
  2699. <param name="args" type="java.lang.String[]"/>
  2700. <exception name="Exception" type="java.lang.Exception"/>
  2701. </method>
  2702. <method name="createYarnClient" return="org.apache.hadoop.yarn.client.api.YarnClient"
  2703. abstract="false" native="false" synchronized="false"
  2704. static="false" final="false" visibility="protected"
  2705. deprecated="not deprecated">
  2706. </method>
  2707. <method name="main"
  2708. abstract="false" native="false" synchronized="false"
  2709. static="true" final="false" visibility="public"
  2710. deprecated="not deprecated">
  2711. <param name="args" type="java.lang.String[]"/>
  2712. <exception name="Exception" type="java.lang.Exception"/>
  2713. </method>
  2714. <method name="getAMContainerInfoForRMWebService" return="java.util.List"
  2715. abstract="false" native="false" synchronized="false"
  2716. static="false" final="false" visibility="protected"
  2717. deprecated="not deprecated">
  2718. <param name="conf" type="org.apache.hadoop.conf.Configuration"/>
  2719. <param name="appId" type="java.lang.String"/>
  2720. <exception name="ClientHandlerException" type="com.sun.jersey.api.client.ClientHandlerException"/>
  2721. <exception name="UniformInterfaceException" type="com.sun.jersey.api.client.UniformInterfaceException"/>
  2722. <exception name="JSONException" type="org.codehaus.jettison.json.JSONException"/>
  2723. </method>
  2724. <method name="getMatchedContainerLogFiles" return="java.util.Set"
  2725. abstract="false" native="false" synchronized="false"
  2726. static="false" final="false" visibility="public"
  2727. deprecated="not deprecated">
  2728. <param name="request" type="org.apache.hadoop.yarn.logaggregation.ContainerLogsRequest"/>
  2729. <param name="useRegex" type="boolean"/>
  2730. <param name="ignoreSizeLimit" type="boolean"/>
  2731. <exception name="IOException" type="java.io.IOException"/>
  2732. </method>
  2733. <method name="getResponeFromNMWebService" return="com.sun.jersey.api.client.ClientResponse"
  2734. abstract="false" native="false" synchronized="false"
  2735. static="false" final="false" visibility="public"
  2736. deprecated="not deprecated">
  2737. <param name="conf" type="org.apache.hadoop.conf.Configuration"/>
  2738. <param name="webServiceClient" type="com.sun.jersey.api.client.Client"/>
  2739. <param name="request" type="org.apache.hadoop.yarn.logaggregation.ContainerLogsRequest"/>
  2740. <param name="logFile" type="java.lang.String"/>
  2741. </method>
  2742. <method name="getNodeHttpAddressFromRMWebString" return="java.lang.String"
  2743. abstract="false" native="false" synchronized="false"
  2744. static="false" final="false" visibility="public"
  2745. deprecated="not deprecated">
  2746. <param name="request" type="org.apache.hadoop.yarn.logaggregation.ContainerLogsRequest"/>
  2747. <exception name="ClientHandlerException" type="com.sun.jersey.api.client.ClientHandlerException"/>
  2748. <exception name="UniformInterfaceException" type="com.sun.jersey.api.client.UniformInterfaceException"/>
  2749. <exception name="JSONException" type="org.codehaus.jettison.json.JSONException"/>
  2750. </method>
  2751. <field name="HELP_CMD" type="java.lang.String"
  2752. transient="false" volatile="false"
  2753. static="true" final="true" visibility="public"
  2754. deprecated="not deprecated">
  2755. </field>
  2756. </class>
  2757. <!-- end class org.apache.hadoop.yarn.client.cli.LogsCLI -->
  2758. <!-- start class org.apache.hadoop.yarn.client.cli.SchedConfCLI -->
  2759. <class name="SchedConfCLI" extends="org.apache.hadoop.conf.Configured"
  2760. abstract="false"
  2761. static="false" final="false" visibility="public"
  2762. deprecated="not deprecated">
  2763. <implements name="org.apache.hadoop.util.Tool"/>
  2764. <constructor name="SchedConfCLI"
  2765. static="false" final="false" visibility="public"
  2766. deprecated="not deprecated">
  2767. </constructor>
  2768. <method name="main"
  2769. abstract="false" native="false" synchronized="false"
  2770. static="true" final="false" visibility="public"
  2771. deprecated="not deprecated">
  2772. <param name="args" type="java.lang.String[]"/>
  2773. <exception name="Exception" type="java.lang.Exception"/>
  2774. </method>
  2775. <method name="run" return="int"
  2776. abstract="false" native="false" synchronized="false"
  2777. static="false" final="false" visibility="public"
  2778. deprecated="not deprecated">
  2779. <param name="args" type="java.lang.String[]"/>
  2780. <exception name="Exception" type="java.lang.Exception"/>
  2781. </method>
  2782. <doc>
  2783. <![CDATA[CLI for modifying scheduler configuration.]]>
  2784. </doc>
  2785. </class>
  2786. <!-- end class org.apache.hadoop.yarn.client.cli.SchedConfCLI -->
  2787. </package>
  2788. <package name="org.apache.hadoop.yarn.client.util">
  2789. </package>
  2790. </api>