5.20.10 Configuration Upload and Download


Configuration Upload is a process by which the configuration data is fetched from the network device.  Similarly, Configuration Download is a process in which the device is configured with the supplied data.  This feature will be of immense use, when you want to fetch the configuration details from one device and set it over another device.  


The method getDeviceConfiguration() of DeviceConfigurationAPI is used to perform Configuration Upload and Download operations. It gets the task XML as its argument and fetches the values for the attributes from the devices specified in the task.  


To download the collected data (Configuration Download), the method executeTask() of DeviceConfigurationAPI is used. This method also gets the taskXML got from the result of getDeviceConfiguration() and applies the task to the set of devices.   


For getting the values for the attributes through the ConfigClientAPI, the method requestDeviceConfiguration(String taskXML) is used.


Note: The information like attributes and the devices from which it has to be fetched are specified in the taskXML


Implementing ConfigurationUpload Interface


An interface named ConfigurationUpload has been provided which can be used by you during the Configuration Upload. When the rollback is set to true, the implementation class of this interface will be used for current configuration.  


Ordinarily, when the configuration upload fails, the current configuration will be executed by default, through which the older values gets restored to the device. If implementation is provided for the method uploadConfiguration(ConfigTask ctask) of ConfigurationUpload interface, then this implementation will be executed, in case, the configuration to the device fails.  This implementation is called whenever the getDeviceConfiguration() method is called.


Copyright © 2013, ZOHO Corp. All Rights Reserved.