fixed some bugs. Tested on ID10

3 jobs for 14-in-tango-device-set-cache-for-few-attributes in 5 minutes and 11 seconds (queued for 4 seconds)