ByteCode.News
Submit RSS Atom Podcast Sign in

Back to the channels

#java

  1. NeXeN jreicher: yeah i like it, but i would prefer a solution that doesn't come with instructions one must follow
  2. jreicher NeXeN: what do you mean? I'm not arguing, just trying to understand.
  3. NeXeN well it's an idiom devs have to adopt if they use the lib. i wanted to be dx focused as it's really not a permenant solution just a way to help people ease into the domain
  4. NeXeN it is a good solution, none the less
  5. jreicher You mean it's the devs using the lib that would be writing this try-with-resource block? I thought it was in the library itself.
  6. NeXeN yes, a dev would want to use it. it switches contexts and so it's tidy way to keep from remembering to close a context
  7. jreicher Is there a way to private an in-library helper of some kind so that this solution (which seems to be the right one) can be used without consuming devs having to write it?
  8. jreicher ^private^provide
  9. NeXeN the spring implementation is quite different as spring already understands contexts really well and it's well suited for it
  10. NeXeN and i really expect that to be 90% of the use case, but i also wanted a way for "vanilla" client code to interface with the lib without having to instantiate contexts and manually manage the lifecycle
  11. NeXeN essentially the lib lets you take a pojo and either a) use a provided object or b) wrap their object so that they can created the objects using factories i've hidden behind this context, so it's seamless you can begin to use and test value objects (identityless). there's some guards for mutation issues and other things
  12. NeXeN but you know let you benchmark if you could take a stream of objects and what they would perform as a value object....uh lemme find the jep number
  13. NeXeN hehe, jep 401 (not found)
  14. jreicher You mean the value object jep? I'm aware of that stuff
  15. jreicher ~jep401 you say?
  16. javabot '401 you say?' is not a valid JEP reference.
  17. jreicher Oh wow. I thought it would strip the suffix
  18. jreicher ~jep401
  19. javabot 'JEP 401: Value Objects (Preview)' can be found at http://openjdk.java.net/jeps/401
  20. NeXeN yeah, so the lib wraps a block of code in this context with the try-with-resources, so that the code within that block will utilize these value objects instead of regular identity based objects
  21. nevet JEP 401: Value Objects (Preview)
  22. NeXeN i originally had been building a lib to do a similar thing as value objects, which essentially packs objects into primitives for performance, but now that we have jep 401, i refactored the lib to essentially let you choose your strategy, identity safe, value objects, or primitive packed
  23. jreicher Why didn't you rewrite the whole thing in C like a normal person?
  24. NeXeN so i didn't abandon my old effort but i see that also it will be defeated by value objects. also i did some panama stuff and since it's essentially a benchmarking lib, i have made also a strategy for it, to store off heap
  25. jreicher (I'm joking, BTW)
  26. NeXeN i have some in C, but just where i needed performance
  27. NeXeN anyways, at the end of the day, now i have a neat little javafx dashboard that runs simulations to max out and count garbage collection and other stutters so i can watch how each strategy performs (identity safe, value objects, primitive packed, and panama offheap)
  28. NeXeN and i see that all my work has been deprecated. i think value objects will be how i'll do things moving forward
  29. jreicher I haven't used them yet but I've been really looking forward to doing so.
  30. NeXeN i need to start writing some docs, i'm so lazy. i want to upload it so i can get advice, but i'm embarrased because i can't maintain a project like that.....i'm too lazy
  31. NeXeN that's the purpose. i had the idea to merge it with what i had already been doing because i wanted to test it on an app i have that has lots of gc churn in the eden space
  32. NeXeN which i find i can get from like 3x to 30x in simulations (like vectors and pixel visual simulations, real data streaming in from the firehose is a different story)
  33. NeXeN one of the difficulties i have found is with threading. man with virtual threads being so cheap they really move the pressure around. it used to be you want to get latency down as small as possible, but now you gotta worry about backpressure because everything's insanely good now
  34. hassoon 'morning
  35. Inline morning
  36. odinsbane Intellij is giving me a strange warning. `'ForkJoinPool' used without 'try'-with-resources statement`
  37. odinsbane The forkjoinpool isn't autoclosable and if I put it inside of a try/catch it doesn't get rid of the warning.
  38. deebo it is autocloseable though? via AbstractExecutorService
  39. odinsbane Ah, I see. ForkJoinPool now implements closable, but I'm still targeting java 8.
  40. odinsbane Looks like that change happened in java 19.
  41. deebo language level for project maybe off then?
  42. odinsbane That would explain it. It is set to 25 somewhere, but maven has a rule to target 8.
  43. Bombe Yeah, you need to configure some more shit to make IDEA adhere to that.
  44. dreamreal targeting java 8, ouch :/
  45. Para With a gun, I hope.
  46. dreamreal hey, java 8 was really good
  47. sbalmos 8 was good, 11 was good
  48. dreamreal 25 is better, and the next LTS is likely to be yet another game changer
  49. odinsbane 25 seems to have better performance for me than 21.
  50. dreamreal tehre's a reason for that!
  51. Bombe I’m happy we recently switched our main product from Java 11 to 21.
  52. dreamreal We went 8->17, with a plan to go to 25 real soon now
  53. ernimril jikes, what is taking you soo long to get to modern java?
  54. dreamreal maintainers and/or love
  55. dreamreal ernimril: I thought you had your own compiler
  56. ernimril I do, I am actually working on it right now :-)
  57. dreamreal So why you carin about dum ol jikes huh
  58. ernimril It can actually compile itself in a loop now (java 25).... But I know it still has a few problems with real world codebases
  59. ernimril jikes was a fine compiler, sadly it never got updated for java 5
  60. dreamreal i remember being quite impressed when it first came out
  61. ernimril it was on hold for a long time, but I have gotten back to it now
  62. jbosmans way back when, it used to be expensive supported middleware keeping solutions back from upgrading
  63. Optic java 21 is the last 32 bit java i think