Added Dependency Injection for online/offline mode

Added dependency injection for elasticsearch online/offline mode.  As a
result, reshaped and greatly cut down the ResourceAlloc class.

Created OfflineMode and OnlineMode classes that allocate online and
offline resources upon initialization.

Created the IResourceAlloc inteface to work with OfflineMode and
OnlineMode.

Updated UnitTests in ResourceAllocTest.

Updated Controller to handle the dependency injection.

Edited some constants to make things work a little smoother.

Today was a good day.