public static Map < String , String > getBlockDeviceMapping ( ) { Map < String , String > blockDeviceMapping = new HashMap < String , String > ( ) ; List < String > devices = getItems ( EC2_METADATA_ROOT + "/block-device-mapping" ) ; if ( devices != null ) { for ( String device : devices ) { blockDeviceMapping . put ( device , getData ( EC2_METADATA_ROOT + "/block-device-mapping/" + device ) ) ; } } return blockDeviceMapping ; }
Get the virtual devices associated with the ami root ebs and swap .