some namespace renaming to keep things consistent (nitpicky...)
This commit is contained in:
parent
613c75953b
commit
b61be5ae21
|
@ -6,9 +6,9 @@
|
||||||
[ring.middleware.defaults :refer [wrap-defaults site-defaults]]
|
[ring.middleware.defaults :refer [wrap-defaults site-defaults]]
|
||||||
[ring.util.response :refer [response]]
|
[ring.util.response :refer [response]]
|
||||||
[clj-pebble.core :as pebble]
|
[clj-pebble.core :as pebble]
|
||||||
[net.thegeez.browserchannel :as browserchannel]
|
[net.thegeez.browserchannel.server :as browserchannel]
|
||||||
[net.thegeez.jetty-async-adapter :as jetty]
|
[net.thegeez.browserchannel.jetty-async-adapter :as jetty]
|
||||||
[clj-browserchannel-immutant-adapter.core :as immutant]
|
[net.thegeez.browserchannel.immutant-async-adapter :as immutant]
|
||||||
[environ.core :refer [env]]))
|
[environ.core :refer [env]]))
|
||||||
|
|
||||||
(defonce clients (atom #{}))
|
(defonce clients (atom #{}))
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
(ns clj-browserchannel-immutant-adapter.core
|
(ns net.thegeez.browserchannel.immutant-async-adapter
|
||||||
(:require
|
(:require
|
||||||
[immutant.web :as iweb]
|
[immutant.web :as iweb]
|
||||||
[immutant.web.async :as iasync]
|
[immutant.web.async :as iasync]
|
||||||
[net.thegeez.async-adapter :as bc-async-adapter]))
|
[net.thegeez.browserchannel.async-adapter :as bc-async-adapter]))
|
||||||
|
|
||||||
(deftype ImmutantResponse [channel]
|
(deftype ImmutantResponse [channel]
|
||||||
bc-async-adapter/IAsyncAdapter
|
bc-async-adapter/IAsyncAdapter
|
|
@ -1,4 +1,4 @@
|
||||||
(ns net.thegeez.jetty-async-adapter
|
(ns net.thegeez.browserchannel.jetty-async-adapter
|
||||||
"BrowserChannel adapter for the Jetty webserver, with async HTTP."
|
"BrowserChannel adapter for the Jetty webserver, with async HTTP."
|
||||||
(:import [org.eclipse.jetty.server.handler AbstractHandler]
|
(:import [org.eclipse.jetty.server.handler AbstractHandler]
|
||||||
[org.eclipse.jetty.server Server Request Response]
|
[org.eclipse.jetty.server Server Request Response]
|
||||||
|
@ -10,7 +10,7 @@
|
||||||
[javax.servlet.http HttpServletRequest]
|
[javax.servlet.http HttpServletRequest]
|
||||||
[java.security KeyStore])
|
[java.security KeyStore])
|
||||||
(:require [ring.util.servlet :as servlet]
|
(:require [ring.util.servlet :as servlet]
|
||||||
[net.thegeez.async-adapter :as async-adapter]))
|
[net.thegeez.browserchannel.async-adapter :as async-adapter]))
|
||||||
|
|
||||||
;; Based on ring-jetty-async-adapter by Mark McGranaghan
|
;; Based on ring-jetty-async-adapter by Mark McGranaghan
|
||||||
;; (https://github.com/mmcgrana/ring/tree/jetty-async)
|
;; (https://github.com/mmcgrana/ring/tree/jetty-async)
|
|
@ -1,4 +1,4 @@
|
||||||
(ns net.thegeez.async-adapter)
|
(ns net.thegeez.browserchannel.async-adapter)
|
||||||
|
|
||||||
(defprotocol IAsyncAdapter
|
(defprotocol IAsyncAdapter
|
||||||
(head [this status headers])
|
(head [this status headers])
|
|
@ -1,11 +1,12 @@
|
||||||
(ns net.thegeez.browserchannel
|
(ns net.thegeez.browserchannel.server
|
||||||
"BrowserChannel server implementation in Clojure."
|
"BrowserChannel server implementation in Clojure."
|
||||||
(:require [ring.middleware.params :as params]
|
(:require [ring.middleware.params :as params]
|
||||||
[ring.util.codec :as codec]
|
[ring.util.codec :as codec]
|
||||||
[clojure.data.json :as json]
|
[clojure.data.json :as json]
|
||||||
[clojure.string :as str]
|
[clojure.string :as str]
|
||||||
[net.thegeez.async-adapter :as async-adapter])
|
[net.thegeez.browserchannel.async-adapter :as async-adapter])
|
||||||
(:import [java.util.concurrent ScheduledExecutorService Executors TimeUnit Callable ScheduledFuture]))
|
(:import [java.util.concurrent ScheduledExecutorService Executors TimeUnit Callable ScheduledFuture]))
|
||||||
|
|
||||||
;; @todo: out of order acks and maps - AKH the maps at least is taken care of.
|
;; @todo: out of order acks and maps - AKH the maps at least is taken care of.
|
||||||
;; @todo use a more specific Exception for failing writes, which
|
;; @todo use a more specific Exception for failing writes, which
|
||||||
;; indicate closed connection
|
;; indicate closed connection
|
Reference in a new issue