[pve-devel] Plugin to add support for native ZFS on shared storage

Alexandre DERUMIER aderumier at odiso.com
Mon Aug 12 20:24:20 CEST 2013


Thanks, I'll really try to test it this month !
	

----- Mail original ----- 

De: mir at datanom.net 
À: pve-devel at pve.proxmox.com 
Envoyé: Lundi 12 Août 2013 20:12:48 
Objet: [pve-devel] Plugin to add support for native ZFS on shared storage 

This newest version fixes a serious bug cause my asynchronious AJAX calls from 
web gui. 

The problem displays its ugly face when the content tab is invoked in the gui. 
This request calls to plugin method 'list_images' which will produce a list of 
all images available on the storage server. After the gui receives this list it 
will call the plugins method 'path' on every image in the list, each call 
requires two ssh requests to the storage server and since each path call is 
made asynchronious a race condition is likely to happening if only a few 
images is found on the storage causing the receive buffer on the node being 
mangled with responses from numerous ssh calls. This means that the receive 
buffer growing faster than the the gui is able to consume causing AJAX calls 
to be terminated by the default timeout - eg. the gui gives up and shows 
'communication error' to the user. 

To prevent this I have refactored the code handling 'list_images' so that all 
needed information is collected by the first call and at the same time this 
information is cached in the plugin to elimate further calls to the storage. 
Apart from solving the nasty bug the refactored code also has improved 
performance of 'list_images' with a factor 10;-) 

_______________________________________________ 
pve-devel mailing list 
pve-devel at pve.proxmox.com 
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel 



More information about the pve-devel mailing list