[RESOLVED] Java 8 Audio Crashes App on R21.1 and R21.2

I am using Java 8 running on the TK1 and using the javax.sound.sampled.* classes to play audio tones and samples thru the TK1 head phone port.

I had a few problems with 19.x kernel, occasionally the sound just wouldn’t play. I updated to 21.2 and then back to 21.1 and both versions seem to hang badly when I try to play any audio.

Does anyone have fix? or suggestions on where I am poke around to find a solution.

FYI… I confirmed that the sound is working on the device. I used RythmBox to play some MP3s. Looks like it is just Java that is the problem.

I have a solution that isn’t ideal but is reliable. I switch to the Open JDK VM. It uses “ICETEA” as the sound provider which acts as a wrapper to Pulse Audio.

The native library that Java 8 and Java 7 use talk with ALSA and there seems to be a bug that causes the crash.