Check invalid uuid for get-by-instance db api

The db api get_node_by_instance did not check if the given
instance uuid is a valid uuid or not. This patch fixes it.

Change-Id: Ic22e0bf5db34fdd3d8ef974f40ea3a736ee95525