add handling for number of instances to domain-server
add the ability to ask for multiple instances from JS page