Changes to application, search and history apis.

Default to paginated json instead of a json list, use the list size as the
page size in that situation.

Allow for paginated queries with no results.

Rename machine_search to search.

	modified:   api/application.py
	modified:   api/instance.py
	modified:   api/machine.py
	renamed:    service/machine_search.py -> service/search.py
PEP8 Compliance.
	modified:   core/query.py