New Worst Day Record

Some months ago I thought I’d hit a low in my life when my then 7 week old daughter had to undergo surgery for intestinal invagination. Well, this midsummer’s eve was even worse. Natalie had been sick for almost two days. We had called the hospital, which told us that the flu was at large among small kids in Stockholm right now, and that we had nothing to worry about. The second day she actually seemed to be better. She got to keep some food. Well, two hours after eating she started vomiting again. She didn’t even get to keep water, so we went straight for the hospital. At the hospital they gave her antibiotics and put her on IV since she was dehydrated. Sure enough – X-rays showed that the intestines were obstructed and we went by ambulance (again) to Karolinska (the hospital where the surgeons for infants are located).

When we arrived at the hospital, she was fairly lucid but weak. They connected her to telemetry equipment monitoring her heart rate and oxygen levels and then we went for another round of X-rays. That’s when the scariest moment in my life so far happened. We were almost done with the X-rays when the Natalie’s oxygen saturation levels started to crash. The nurse standing next to Natalie got stressed out and yelled “Call the doctor. Call him now!”, while running for an oxygen bottle next to the entrance to the room. She started giving Natalie oxygen whilst rather incoherently discussing with one of the other nurses what emergency code to use on one of the handsets. During all this I was standing next to the X-ray machine, holding Natalie’s hand. My mind was racing to horrible conclusions and I was thinking “shit, ohpleaseohpleaseohplease, nononono, I really can’t loose her”. I glanced at Malin, and she looked just about as terrified as I felt. I watched the oxygen work it’s magic, and the saturation levels started to improve.

They put a probe through her nose down her stomach, through which they sent contrast fluid. Then they took X-ray images every now and then to find out where the obstruction was. The diagnosis was Ileus, and they decided surgery was necessary. Once they opened her up, they couldn’t believe how bad it was. She had, after all, been fairly lucid during all this. They had to cut away 90cm of her small intestine.

Now we’re at home again, and they expect her to make a full recovery, despite the heavy surgery. I’m just glad it is over, and I pray my lovely little daughter never have to go through something like this again. Ever.

The JRockit Book is Now in Print!

Yes. I know. It’s been in print for some days already, but I haven’t found time to write about it until now. The book is a good guide for JVM’s in general, and for JRockit in particular. If you’ve ever wondered how the innards of the Java Virtual Machine works, or how to use the JRockit Mission Control to hunt down problems in your Java applications, this book is for you.

8068_Oracle JRockit The Definitive Guide_Cov

The book is written for intermediate to advanced Java Developers.

These are the chapters:

  1. Getting Started
  2. Adaptive Code Generation
  3. Adaptive Memory Management
  4. Threads and Synchronization
  5. Benchmarking and Tuning
  6. JRockit Mission Control
  7. The Management Console
  8. The Runtime Analyzer
  9. The Flight Recorder
  10. The Memory Leak Detector
  11. JRCMD
  12. Using the JRockit Management APIs
  13. JRockit Virtual Edition

    Appendix A: Bibliography
    Appendix B: Glossary
    Index

The book is 588 pages long.
For more information about the book, see the book page at Packt.

Embarrassing Bug

Writing the JRockit book has made me take trips down memory lane more than once. The last read through made me think of one of the more embarrassing bugs we’ve had in JRockit Mission Control. Since it’s too late to add content to the book – most of the chapters are already finalized, or in the process of being finalized -  I thought I’d just put it here on the blog. 🙂

So, one of the more embarrassing bugs in Mission Control would be when an attibute was misspelt in the Management Console. An attribute ending with the word count lacked the letter ‘o‘. The bug report stated that the "customer was not amused".

I couldn’t help being slightly amused though.

JRockit R28/JRockit Mission Control 4.0 is out!

The next major release of JRockit is finally out! Here are some highlights:

  • Includes the all new JRockit Flight Recorder – supersedes the old JRockit Runtime Analyser. The new flight recorder is inspired by the “black box” in airplanes. It uses a highly efficient recording engine and thread local buffers to capture data about the runtime and the application running in the JVM. It can be configured to always be on, so that whenever anything “interesting” happens, data can be dumped for some time back. Think of it as your own personal profiling time machine.
  • Automatic shortest path calculation in Memleak – no longer any need for running around in circles when trying to find your way back to a thread root from an instance.
  • Memleak can now show class loader related information and split graphs on a per class loader basis.
  • More easily configured JMX agent – default port for both RMI Registry and RMI Server can be configured, and is by default the same, allowing easier configuration of firewalls.
  • Up to 64 GB (was 4GB) compressed references.
  • Per thread allocation profiling in the Management Console.
  • Native Memory Tracking – it is now possible to track native memory allocations with very high resolution. The information can either be accessed using JRCMD, or the dedicated Native Memory Tracking experimental plug-in for the Management Console (alas only available for the upcoming 4.0.1 release).
  • JRockit can now produce heap dumps in HPROF format.
  • Cooperative suspension – JRockit is no longer using system signals for stopping threads, which could lead to hangs if signals were lost or blocked (for example bad NFS shares). Now threads check periodically to see if they are suspended.
  • VPAT/Section 508 compliant JRMC – greatly improved keyboard navigation and screen reader support.

