added connection timeout to connectToHost (with callback). Commented out a few deprecated delegates