class ResourceInformationReflector {

	@VisibleForTesting
	void setResourceInformationUnSafe(Object resource, String resourceName, long amount) {
		if (!isYarnResourceTypesAvailable) {
			LOG.info("Will not request extended resource {} because the used YARN version does not support it.", resourceName);
			return;
		}
		try {
			resourceSetResourceInformationMethod.invoke(
				resource,
				resourceName,
				resourceInformationNewInstanceMethod.invoke(null, resourceName, amount));
		} catch (Exception e) {
			LOG.warn("Error in setting the external resource {}. Will not request this resource from YARN.", resourceName, e);
		}
	}

	private  ResourceInformationReflector();
	@VisibleForTesting  ResourceInformationReflector(String resourceClassName, String resourceInfoClassName);

}