If you have a copy of the Hadoop source and a working build environment, then here is a cool way to answer questions about which state transitions are valid. There is a Maven build command that inspects the current implementation of the state machines and summarizes the state transitions in a GraphViz file. There are visualization tools available for browsing the GraphViz file, but they are plain text, so I tend to just browse them in my text editor.
This special build command is available for both ResourceManager and NodeManager. Your question relates to the ResourceManager, so let's look at that one. > cd >hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-reso >urcemanager/ > mvn -o clean compile -Pvisualize > ls -lrt *.gv -rw-r--r--+ 1 chris staff 14K Jan 6 10:42 ResourceManager.gv Looking in that file, I can see that this is one of the state transitions for RMContainer. subgraph cluster_RMContainer { label="RMContainer" ... "RMContainer.ACQUIRED" -> "RMContainer.COMPLETED" [ label = "FINISHED" ]; ... Based on this, we know that ACQUIRED to COMPLETED is a valid state transition. Unfortunately, I'm not deep enough on this code to quickly answer the second part of your question: when would this happen? Can someone deeper on YARN please add to this? --Chris Nauroth On 1/6/16, 10:33 AM, "Prabhu Joseph" <prabhujose.ga...@gmail.com> wrote: >Hi Experts, > > I have a Custom ApplicationMaster written using TWILL which asks for 20 >Containers and RM ApplicationMasterService has assigned 20 containers out >of which 19 are moved from ACQUIRED to RUNNING. And there is one moved >from >*ACQUIRED to COMPLETED. * >So my doubt is is ACQUIRED to COMPLETED a correct state flow and if so >when >that will happen. > > >Thanks, >Prabhu Joseph