Fixed a couple of trivial typos in BlockingConnection init.
Fixed various heartbeat bugs
Merge pull request #171 from datakurre/master

Fixed a couple of trivial typos in BlockingConnection's init.
Add flush call when publishing messages, but set the flush so polling is write only - this prevents callbacks from interrupting between the frames of a publish; Add an optional parameter to poll() which allows for write only polls
Remove unused and expensive import
Remove pika.log and use a local logger in each module

This reduces unneeded code in Pika and relies on the logging module to do things that were done in pika.log and when calling it and appending class or module names.
Merge pull request #173 from openx/patches

Asynch patches
Remove the import outright
Fix merge conflict
Refactor a bunch of methods in Connection to make it easier to test

- Removal of unused template.py
- Code cleanup in related modules
- New channel behavior, if Channel.basic_cancel is called, any subsequent deliveries for the consumer_tag will be rejected.
- General code cleanup
Merge branches 'code-cleanup' and 'master'
Bugfix, needs to call correct method name
Conditional error message for Exchange
Add connection state to Channels

- Don't send frames on a closed channel
- When remotely closed, set as closed
Updates to base_connection

- Return bytes written and read from _handle_* methods
- Don't set timeout by default, as it'll get overridden by socket.setblocking anyway
General Connection cleanup

- Lower default socket timeout
- Cleanly handle remote shutdowns
- Don't try and send Channel.CloseOk to a connected socket
- Raise an exception if a frame makes it all the way to frame_write
Cleanly handle both remote and local Connection.Close
Address the issue in issue 163
Address Issue #139
Give the socket a timeout when trying to connect

Address issue #100