Skip to content

Commit

Permalink
Remove (all but one) reflection from riemann.client.
Browse files Browse the repository at this point in the history
  • Loading branch information
aphyr committed May 23, 2012
1 parent 9be50e2 commit a404d3b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions project.clj
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"A network event stream processor. Intended for analytics, metrics, and
alerting; and to glue various monitoring systems together."
:url "http://github.com/aphyr/riemann"
; :warn-on-reflection true
:repositories {
"boundary-site" "http://maven.boundary.com/artifactory/repo"
}
Expand Down
10 changes: 5 additions & 5 deletions src/riemann/client.clj
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@

(defn send-event
"Send an event over client."
([^AbstractRiemannClient client event]
([client event]
(send-event client event true))
([^AbstractRiemannClient client event ack]
(let [e (.event client)]
Expand All @@ -44,7 +44,7 @@
(when-let [s (:state event)] (.state e s))
(when-let [d (:description event)] (.description e d))
(when-let [m (:metric event)] (.metric e (float m)))
(when-let [t (:tags event)] (.tags e t))
(when-let [^java.util.List t (:tags event)] (.tags e t))
(when-let [t (:time event)] (.time e (long t)))
(when-let [t (:ttl event)] (.ttl e (float t)))

Expand All @@ -57,7 +57,7 @@
(tcp-client)
(tcp-client :host \"foo\" :port 5555)"
[& { :keys [host port]
[& { :keys [^String host ^Integer port]
:or {port 5555
host "localhost"}
:as opts}]
Expand All @@ -69,7 +69,7 @@
(udp-client)
(udp-client :host \"foo\" :port 5555)"
[& {:keys [host port]
[& {:keys [^String host ^Integer port]
:or {port 5555
host "localhost"}
:as opts}]
Expand All @@ -78,7 +78,7 @@

(defn close-client
"Close a client."
[client]
[^AbstractRiemannClient client]
(.disconnect client))

(defn reconnect-client
Expand Down

0 comments on commit a404d3b

Please sign in to comment.