Chat Logs

  1. dreamrealhttps://bytecode.news/posts/2026/04/performance-whack-a-mole
  2. javabotdreamreal's title: "Performance Whack-a-Mole | bytecode.news"
  3. mawkI'm trying to implement elliptic curves in my javacard applet
  4. mawkit takes something like 60 seconds to generate a RSA 4096 key pair
  5. mawkand 212ms to generate a key pair for 320 bit elliptic curve
  6. ParaSounds about right.
  7. dreamrealhttps://bytecode.news/posts/2026/04/gitbutler-an-approach-to-git-branch-management
  8. mawkthe memory management is still weird to me
  9. mawkif you use 'new' the data is actually stored in NVRAM, it survives resets
  10. mawkand if you use the special API functions to allocate transient objects they're not deleted on reset, just zero-ed out
  11. mawkit seems that by calling the GC after each command processing I don't have memory leaking by repeatedly allocating transient objects
  12. metalmaniachello there, I was wondering if someone could help me out with something I don't know how to debug within eclipse IDE. fresh installation of eclipse and maven, JDK21 for a project, imported it correctly, no errors, maven update within eclipse through ALT+F5 then seems facets nature for java fell back to jdk1.8 , the project has no 1.8 jdk defined anywhere and its pom has java version for source and
  13. metalmaniactarget. If back to facets and put jdk21 , errors go away, but update maven and again on the very same errors. I think maven configuration, somewhere, defines a default JDK , I have no settings.xml on my m2 but I do have a toolchain.xml for another projects. Any lead? sorry to bother and thanks in advance!
  14. Chronosmawk: Does your JVM not perform GCs unless you explicitly call the GC?
  15. mawkyeah
  16. mawkand the gc is an optional feature I shouldn't use it if I want to be portable
  17. DoofusCanadensisJavaCard operates in some tight spaces
  18. mawkthere's about 180KiB of flash and 4KiB of NVRAM, shared among all the applets
  19. mawkit's easy to go over the limit especially with the NVRAM
  20. mawkthe language itself is pretty limited, no strings, most often no ints
  21. mawkbut I compile with JDK 17 so I have all the static language feature
  22. mawkthese are all the library functions available and nothing else: https://docs.oracle.com/cd/E59935_01/api/index.html
  23. nevetJava Card API, Classic Edition
  24. mawkthere's a couple private/extra APIs specific to card management or using private vendor crypto APIs but that's it; and also you need to sign your soul away for a NDA for most of them
  25. mawkI tried, NXP politely replied "no"
  26. dreamreal~maven version
  27. javabotTo set the targeted java version (for instance java 21), add the following to your pom file: <properties><maven.compiler.release>21</maven.compiler.release></properties>
  28. dreamrealmetalmaniac: ^^^
  29. dreamrealjavacard's been around for a long long long time :D
  30. mawkit's running on a tiny 8-bit secure microcontroller in my case
  31. mawkand from java I even have 32-bit integers which is luxurious
  32. ChronosAs someone that started on 8-bit microcomputers, yep, 32-bit ints are luxurious :)
  33. * dreamreal is so tempted by the commodore 64 ultimate...
  34. dreamrealmy foolish wife actually sort of gave me the thumbs up on getting one, too. I was annoyed: she was supposed to be helping me NOT get one!
  35. DoofusCanadensisheh
  36. mawkI started my career with 32 bit stuff directly
  37. mawknobody should be using 8-bit micros anymore unless you're a chinese cheap toy company with razor thin margins
  38. mawkor you have special requirements like radiation hardening or security
  39. Chronosdreamreal: There's also the VICE emulator for the Commodore 64. You know, I bet a really minimal Java could run on the Commodore 64...
  40. dreamrealor you have nostalgia poisoning! The c64u isn't actually 8bit anyway
  41. metalmaniacthank dreamreal but I tried those suggestions without any luck. I realise someone added some executions to the maven-compiler-plugin, if the release version is not specified there too, it always falls back to 1.8 , that seems to be its default behaviour. Thanks!
  42. dreamrealChronos: hey, the javalin processor is a real thing
  43. Chronosmawk: Except if you enjoy retrocomputing!
  44. mawkyeah
  45. mawk32 bit is retro now maybe
  46. DoofusCanadensistotally is
  47. dreamrealthe c64 was my second real computer. The Timex/Sinclair 1000 was my first.
  48. dreamrealand THAT thing was a piece of... work
  49. Chronosdreamreal: Similar to me. My first was a TRS-80 Color Computer, my second was a Commodore 64.
  50. DoofusCanadensisRadio Shack/Tandy Color Computer II was my first
  51. dreamrealI never had a Coco - I sold them, but never owned one. It was, however, fun to run OS/9 on the things!
  52. DoofusCanadensisit's out in the garage for want of an RCA-HDMI adapter
  53. dreamrealWe used OS/9 to keep the kids confused :D
  54. DoofusCanadensisOS/9, eh?
  55. dreamrealDoofusCanadensis: look at commodore.net - they have such things, I think
  56. mawkthe first thing I touched was a windows 95 gateway desktop computer when I was 4-5
  57. mawkaround 2000
  58. DoofusCanadensisit was your gateway, eh
  59. mawkthen I broke it by flipping the little red switch on the power supply
  60. dreamrealDoofusCanadensis: yes, os/9!
  61. dreamrealit was awesome for its time :D
  62. Chronosmawk: You make me feel positively fossilized
  63. mawklol
  64. cheeserbut does the Ultimate come with joysticks that are easily broken and have to be glued back together?
  65. dreamrealhmm, no, they have s-video to composite, not HDMI output
  66. ChronosThese days, all the cool kids will tell you that you're old if you program in Java ;)
  67. dreamrealcheeser: no, you have to buy tougher things. But you can USE those old joysticks, as I understand it
  68. mawkI just write C usually, but this time I had to pick up java
  69. DoofusCanadensisdreamreal: it could handle maybe three concurrent users‽ that's amazing
  70. dreamrealDoofusCanadensis: os/9? Pffft, on that machine, you were lucky to run rogue :D
  71. DoofusCanadensishahahaha
  72. dreamreal... which is what I typically did on it
  73. DoofusCanadensisI mean, that's what the Wikipedia entry says it was theoretically capable of
  74. mawkspeaking of concurrent users I convinced my javacard distributor to enable logical channels on the card, so now I can have 4 concurrent connections (or even 5 if I use both the contact and the contactless interface at the same time)
  75. mawkI have to find a way to safely store transient state specific to one logical channel
  76. dreamrealWe never tried, but we also never hooked it up to multiple-session-capable systems
  77. dreamrealwe also ran xenix on the RS/6000 and the 80386 machines we had in the office
  78. dreamrealI actually LIKED xenix back then
  79. Chronosmawk: What is your project? Like the 10,000 foot (or 10,000 kilometer) view?
  80. dreamrealthose damn 6000s were ... really kinda surprisingly good. You could literally upgrade a TRS/80 Model I to a 6000 and it'd be GREAT
  81. mawkI'm trying to design a cheap and removable secure element for managing certificates or secret keys
  82. mawklike for IoT stuff
  83. mawkwith the new cyber security regulations in the EU a lot of companies will have to start doing something and I can maybe become rich
  84. ChronosQNX > Xenix :)
  85. Chronosmawk: Oh, very interesting
  86. dreamrealQNX postdated xenix by a bit, though, and didn't have SCO at the end
  87. Chronosdreamreal: Xenix predates QNX?! I had no idea
  88. dreamrealI was using XENIX in 1987
  89. mawkI could also easily turn this into a yubikey-like product for consumer authentication but the market is saturated
  90. mawkand companies have more money
  91. mawk basically trying to become their concurrent: https://www.smartcard-hsm.com/
  92. dreamrealoooo QNX might have been ahead of Xenix
  93. dreamrealINTERESTING.
  94. Chronosdreamreal: I think you're right. It looks like Xenix may predate QNX by around 2 years.
  95. dreamrealXenix and QNX had different userbases, though: QNX was RTOS, yeah?
  96. mawkin an embedded device all they need is a USART (like UART with a clock signal) and a SIM slot, maybe a transistor to turn it off when unused, and they can talk to it
  97. Chronosdreamreal: Yes
  98. dreamrealXenis was ... not. :D
  99. dreamrealand then SCO poisoned the name altogether
  100. * Chronos mumbles something about the JNode operating system
  101. dreamrealbwahaha
  102. dreamrealJINI could have done it but Sun never could figure out how to market
  103. tilerenderinghi - i need a spring boot project serving as reference (best practices with boilerplate code, ready to use and "copy" or "follow", open source etc., state of the art, you know what i mean, something like the "pet store for ejbs 20yrs ago, but shining and excellent and best-of) for spring boot with java 21. any ideas?
  104. dreamrealtilerendering: err... that's a pretty broad request
  105. tilerenderingejbs -> jee
  106. tilerenderingdreamreal, I actually wouldnt ask here if I hadnt stumbled upon such rereference projects a week or 2 ago
  107. tilerenderingbut youre right
  108. dreamrealI mean... spring's ecosystem is GIANT. What aspects of app development are you looking for? What kind of requirements?
  109. tilerenderingbasically I d like some references. with the maturity of spring boot and java (and java EE), there must be quite a comprehensive list of projects to serve as "state of the art" somewhere
  110. DoofusCanadensishave you tried the spring tutorials?
  111. dreamrealor looking on github, for that matter. There may be a spring recipes thing too
  112. tilerenderingdreamreal, basically a backend with oauth2 keycloak connection postgresql JPA persistence layer, behind it, able to harness java 21 optimizations (even though most will stay under the hood), along with payment integration (stripe) - there s something like that for ruby on rails and it s called "draftkit"
  113. tilerenderingDoofusCanadensis, well tutorials server another purpose than references
  114. tilerenderingserver=serve
  115. dreamreallook for draftkit on spring, I guess. I don't do stripe or keycloak or else I'd point you to nevet :D
  116. tilerenderingdreamreal, I m currently having an AI research exactly that for me, on github, among others.
  117. tilerenderingI just thought maybe I d find some useful info here
  118. dreamrealsure, you probably still can, at least you've NOW given people something to consider as a comparison point :D
  119. tilerenderinglike some "duh - everybody knows - look HERE!"
  120. tilerenderinggot you
  121. tilerenderingdreamreal, arent you Mr. Lombok?
  122. dreamrealerr... no?
  123. tilerenderingah, he used to hang out here.
  124. dreamrealthat'd be surial, but surial hasn't been here for a long time
  125. tilerenderingsee? surial, surreal, dreamreal...
  126. tilerenderingAI-reel, look-n-feel, oneill.
  127. tilerenderingThe original Wiener Schnitzel is based on veil!
  128. dreamrealI actually don't know if I have any projects that use lombok any more
  129. dreamreal$work sort of does but they'e migrating away
  130. tilerenderinglombok conflicted in quite some projects with other stuff - I think it was mapstruct or something else.
  131. tilerenderingso I basically just switched to IDE-driven generation
  132. dreamrealI switched mostly to records and data classes in kotlin
  133. [twisti]mapstruct was historically a problematic combo, but that was fixed a very long time ago, many years certainly
  134. [twisti]ive always been sad how much flack lombok caught, at work too. we have a new dev who pushed to convert some of my old projects to drop lombok, and since i no longer work on them i gave my okay, i mean, hes the one who has to maintain them. so far, the code base has gone up ~700% with purely generated, copy/pasted code, and whats worse; because lombok allowed some fine tuning, 99% of that shit is copy/paste, but 1% is not. good luck noticing those
  135. [twisti]differences in the future amongst those thousands of pages of generated, identical looking code 🤷🏼‍♂️
  136. [twisti]i try not to care, letting go is healthy, but still
  137. dreamreal[twisti]: some people want to have their fingers in every pie, yeah :(
  138. dreamrealI mean, I migrate away from lombok structurally - if records make sense, there we are, same for other types. But if there's not a reason to move away... why?
  139. [twisti]well, its their project, so i want them to feel like they can make decisions like that - they are sort of junior, not completely, but definitely compared to me. so i try not to bully my opinion when they are the ones having to do the maintenance in the future
  140. dreamrealOh, you're doing the right thing
  141. [twisti]of course they 'had problems getting it to work with lombok', which i know youre a sucker for, but in my experience, there hasnt been anything that couldnt be solved with literally five minutes of google in almost a decade in regards to lombok, so that doesnt feel like a good reason to me
  142. dreamrealwhat?
  143. dreamrealI am missing something, I think
  144. dreamrealI'm a sucker for "had problems getting it to work with lombok?" What does that mean, and what makes you say it?
  145. tilerenderingdreamreal, [twisti] : a little aspect there, another annotation there, some more annotations, some more aspects, precompile, runtime, postbla, and in the end, nobody knows whats going on anymore!
  146. tilerendering:)
  147. [twisti]dreamreal: thats one of the arguments you used to bring up, and jump on when people came here that had a problem with that, basically saying 'thats why i dislike lombok'
  148. [twisti]its fine, you werent wrong
  149. dreamrealwhat?
  150. dreamrealI mean, my argument against lombok isn't that it doesn't WORK, it's that it's not entirely necessary, but what it does it does really well
  151. [twisti]lombok causing problems for peoples build process, ides, code checkers/analyzers, due to how lombok hooked into javac in a non-sanctioned way
  152. dreamrealbuilders in lombok are great, the rest is less necessary than it was, and the AST dependency is a concern
  153. tilerenderingcan we all agree to some more diversity here? @Getters @Setters @Whatsoevers?
  154. tilerenderingbtw what is AST again
  155. dreamrealbut that's a maintenance problem: how much do you trust surial, etc., and should you? Generally the answer is "yes" but it's STILL a trust issue
  156. [twisti]granted, that was back when they used to do a lot more illegal black magic, before their kind of magic was properly supported by java/javac
  157. dreamreal~ast
  158. javabotAn AST (or "Abstract Syntax Tree") is a reference to a structure generated from an input. A sentence, then, might have an "AST" of a subject, verb, and a predicate, where the predicate is optional and all three parts might be constructed with different complexity. Program source is normally conversted to an AST before generating executable code.
  159. tilerenderingah AST, the tree recursively worked on by a parser for instance
  160. tilerenderingdidnt know it was called ast
  161. dreamrealtilerendering: lombok works by hooking into some javac internals, there's not a published API they use, so it has to be ported for every iteration of javac; it's fairly constant so they can track it really closely, but even so
  162. dreamrealand they're *really* good coders
  163. [twisti]ive been sadly out of touch with java for years by now; does java have first class support for @Delegate these days ? `class SomeListWrapper implements List<T> { @Delegate private final ArrayList ... }` would just delegate all non-overridden calls to interface methods to the, well, delegate
  164. [twisti]we made such nice code with that
  165. dreamrealI don't quite know what [twisti] is talking about. I don't tell people "you should use lombok!" but apparently that means I'm anti-lombok now
  166. [twisti]composition > inheritance
  167. [twisti]dude, you used to have a real chip on your shoulder about lombok
  168. dreamrealnot that I know of yet
  169. dreamrealI'm trying to remember having such a chip, esp when I was the person who first put lombok in print
  170. dreamrealhell, I remember asking surial if that was okay *here* (well, on freenode, but still)
  171. [twisti]i feel like we used to get into arguments about it all the time
  172. dreamrealI think you argue with me a lot more than I argue with you, TBH
  173. dreamrealyou keep saying I have chips on my shoulders about things you like, or whatever, and I'm pretty much always slightly lost, and I don't really enjoy not understanding WTF is going on much
  174. dreamrealand since I keep wondering what you're talking about, that actually creates a low-grade conflict, because I really don't know what you're talking about when it comes to me very much
  175. [twisti]to be fair, from my perspective it feels like the exact opposite - like you retroactively change how/what you remember a lot
  176. tilerenderingI dont like the term "coding" btw.
  177. dreamrealmaybe it's because I don't actually take hard positions very often, as a professional behavior
  178. dreamrealI can push back on almost all positions, and I push back on absolute statements habitually because absolutism is almost always wrong
  179. dreamrealon reddit: "Spring sucks!" No, it kinda doesn't. "Spring lover!" ... meanwhile I wrote articles saying why Spring wasn't necessary and it's still not necessary. "Oh, you love Jakarta EE huh?!?!" No, I write Spring apps pretty much every day.
  180. [twisti]ive stopped collecting logs, and on some level i suspect as rational as it feels, going through decade old logs to win an argument is somehow neither fair nor productive, but in this instance i would love to go back and see what really happened. my memory is terrible, but usually in the 'i dont remember' way, not the 'i made up fake memories' way
  181. dreamrealWell, it *sounds like* you have an impression that either got reinforced or did NOT get opposed and it calcified
  182. dreamrealbut you have your own life and your own impressions, and that's fine
  183. dreamrealI stopped suggesting lombok and stopped using it in my own code, for actual reasons that I find rational and justifiable, but if someone uses it, I don't *care*
  184. dreamrealThe number of projects I utterly reject is really pretty low: siteminder, vignette storyserver, dynamodb
  185. dreamrealafter that... don't really care
  186. dreamrealif $work were to say "let's front storyserver with siteminder, and use dynamo as a backend" I'd quit within about five minutes, as soon as I stopped screeching in rage at them
  187. dreamrealthankfully they're not stupid so none of those will infect our codebase
  188. [twisti]ive been shoved into the world of outdated php and react, so who am i to talk
  189. dreamrealIt's kinda funny: at work they'll mention technology X, and I'm constantly going "oh, I know that guy" :D
  190. Swayzepsychologist prob
  191. Swayzeor try #php
  192. jbosmansregarding lombok, to me that's a case of choosing between pretty clear upsides and downsides
  193. jbosmansaka a tradeoff i guess
  194. jbosmansand/or "trade off"
  195. jbosmansi remember thinking when a saw an early talk a long time ago (i think javapolis days) that it was a lot of generated code that removed a lot of boilerplate, which was nice
  196. jbosmansbut then, besides coding i also had to put out a lot of production fires, where generated code doesn't help per se
  197. jbosmansin any case i think it is and always was a very clever project, with attached pro's and cons as always
  198. cheesermostly cons
  199. jbosmansfor me same
  200. jbosmans~4 hours until artemis 2 reentry
  201. javabotjbosmans, what does that even *mean*?
  202. cheeseri'm worried about that heat shield.
  203. jbosmansyeah, read same :s
  204. jbosmansi'm sure it'll be fine
  205. cheeserwhat's the worst that could happen? ¯\_(ツ)_/¯
  206. jbosmansyeah :s
  207. jbosmansi'm not religious, but (choose to) have faith in nasa's attention to detail
  208. ParaI'm annoyed that it's still not reusable boosters.
  209. ParaOther than that, space is cool. Stuff.
  210. cheeserfaith isn't exclusive to religion. replacing logic with it (almost) is. :)
  211. jbosmansokay, i agree :)
  212. jbosmansafaik no logical reasons to assume the worst tho
  213. jbosmansalso, afaik, there'd be a backup plan, and then x more
  214. jbosmansregarding lombok again, the only generated code i know of in use is for 1 project, where the code in question were once classes and now records, and said code is generated by manually written java code and compiled as part of the standard classpath
  215. jbosmansbasically a (whole) bunch of DTOs
  216. jbosmansdefined by a non-java ERP for that matter
  217. Para~immutables
  218. javabotPara, immutables is an annotation processor capable of producing fully immutable objects with many configurable features from a simple interface or abstract class definition. See https://immutables.github.io
  219. ParaIt was that time again.
  220. jbosmanshow so?
  221. jbosmans(crazy view watching artemis approach the earth)
  222. ParaPeople tend to revolve around the whole lombok or not to lombok thing, while the true answer is "immutables until withers" (:
  223. jbosmansI tend to agree, unless mistaken "until withers" is superfluous tho ;)