Skip to content

Instantly share code, notes, and snippets.

arturas@zeus:~/work/spacegame/flex$ jruby --1.9 -S rake flex:locales:check --trace
** Invoke flex:locales:check (first_time)
** Execute flex:locales:check
Checking lt.xml
UTF-8
rake aborted!
rake aborted!
incompatible character encodings: UTF-8 and ASCII-8BIT
org/jruby/RubyString.java:2499:in `concat'
/home/arturas/.rvm/rubies/jruby-1.6.6/lib/ruby/1.9/rexml/parseexception.rb:24:in `to_s'
^\2012-01-31 17:47:02
Full thread dump Java HotSpot(TM) Server VM (23.0-b11 mixed mode):
"process reaper" daemon prio=10 tid=0x095ae400 nid=0x319e waiting on condition [0x8cf52000]
java.lang.Thread.State: TIMED_WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x98dec9d8> (a java.util.concurrent.SynchronousQueue$TransferStack)
at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:226)
at java.util.concurrent.SynchronousQueue$TransferStack.awaitFulfill(SynchronousQueue.java:460)
at java.util.concurrent.SynchronousQueue$TransferStack.transfer(SynchronousQueue.java:359)
^\2012-01-31 17:18:23
Full thread dump Java HotSpot(TM) Server VM (22.0-b10 mixed mode):
"Service Thread" daemon prio=10 tid=0x09f44000 nid=0x1fe9 runnable [0x00000000]
java.lang.Thread.State: RUNNABLE
"C1 CompilerThread1" daemon prio=10 tid=0x09f39800 nid=0x1fe8 waiting on condition [0x00000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread0" daemon prio=10 tid=0x09f37c00 nid=0x1fe7 runnable [0x00000000]
^\2012-01-31 17:15:33
Full thread dump Java HotSpot(TM) Server VM (22.0-b10 mixed mode):
"process reaper" daemon prio=10 tid=0x09f15400 nid=0x1ecf waiting on condition [0x8cfe2000]
java.lang.Thread.State: TIMED_WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x98ddc190> (a java.util.concurrent.SynchronousQueue$TransferStack)
at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:226)
at java.util.concurrent.SynchronousQueue$TransferStack.awaitFulfill(SynchronousQueue.java:460)
at java.util.concurrent.SynchronousQueue$TransferStack.transfer(SynchronousQueue.java:359)
@arturaz
arturaz / gist:1710912
Created January 31, 2012 14:57
jthread dump of hanging j7 u2 nebula44 server
spacegame@nexar:~/nebula-server/current$ jstack 1241
1241: Unable to open socket file: target process not responding or HotSpot VM not loaded
The -F option can be used when the target process is not responding
spacegame@nexar:~/nebula-server/current$ jstack -F 1241
Attaching to process ID 1241, please wait...
Debugger attached successfully.
Server compiler detected.
JVM version is 22.0-b10
Deadlock Detection:
$LOAD_PATH << "lib/"
require 'celluloid'
class LogActor
include Celluloid
def log(message); puts message; end
end
LOG = LogActor.new
scala> arturas@zeus:~/work/spacegame/server$ scala
Welcome to Scala version 2.9.1.final (Java HotSpot(TM) Server VM, Java 1.7.0).
Type in expressions to have them evaluated.
Type :help for more information.
scala> :paste
// Entering paste mode (ctrl-D to finish)
object A { def t = 3 }
class A { def t = 4 }
arturas@zeus:~/work/spacegame/server$ cat t.scala
object T {
def three = 3
}
arturas@zeus:~/work/spacegame/server$ scalac t.scala
arturas@zeus:~/work/spacegame/server$ javap T.class
Compiled from "t.scala"
public final class T {
arturas@zeus:~/work/spacegame/server$ ruby ctest.rb
Starting simulation
18:03:09 [worker_1|#<Thread:0x917da50>] --- message arrived ---
18:03:09 [worker_1|#<Thread:0x917da50>] Starting work for 1 seconds.
18:03:09 [worker_2|#<Thread:0x909136c>] --- message arrived ---
18:03:09 [worker_2|#<Thread:0x909136c>] Starting work for 3 seconds.
18:03:10 [worker_1|#<Thread:0x917da50>] Done working.
18:03:10 [worker_1|#<Thread:0x917da50>] --- message arrived ---
18:03:10 [worker_1|#<Thread:0x917da50>] Waiting until worker_2 is done.
18:03:10 [worker_1|#<Thread:0x917da50>] --- message arrived ---
describe "fail" do
it "should not fail" do
a = some_method_that_returns_activerecord_relation
a.include?(object).should be_true # This does not fail.
a.should include(object) # This fails.
end
end