ResourceInstance createExtensionResource(String extensionName) {

    return createResource(Resource.Type.Extension,
        Collections.singletonMap(Resource.Type.Extension, extensionName));

  }
Service for extensions management.

An extension version is like a stack version but it contains custom services.  Linking an extension
version to the current stack version allows the cluster to install the custom services contained in
the extension version.
ambari-server/src/main/java/org/apache/ambari/server/api/services/ExtensionsService.java