I'm trying to run the latest JBang v0.102.0 on Eclipse/IBM JDK, but I get this error.
Any suggestions?
C:\bin\jbang\bin>java -version
openjdk version "17.0.5" 2022-10-18
IBM Semeru Runtime Open Edition 17.0.5.0 (build 17.0.5+8)
Eclipse OpenJ9 VM 17.0.5.0 (build openj9-0.35.0, JRE 17 Windows 11 amd64-64-Bit Compressed References 20221018_298 (JIT enabled, AOT enabled)
OpenJ9 - e04a7f6c1
OMR - 85a21674f
JCL - 32d2c409a33 based on jdk-17.0.5+8)
C:\bin\jbang\bin>jbang.cmd
Errore: LinkageError durante il caricamento della classe principale dev.jbang.Main
java.lang.NoSuchFieldError: jdk/internal/loader/URLClassPath$JarLoader.csu
You'll need to provide more details about your environment; using the same VM works for me:
C>java --version openjdk 17.0.5 2022-10-18 IBM Semeru Runtime Open Edition 17.0.5.0 (build 17.0.5+8) Eclipse OpenJ9 VM 17.0.5.0 (build openj9-0.35.0, JRE 17 Windows 10 amd64-64-Bit Compressed References 20221018_298 (JIT enabled, AOT enabled) OpenJ9 - e04a7f6c1 OMR
- 85a21674f JCL - 32d2c409a33 based on jdk-17.0.5+8)
C>dir Volume in drive C has no label. Volume Serial Number is 980D-DE8B
Directory of C:\cygwin\home\keithc\jbang-0.102.0\bin
80/02/01 00:00 <DIR> . 80/02/01 00:00 <DIR> .. 80/02/01 00:00 7,495 jbang 80/02/01 00:00 3,115 jbang.cmd 80/02/01 00:00 5,810,175 jbang.jar 80/02/01 00:00 7,737 jbang.ps1
4 File(s) 5,828,522 bytes
2 Dir(s) 269,905,985,536 bytes free
C>jbang.cmd --version
0.102.0
It also works with a jar I built from source:
C>java -cp jbang.jar dev.jbang.Main --version
0.102.0.7
Related
I am trying to use Netbeans 12.5 profiler on OpenJDK 64-Bit Server VM (Zulu 8.58.0.13-CA-macos-aarch64)
The first calibration process always fail.
Deleting ~/.nbprofiler doesn't fix the problem.
I am getting the error:
Profiler calibration data file does not exists:
/Users/myhome/.nbprofiler/machinedata.jdk18
and Netbeans output:
*** Profiler message (Sun Jan 23 12:30:38 CET 2022): Starting target application...
/Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/bin/java
-agentpath:/Applications/NetBeans/Apache NetBeans 12.5.app/Contents/Resources/NetBeans/netbeans/profiler/lib/deployed/jdk16/mac/libprofilerinterface.jnilib
-Xbootclasspath/a:/Applications/NetBeans/Apache NetBeans 12.5.app/Contents/Resources/NetBeans/netbeans/profiler/lib/jfluid-server.jar:/Applications/NetBeans/Apache
NetBeans
12.5.app/Contents/Resources/NetBeans/netbeans/profiler/lib/jfluid-server-15.jar
org.netbeans.lib.profiler.server.ProfilerServer
/Applications/NetBeans/Apache NetBeans
12.5.app/Contents/Resources/NetBeans/netbeans/profiler/lib/deployed/jdk16/mac
5141 10 Profiler+Calibration+Run
*** Profiler warning (Sun Jan 23 12:33:11 CET 2022): timed out while trying to connect to the target JVM.
*** Profiler error (Sun Jan 23 12:33:11 CET 2022): connection with server not open
My environment:
Netbeans 12.5 openjdk version "1.8.0_312" OpenJDK Runtime Environment
(Zulu 8.58.0.13-CA-macos-aarch64) (build 1.8.0_312-b07) OpenJDK 64-Bit
Server VM (Zulu 8.58.0.13-CA-macos-aarch64) (build 25.312-b07, mixed
mode) macOS 12.1 Chip Apple M1 Pro
Thanks in advance for any help/suggestion
You can manually create your calibration file.
Navigate to the directory
cd ~/.nbprofiler
Then create the file machinedata.jdk18
touch machinedata.jdk18
And lastly, give the file 644 permission
chmod 644 machinedata.jdk18
Once you finish, you can run the profiler without errors.
I'm not able to set Java11 to my JAVA_HOME env
I installed Java through home brew, how can I switch the version?
I needed to intall this java zulu to run Salesforce Data loader.
$ java -version
openjdk version "11.0.12" 2021-07-20
OpenJDK Runtime Environment Homebrew (build 11.0.12+0)
OpenJDK 64-Bit Server VM Homebrew (build 11.0.12+0, mixed mode)
$ /usr/libexec/java_home -V
/usr/libexec/java_home -V
Matching Java Virtual Machines (1):
16.0.2 (x86_64) "Azul Systems, Inc." - "Zulu 16.32.15" /Library/Java/JavaVirtualMachines/zulu-16.jdk/Contents/Home
/Library/Java/JavaVirtualMachines/zulu-16.jdk/Contents/Home
ls -la /usr/bin/java
-rwxr-xr-x 1 root wheel 138880 Jan 1 2020 /usr/bin/java
ls -la /System/Library/Frameworks/JavaNativeFoundation.framework/Versions/Current
lrwxr-xr-x 1 root wheel 1 Jan 1 2020 /System/Library/Frameworks/JavaNativeFoundation.framework/Versions/Current -> A
I am facing a quite bizarre situation regarding Intellij IDEA and Pycharm annotate (git blame) functionality.
Late last year I decided to install different JDKs on my MacOS Mojave (version 10.14.6) for development purposes. It seemingly messed up things quite bit, so I spent some time trying to "undo" (i.e., removing) the JDKs and jEnv. I am able to start and use IntelliJ IDEA and PyCharm (in fact, I never lost the ability to start and use them), but both programs now show a wrong fixed date (10/01/2019) for all the lines when I click on "Annotate" option of every versioned file no matter how old or new is the line. If I use git blame on the command line I see the correct dates of each file's lines. Downloading and installing the newest version of Intellij IDEA didn't help to solve the issue. Please, anyone could help me restore the default behaviour?
The default java version is below:
openjdk version "11.0.1" 2018-10-16
OpenJDK Runtime Environment 18.9 (build 11.0.1+13)
OpenJDK 64-Bit Server VM 18.9 (build 11.0.1+13, mixed mode)
git blame on CLI:
Annotate option in Intellij IDEA:
The default java version is:
openjdk version "11.0.1" 2018-10-16
OpenJDK Runtime Environment 18.9 (build 11.0.1+13)
OpenJDK 64-Bit Server VM 18.9 (build 11.0.1+13, mixed mode)
The git version is:
git version 2.21.1 (Apple Git-122.3)
The Intellij IDEA and PyCharm versions are:
IntelliJ IDEA 2020.3.1 (Community Edition)
Build #IC-203.6682.168, built on December 29, 2020
Runtime version: 11.0.9.1+11-b1145.63 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 10.14.6
GC: ParNew, ConcurrentMarkSweep
Memory: 990M
Cores: 4
Registry: editor.distraction.free.mode=true
Non-Bundled Plugins: DBN
PyCharm 2019.3.4 (Community Edition)
Build #PC-193.6911.25, built on March 18, 2020
Runtime version: 11.0.6+8-b520.43 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
macOS 10.14.6
GC: ParNew, ConcurrentMarkSweep
Memory: 990M
Cores: 4
Registry:
Non-Bundled Plugins: com.alayouni.ansiHighlight, com.intellij.ideolog
Try to right click on the annotations in Intellij -> Options -> Show Commit Timestamp.
Im using Openshift Platfrom (jre 1.6) to deploy my java application with jasper reports. From last few days Im receiving following exception during jasper report execution.
java.lang.NullPointerException
sun.font.FontManager.getDefaultPlatformFont(FontManager.java:3409)
sun.java2d.SunGraphicsEnvironment$2.run(SunGraphicsEnvironment.java:263)
java.security.AccessController.doPrivileged(Native Method)
sun.java2d.SunGraphicsEnvironment.<init>(SunGraphicsEnvironment.java:164)
any info how to resolve this issue?
Our sysadmins had updated java to
java version "1.6.0_39"
OpenJDK Runtime Environment (IcedTea6 1.13.11) (rhel-1.13.11.1.el6_8-x86_64)
OpenJDK 64-Bit Server VM (build 23.25-b01, mixed mode)
on
Linux version 2.6.32-573.7.1.el6.x86_64 (mockbuild#x86-031.build.eng.bos.redhat.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16) (GCC) ) #1 SMP Thu Sep 10 13:42:16 EDT 2015
I got around that problem by installing these with yum
dejagnu.noarch 1:1.4.4-17.el6
dejavu-sans-mono-fonts.noarch 2.33-1.el6
dejavu-serif-fonts.noarch 2.33-1.el6
yum install dejagnu.noarch 1:1.4.4-17.el6
yum install dejavu-sans-mono-fonts.noarch 2.33-1.el6
yum install dejavu-serif-fonts.noarch 2.33-1.el6
I am trying to get the Java 6 JDK on my mac. I've tried downloading this http://support.apple.com/kb/DL1572
But I can't find it in /Library/Java/JavaVirtualMachines
I already have Java 8 installed, and I don't want to remove it or replace it, I just want to have the Java 1.6 JDK that I can work with on my computer. (Need it to do my mandatory assignemtns for class. Studying Computer Science)
What do I have to do? Thanks in advance!
It installs in a different location.
$ uname -a
Darwin Yoyo-2.local 13.4.0 Darwin Kernel Version 13.4.0: Sun Aug 17 19:50:11 PDT 2014; root:xnu-2422.115.4~1/RELEASE_X86_64 x86_64 i386 MacBookPro11,3 Darwin
$ /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java -version
java version "1.6.0_65"
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode)