add separate functions for openning MaxSCale conn