Skip to content

Instantly share code, notes, and snippets.

@jcheype
Created April 9, 2013 14:48
Show Gist options
  • Select an option

  • Save jcheype/5346288 to your computer and use it in GitHub Desktop.

Select an option

Save jcheype/5346288 to your computer and use it in GitHub Desktop.
def main(args: Array[String]) {
val kryo = new KryoInjection2(new Output(1024 * 4))
kryo.register(classOf[String])
for (_ <- 1 to 100000) {
kryo("toto")
}
Thread.sleep(1000)
start = System.nanoTime()
for (_ <- 1 to 1000){
val v: Array[Byte] = kryo("toto")
}
println("delay: " + (System.nanoTime() - Main.start))
}
@jcheype
Copy link
Author

jcheype commented Apr 9, 2013

delay: 23099000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment