This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; to sie dlawi przy wiekszej liscie albo wektorze | |
(defn buildlist [x acc] | |
(if (= x 0) acc | |
(buildlist (dec x) (cons x acc)))) | |
;; to dziala ok | |
(defn buildlist2 [x acc] | |
(if (= x 0) acc | |
(recur (dec x) (cons x acc)))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns prop-test.core | |
(:require [clojure.test.check :as tc] | |
[clojure.test.check.generators :as gen] | |
[clojure.test.check.properties :as prop] | |
[cheshire.core :as json])) | |
(def key-gen | |
(gen/such-that not-empty gen/string-alphanumeric)) | |
(def value-any (gen/one-of [gen/string-alphanumeric gen/boolean gen/int])) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Starting nREPL server via lein repl :headless... | |
Contacting host: melpa.milkbox.net:80 | |
Quit | |
error in process sentinel: nrepl-server-sentinel: Could not start nREPL server: Retrieving cider/cider-nrepl/0.9.0-SNAPSHOT/cider-nrepl-0.9.0-20150413.143741-24.pom from clojars | |
Retrieving compliment/compliment/0.2.1-SNAPSHOT/compliment-0.2.1-20150306.111224-5.pom from clojars | |
Retrieving defprecated/defprecated/0.1.1/defprecated-0.1.1.pom from clojars | |
Retrieving cljs-tooling/cljs-tooling/0.1.5-SNAPSHOT/cljs-tooling-0.1.5-20150313.183918-2.pom from clojars | |
Retrieving debugger/debugger/0.1.7/debugger-0.1.7.pom from clojars | |
Retrieving cljfmt/cljfmt/0.1.10/cljfmt-0.1.10.pom from clojars |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
actorRef ! "whatever" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- 1. Create 'schema' ;) | |
create tablespace test_user_ts | |
datafile 'test_user_tabspace.dat' | |
size 10M reuse | |
autoextend on next 500K; | |
create temporary tablespace test_user_ts_tmp | |
tempfile 'test_user.tabspace_temp.dat' | |
size 10M reuse |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import akka.actor._ | |
import akka.util.ByteString | |
import spray.http.HttpEntity.Empty | |
import spray.http.MediaTypes._ | |
import spray.http._ | |
import spray.routing.{HttpService, RequestContext, SimpleRoutingApp} | |
object ChunkedSpray extends App with SimpleRoutingApp { | |
import StreamingActor._ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import akka.actor._ | |
import akka.util.ByteString | |
import spray.http.HttpEntity.Empty | |
import spray.http.MediaTypes._ | |
import spray.http._ | |
import spray.routing.{HttpService, RequestContext, SimpleRoutingApp} | |
object StreamingActor { | |
// helper methods |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import akka.actor._ | |
import akka.util.ByteString | |
import spray.http.HttpEntity.Empty | |
import spray.http.MediaTypes._ | |
import spray.http._ | |
import spray.routing.{HttpService, RequestContext, SimpleRoutingApp} | |
object ChunkedSpray extends App with SimpleRoutingApp { | |
import StreamingActor._ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import spray.http.MediaType | |
import spray.http.MediaTypes._ | |
/** | |
* Recognize MediaType based on file name | |
* @return MediaType | |
*/ | |
def mimeType: String => MediaType = { | |
lazy val ExtensionRegex = """^.*\.(.*)$""".r |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-J-Xmx4G | |
-J-XX:+UseConcMarkSweepGC | |
-J-XX:+CMSClassUnloadingEnabled | |
-J-Xss2M -Duser.timezone=GMT | |
-jvm-debug 5008 |