ByteCode.News
Submit RSS Atom Sign in

Back to the channels

#java

  1. * dob1_ joined #java
  2. * Bharton joined #java
  3. * yamada joined #java
  4. * victori- joined #java
  5. * Techcable joined #java
  6. * graves joined #java
  7. * Disconsented joined #java
  8. * ganthore joined #java
  9. * mixfix41 joined #java
  10. * pioto joined #java
  11. * deglebe joined #java
  12. * Maldivia joined #java
  13. * DCTWD joined #java
  14. * puppy_za joined #java
  15. * codebam joined #java
  16. * jontxu joined #java
  17. * bakerst joined #java
  18. * ra4king joined #java
  19. * michele joined #java
  20. * johnjay joined #java
  21. * Anaphaxaway joined #java
  22. * Anaphaxaway joined #java
  23. * metalmaniac joined #java
  24. * five618480339176 joined #java
  25. * michele joined #java
  26. * mwnaylor joined #java
  27. * rvalue joined #java
  28. * Zapek joined #java
  29. * stfstfm joined #java
  30. * stfstfm_ joined #java
  31. * michele joined #java
  32. * michele joined #java
  33. * michele joined #java
  34. * ghodawalaaman7 joined #java
  35. * ghodawalaaman joined #java
  36. * ChaiTRex joined #java
  37. * ghodawalaaman joined #java
  38. * ChaiTRex joined #java
  39. * Anaphaxaway joined #java
  40. * ChaiTRex joined #java
  41. * jbosmans joined #java
  42. * MikeBux joined #java
  43. * kathadris joined #java
  44. * Afroboy joined #java
  45. * fgarcia joined #java
  46. * fgarcia joined #java
  47. * michele joined #java
  48. * pebble joined #java
  49. * Betal joined #java
  50. * GreenResponse joined #java
  51. * onu joined #java
  52. * JurassCZ joined #java
  53. * JurassCZ joined #java
  54. * Anaphaxaway joined #java
  55. * michele joined #java
  56. dreamreal https://bytecode.news/posts/2026/07/bjarnason-the-labour-arbitrage-theory-of-dev-tool-popularity
  57. dreamreal jreicher: ^^
  58. * victori joined #java
  59. * five618480339176 joined #java
  60. * jamezp joined #java
  61. * Fiji_ joined #java
  62. nb-ben dreamreal: yeah, people keep their broken ways because learning is slow. But after you learn you can do it both well and fast. Nothing delays projects more than a broken design
  63. * pebble joined #java
  64. nb-ben anyway I don't know that people manually code anymore, feels like I'm the only one
  65. * rvalue joined #java
  66. dreamreal Nah, you're not the only one
  67. dreamreal it's still worth it, but the problem is that someone who *can* work with the tools well is gonna fly past you, a lot like how someone who knew C well was going to deliver enough value *easily* to make them worthwhile compared against someone hand-tuning ASM code. The ASM code was "better," but... the C guy is like "I wrote a method to do Thing() this morning, barely worth mentioning the 15 minutes of
  68. dreamreal effort" while the ASM guy's going "just you wait, in two weeks I'll have saved you 22us!"
  69. * Tomte joined #java
  70. * ghodawalaaman joined #java
  71. * stfstfm joined #java
  72. * Anaphaxaway joined #java
  73. deebo i moved a big service from jaxrs to spring mvc with $250 of sonnet and a day or two, would've taken me at least a week just typing shit
  74. deebo but damn if it didn't make a lot of annoying mistakes like unnecessary annotations etc, still had to read through all of it
  75. * Cae2 joined #java
  76. * GreenResponse joined #java
  77. * ernimril joined #java
  78. dreamreal You'd have had to read through regardless, although I've found I usually give pretty precise and limited instructions that handle a lot of that- and almost ALL of my instructions screech about red/green testing hard enough that we write specs to conform with that keep everything in line. I also use green/green - which is what a porting exercise would want - but that's rare.
  79. * metalmaniac joined #java
  80. * stfstfm_ joined #java
  81. * rvalue joined #java
  82. * stfstfm joined #java
  83. whaley https://openjdk.org/jeps/540 JSON API just hit incubation
  84. javabot whaley's title: "JEP 540: Simple JSON API (Incubator)"
  85. nevet JEP 540: Simple JSON API (Incubator)
  86. whaley ~jackson
  87. javabot Jackson is a library that provides a streaming parser for many, many common dataformats (including ~XML, ~JSON, ~YAML, ~CSV, and others) and can map those formats into and from Java Objects as well. See https://github.com/FasterXML/jackson - it's probably the most common such library in use in Java today.
  88. whaley * whaley humps jackson
  89. Para Looking at the lack of anything useful in the proposed API I wouldn't be that quick.
  90. Para tryGet(), no has()
  91. Para Standard object problem "is the key 'foo' missing or does it just have a null value" will be ugleh.
  92. nimaje Para: I think that's the reason why there is JsonNull
  93. Para so what does getting JsonNull mean for obj.get("key")
  94. Para Is that {"key": null} or {]
  95. whaley I think what's being referenced here is how Jackson does it by returning a MissingNode when parentNode.get("foo") is called where "foo" isn't a key.
  96. Para {}
  97. whaley jackson-databind has such a nice fluent API that has effectively no extra noise. I can't tell if JEP 540 has that entirely... though it does look more fluent than most other impls
  98. Para Jackson also added .has(...) methods at one point for solving this particular problem. And find*() methods for similar convenience.
  99. whaley though tbh, java was *wayyyy* behind the times by not including json processing of any kind in the standard api
  100. Para And these are all indeed in databind, which I totally agree with you, the API is very low friction to use these days.
  101. Para It feels a bit that JEP 540 is being modeled by the reference implementation org.json which is...not that great ergonomics wise.
  102. nimaje if obj is parsed from {"key": null} then obj.get("key") would give you a JsonNull value, if "key" doesn't exist in obj it would throw JsonValueException
  103. Para Exceptions for flow control ;_;
  104. nimaje .tryGet(…) would give you an Optional instead
  105. * Drixtan joined #java
  106. nimaje hm, that API seems to be missing BigInteger/BigDecimal support
  107. whaley eww
  108. Para Which is kinda odd as technically that's the only type they should support and coerce from that.
  109. whaley https://cr.openjdk.org/~naoto/json/javadoc/api/jdk.incubator.json/jdk/incubator/json/JsonNumber.html
  110. javabot whaley's title: "JsonNumber (Java SE 28 & JDK 28 [ad-hoc build])"
  111. nevet JsonNumber (Java SE 28 & JDK 28 [ad-hoc build])
  112. whaley that toString() is icky
  113. nimaje ok, it handles numbers correctly, but doesn't exposes them nicely
  114. Para Maybe that's behind Oracle+ subscription.
  115. dreamreal I hate that JEP so much
  116. dreamreal have we learned so little
  117. nimaje hm, is the only good part of that JEP, that it doesn't try to use javas null for a json null value?
  118. dreamreal * dreamreal hits the "support trailing commas" bits and decides NO on the JEP. I have no vote, but that single paragraph would be enough, and combined with.. uh... all the other paragraphs...
  119. Para This is like trying to express zero in Roman numerals...
  120. dreamreal "This paragraph, along with all of the other paragraphs, convinces me that I would be compelled to happily, nay, ecstatically and emphatically, kick this idiotic effing JEP into the sun. We could, of course, remove that paragraph and its asinine assumptions and restrictions, but that would leave the others. Still sun-bound, in my opinion. Geez, people. Sincerely, me."
  121. * mixfix41 joined #java
  122. * monkeyPlus joined #java
  123. * ganthore left #java
  124. * stfstfm_ joined #java
  125. * ChaiTRex joined #java
  126. * Ragnor joined #java
  127. * redj joined #java
  128. * kathadris joined #java
  129. * m2 joined #java
  130. * ChaiTRex joined #java
  131. * Anaphaxeton joined #java
  132. * mindCrime joined #java
  133. * Alastair joined #java
  134. * CygniX joined #java
  135. * jwisbell35 joined #java
  136. * bdkl joined #java
  137. * stfstfm joined #java
  138. * tomboy64 joined #java
  139. * jreicher joined #java
  140. * ball joined #java
  141. * sweatiest_ joined #java
  142. * ferdna joined #java
  143. * Crusher joined #java
  144. * marcel joined #java
  145. * Anaphaxeton joined #java