Updated server to support hierarchical entities.