 
 import Foundation
 
-private class SessionRequest: SocketIORequester {
-    
-    // Request session
-    private let session: NSURLSession
-    // Handling a lot of requests at once
-    private var requestsQueue = NSOperationQueue()
-    
-    init() {
-        session = NSURLSession(configuration: NSURLSessionConfiguration.ephemeralSessionConfiguration(), delegate: nil, delegateQueue: self.requestsQueue)
-    }
-    
-    func sendRequest(request: NSURLRequest, completion: RequestCompletionHandler) {
-        // Do request
-        session.dataTaskWithRequest(request, completionHandler: completion).resume()
-    }
-    
-}
-
-class SocketIOConnection: SocketIOEventHandler, SocketIOEmitter, SocketIOTransportDelegate {
+class SocketIOConnection: SocketIOEventHandler, SocketIOEmitter {
     
     private let requester: SocketIORequester
     private let transport: SocketIOTransport
+    private let transportDelegate: TransportDelegate
     
     convenience init(transport: SocketIOTransport.Type) {
         self.init(requester: SessionRequest(), transport: transport)

        performEvent(event, withError: error)
    }
    
    
    // MARK: SocketIOTransportDelegate
    
    func didReceiveMessage(event: String, withString message: String) {
        

    init(requester: SocketIORequester, transport: SocketIOTransport.Type) {
        // Connection transport
        self.requester = requester
        self.transportDelegate = TransportDelegate()
        self.transport = transport(delegate: transportDelegate)
        // Designated
        super.init()
        
        // ToDo - Don't like this solution! (RP)
        self.transportDelegate.connection = self
    }
    
    func open(hostUrl: NSURL) {
