add hash table for typename and protocol name, speed up name querying.