ByteCode.News
Submit RSS Atom Sign in

Back to the channels

#java

  1. * kusanagi joined #java
  2. * MrHAPPY joined #java
  3. * zorone_ joined #java
  4. * domicron joined #java
  5. * mindCrime joined #java
  6. * kcomhnall joined #java
  7. * ferdna joined #java
  8. * rvalue joined #java
  9. * Pixi joined #java
  10. * Aedil joined #java
  11. * johnjay joined #java
  12. * LtHummus joined #java
  13. * B_fd joined #java
  14. * Gaz7051122720067 joined #java
  15. * Ragnor joined #java
  16. * leppard joined #java
  17. * MikeBux joined #java
  18. * jreicher joined #java
  19. * Exa joined #java
  20. Para jreicher: That's what "fast forwarding" means.
  21. Para History linearization in general is not fun and cashmoney, especially for automation and tooling.
  22. jreicher Para: I've never heard of fast forwarding removing commits. Just not making them in the first place.
  23. Para It's not _removing_, it creates a different kind of commit. "Merge commit" is a bit silly name as it's really just a a commit with >1 parents.
  24. Para there's this classic which is kinda related https://old.reddit.com/r/git/comments/1vsvgs/66way_merge_christ_thats_not_an_octopus_thats_a/
  25. jreicher I haven't yet taken the time to understand a commit with more than 2 parents
  26. Para Maybe one day I'll actually use that (probably not)
  27. Para I can invent a workflow for that, build features based on forks from common parent, never merge, collate releases through megamerges, leave it to someone else to figure out how to do mainline integration so that the future versions include the important stuff.
  28. jreicher Actually, since we're talking about git merges, what conflictstyle do you use?
  29. Para I haven't found the need to customize that, although I am aware there's apparently betterer ones than whatever the default is.
  30. Para 9 out of 10 times IDEA's magic merge does things perfectly :P
  31. jreicher Does IDEA show the common ancestor?
  32. Para Any 3-way diff tool is usually enough to me tooling wise.
  33. Para Hm, I'm going to say maybe? I think it relies on the git executable doing the right thing quite heavily.
  34. jreicher That's why I asked about conflictstyle. I don't think git will give you that unless you ask it by changing the style
  35. Para Well, I guess I've kinda avoided that with the reliance of three-way diffs :)
  36. Para IDEA has one, Beyond Compare is a very good standalone one.
  37. Para You can also run IDEA's on any two files with `idea diff filea fileb` which is very handy
  38. jreicher Yeah I think most tools have good diff support. But conflict resolution is a little different. The separation between frontend and git's conflict markers surprised me when I first started looking at it.
  39. Para I avoid commit related things through commandline, while git is otherwise excellent for cli out of the box, commit management through visual tooling benefits quite a bit from the visualizations.
  40. jreicher Same
  41. * kathadris joined #java
  42. * agnivn joined #java
  43. * acidsys joined #java
  44. [twisti] I've never found anything as intuitive and sensible as `git add -p`, maybe discounting the terrible edit mode
  45. jreicher I've always wondered when, if ever, I would need to do something like that, but I never find myself doing an edit I don't want in the index immediately.
  46. * MikeBux joined #java
  47. [twisti] Wild
  48. Para IDEA's commit view and gitx allow per-line staging/commiting, so same difference.
  49. * Aedil joined #java
  50. dreamreal morning
  51. * johnjay joined #java
  52. * IndoleaceticA joined #java
  53. dreamreal https://bytecode.news/posts/2026/04/trust-is-not-an-opinion
  54. javabot dreamreal's title: "Trust is Not An Opinion | bytecode.news"
  55. * agnivn joined #java
  56. kcomhnall ~jlink
  57. javabot jlink is a tool to assemble and optimize a set of modules and their dependencies into a custom runtime image. For documentation, see https://docs.oracle.com/en/java/javase/17/docs/specs/man/jlink.html for more. Also see https://maven.apache.org/plugins/maven-jlink-plugin/ and ~graalvm
  58. nevet The jlink Command
  59. * simon816 joined #java
  60. * agnivn joined #java
  61. * jreicher joined #java
  62. * GreenResponse joined #java
  63. * domicron4 joined #java
  64. * domicron joined #java
  65. * kcomhnall joined #java
  66. * leppard joined #java
  67. * stewi joined #java
  68. * ultralan joined #java
  69. * jamezp joined #java
  70. * stfstfm joined #java
  71. * agnivn joined #java
  72. * ferdna joined #java
  73. * agnivn joined #java
  74. * jink joined #java
  75. * agnivn joined #java
  76. dmlloyd finally posted part 2 of this series: https://word-bits.flurg.com/posts/the-new-reflection-intermediate-method-handles/
  77. dmlloyd hopefully it won't be another 18 months before part 3
  78. dmlloyd I'll die of old age before I finish the last part
  79. dmlloyd sorry wrong link: https://word-bits.flurg.com/posts/the-new-reflection-intermediate-use-cases/
  80. javabot dmlloyd's title: "The new reflection - Intermediate use cases - David M. Lloyd"
  81. dmlloyd I'm doing great
  82. * B_fd joined #java
  83. Para I think someone missed an opportunity in naming those unreflects. Could've been e.g. deflect.
  84. dmlloyd <Sulu> shields! shields!!
  85. * kento2 joined #java
  86. * agnivn joined #java
  87. dreamreal damn it dmlloyd
  88. dreamreal dmlloyd: that's a technically very interesting writeup but it desperately wants application
  89. dmlloyd fair enough
  90. dmlloyd I have at least three more parts planned out, so I'll try to get some better examples in there (hopefully without going too long...)
  91. dreamreal like, you obliquely refer to currying in *java*, and ... move right on past
  92. dreamreal I want to write this up for bytecode.news but I don't trust myself to synthesize the bits it needs
  93. dmlloyd maybe I'll cap the whole thing off with an explanation of how smallrye-ffm uses bytecode generation plus method handle magic plus indy to do its thing
  94. dreamreal you need to start capping sooner rather than later
  95. dreamreal check the other channel?
  96. dmlloyd "no cap"
  97. dmlloyd also, six seven
  98. dmlloyd greetings fellow young people
  99. dreamreal bet
  100. Para I saw an article that RAG's part of the AI hype might have passed now.
  101. Para Semantic Web, moving from yet another loss to another.
  102. * Demi left #java (Closing Window)
  103. cheeser dreamreal: let chatgippity do it
  104. cheeser dmlloyd: that url is giving me a 404
  105. dmlloyd the second url
  106. cheeser ah. missed that. tack.
  107. dmlloyd I renamed it at the last minute
  108. Para gpt tell us a short summary about java methodhandles using genz language
  109. Para ...or whatever it was
  110. cheeser also, the "previous post" link it broken. :)
  111. dreamreal ~gpt tell us a short summary about java methodhandles using genz language
  112. javabot Java MethodHandles in GenZ language can be seen as a powerful tool for direct method invocation. They offer a high-performance alternative to Java's reflection API, with lower overhead and better optimizations. MethodHandles support both static and non-static methods, along with constructors and field accessors. They can be combined in many ways to create complex behavior. You can find more at: https://docs.oracle.com/javase/7/docs/api/java/lang/invoke/M
  113. nevet JDK 26 Documentation - Home
  114. dreamreal suggest https://word-bits.flurg.com/posts/the-new-reflection-intermediate-use-cases/
  115. javabot dreamreal's title: "The new reflection - Intermediate use cases - David M. Lloyd"
  116. nevet Suggested draft saved from https://word-bits.flurg.com/posts/the-new-reflection-intermediate-use-cases/.
  117. Para That's exactly the kind of failure ChatGPT would produce.
  118. * dreamreal giggles
  119. Para Claude's thought prompts turned into genz but it's also having just as hard of a time parsing that
  120. Para "no cap thinking" and all that
  121. Para ~gpt quack like a duck
  122. javabot "Quack like a duck" in the context of Java Virtual Machine is likely referring to the concept of "duck typing". However, Java does not support duck typing by default as it is a statically typed language. Duck typing is a concept of dynamic languages where the semantics of an object is determined by its current set of methods and properties, rather than its inheritance from a particular class or implementation of a specific interface. It's more about what
  123. javabot the object is. In Java, you can somewhat emulate duck typing with reflection or interfaces.
  124. Para :D
  125. Para (really just wanted to see if the command actually works for us plebians)
  126. dreamreal I think nevet needs certain privilege levels, but not javabot
  127. dreamreal I'm nto even sure javabot has that concept
  128. Para concept of a plan^H^H^Hrivilege
  129. mawk I want to analyse a java library which is obfuscated; I gave up disassembling it and want to analyze its dynamic behavior; it communicates with a NFC tag using a reader interface I need to provide, so I can easily intercept commands and responses
  130. mawk but it's also doing encryption, it uses BouncyCastle for it; I have to register BC as a security provider for it to work
  131. dreamreal ok
  132. mawk but all the interesting classes are final; how can I easily trace method calls in a library? like arguments and then response
  133. dreamreal this is still on java micro profile?
  134. mawk I can also recompile BC with the right stuff inserted in the right place but it looks hard
  135. mawk no this is on PC
  136. mawk regular java 21 or something like that
  137. mawk I suppose it's not like python where I can just patch whatever I want in a library to wrap functions; that would be very useful
  138. dreamreal well, you DO have the classpath at your disposal
  139. * Betal joined #java
  140. Para I was thinking of byteweaving a logger.
  141. Para Wireshark on the BT traffic will also probably provide insight if that fits the setup.
  142. mawk it's NFC, I can get the commands and responses easily already, with pcsc_spy or just providing my own reader class
  143. mawk but then it's still encrypted
  144. mawk theoretically I can provide my own crypto provider too but it's infinitely more complicated, it's a giant codebase full of runtime lookups
  145. mawk I guess the safest way is to recompile bouncycastle with my own logging inside it
  146. dmlloyd ~byteman
  147. javabot dmlloyd, byteman is a tool for tracing, monitoring, and testing a Java program using AOP-ish constructs; see https://byteman.jboss.org/ for more info
  148. dmlloyd or a debugger
  149. * rvalue joined #java
  150. cheeser bytebuddy proxies might work.
  151. * kathadris joined #java
  152. * johnjay joined #java
  153. mawk o nice
  154. mawk the debugger is a bit annoying I just want to trace not to break
  155. mawk but probably jdb can do dprintf like gdb
  156. mawk you do like dprintf file.c:42,'%s\n',local_variable
  157. mawk and it prints according to the format string when reaching the breakpoint instead of pausing
  158. dreamreal do not use jdb
  159. dreamreal seriously
  160. dreamreal if jdb is your last resort someone has screwed up, badly
  161. mawk lol
  162. dreamreal ~jdb
  163. javabot JDB is a console-based debugger for Java that's only slightly worse than gdb. Don't use it. Using it is like voluntarily rolling around naked on a floor covered with thumbtacks and about 2cm of grain alcohol, but slightly less pleasant.
  164. mawk I like gdb
  165. dreamreal Cool. Do you routinely drive rail spikes into your eyes, too?
  166. dreamreal just curious
  167. mawk the tooling for embedded is pretty bad
  168. mawk I gave up trying to integrate eclipse and the right plugins for debugging
  169. dreamreal But you said you're on java 21 NOT on microprofile
  170. mawk gdb has a beautiful TUI that shows the code
  171. mawk yeah I mean I like gdb because that's what I use for embedded C
  172. dreamreal gdb is better for C than jdb is for java
  173. mawk but the java in this case is on a regular pc yeah
  174. dreamreal ddd works for java too, for the record
  175. mawk the library I'm trying to reverse engineer is the NXP SDK to talk to their cards like Mifare DESFire
  176. mawk it's java only and I don't know much about java, and it requires an online license and a connection at all times to function
  177. mawk very unergonomic
  178. p14nd4 somewhat related (to low-level debugging utilities), i just saw that strace recently added color output
  179. * Drixtan joined #java
  180. * dreamreal shudders at strace for java
  181. mawk and they don't give me the time of day when I ask to sign the NDA to know the commands for the cards, so I'm figuring it out myself
  182. * agnivn joined #java
  183. * agnivn joined #java
  184. * stfstfm_ joined #java
  185. * szkl joined #java
  186. * domicron joined #java
  187. * johnjay joined #java
  188. * agnivn joined #java
  189. * stfstfm joined #java
  190. * B_fd joined #java
  191. dmlloyd you know, it would be neat to claude up a *good* console debugger for java
  192. DoofusCanadensis would it be necessary with how good JetBrains' debugger is?
  193. * mindCrime joined #java
  194. * Steeve joined #java
  195. * agnivn joined #java
  196. * bdkl joined #java
  197. * Tenchi joined #java
  198. * domicron joined #java