Skip to content
Advertisement

Tag: java-11

Eclipse(2020 09) Java Installation issue || Windows 10 OS

I am new to Java programming. I have installed Java SE 11 (LTS) (JDK 11.0.8) on my OS. Note that former Java also has jre folder in it. But Java 11 onward there come only JDK folder. So, I have set JAVA_HOME environment variable as well as, included jdkbin in path as well. By checking on cmd java version shows

Where is the description of Constant Folding in the Java Language Specification, Java SE 11 Edition (JLS SE 11)?

As far as I know, Java deals with constant variables ยง4.12.4 by constant folding in compile time. I’ve tried my best, but I couldn’t find its description from JLS. Could anybody tell me where I could find official description of the constant folding process for Java 11? Answer The specification does not use the term Constant Folding. It has the

What is Coder in String Value?

I am reading a CSV file, by using com.opencsv.CSVReader Like below Value for header is coming like below screen shot: What’s coder here (Highlighted in yellow)? Why the value is 1 for first index and 0 for all other? Answer The official response is “none of your business”, since it’s a private member ๐Ÿ˜› Which means it can very well

Getting ‘allocation stall’ when enabling ZGC

I am testing the new zgc garbage collector that was included in java 11 since it promises really low latency. Our application is a real-time service that creates and destroys many objects per second and it does it in a multi-threaded environment using akka. When enabling zgc by passing the options -XX:+UnlockExperimentalVMOptions -XX:+UseZGC and enabling gc logs, we can see

Can’t connect to kubernetes API from inside the cluster

I’m trying to use the fabric8io/kubernetes-client in a simple example on my local minikube cluster where I get an IP of a pod some-pod-name-jnfen3 is a name of a pod which finished execution and visible if I execute kubectl get pods. https://localhost:32780/ is a kubernetes API host which I get from kubectl config view -o jsonpath=”{.clusters[?(@.name==”minikube”)].cluster.server}”. minikube has only 1

parallelStream() java 1.8 vs 11

Consider the following code: When it is compiled and run with java 11, it returns the following: But with java 1.8, it returns different result: Why results are different? Answer Both results are consistent with the Java Memory Model. One possible ordering in which execution occurs is: but, because you don’t do anything to ensure that the set and print

Advertisement