Ranking Java Features Added from Versions 8 to 21!

Поделиться
HTML-код
  • Опубликовано: 17 янв 2025

Комментарии • 47

  • @thomasniessen9131
    @thomasniessen9131 3 месяца назад +5

    Virtual threads are in my firts tier, for sure. A very small change in my code safed me up to 5/6 of running time in a critical application!

    • @talesfromthejarside
      @talesfromthejarside  3 месяца назад

      Wow, that's impressive. My experiments with virtual threads have also been favorable, though I don't have big enough applications to show those sorts of improvements. Thanks for the info

    • @thomasniessen9131
      @thomasniessen9131 3 месяца назад

      @@talesfromthejarside Of course, one can argue that something was wrong before. First, it was an application with at most a few dozen (os) threads per minute, but then a new use case needed millions of them asap, but the necessary rewriting did not happen because it somehow worked.

  • @omnipoten8
    @omnipoten8 6 месяцев назад +2

    Your videos are adventurous and informative at the same time . Thanks for sharing!

  • @michaeleaster1815
    @michaeleaster1815 6 месяцев назад +3

    20:19 IMHO such a benefit in the platform is a big deal, even if I don't use the feature directly! The big story with the system-level features like virtual threads (and somewhat, with modules) is that Java is looking beyond feature-parity with C#: they are looking at Node/Javascript for areas to improve. This is true with respect to throughput metrics, start-up times, binary footprint, and release cadence (IMHO modules and cleaning up the JDK facilitates faster feature development).

  • @kappaj01
    @kappaj01 6 месяцев назад +3

    Great summary - agree big time with the shell rating. Never used it and not missing it either. tbh I work 99% in Spring env, so the HTTP client is pretty much optional for me.
    TextBlocks is a major feature in my world. Building a lot of rather large json payloads and then testing the app with that - text block is pure magic!

  • @roshinivr123
    @roshinivr123 Месяц назад

    Excellent summary! Very bold!

  • @LukasSmith827
    @LukasSmith827 6 месяцев назад +1

    looking at the changelog of anything is a huge stepping point into mastering it and this helped a lot, although I did have to take a lot of notes lol

  • @ssamani24
    @ssamani24 Месяц назад

    Love this summary. My company is in the process of moving from JDK 8 to JDK 21 and this was extremely helpful in articulating to my team what the benefits of upgrading are.
    Would have loved to see some code examples of all the features.

    • @talesfromthejarside
      @talesfromthejarside  Месяц назад

      See my videos on Data Oriented Programming for a combination of records, sealed interfaces, switch expressions, and more. In fact, most of my other videos try to use the newer features of Java in a practical way, and all of that code is in one or another of my GitHub repositories at github.com/kousen .

  • @arghyamitra3281
    @arghyamitra3281 3 месяца назад +1

    The idea of virtual thread is that u end up writing sync code but enjoy async behaviour, rather than using is async await everywhere, now from server side point spring boot 3 and most of other framework supports virtual thread by just adding one property and thats it ur existing code can scale better . Although I definitely agree with the structure concurrency part which hopefully we will get in GA by Java 25 🤞.

    • @Z3U5.0g
      @Z3U5.0g 2 месяца назад +1

      Don’t you also have green threads now in Java? I mean like lightweight threads similar to what we have in Golang.

  • @harrykaradimas857
    @harrykaradimas857 Месяц назад

    Entertaining video, I much agree with you. Except for a small detail that most people don't know : the switch in java, when you have cases as consecutive integers, gets compiled into a computed goto !
    This is very useful for writing bytecode interpreters and python developers for example have been asking that for years, it only made it recently in Python.

  • @michaeleaster1815
    @michaeleaster1815 6 месяцев назад +1

    super-fun video: thank you! Some comments: (a) I also encourage everyone to read Brian Goetz' article on data-oriented programming, which combines several features into a unified idea. (b) The history of modules, as Ken surely knows, is more complicated, as the OSGi initiative (re: bundles) was getting traction circa 2010, and there were other competing ideas as well. The Java team decided to do their own spec, and _then_ start with the JDK, which took a long, long time. There was serious debate in the community over this; pundits wondered if it would ever be complete (and the OSGi camp was incensed that their work wasn't being used). Java 9 was _finally_ the end result. If the Java team had waited longer, it would have only extended the uncertainty and acrimony. I do agree that adoption and impact seems to be quite low.

    • @talesfromthejarside
      @talesfromthejarside  6 месяцев назад +2

      Right. The way I remember it, there were members of both the OSGI and the JBoss modules teams on the committee. I think the result was good. It's just that most devs didn't realize they could upgrade and safely ignore modules if they wanted to.
      Thanks for the comment!

    • @koncz314
      @koncz314 6 месяцев назад

      Making jigsaw instead of adopting the already existing OSGi solution (not the whole spec) was a mistake.

    • @Mig440
      @Mig440 6 месяцев назад +1

      ​@@koncz314 well that would have meant no virtual threads. Java modules for the JDK is absolutely essential for that as has been pointed out on numerous occasions. The JDK from before was an unmaintainable mess that got reined in by modules. Modules outside the JDK needs to speed up but luckily it is happening albeit slowly. Try out avaje inject for example. No need for reflection magic to have DI. Now spring adopting moduels can hoepfully speed things up a bit. 😊

  • @billfly1
    @billfly1 6 месяцев назад +1

    Great job. I agree with assessments. JMS is good for JavaFX to adding the Java FX components on the Java statement.

  • @ZemenFidel
    @ZemenFidel 3 месяца назад +1

    Most of my interaction with modules so far has been when they get in my way and I have to work around them.

    • @talesfromthejarside
      @talesfromthejarside  3 месяца назад

      Yeah, I hear that. I haven't seen any real benefit from them either

  • @Talaria.School
    @Talaria.School 5 месяцев назад

    this is the kind of content I like, thanks a lot.

  • @farrukhahmedsid
    @farrukhahmedsid 6 месяцев назад +1

    Sequenced Collection? Where you put it?

    • @talesfromthejarside
      @talesfromthejarside  6 месяцев назад +2

      Oof. I knew I overlooked something. I'm not sure what a good icon would be for that, too. :) Mostly I use the getFirst() method out a lot on lists, so I would put sequenced collections at the "Okay" level, because it does exactly what I expected. Thanks for noticing.

    • @farrukhahmedsid
      @farrukhahmedsid 6 месяцев назад

      @@talesfromthejarside thanks for sharing that.

  • @attainconsult
    @attainconsult 6 месяцев назад +1

    great summary thanks

  • @Savatore83
    @Savatore83 6 месяцев назад

    well done, could you do a video for this data driven programming? It could be interesting seeing it together with java 21

  • @cariyaputta
    @cariyaputta 6 месяцев назад

    Nice overview of Java changes.

  • @adambickford8720
    @adambickford8720 6 месяцев назад +2

    I find records to be an anemic and insufficient replacement for lombok. Sure, once you consider pattern matching it's now useful, but otherwise? Nah.
    Virtual threads are huge. Even if you are just doing a request/response (with no meaningful concurrency control between requests) you'll scale far better. Getting the benefits of reactive w/o the learning curve shouldn't be overlooked. Its one of the rare things i think java's solution is *better* than async/await, co-routines, etc. Its essentially transparent (everything in java has an asterisk)
    Modules are so you can now treat logical boundaries the same as physical. i.e. all the separation of microservices but with the low price of a monolith. I'd agree it was a dollar short and a day late, but i love the idea. Kind of obnoxious things like spring modulith don't even leverage it.

  • @MattPayneOrg
    @MattPayneOrg 6 месяцев назад

    Great video!
    Please do a video about
    data oriented programming introduced by brian getz

    • @talesfromthejarside
      @talesfromthejarside  6 месяцев назад +1

      I have an app ready. I'm working on a title and thumbnail that describes it without getting way too wordy

  • @illia4503
    @illia4503 Месяц назад

    I don't think this video can be useful for experienced Java developers, but it would be useful for those studying Java and preparing for interviews. Unfortunately, the video lacks examples of each feature. Anyway, thank you for your work.

    • @talesfromthejarside
      @talesfromthejarside  Месяц назад

      The lack of examples was specifically to keep the video runtime as short as possible. Most of my other videos include code examples. See, for example, the data oriented programming examples as part of github.com/kousen/java_latest .

  • @emaayan
    @emaayan 6 месяцев назад

    another thing about jigsaw is that although it supports modules AFAIK it does not support version numbering, meaning you can't specify what version you require which is one major minus, and still might give you jar hell, oracle killed java 9 as soon as they decided with their dumb money grabbing scheme of release versioning of every 6 months, no one would upgrade to a version which would be killed in 6 months, and they probably knew that.

    • @talesfromthejarside
      @talesfromthejarside  6 месяцев назад

      Yeah, version numbering in modules is definitely an issue, which I think OSGI handles. I don't mind the six-month release schedule, though, or maybe I'm just used to it by now. Most companies only care about the LTS releases anyway.

    • @emaayan
      @emaayan 6 месяцев назад

      @@talesfromthejarside you need to remember that when 6 months schedule was released there was NO free LTS TCK jvm's available, and java 8 LTS was declared to be end of life in a year (and afterwards it would paid) , so you had to pay up, when i saw this, i've figured it would be the end of java as no company would risk trusting them again, corretto literally saved this.
      not to mention breaking backwards compatibility, consider that jaxb was removed from the jvm because it was thought of as j2ee technology , buy then they went and inserted HTTP client on java 11? cause that's not j2ee? for the record i've thought about replacing our commons http client for that, but then i remembered we also used http server in our j2se server, so what's the point .

  • @michaelm655
    @michaelm655 5 месяцев назад

    it's awesome)

  • @sadiulhakim7814
    @sadiulhakim7814 3 месяца назад

    Oh, you are a kotlin guy? Tell me from your perspective, is java doing good enough?

    • @talesfromthejarside
      @talesfromthejarside  3 месяца назад

      Honestly? Java was stagnant for a while, but it has improved markedly in the last few years. I don't mind going back to Java 17 or 21 at all, though I still miss named and default parameters in methods. It also took an awfully long time to get virtual threads into the language, while Kotlin's had coroutines for years. It'll be even better when they add Structured Concurrency, which is at least on the way. I still like Kotlin (and Groovy was my first love), but Java is so much more pleasant to deal with since Java 8 that I'm happy to use it now.

  • @witlessworm
    @witlessworm 6 месяцев назад +1

    What you might call... Java script 🥁

  • @JonDisnard
    @JonDisnard 26 дней назад

    Thanks for the video. The reason I stopped watching Midway through was because of the ridiculous icons. Please just use words next time, if you ever consider doing this again. I think your opinions are good, and everyone makes mistakes sometimes, and this was a mistake.