upload_engine,
cache_fname,/* cache_fname is duplicated in the transfer constructor*/
VolumeName, /* VolumeName is duplicated in the transfer constructor*/
+ name(), /* device name() is duplicated in the transfer constructor*/
upart,
driver,
dcr->jcr->JobId,
download_engine,
cache_fname,/* cache_fname is duplicated in the transfer constructor*/
VolumeName, /* VolumeName is duplicated in the transfer constructor*/
+ name(), /* device name() is duplicated in the transfer constructor*/
dpart,
driver,
dcr->jcr->JobId,
* funct : function to process
* arg : argument passed to the function
* cache_fname : cache file name is duplicated in the transfer constructor
- * volume_name : volume name is duplicated in the transfer constructor
+ * volume_name : volume name is duplicated in the transfer constructor
+ * device_name : device name is duplicated in the transfer constructor
* part : part index
* driver : pointer to the cloud_driver
* dcr : pointer to DCR
transfer_engine* funct,
const char *cache_fname,
const char *volume_name,
+ const char *device_name,
uint32_t part,
cloud_driver *driver,
uint32_t JobId,
m_debug_retry(true),
m_cache_fname(bstrdup(cache_fname)), /* cache fname is duplicated*/
m_volume_name(bstrdup(volume_name)), /* volume name is duplicated*/
+ m_device_name(bstrdup(device_name)), /* device name is duplicated*/
m_part(part),
m_driver(driver),
m_job_id(JobId),
pthread_mutex_destroy(&m_mutex);
pthread_mutex_destroy(&m_stat_mutex);
+ free(m_device_name);
free(m_volume_name);
free(m_cache_fname);
if (m_use_count > 0) {
if (m_state > TRANS_STATE_PROCESSED) {
ow.get_output(OT_START_OBJ,
+ OT_STRING,"device_name", NPRTB(m_device_name),
OT_STRING,"volume_name", NPRTB(m_volume_name),
OT_INT32, "part", m_part,
OT_INT32, "jobid", m_job_id,
OT_END);
} else {
ow.get_output(OT_START_OBJ,
+ OT_STRING,"device_name", NPRTB(m_device_name),
OT_STRING,"volume_name", NPRTB(m_volume_name),
OT_INT32, "part", m_part,
OT_INT32, "jobid", m_job_id,
transfer_engine *funct,
POOLMEM *cache_fname,
const char *volume_name,
+ const char *device_name,
uint32_t part,
cloud_driver *driver,
uint32_t JobId,
funct,
cache_fname,/* cache_fname is duplicated in the transfer constructor*/
volume_name, /* volume_name is duplicated in the transfer constructor*/
+ device_name,/* device_name is duplicated in the transfer constructor*/
part,
driver,
JobId,
rtn = true;
} else {
exists = 1;
- transfer xfer(statbuf.st_size, NULL, cloud_source_name, VolumeName, apart, NULL, 0, NULL, NULL);
+ transfer xfer(statbuf.st_size, NULL, cloud_source_name, VolumeName, dev->name(), apart, NULL, 0, NULL, NULL);
rtn = put_object(&xfer, cloud_source_name, cloud_dest_name, &upload_limit);
Mmsg(err,"%s",rtn ? to:xfer.m_message);
}