[WIP] data structures for resources

This PR introduced some data structure to represent resources.
This is a good point. I vote we defer resource merging code to the future.

However, note that in the kubernetes model, ports are *not* a dynamic resource, due to the IP-per-pod rule.