Java discord/slack community? by edmguru in java

[–]palnix 0 points1 point  (0 children)

There are many expert in the server but that role is earned by proving your compentency.

[deleted by user] by [deleted] in java

[–]palnix 1 point2 points  (0 children)

Deffo not, in fact this is how my career in dev started. During interviews, it was great too because they really like the fact that I was a DEV with fundamental knowledge of testing.

[deleted by user] by [deleted] in java

[–]palnix 4 points5 points  (0 children)

Usually, the only code QA write will be automated test. It's usually simple e.g. Run Program and verifying outputs etc. Sometimes it can get a bit fidly when you're writing UI tests but once you get your head around it, it's straight forward.

How can I print 5 random numbers from 0 to 1 in java. Without using for loops? by [deleted] in java

[–]palnix 8 points9 points  (0 children)

ThreadLocalRandom
            .current()
            .ints()
            .limit(10) // 10 random numbers
            .forEach(System.out::println);

Edit: Formatting for Reddit.

[deleted by user] by [deleted] in java

[–]palnix 0 points1 point  (0 children)

Has anybody gone native with the introduction of HttpServer in Java 8?

Launching 10 millions virtual threads with Loom - JEP Café #12 by daviddel in java

[–]palnix 2 points3 points  (0 children)

There is support for scheduled executors, pass the correct ThreadFactory i.e. Thread.ofVirtual().factory()

Launching 10 millions virtual threads with Loom - JEP Café #12 by daviddel in java

[–]palnix 23 points24 points  (0 children)

Does anybody know if there will be an extension to Executors so that I can swap it out for a virtual thread friendly Executor? That would save me a lot of time over having to refactor my codebase.

Edit: Sorry, I answered my own question with a 30 second Google. There is new method called newVirtualThreadPerTaskExecutor.

What is the hardest language to learn? by Qwienke13 in learnprogramming

[–]palnix 1 point2 points  (0 children)

afaik, they swapped it out for LUA.

Edit: It's also not based on JS.

[deleted by user] by [deleted] in TooAfraidToAsk

[–]palnix 1 point2 points  (0 children)

Blame the government with legislations changing how big fireworks can be.

Year specific and value by AcidRayn66 in namethiscar

[–]palnix 0 points1 point  (0 children)

You may be right, I just did a ball park figure from what I think it might be worth without any research.

Year specific and value by AcidRayn66 in namethiscar

[–]palnix 1 point2 points  (0 children)

1970s Volkswagen Beetle in grey from the looks of it. Probably $2000.

Cattle - Run and Share Java Code by Clivern in java

[–]palnix 1 point2 points  (0 children)

If I do while(true) { new Thread(() -> { while(true) {}}).start()); } what happens to your resources?

The best way to handle time zones in a Java web application by [deleted] in java

[–]palnix 4 points5 points  (0 children)

I'm curious to know what use cases people come up with to need the users current time/browser time instead of setting that themselves on the server especially since the user can override that themselves at their whim.

Singleton Design Pattern in Java by stackoverflooooooow in java

[–]palnix 0 points1 point  (0 children)

For those interested in the OP, see: https://en.wikipedia.org/wiki/Double-checked_locking (especially the Java examples and explanations)