See New and Noteworthy for more information.

JRockit Mission Control 4.0.0 can be downloaded from here:
http://www.oracle.com/technology/software/products/jrockit/index.html

There is even a book to go with JRMC 4.0.0/JRockit R28!  🙂http://www.packtpub.com/oracle-jrockit-the-definitive-guide/book/

Laziness is the Mother of All Inventions

I recently got tired of monitoring the weather for various locations to find a nice time and spot to fly my planes. Enter WindBot. WindBot sends me an e-mail whenever new opportunities are found:

—–

The WindBot@hirt.se has found changes to the available flying opportunities for you in Trollbäcken:

New opportunities:
==================
Friday 15:00 (2010-04-23) [wind 2.0m/s, precipitation 0.0mm, cloud cover 43.0%]
Friday 22:00 (2010-04-23) [wind 2.0m/s, precipitation 0.0mm, cloud cover 100.0%]

Lost opportunities:
===================

Triggering condition was:
MicroPlaneFlyCondition [wind speed <= 2.0, precipitation <= 1.0, 5 <= time <= 22]

/WindBot v0.0.3

—–

Lovely! 🙂

My Server and Folding@Home

I’ve started running folding at home on all my computers, including the server and the PS3. Since my connection is a bit sluggish, it will probably not be that noticable anyway.  😉

folding

For more information, see http://folding.stanford.edu/. Donate a few cycles and be part of the world’s biggest super-computer! It’s all for a good cause!

JRockit Mission Control @ OOW 2009

There are a bunch of JRockit related sessions at OOW 2009! Joy!

Here are the ones I am involved in:

Session ID Session Title Date/Time Room

S309689

The Next Generation of Profiling and Diagnostics Tools

Sunday
10/11/2009
10:30 – 11:30

Hilton Hotel
Golden Gate 4/5

S309676

Advanced Java Diagnostics and Profiling with Oracle JRockit Mission Control

Monday
10/12/2009
11:30 – 12:30

Hilton Hotel
Continental Ballroom 4

Other exciting sessions:

Session ID Session Title Date/Time Room
S309305 Oracle JRockit: What’s New and What’s Coming Monday
10/12/2009
16:00 – 17:00
Marriott Hotel
Salon 7
S309680 Latency Is a Bug: Tuning Your Java Virtual Machine for Optimal Performance Monday
10/12/2009
10:15 – 11:15
Hilton Hotel
Continental Ballroom 4
S309331 A Next-Generation Platform for Virtualized Java Wednesday
10/14/2009
13:00 – 13:30
Moscone South
Room 309

Scariest Night Ever

Last 32 hours have been a nightmare. Malin called me at work around 10 a.m. yesterday and told me Natalie wasn’t herself. She was really lax and not responding. I immediately took the bike to the drug store, bought a breast pump and went home. After spoon-feeding her some milk it looked like she started to come around. She didn’t get to keep the milk for long though. We tried a few times, but every time we tried she vomited after a little while. We called the doctor who told us to bring her in.

At the hospital (SöS) she got some routine anti-biotic treatment and they took a lot of different tests. When we changed diapers, we discovered quite a bit of blood in her feces and they put us in a room for observation. Later she underwent a battery of X-rays. The X-ray was probably not so traumatic for Natalie, but holding her tiny little body beneath that X-ray machine really broke my heart.

After getting the results from the X-rays, Natalie had to get an ultra sound examination. The ultra sound revealed intestinal invagination – part of the intestines had folded in on themselves (telescoping).

They wrapped Natalie up in blankets and strapped her to an ambulance stretcher. Malin and Natalie went by ambulance to another hospital (Astrid Lindgren’s) where the pediatric surgeons in Stockholm reside. Natalie looked so tiny and cute on that stretcher that I’d probably have laughed if circumstances would have been different. I followed in my car.

At Astrid Lindgren’s the specialist put her in another X-ray machine and the team started filling her with contrast fluid. Sometimes the pressure from the contrast fluid can be used to make the intestines sort themselves out without having to resort to surgery. She had some morphine in her drip by then, so she didn’t seem to mind terribly.

In this case it worked out, and they never had to cut her open. The procedure was done by 3 a.m. in the morning. By this time Natalie was totally exhausted from all the vomiting, the morphine and the contrast fluid procedure. They kept us for observation and we stayed the night. Today we arrived back at home. A little while ago we were, probably for the very first time, immensely happy to find that she’d done #2. A lot.

Welcome to the world!

Less than two days ago my daughter Natalie was borne. She is 51 cm tall and weighs in at 3850g. Malin, Natalie and I are all exhausted from the experience, but otherwise fine.

She is the cutest little thing and has already managed to wrap me all around her tiny little finger.