Info

Login

Channels

APIs

Credits

  • cheeser
  • ernimril
  • joed
  • kinabalu
  • lunk
  • ojacobson
  • r0bby
  • ThaDon
  • ricky_clarkson
  • topriddy

« 2021-03-02

2021-03-03

2021-03-04 »

Nick Message Date
dec0d3r [dec0d3r!~dec0d3r@2001:8003:4808:9000:5f63:4185:4213:fdf7] has joined ##java [12:00]
czhou [czhou!~czhou@unaffiliated/czhou] has joined ##java [12:30]
infinite_loop [infinite_loop!~rkeim@160-2-131-3.cpe.sparklight.net] has joined ##java [12:51]
aqd [aqd!~aqd@84.20.147.33] has joined ##java [01:02]
hd1 [hd1!6bb8e407@gateway/web/cgi-irc/kiwiirc.com/ip.107.184.228.7] has joined ##java [01:18]
AndroidDAW [AndroidDAW!~AndroidDA@cpe-172-193-183-39.qld.foxtel.net.au] has joined ##java [01:18]
hd1 https://dpaste.org/iDq8 anyone know how to fix this? [01:19]
hd1 hd1's title: "dpaste/iDq8 (Plain Code)" [01:19]
hd1 Do I need to downgrade to JDK14 or is it possible to use JDK15 with spring-boot? [01:20]
dob1 [dob1!~dob1@unaffiliated/dob1] has joined ##java [01:24]
ernimril 59 [01:28]
ernimril ernimril, 59 is the class file format version number of class files emitted when using --release 15. You will need Java 15 or higher to run these. [01:28]
rocktop [rocktop!~rocktop@105.158.12.155] has joined ##java [01:34]
forgottenone [forgottenone!~forgotten@176.42.25.89] has joined ##java [01:39]
istlf [istlf!~istlf@s13490149139.blix.com] has joined ##java [01:39]
rzanetti [rzanetti!~zanetti@2804:14d:5282:1b7:198a:8b45:1b45:36d0] has joined ##java [01:39]
AndroidDAW [AndroidDAW!~AndroidDA@cpe-172-193-183-39.qld.foxtel.net.au] has joined ##java [02:11]
ScrambledRK using junit5, can I print a message if any asserts within my test fail? Without using assertAll? Do I need to wrap my test in try/catch and fail() on catch? The motivation is to make debugging a bit easier and print the given test parameters on fail. [02:11]
ScrambledRK Its a parameterized test and there are lots of cases; simply printing the arguments and expected result would help a lot to figure out whats wrong [02:12]
ricky_clarkson ScrambledRK: I use some parameterised test framework with JUnit4, it includes the arguments in the test name in the results [02:27]
ricky_clarkson testFoo(x=3, y=4): AssertionFailed... [02:28]
georgios [georgios!~george@unaffiliated/anaphaxeton] has joined ##java [02:44]
ScrambledRK ricky_clarkson: true, it does so for me too, but the inputs are rather long lists and it becomes a bit messy [02:47]
ScrambledRK but its not a big deal, I'll just log it in debug. thats omitted when build via maven but visible when testing locally [02:48]
ScrambledRK and thats enough for me I guess [02:48]
ScrambledRK thank you though [02:52]
dob1 if in a database I have a timestamp field (WITHOUT timezone) and I am querying for it, once I get it as java.sql.Timestamp it's corrret that getTime() on this object gives different values regarding of the timezone I am using (I am changing it as test using -Duser.timezone)? so I get always the same datetime when I stored it regarding of the timezone [02:56]
kofc [kofc!02cf7dcd@unaffiliated/kofc] has joined ##java [02:58]
kofc Hello. Does anyone know of an api library that has the ability to add a new element to a set/list and return the new list all in a single inline statement? [02:58]
elaremen [elaremen!~stv@hermes.gatewaynet.com] has joined ##java [03:02]
db kofc: with "new list" you mean - you want to create a new list consisting of the old list plus the new element wihtout modifying the original list=? [03:07]
kofc db: Yep [03:08]
dpl__ [dpl__!~dpl@77.121.78.163] has joined ##java [03:08]
kofc Something like List<String> newList = oldList.add("Elem"); [03:08]
kofc I can't believe there is no fluent API for this in Java. [03:09]
db also that will modify oldList [03:09]
db maybe use a library like https://github.com/brianburton/java-immutable-collections [03:09]
db db's title: "GitHub - brianburton/java-immutable-collections: Efficient Immutable/Persistent Collections for Java" [03:09]
kofc There is something like EnumSet.of("newElem", oldSet.toArray(new String[0]); for Set creation, but this is fugly IMO. [03:09]
db Idk just googleguessing [03:09]
Xiti` [Xiti`!~Xiti-@unaffiliated/xiti] has joined ##java [03:22]
[twisti] shame you cant leverage lomboks @Wither on existing classes [03:29]
gelignite [gelignite!~gelignite@55d4551e.access.ecotel.net] has joined ##java [03:35]
Swish[\] [Swish[\]!cvakin@pool-72-66-31-217.washdc.fios.verizon.net] has joined ##java [03:42]
Xiti [Xiti!~Xiti-@unaffiliated/xiti] has joined ##java [03:43]
Koopz [Koopz!~Koopz@koopz.rocks] has joined ##java [03:43]
Intrepd_ [Intrepd_!~intrepd@pool-98-115-73-43.phlapa.fios.verizon.net] has joined ##java [03:44]
NorthwestVegan [NorthwestVegan!~Northwest@gateway/tor-sasl/northwestvegan] has joined ##java [03:46]
Discordian93 [Discordian93!1f04f7c4@31.4.247.196] has joined ##java [03:47]
infinite_loop [infinite_loop!~rkeim@160-2-131-3.cpe.sparklight.net] has joined ##java [03:52]
Koopz howdy, i'm getting really desperate now... I've got this java based reporting engine running on Server A which connected through JDBC to an informix db running on Server B. It worked just fine until yesterday when i restarted the informix database. From then on the reporting engine refused to connect to the database not giving me any errors or [03:53]
Koopz stacktraces whatsoever that could tell me what is wrong. Meanwhile i can connect to that very db through DBeaver just fine using the exact same information. [03:53]
Koopz i've restarted the reporting engine multiple times, even the server it was running on this morning, no change, still just telling me to contact the site admin. In the logs [03:54]
yawkat consults the tea leaves [03:54]
fabiim [fabiim!~fabiim@2a02:c7f:ea07:7a00:f86f:e67:42d6:87cb] has joined ##java [03:55]
Koopz i don't know where to look anymore... how would i debug jdbc connection attempts? [03:55]
yawkat a debugger, i guess [03:56]
yawkat contact the developers? [03:56]
Koopz TIBCO Jaspersoft? Doing support? xD [03:57]
eedgit [eedgit!~textual@84.65.144.206] has joined ##java [04:02]
dougquaid [dougquaid!dougquaid@gateway/vpn/privateinternetaccess/dougquaid] has joined ##java [04:08]
ScrambledRK try to figure out if your jdbc driver implementation supports logs? [04:12]
ScrambledRK or the 3rd party involved :\ [04:12]
BluesBoy Koopz: did you try connecting to the db using dbeaver from server A or from some other PC? [04:13]
SirMangler [SirMangler!~SirMangle@host31-50-223-230.range31-50.btcentralplus.com] has joined ##java [04:13]
SirMangler [SirMangler!~SirMangle@host31-50-223-230.range31-50.btcentralplus.com] has joined ##java [04:15]
SirMangler [SirMangler!~SirMangle@host31-50-223-230.range31-50.btcentralplus.com] has joined ##java [04:16]
SirMangler [SirMangler!~SirMangle@host31-50-223-230.range31-50.btcentralplus.com] has joined ##java [04:17]
Koopz i'm connecting from my computer which is not Server A, indeed [04:18]
Koopz just did a tcpdump to check if a connection to Server B is even created [04:19]
Koopz at least that seems to happen [04:22]
[twisti] Koopz: we dont really do tech support for other peoples apps that just happen to be written in java here [04:24]
[twisti] yawkat is right, contact the developers, they probably have an issue tracker for that kind of thing [04:24]
AndroidDAW [AndroidDAW!~AndroidDA@cpe-172-193-183-39.qld.foxtel.net.au] has joined ##java [04:34]
istlf_ [istlf_!~istlf@s13490149139.blix.com] has joined ##java [04:35]
DataComputist [DataComputist!~lumeng@50.43.26.251] has joined ##java [04:49]
infinite_loop [infinite_loop!~rkeim@160-2-131-3.cpe.sparklight.net] has joined ##java [04:53]
aedroid [aedroid!~aedroid@89-181-227-120.net.novis.pt] has joined ##java [04:59]
zanetti [zanetti!~zanetti@2804:14d:5282:1b7:b4da:a6de:b7fa:d247] has joined ##java [05:10]
AndroidDAW where can i find instructions for setting up JDK for development on Mac OS [05:17]
AndroidDAW specifically i am getting fatal error: 'jni.h' file not found [05:17]
AndroidDAW for #include <jni.h> [05:17]
mbooth AndroidDAW: JDK comes with everything you need -- jni.h is in the "include" directory [05:19]
Diablo-D3 AndroidDAW: your name implies you want #android-dev [05:19]
AndroidDAW hmm nvm, i seem to get this when invoking java --version [05:20]
AndroidDAW Error: Could not create the Java Virtual Machine. [05:20]
AndroidDAW Error: A fatal exception has occurred. Program will exit. [05:20]
AndroidDAW Diablo-D3: im cross compiling for both mac os and android [05:20]
mbooth AndroidDAW: Just pass it to your compiler in the usual way for header directories, IIRC for gcc it's -I/path/to/include [05:20]
Diablo-D3 same with clang, since hes on a mac [05:21]
AndroidDAW i have this installed [05:22]
AndroidDAW openjdk version "1.8.0_282" [05:22]
AndroidDAW OpenJDK Runtime Environment Corretto-8.282.08.1 (build 1.8.0_282-b08) [05:22]
AndroidDAW OpenJDK 64-Bit Server VM Corretto-8.282.08.1 (build 25.282-b08, mixed mode) [05:22]
AndroidDAW mbooth: where would i find the directory that it is included in [05:23]
AndroidDAW my env has no JAVA_HOME [05:23]
Diablo-D3 its in the directory you installed java to [05:23]
AndroidDAW /usr/bin/java -> /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java [05:23]
mbooth AndroidDAW: Usually it's /path/to/jdk/include [05:25]
AndroidDAW `find /System/Library/Frameworks/JavaVM.framework -name jni.h` results in nothing [05:25]
mbooth AndroidDAW: But Macs like to be different, and you know macs better than me [05:25]
AndroidDAW mbooth: i dont know where that is [05:25]
mbooth Maybe you should find a mac os support channel [05:26]
Diablo-D3 that directory structure doesnt even make sense [05:26]
Diablo-D3 I dont remember the jvm looking that weird on osx the last time I used osx [05:26]
mbooth AndroidDAW: Did you try googling for "macos jni.h" ? [05:27]
AndroidDAW im on Mac Os Catalina [05:27]
Diablo-D3 but it packed it the same way its done on other OSes, so /some/mac/dir/java/bin/java for java itself, etc [05:27]
mbooth This is almost certainly not the best channel for teaching you how to use your OS ;-) [05:28]
Diablo-D3 yup [05:28]
Diablo-D3 maybe try a different distro instead of coretto? [05:29]
mbooth Or just use [05:29]
mbooth sdkman [05:29]
mbooth SDKMAN is a tool for managing parallel installations of JVMs and tools on Mac/Linux/Unix. See http://sdkman.io/ - you can run it on Windows if you have a working Bash installation, too. To install java, you'd use "sdk install java" if you're wondering. [05:29]
AndroidDAW hmm it seems like i can use `/usr/libexec/java_home` to identify the JDK home [05:30]
AndroidDAW $ /usr/libexec/java_home [05:30]
AndroidDAW /Users/smallville7123/Library/Java/JavaVirtualMachines/corretto-1.8.0_282/Contents/Home [05:30]
mbooth Hurrah [05:32]
AndroidDAW how would i set it up so that i can use the "$(JAVA_HOME)/include" directory when compiling [05:33]
AndroidDAW mbooth: :) [05:33]
Maldivia AndroidDAW: set your JAVA_HOME to point to the right place [05:33]
Maldivia duh [05:33]
AndroidDAW i did [05:34]
mbooth AndroidDAW: You don't know how to set environment variables? [05:34]
caipiblack2 [caipiblack2!b09af35c@176-154-243-92.abo.bbox.fr] has joined ##java [05:34]
AndroidDAW but i also need to set the correct compiler flags as well right? [05:34]
Maldivia well, that is outside the scope of this channel [05:34]
AndroidDAW so that its include directory is actually included [05:34]
Maldivia this is a Java channel, not gcc or whatever native compile you're using [05:34]
mbooth AndroidDAW: I mean we already told the compiler flag for gcc and clang is -I [05:35]
caipiblack2 Hi, I have a question about the timers in JAVA ! Is it possible for a timer to interrupt a function ? Or can it only interrupt when functions are doing blocking task (delay, IO, ..) [05:35]
mbooth AndroidDAW: If you need more than that, you should find a support channel for your compiler [05:35]
Maldivia caipiblack2: depends how you've coded that method -- if that method reacts to interrupt events, then yes [05:35]
AndroidDAW hmm seems to be https://stackoverflow.com/a/37889423/14942779 [05:35]
AndroidDAW AndroidDAW's title: "java - Where can I find the jni headers for Mac OS - Stack Overflow" [05:35]
caipiblack2 Maldivia : How did you know if a method react to interrupt events ? [05:37]
AndroidDAW tho im just gonna use `export CPPFLAGS="-I $(JAVA_HOME)/include -I $(JAVA_HOME)/include/darwin $(CPPFLAGS)"` instead as mine uses bash by default [05:37]
Maldivia AndroidDAW: Not on topic for this channel [05:37]
AndroidDAW sorry [05:38]
Maldivia caipiblack2: well, do the methods you call support InterrupedException? do you check for it yourself? is there another flag you check for to see if you should continue? [05:38]
ScrambledRK [ScrambledRK!~RK@80-110-107-100.cgn.dynamic.surfer.at] has joined ##java [05:38]
mbooth JCIP [05:38]
mbooth caipiblack2, jcip is Java Concurrency In Practice, a book focused on implementing threaded and concurrent applications in Java. You can read more at http://jcip.net and buy a copy at http://amzn.to/1pujbTy [05:38]
mbooth That's a good reference for concurrency [05:39]
caipiblack2 The method that i don't want to be interrupt doesn't support "interruptedException" [05:39]
caipiblack2 throw* [05:39]
Maldivia well, then no [05:39]
caipiblack2 Perfect! [05:39]
caipiblack2 Thank you. [05:39]
Maldivia unless it checks on some other flag [05:39]
caipiblack2 Oh [05:39]
Maldivia if I have a while (running) {...} -- well, then my code check on that field, right -- and changing it (in a thread-safe manner) would act as a flag for that method [05:40]
Maldivia many of the blocking IO methods in Java support the Thread.interrupted() flag for instance [05:41]
bolovanos__ [bolovanos__!~bolovanos@unaffiliated/bolovanos] has joined ##java [06:00]
MGD [MGD!5c069036@host-92-6-144-54.as43234.net] has joined ##java [06:00]
zeden [zeden!~user@unaffiliated/zeden] has joined ##java [06:37]
Intense [Intense!Intense@ko-169-180.tm.net.my] has joined ##java [06:39]
Feuermagier [Feuermagier!~Feuermagi@2a02:2488:4211:3400:246e:bf09:8453:9d6] has joined ##java [06:39]
aedroid [aedroid!~aedroid@89-181-227-120.net.novis.pt] has joined ##java [06:44]
gelignite [gelignite!~gelignite@55d4551e.access.ecotel.net] has joined ##java [06:59]
Lengsdorfer [Lengsdorfer!~Lengsdorf@unaffiliated/lengsdorfer] has joined ##java [07:00]
aedroid [aedroid!~aedroid@89-181-227-120.net.novis.pt] has joined ##java [07:02]
Peste_Bubonica [Peste_Bubonica!~Peste_Bub@unaffiliated/peste-bubonica/x-4612396] has joined ##java [07:09]
n01d [n01d!~n01d@unaffiliated/n01d] has joined ##java [07:14]
n01d Does anyone know of a good book on algorythms? [07:15]
aedroid [aedroid!~aedroid@89-181-227-120.net.novis.pt] has joined ##java [07:21]
Koopz [Koopz!~Koopz@koopz.rocks] has joined ##java [07:30]
[twisti] try ##programming [07:32]
di0_ [di0_!~di0_@unaffiliated/di0-/x-5053590] has joined ##java [07:33]
greyline [greyline!1f2ed78d@1F2ED78D.dsl.pool.telekom.hu] has joined ##java [07:33]
sleepingforest [sleepingforest!~sleepingf@unaffiliated/sleepingforest] has joined ##java [07:42]
mbooth "Al Gore Rhythms" Isn't that a book on vice-presidential dance moves? [07:45]
Diablo-D3 get out [07:46]
EveryOS [EveryOS!uid454739@gateway/web/irccloud.com/x-pjezhugyesswpjoh] has joined ##java [07:46]
bolovanos_ [bolovanos_!~bolovanos@unaffiliated/bolovanos] has joined ##java [08:00]
n01d I mean in java [08:04]
mbooth n01d: Algorithms are language agnostic [08:06]
dreamreal morning [08:09]
dreamreal n01d: look up sedgewick's books, BTW [08:10]
dreamreal the channel blog also has some references on algorithms, if memory serves [08:10]
dreamreal sedgewick's book on algorithms in java is good, because he knows his stuff, but the java in it is really primitive [08:13]
georgios [georgios!~george@unaffiliated/anaphaxeton] has joined ##java [08:13]
n01d Hey why not start a channel like #english119? [08:15]
roosaap [roosaap!~Admin@213.232.87.90] has joined ##java [08:16]
forgottenone [forgottenone!~forgotten@176.88.30.190] has joined ##java [08:22]
AndroidD_ [AndroidD_!~AndroidDA@cpe-172-193-183-39.qld.foxtel.net.au] has joined ##java [08:25]
perrier-jouet [perrier-jouet!~perrier-j@modemcable012.251-130-66.mc.videotron.ca] has joined ##java [08:25]
dreamreal n01d: How do you know there isn't one [08:26]
dreamreal have you looked? [08:26]
dreamreal and what does that have to do with us [08:26]
Sheilong [Sheilong!uid293653@gateway/web/irccloud.com/x-ywkwdxdlophboxsa] has joined ##java [08:30]
infinite_loop [infinite_loop!~rkeim@160-2-131-3.cpe.sparklight.net] has joined ##java [08:49]
TideFN [TideFN!~TideFN@2601:cb:8280:9520:b0e5:4df8:a430:ab43] has joined ##java [08:50]
onu [onu!~onufn@gibbs.uberspace.de] has joined ##java [08:54]
n01d You could teach a class directly through irc [09:00]
dreamreal topic [09:00]
dreamreal The topic has several references for your perusal. That's why Chanserv msgs you to read the topic. Reading the topic and asking questions is a great way to get help. [09:00]
dreamreal n01d: If you can't tell, I'm gently telling you that we don't care, get back on topic :) [09:01]
Teckla Memory/garbage collection question: We have a JVM where work comes in, and we don't know what the memory requirements of the work will be (could be high). We "protect" ourselves by rejecting the work if the heap size is already >= 90%. -> [09:06]
Teckla But this is causing a problem with the GC which seems to happily sit there with a >90% heap, even though a GC would reduce the heap size considerably. -> [09:06]
Teckla (To 50% or lower, in most cases.) [09:06]
Maldivia Teckla: use a GC that will periodically run the GC regardless of load then [09:06]
Teckla Maldivia: Do you know how often it'll periodically run the GC? [09:07]
Maldivia Teckla: unless you explicitly set an option, it won't [09:07]
Teckla Maldivia: Ah ha. OK. Thanks. [09:08]
Teckla Is it frowned upon to periodically run System.gc() yourself? [09:08]
odinsbane Yes. [09:08]
Maldivia yes [09:08]
Maldivia and it might do absolutely nothing [09:08]
Teckla Darn. Off the tops of your heads, do you know if G1GC supports the "periodically run the GC" feature? [09:08]
mbooth Teckla: Note that System.gc() is just a "suggestion", and will not guarantee it runs [09:08]
Peste_Bubonica [Peste_Bubonica!~Peste_Bub@unaffiliated/peste-bubonica/x-4612396] has joined ##java [09:08]
Teckla (For various reasons, we must use G1GC.) [09:09]
Teckla Or what the feature is named -- I can look it up. [09:09]
Maldivia jep 346 [09:09]
Maldivia 'JEP 346: Promptly Return Unused Committed Memory from G1' can be found at http://openjdk.java.net/jeps/346 [09:09]
jackiiilong [jackiiilong!~Andy@60.10.23.167] has joined ##java [09:10]
mbooth Teckla: For tuning options see https://www.oracle.com/technical-resources/articles/java/g1gc.html [09:10]
mbooth mbooth's title: "Garbage First Garbage Collector Tuning" [09:10]
jackiiilong is there spring channel [09:10]
mbooth jackiiilong: Maybe, your client doesn't let you search the channel list? [09:11]
Teckla Great! Thanks a bunch all :) [09:11]
dreamreal jackiiilong: yes. [09:11]
Maldivia Teckla: basically, if you're using a new enoigh JVM, you can set the -XG1PeriodicGCInterval= setting to enable periodic gc, even when idle [09:11]
Maldivia -XX:G1PeriodicGCInterval [09:11]
jackiiilong yes ,there is [09:11]
dreamreal Teckla: also, can you consider spinning up a secondary VM, a microcontainer or something, using messaging to process the jobs? [09:11]
dreamreal Teckla: then you would have the external container handle ONE job at a time (guaranteeing "space") and if you needed faster throughput you could spin up other containers; each one would give you the ability to process another job at a given time [09:12]
Teckla dreamreal: Alas, it takes ~20-30m to "spin up" one of these JVMs. [09:13]
Teckla And they run on kind of expensive AWS VMs. We use ~60 GiB heaps. [09:13]
Maldivia well, if you could split them into smallers, perhaps the startup time would be significant lower, and also the required VM size would also be lower? [09:14]
dreamreal well, my thought is that if you had those containers, maybe they could use LESS room [09:14]
dreamreal i.e., what Maldivia just said [09:14]
hussam [hussam!~hussam@unaffiliated/hussam] has joined ##java [09:14]
mbooth 20-30minutes! AWS is made of potatoes, confirmed. [09:15]
Teckla We do indeed have a medium-term project to eject the parts of the code that cause the ~20-30m spin up time, as a side effect that'll make the heap much smaller too. We currently make direct Java calls into another team's API, which is what requires all the resources. We are changing those out to web calls to their JVMs (which they now support). [09:15]
AmVarPG [AmVarPG!~amvarpg@pool-100-36-155-137.washdc.fios.verizon.net] has joined ##java [09:16]
Maldivia mbooth: have you ever tried booting a SAP Hybris installation ? :D [09:17]
mbooth Maldivia: If by "booting" you mean "kicked with a booted foot" [09:17]
dougquaid [dougquaid!~dougquaid@unaffiliated/dougquaid] has joined ##java [09:19]
Sgeo [Sgeo!~Sgeo@ool-18b98aa4.dyn.optonline.net] has joined ##java [09:22]
DataComputist [DataComputist!~lumeng@50.43.26.251] has joined ##java [09:22]
Maldivia mbooth: well, in this case, considering it's SAP, I guess that's an appropriate analogy [09:27]
Jantz [Jantz!~IceChat95@118-93-24-249.dsl.dyn.ihug.co.nz] has joined ##java [09:27]
dougquaid [dougquaid!dougquaid@gateway/vpn/privateinternetaccess/dougquaid] has joined ##java [09:32]
plarsen [plarsen!~plarsen@redhat/jboss/pdpc.professional.plarsen] has joined ##java [09:32]
hussam [hussam!~hussam@unaffiliated/hussam] has joined ##java [09:33]
ries [ries!~ries@217-121-199-239.cable.dynamic.v4.ziggo.nl] has joined ##java [09:33]
ries any recommendation for a online 1Z0-817 course? This is for private person, so a 3000euro classical is unfortunatly out of the question [09:35]
mbooth What the heck is a "1Z0-817" course? [09:36]
cheeser java cert stuff apparently. [09:37]
ries mbooth: well, english is not my native language? but I want to preperare for 1z0-817?. so I just want to get all the in?s and outs of java 11 comming from java 8? [09:38]
Teckla Thanks again, folks, for the GC help above ^^^ [09:39]
mbooth When I google for the "1Z0-817" syllabus, it just looks like the ToC from the tutorial? Is that right? [09:39]
mbooth Just do the tutorial :-p [09:39]
ries perhaps I should have said study guide? [09:39]
dreamreal ries: why not do the tutorial, if it's for java certification? Then read effective Java. Then take the cert course, and throw the certificate away. [09:53]
ries unfortunatly, companies I currently work for somewhat cares for the cert (for good reasons) [09:54]
dreamreal there really are no GOOD reasons, they might care but it's still not a good reason, no matter what it is [09:55]
ries For them it?s just to set a baseline, that?s it? [09:56]
dreamreal see? not a good reason [09:56]
ries it helps to seperate the script kiddies from the rest?. mind you, this is a company where people are working for +20 years? and people comming from different technologies so they don?t come in and hired with some knowledge set? [09:57]
ries I get what you are saying though... [09:57]
dougquaid [dougquaid!dougquaid@gateway/vpn/privateinternetaccess/dougquaid] has joined ##java [09:58]
dreamreal yeah, I get it: it's sort of a badge, a signal that someone had the time and commitment to go through certification [09:59]
dreamreal but it's sort of like a tattoo: having one doesn't mean anything more than you actually were willing to get a tattoo, if it's of a cross or something it doesn't mean you have any convictions, just that you're signalling those convictions [09:59]
Suchorski [Suchorski!~regex@unaffiliated/suchorski] has joined ##java [10:00]
hussam [hussam!~hussam@unaffiliated/hussam] has joined ##java [10:01]
seschwar [seschwar!~seschwar@unaffiliated/seschwar] has joined ##java [10:03]
Jantz_ [Jantz_!~IceChat95@118-93-24-249.dsl.dyn.ihug.co.nz] has joined ##java [10:06]
Jantz [Jantz!~IceChat95@118-93-24-249.dsl.dyn.ihug.co.nz] has joined ##java [10:12]
dreamreal https://blogs.oracle.com/javamagazine/how-to-program-machine-learning-in-java-with-the-tribuo-library?source=:em:nw:mt::::RC_WWMK200429P00043:NSL400135485&elq_mid=186705&sh=1712822111912771813202291515214613&cmid=WWMK200429P00043C0021 [10:18]
Maldivia lovely tracking info there :D [10:18]
dreamreal yeah, strip that crap out, I guess :) [10:19]
dreamreal https://blogs.oracle.com/javamagazine/how-to-program-machine-learning-in-java-with-the-tribuo-library [10:19]
muhaha [muhaha!59b09477@gateway/web/cgi-irc/kiwiirc.com/ip.89.176.148.119] has joined ##java [10:20]
tang^ Thanks for stripping [10:24]
Jantz_ [Jantz_!~IceChat95@2407:7000:8d04:100:60da:aa3b:77cc:3493] has joined ##java [10:31]
perrier-jouet [perrier-jouet!~perrier-j@modemcable012.251-130-66.mc.videotron.ca] has joined ##java [10:31]
cheeser woo woo! [10:33]
AStorm hey, is there a way to create an entity that's essentially an alias for another in JPA? Normally subclassing requires a discriminator, but I don't want one; I need a mutable version of the entity and an Immutable one [10:38]
AStorm (because locking in JPA) [10:38]
AStorm ah, forgot to mention, this is Hibernate where @Immutable comes from [10:41]
AStorm however Entity and subclassing come from JPA and it seems they either didn't make it possible to have a subclasses that are essentially a variant of the superclass with no new non-transient fields that is not discriminated in any way except by type [10:42]
AStorm there's MappedSuperclass for when the superclass does not matter, but in my case I want to have subclass be just the same as superclass except mutable [10:45]
cheeser sounds like a questionable design [10:45]
AStorm questionable is that I have to do it because getting a mutable entity puts a database lock on it in SERIALIZED with no modifications to it [10:45]
iamroot [iamroot!~iamroot@kohoutek.uberspace.de] has joined ##java [10:46]
Jantz [Jantz!~IceChat95@2407:7000:8d04:100:c82a:9b6a:244c:5ffa] has joined ##java [10:46]
AStorm theoretically readOnly on @Transactional should prevent this behavior, however this is implemented in newer Spring for hibernate than I can use [10:47]
dreamreal also might be of interest: https://www.humblebundle.com/books/pocket-reference-guides-oreilly-books [10:48]
AStorm (they implemented it in Spring 5.1...) [10:48]
dreamreal dreamreal's title: "Humble Book Bundle: Pocket Reference Guides by O'Reilly (pay what you want and help charity)" [10:48]
AStorm Hibernate's Immutable is weird anyway, not an actual immutability or quarantee [10:57]
AStorm can't cheat it with TABLE_PER_CLASS and same table [11:05]
AStorm ffs Hibernate DWIM [11:05]
AStorm Do I really have to be nasty and extract the fields into MappedSuperclass because :( [11:07]
cheeser sounds like you need to ask a hibernate forum instead of ranting here. clearly no one here knows the answer to your problem. [11:08]
AStorm I suppose [11:09]
mbooth Programming, man. As 7 year old cousin said, "It's just typing!" [11:09]
dreamreal AStorm: what are you trying to do? [11:10]
mbooth So y'know, type harder :-) [11:10]
cheeser mbooth: unless it's javascript [11:10]
AStorm dreamreal: so the problem is, I have a bunch of transactions that are and should be SERIALIZED; there are a few entities required for processing that are in essence immutable too [11:11]
dreamreal okay [11:11]
dreamreal and? [11:11]
mbooth cheeser: Who writes javascript? I thought the cool kids rediscovered type systems and write typescript [11:11]
cheeser \_(?)_/ [11:11]
mexen_office [mexen_office!~mexen@165.56.185.150] has joined ##java [11:12]
AStorm however, there is an admin page where you can modify those entities essentially, totally separate [11:12]
AStorm now if I just use a mutable entity in SERIALIZED transaction, Hibernate takes a lock on the Entity in transaction and I hit an exception when saving and flushing an unrelated thing (cascade is not involved) [11:12]
Christofosho [Christofosho!~christofo@unaffiliated/christofosho] has joined ##java [11:12]
AStorm the actually not changed entity is bound to this serialized transaction for no good reason [11:14]
mbooth AStorm: You need a twitter account :-) [11:14]
AStorm and hibernate in case of SERIALIZED takes a row lock; this results in specifically ORA-08177 [11:14]
AStorm if entity is @Immutable hibernate does not take a row lock on it, which is all nice and solves my problem [11:15]
muhaha27 [muhaha27!59b09477@gateway/web/cgi-irc/kiwiirc.com/ip.89.176.148.119] has joined ##java [11:15]
AStorm however I still need the mutable version [11:15]
muhaha is there any database cli ( like flyway,liqibase ) that can actually create databases ? [11:16]
muhaha cli/library* [11:16]
Maldivia both of those can [11:16]
muhaha they can not [11:16]
muhaha only schemas [11:16]
cheeser dbunit [11:17]
cheeser DbUnit is a JUnit extension targeted at database-driven projects that puts your database into a known state between test runs. See http://dbunit.sourceforge.net/ [11:17]
dreamreal AStorm: so you have a few options... one is to actually have a different admin *app* [11:18]
AStorm (yes, which would take half a month to separate out of this pile of code, not an option as much as I'd like that) [11:19]
dreamreal You could also have the class mapped in via XML, and have teh class just be a POJO; the admin page would use the sessionfactory that had the mutable mapping, the app would use the immutable version [11:19]
AStorm very interesting and nasty, I'll check this out [11:19]
dreamreal nasty? [11:19]
AStorm see we don't have any XML mappings, this is all Spring Boot and as such everything is done in code and annotations [11:20]
dreamreal shrugs [11:20]
AStorm so this means I'd have to mangle current Hibernate configuration, whihc is autoconfiguration [11:22]
AStorm to get it to ignore some entities, and drop them only in one of two factories [11:22]
mexen_office [mexen_office!~mexen@165.56.185.150] has joined ##java [11:23]
dreamreal don't know what else to tell you offhand [11:23]
AStorm it's fine, dirty hacks is where I'm at right now [11:23]
dreamreal that's not a dirty hack, though :) [11:23]
AStorm oh, or I could get the admin page to never modify entities, just construct new ones [11:23]
mbooth be a rubber ducky [11:23]
mbooth WHY WOULD I WANT TO? [11:23]
AStorm that's because Immutable only affects update, not insert or delete [11:24]
dreamreal It's a little unusual in that the two mappings would be over the same schema, but eh, the metadata for the tables WOULD be different [11:24]
mexen_office [mexen_office!~mexen@165.56.185.150] has joined ##java [11:24]
mbooth Err, sorry javabot [11:24]
AStorm thanks, now I have 4 options [11:24]
AStorm dreamreal++ [11:24]
AStorm (or am I bad at giving karma) [11:25]
tang^ dreamreal++ [11:25]
tang^ dreamreal has a karma level of 2, tang^ [11:25]
tang^ he has no karma anyway [11:25]
AStorm dreamreal++ [11:26]
AStorm dreamreal has a karma level of 3, AStorm [11:26]
cheeser giggles [11:26]
dreamreal I liked it better the first time. [11:26]
georgios [georgios!~george@unaffiliated/anaphaxeton] has joined ##java [11:27]
ADG1089__ [ADG1089__!~aditya@122.163.250.138] has joined ##java [11:28]
sagax [sagax!~sagax_nb@213.138.71.146] has joined ##java [11:29]
ADG1089__ [ADG1089__!~aditya@122.163.250.138] has joined ##java [11:40]
gelignite [gelignite!~gelignite@55d4551e.access.ecotel.net] has joined ##java [11:47]
Jantz_ [Jantz_!~IceChat95@2407:7000:8d04:100:d83d:d29b:adce:f9b4] has joined ##java [12:04]
hnOsmium0001 [hnOsmium0001!uid453710@gateway/web/irccloud.com/x-czcoxqegzsrqhure] has joined ##java [12:05]
linext [linext!~linext@pool-108-53-128-75.nwrknj.fios.verizon.net] has joined ##java [12:05]
georgios [georgios!~george@unaffiliated/anaphaxeton] has joined ##java [12:07]
plarsen [plarsen!~plarsen@redhat/jboss/pdpc.professional.plarsen] has joined ##java [12:07]
sleepingforest [sleepingforest!~sleepingf@unaffiliated/sleepingforest] has joined ##java [12:07]
jaskal [jaskal!jaskal@unaffiliated/jaskal] has joined ##java [12:07]
perrier-jouet [perrier-jouet!~perrier-j@modemcable012.251-130-66.mc.videotron.ca] has joined ##java [12:07]
baiguai [baiguai!~baiguai@c-73-181-176-71.hsd1.wa.comcast.net] has joined ##java [12:07]
ebullient [ebullient!~ebullient@redhat/ebullient] has joined ##java [12:07]
grumble [grumble!~Thunderbi@freenode/staff/grumble] has joined ##java [12:07]
GnarlyBob [GnarlyBob!~chris@unaffiliated/gnarlybob] has joined ##java [12:07]
Orphis [Orphis!~orphis@adam.orphis.net] has joined ##java [12:07]
mz` [mz`!~mz@unaffiliated/mz/x-1545692] has joined ##java [12:07]
mzajc [mzajc!~mzajc@unaffiliated/mzajc] has joined ##java [12:07]
mz` [mz`!~mz@unaffiliated/mz/x-1545692] has joined ##java [12:11]
veegee [veegee!~veegee@bras-base-toroon0411w-grc-54-142-114-200-174.dsl.bell.ca] has joined ##java [12:20]
glowdemon1 [glowdemon1!~glowdemon@ptr-lshz04u69n455moooc.18120a2.ip6.access.telenet.be] has joined ##java [12:33]
glowdemon1 https://gist.github.com/RobbeVW/89faedb21cdc974772cee97b07f02aab [12:35]
glowdemon1 Hi. Does anyone know if there's a cleaner way to use WHERE IN with a SET when using the JdbcTemplate in Spring Boot? [12:35]
glowdemon1 Right now I have to ",?".repeat(ids.size) and thats kinda gross [12:36]
yawkat postgres has an array contains [12:37]
ernimril glowdemon1, I do not use JdbcTemplate, but jdbc does not really have any nice way to bind an array that works across databases [12:37]
yawkat but yes thats generally what you have to do [12:37]
Maldivia glowdemon1: is there a reason you're not using the build in functionality for it? [12:38]
Maldivia or at lieast the spring respository has support for List<Foo> findByIdIn(List<Long> ids); [12:39]
glowdemon1 It's for my uni course [12:40]
glowdemon1 Spring Hibernate comes after this, I guess they want to build on this [12:40]
glowdemon1 I guess I'll have to come to terms with my perfectionism then. Thanks for the advice yall [12:41]
marccollin glowdemon1: there is spring data jdbc [12:42]
Maldivia why no homework [12:43]
Maldivia We understand you aren't asking us to do your homework. That's not why we don't answer. We don't because 1) You usually don't comprehend the answer and we get stuck in an endless loop of 'why', 2) You will understand, but you'll retort with "my professor doesn't want me to do it this way'. That's frustrating. 3) Homework questions are boring questions. We don't get paid. Your prof does. [12:43]
Peste_Bubonica [Peste_Bubonica!~Peste_Bub@unaffiliated/peste-bubonica/x-4612396] has joined ##java [12:58]
zeden [zeden!~user@unaffiliated/zeden] has joined ##java [01:01]
dmlloyd there's a java discord server that will help with homework fwiw [01:06]
dmlloyd could start redirecting people there [01:06]
fingo [fingo!~fingo@gateway/tor-sasl/fingo] has joined ##java [01:10]
glowdemon1 [glowdemon1!~glowdemon@ptr-lshz03fj07hkyxyvy0.18120a2.ip6.access.telenet.be] has joined ##java [01:11]
fax [fax!~quassel@unaffiliated/fax] has joined ##java [01:17]
Jigsy [Jigsy!~Jigsy@unaffiliated/jigsy] has joined ##java [01:30]
mizi_ [mizi_!~mizi@p200300ecf70719006943bae37d984647.dip0.t-ipconnect.de] has joined ##java [01:30]
anovick [anovick!~anovick@IGLD-83-130-128-226.inter.net.il] has joined ##java [01:30]
anovick is there a web-based Java IDE that can format the code? I'm using Repl.it but it can't do formatting apparently [01:32]
dreamreal Isn't Che web-based now? [01:32]
cheeser it is [01:33]
Maldivia VS Code :D [01:33]
ernimril anovick, why must it be web-based? [01:36]
bolovanos_ [bolovanos_!~bolovanos@unaffiliated/bolovanos] has joined ##java [01:39]
Maldivia if it's just for formatting, https://github1s.com/github/.github - F1, >new document, paste code, ctrl-k m, select javascript, shift-alt-f (yes, I know javascript is not java, but that VS Code in browser has the javascript formatter installed, and not the java formatter, and it's close enough) [01:39]
fingo [fingo!~fingo@gateway/tor-sasl/fingo] has joined ##java [01:46]
fingo [fingo!~fingo@gateway/tor-sasl/fingo] has joined ##java [01:47]
kicked fingo (Banned: please fix your connection. you're bouncing in and out. this ban will expire after 2h) [01:57]
anovick does anybody know why the formatted output looks worse than the input in this case?: https://codebeautify.org/javaviewer/cbe99728 [02:00]
cr6pt2r [cr6pt2r!~cr6pt2r@modemcable010.222-200-24.mc.videotron.ca] has joined ##java [02:00]
Maldivia anovick: learn to always use {} [02:01]
anovick i mean the if-if-else-else are on the same external indentation [02:01]
anovick also, the else inside the first if is just dangling there [02:02]
ernimril anovick, they are using some bad parsing/syntax tree handling and end up with a mess. Partly due to your code being a mess. [02:02]
anovick it's apparently not the only formatter that does it [02:03]
anovick first two results on google lead to the same output of formatting [02:03]
yawkat have you tried following the suggestions from above? [02:07]
muhaha52 [muhaha52!59b09477@gateway/web/cgi-irc/kiwiirc.com/ip.89.176.148.119] has joined ##java [02:07]
NorthwestVegan [NorthwestVegan!~Northwest@gateway/tor-sasl/northwestvegan] has joined ##java [02:09]
hussam [hussam!~hussam@unaffiliated/hussam] has joined ##java [02:10]
ries parted the channel: [02:16]
ries [ries!~ries@217-121-199-239.cable.dynamic.v4.ziggo.nl] has joined ##java [02:31]
ries when doing this : https://education.oracle.com/java-programming-learning-subscription/ls_40805 do you will get a certificate inlaid with gold and diamonds? :D [02:32]
Maldivia ries: no, but you get the personal satisfaction of having contributed to Larry's next yacht [02:35]
ries Maldivia: I will take a piacture from the internet and put it on the desk? But to be honest, the The Musashi is a small Yacht? [02:37]
ries so I can imagine he ordered to make a new one [02:38]
nyxyn [nyxyn!~nyxyn@2600:1700:3db0:2540:c6:39f0:e1b5:35b6] has joined ##java [02:47]
gareppa [gareppa!~gareppa@unaffiliated/gareppa] has joined ##java [02:51]
Jantz [Jantz!~IceChat95@118-93-24-249.dsl.dyn.ihug.co.nz] has joined ##java [02:55]
dreamreal ugh, Jena is arguing about upgrading log4j1 to log4j2... and not, like, slf4j [03:01]
dreamreal which isn't perfect but it's a damn bit better than log4j [03:01]
kupi [kupi!uid212005@gateway/web/irccloud.com/x-cgsykjurvegvbxhp] has joined ##java [03:05]
Maldivia sure upgrade to log4j2... but use the slf4j API and then bind to log4j as the backend? :D [03:05]
dreamreal exactly [03:05]
dreamreal but they apparently mangle some of the configurations in a way that mostly binds them to log4j, which is kinda gross [03:05]
dpl__ [dpl__!~dpl@77.121.78.163] has joined ##java [03:09]
mzajc_ [mzajc_!~mzajc@unaffiliated/mzajc] has joined ##java [03:21]
richbridger [richbridger!~richbridg@213-225-34-162.nat.highway.a1.net] has joined ##java [03:24]
cheeser 7 [03:25]
bolovanos__ [bolovanos__!~bolovanos@unaffiliated/bolovanos] has joined ##java [03:39]
svm_invictvs Would you ever want to use HSQLDB in production? [03:41]
yawkat h2, but sure why not [03:42]
Maldivia depends on the production [03:47]
svm_invictvs Well, looking for an embedded databse in Java [03:48]
dreamreal for a specific embedded purpose, sure [03:48]
svm_invictvs Derby works as well [03:48]
dreamreal and I would use h2 over hsqldb, although I could be convinced to consider hypersql [03:48]
Maldivia in the license server software we distribute, we have an embedded h2 [03:48]
dreamreal svm_invictvs: h2 starts FAR more quickly [03:48]
svm_invictvs Is Derby a Red Had joke? [03:48]
svm_invictvs *Red Hat [03:49]
dreamreal svm_invictvs: no, it was an IBM DB [03:49]
svm_invictvs I see. [03:49]
dreamreal it's basically db2 in an embedded db [03:49]
Maldivia derby, or Java DB as it was called, was bundled with the JDK in Java 6 to 8 [03:51]
Maldivia with OracleJDK, that is [03:51]
moldorcoder7 [moldorcoder7!~moldorcod@206.166.251.59] has joined ##java [03:57]
Remavas [Remavas!~Remavas@unaffiliated/remavas] has joined ##java [04:06]
aedroid [aedroid!~aedroid@89-181-227-120.net.novis.pt] has joined ##java [04:10]
mirrorbird [mirrorbird!~psutcliff@2a00:801:3f2:fa8e:16b2:2b3e:c801:a519] has joined ##java [04:15]
kicked mirrorbird (Banned: this ban will expire after 180d) [04:15]
Alina-malina [Alina-malina!~Alina-mal@unaffiliated/alina-malina] has joined ##java [04:17]
dpl_ [dpl_!~dpl@77.121.78.163] has joined ##java [04:23]
Exagone313 [Exagone313!exa@3131313.xyz] has joined ##java [04:26]
Tabmow [Tabmow!~tabmow@freenode/staff-emeritus/tabmow] has joined ##java [04:26]
ashka [ashka!~postmaste@pdpc/supporter/active/ashka] has joined ##java [04:26]
Tabmow [Tabmow!~tabmow@freenode/staff-emeritus/tabmow] has joined ##java [04:27]
AcTiVaTe [AcTiVaTe!~activate@host-4b6u8h.tnz1.zeelandnet.nl] has joined ##java [04:30]
averell [averell!~averell@unaffiliated/averell] has joined ##java [04:34]
jcnmark6 [jcnmark6!~jcnmark6@static.213-133-100-141.clients.your-server.de] has joined ##java [04:34]
dansan [dansan!~daniel@75.81.148.51] has joined ##java [04:34]
fizzie [fizzie!fis@unaffiliated/fizzie] has joined ##java [04:34]
qqqhhh [qqqhhh!~qqqhhh@94.228.80.243] has joined ##java [04:34]
seanBE [seanBE!~seanBE@unaffiliated/seanbe] has joined ##java [04:34]
Azrael_- [Azrael_-!~aweoi@51.154.62.124] has joined ##java [04:34]
makani [makani!makani@gateway/vpn/privateinternetaccess/makani] has joined ##java [04:34]
LaSombra [LaSombra!lasombra@unaffiliated/lasombra] has joined ##java [04:34]
hanetzer [hanetzer!~hanetzer@abyss/hanetzer] has joined ##java [04:34]
markmarkmark [markmarkmark!~mark@167.99.235.46] has joined ##java [04:34]
polyrob [polyrob!~rob@unaffiliated/mickn] has joined ##java [04:34]
VectorX [VectorX!~VectorX@unaffiliated/vectorx] has joined ##java [04:34]
m1dnight_ [m1dnight_!~m1dnight@188.ip-51-91-158.eu] has joined ##java [04:34]
jontxu [jontxu!~jon@unaffiliated/jontxu] has joined ##java [04:34]
michele [michele!~eraser@unaffiliated/michele] has joined ##java [04:34]
raj [raj!~raj@unaffiliated/cypha] has joined ##java [04:34]
a3Dman [a3Dman!~3Dman@unaffiliated/a3dman] has joined ##java [04:34]
Squarism [Squarism!~someone@unaffiliated/squarism] has joined ##java [04:34]
gurrkiin [gurrkiin!~irc@unaffiliated/gurrkiin] has joined ##java [04:34]
nortti^ [nortti^!nortti@nortti.win] has joined ##java [04:34]
tabakhase [tabakhase!tabakhase@unaffiliated/tabakhase] has joined ##java [04:34]
amosbird [amosbird!~amosbird@13.75.119.182] has joined ##java [04:34]
ricky_clarkson Just out of curiosity, if mirrorbird gets banned for 180 days at a time, why do I see it back here before 180d? [04:34]
makani [makani!makani@gateway/vpn/privateinternetaccess/makani] has joined ##java [04:35]
michele [michele!~eraser@unaffiliated/michele] has joined ##java [04:35]
m1dnight_ [m1dnight_!~m1dnight@188.ip-51-91-158.eu] has joined ##java [04:37]
Maldivia ricky_clarkson: because the banlist is cleared from time to time [04:37]
Maldivia and then chanserv will auto-kick on join as long as it still knows about it [04:37]
a3Dman [a3Dman!~3Dman@unaffiliated/a3dman] has joined ##java [04:39]
plarsen [plarsen!~plarsen@redhat/jboss/pdpc.professional.plarsen] has joined ##java [04:41]
ricky_clarkson Thanks. [05:00]
Jigsy [Jigsy!~Jigsy@unaffiliated/jigsy] has joined ##java [05:01]
johnjay [johnjay!~pi@38.120.10.99] has joined ##java [05:04]
johnjay hmm. the tutorial for java on oracle's website is for jdk 8. i guess there's been changes since then for 15 [05:04]
Maldivia johnjay: there has been additions, yes, but those additions are not really Java 101 additions, so the tutorial is still good [05:05]
johnjay i see [05:05]
dreamreal Maldivia: I like cheeser's idea of crowdsourcing a new one, though [05:07]
Maldivia a new tutorial ? [05:07]
dreamreal yeah [05:07]
Cahaan_ [Cahaan_!~Cahaan@55.166-245-81.adsl-dyn.isp.belgacom.be] has joined ##java [05:10]
Maldivia for a starter, the java 8 tutorial + a ToC with links to info about new features, could a good starting point? [05:11]
dreamreal yeah, but then we'd run into oracle's licensing on the CURRENT tutorial [05:12]
Maldivia well, refence that as intro, and go from there? [05:12]
pydr [pydr!~pydr@151.37.80.73] has joined ##java [05:13]
pydr hello [05:13]
pydr does anyone have experience with apache tika? [05:13]
pydr i need to understand if there is a way to correctly define box boundaries [05:13]
Maldivia what are you trying to do? [05:14]
pydr Maldivia, my problem is that the extraction should follow some rule... I should do a layout analysis or something like that to understand the "sequence/order" of the blocks of text [05:16]
pydr because if the user creates a pdf with two columns i should extract the row sequence one after the other [05:17]
pydr tika often extract all the text of a column and then the other one.. [05:17]
pydr in many case it mess up all the next steps i need to do (i do NLP) [05:17]
Maldivia is there a reason you're using tika for this, and not using pdfbox directly? [05:17]
pydr so for me the relations of the blocks of text matter [05:18]
pydr Maldivia, because i need to handle different formats, doc, pdf openoffice formats etc [05:18]
pydr for that reason [05:18]
pydr what pdfbox does? [05:18]
mindCrime [mindCrime!~prhodes@2603-6080-5900-001c-33e9-8731-abb2-ef1d.res6.spectrum.com] has joined ##java [05:18]
Maldivia it's a pdf parsing lib [05:19]
pydr i am reading, yes ok...hmm it could works too, i mean that i can convert doc into pdf (and pray everything goes fine) [05:20]
pydr and then use pdfbox [05:20]
pydr the problem as i wrote is not the extraction (with the extraction i mean the capability to understand the format)... i mean that i must understsand the layout and then understand the related boxes [05:21]
pydr because if i get all the text of a column and then the other and the other again...it will mess up everything, my NER model will not understand the real context [05:21]
Maldivia well, that information might not be in the file unless rendered on screen/paper [05:21]
pydr Maldivia, so maybe is better to convert the document in an image? [05:22]
pydr and then work with an OCR [05:22]
Maldivia pydr: well, then you have OCR issues instead -- not that you can't already have that with PDF, but :D [05:22]
pydr Maldivia, yeah you are right but however thinking about the box boudaries i can get TEXT + position(x,y) in a document [05:23]
pydr so maybe an ocr is not needed [05:23]
pydr but i need to train a model that understand with text + position the relations [05:23]
pydr but seems quite difficult [05:23]
Maldivia pydr: but how do YOU know that those boundries are correct? [05:23]
dreamreal Maldivia: I was thinking about just starting a doc on github and just covering installing java... and then kinda progressing from there [05:23]
pydr Maldivia, good question, i can train the model with a labelled document... but yeah i should have many document to train the model well, but it could be a start [05:24]
Maldivia pydr: how do you recognize if it's two columns of text, or a table with left-right values? [05:24]
pydr visually to train the model it depends of text context and mainly on the struture of the document because i am parsing resume/Cv [05:25]
pydr so it is not a completely random format [05:25]
Maldivia ok, yeah, context is key [05:26]
pydr yes absolutely [05:26]
pydr hard task [05:28]
Maldivia pydr: quick example from google image search -- https://cdn-images.zety.com/images/zety/landings/examples/artist-cv-example@2x.png -- I have no idea how it would be stored in a PDF, but there are many columns here, some related to eachother, some not, some spanning multiple lines, etc [05:29]
greentree47 [greentree47!~greentree@unaffiliated/greentree47] has joined ##java [05:31]
greentree47 is there a good data type for really large values that support decimals [05:31]
cheeser javadoc BigDecimal [05:31]
cheeser cheeser: https://bit.ly/2XRM1R0 [JDK: java.math.BigDecimal] [05:31]
Maldivia BigDecimal [05:31]
greentree47 what about double [05:31]
dreamreal BigDecimal? [05:31]
dreamreal depends on what "good" means for you [05:31]
greentree47 i was using long and then i realized i needed decimals too [05:31]
greentree47 but worried about like rounding errors [05:31]
dreamreal IEEE FP is not known for being especially accurate [05:32]
dreamreal if you NEED accuracy, use BigDecimal [05:32]
Maldivia greentree47: what is "really large", and what kind of precision do you need? [05:32]
greentree47 values can go into the trillions [05:32]
Jantz_ [Jantz_!~IceChat95@118-93-24-249.dsl.dyn.ihug.co.nz] has joined ##java [05:32]
pydr Maldivia, i need to understand what model to train, maybe a CNN [05:32]
greentree47 and i could probably round [05:33]
sonOfRa You want BigDecimal and specify a roundingmode [05:33]
sonOfRa That way you control the rounding, rather than the inaccuracies piling up due to float arithmetic [05:33]
Maldivia pydr: "what model to train" -- yeah, that's where I stop being helpful :D [05:33]
pydr Maldivia, :) [05:34]
pydr Thank you i will use that png to do some test [05:34]
greentree47 how do i do that stuff sonOfRa [05:36]
Maldivia pydr: as said, it was one of the first results from a google image search on CV -- just to show how columns may or may not be related -- usually there are some visual ques that we as human just pick up, but how to detect that in code, or train something to detect that -- no idea [05:36]
cheeser greentree47: read the javadoc [05:36]
pydr yeah, very hard [05:36]
sonOfRa BigDecimal myNumber = new BigDecimal("123456789101112131415.1617181920212223") [05:36]
sonOfRa Such magic. [05:36]
sonOfRa javadoc MathContext [05:37]
sonOfRa javadoc BigDecimal [05:37]
sonOfRa sonOfRa: https://bit.ly/2XRM1R0 [JDK: java.math.BigDecimal] [05:37]
sonOfRa sonOfRa: https://bit.ly/307WLw3 [JDK: java.math.MathContext] [05:37]
pydr Maldivia, or maybe i can try an heuristic way just working with the "distance" of blocks and maybe understand if there are titles or something like that [05:37]
sonOfRa you'll need those two, and as a tip: Don't actually round. Only do the rounding when displaying the numbers later on. [05:37]
johnjay weirdly you can still download "Java SE Development Kit 8u281 Documentation" from oracle as well [05:37]
sonOfRa javadoc DecimalFormat [05:37]
sonOfRa sonOfRa: https://bit.ly/2SzgQVJ [JDK: java.text.DecimalFormat] [05:37]
Maldivia johnjay: ofcourse you can - using oracle jdk for developement and testing is still ok [05:38]
johnjay so is the jdk not maintained by oracle? [05:38]
johnjay did they "open source" it and then stop making materials? [05:38]
dreamreal Sun open sourced it [05:39]
dreamreal which I'm sure oracle's resented from day one [05:39]
Maldivia johnjay: OpenJDK is maintained by... OpenJDK -- Oracle helps maintain OpenJDK, but they also have their own distribution of it, that they provide premium support on, that is called OpenJDK [05:39]
Maldivia ehh OracleJDK [05:40]
johnjay why would they resent it? sun did it before they were acquired by oracle according to wiki [05:42]
johnjay that's like me resenting you for damaging your car that i just bought at a reduced price [05:42]
Maldivia johnjay: it's like you resenting me for limping my race horse as you were about to buy it [05:42]
Maldivia sure it's cheaper now, but it's not going to win you a lot of money in races [05:43]
dreamreal johnjay: They resented it because java turned out to be the jewel in teh crown of acquiring Sun [05:52]
dreamreal and damn it ANY old fool could use it [05:52]
dreamreal I mostly wish Sun hadn't ... done what steps they did to wreck themselves, I loved Sun [05:52]
ricky_clarkson If they hadn't have open sourced it I wonder if we'd have basically stopped using it by now out of fear of Oracle's lawyers/licencing costs. [05:54]
dreamreal probably [05:55]
hschmale [hschmale!hschmale@otaku.sdf.org] has joined ##java [05:58]
johnjay i don't know much about what happened to sun. [05:58]
johnjay i did use sun solaris workstations once upon a time. they were cool. [05:59]
dreamreal They went bankrupt because their marketing was ass and the sharks that circled them were smarter than they were. Sun always had a much better tech stack than business plan. [05:59]
johnjay sad. that is the way of the world though [06:00]
johnjay it is as much bravery and power and money that decide things as having the technically best or efficient tech [06:00]
johnjay *cough* iphones *cough* [06:01]
dreamreal Oddly enough java probably helped kill sun, by making the sparc platform less relevant [06:01]
ricky_clarkson I had to support a Java app with a JNI component, including a build for Sparc. That was by far my slowest platform. [06:01]
dreamreal even though java ALSO meant that you could write an app on a pissant windows machine and run it as is on a sparc [06:01]
ricky_clarkson I believe the only Sparc customer we had was actually Sun at the time. :) [06:01]
dreamreal ricky_clarkson: Hrm. I had an E350 personally, and also had root on a E10K [06:02]
dreamreal The E10K was a freaking beast [06:02]
ricky_clarkson I have no idea what it was now, just that it was slow and noisy. This was around 2008, and I think it was already outdated by then. [06:02]
dreamreal I got my E350 in 2006 or so :) [06:03]
dreamreal I actually used it for a few years after that, I loved that thing even though it was pretty much binary compatible with nothing [06:04]
ricky_clarkson "Sun always had a much better tech stack than business plan" - Commodore before them too :/ [06:04]
dreamreal well, commodore had a *cheaper* tech stack which made up for their lack of a business plan... [06:05]
ricky_clarkson heh [06:05]
dreamreal Then the Amiga, of course, but then you're right on target: better tech stack, still amazingly terrible business plan [06:05]
dreamreal The fact that people still idolize the amiga *even now* says a lot about how much value they pissed away [06:06]
ricky_clarkson I still emulate it to compose midi files (OctaMED SoundStudio). [06:07]
dreamreal oof [06:07]
dreamreal that's cool, but... oof [06:07]
johnjay dreamreal: yes i do sometimes hear about the great old days of amiga [06:08]
johnjay i always assumed people do that out of nostalgia or just good marketing [06:08]
dreamreal the amiga was worldshattering for its day [06:08]
ricky_clarkson I even saw Java running on it, probably not technically Java but kava/kawa or something built on gij [06:08]
johnjay > I've had an Amiga for maybe a decade. It's the single most reliable piece of equipment I've ever owned. It's amazing! You can easily understand why so many fanatics are out there wondering why they are alone in their love of the thing. The Amiga continues to inspire a vibrant ? albeit cultlike ? community, not unlike that which you have with Linux, the Unix clone. [06:09]
johnjay --John C Dvorak [06:09]
Tabmow Would there be any possible reason why I get a 'The dependencies of some of the beans in the application context form a cycle only sometimes' error when deploying my application to AWS ECS, but I can't replicate it locally when I start my app seemingly with the same configuration? [06:12]
Anthaas [Anthaas!~Anthaas@unaffiliated/anthaas] has joined ##java [06:12]
cheeser pull down what's deployed there and diff it. [06:17]
cheeser check the logs for errors [06:17]
FreEm1nD [FreEm1nD!~freemindm@177-74-120-62.inbnet.com.br] has joined ##java [06:17]
johnjay hrm the java 15 api has a different layout [06:19]
johnjay i kinda prefered the "one long list of everything" [06:19]
cheeser it started changing with 9 and modules [06:19]
cheeser well, it was always *changing* but, you know... [06:20]
Maldivia well, there was still the frames layout, until java 11 [06:21]
Maldivia johnjay: but now you have a search box instead [06:22]
Maldivia johnjay: and there is also https://docs.oracle.com/en/java/javase/15/docs/api/overview-tree.html [06:22]
Tabmow cheeser: it's the exact same package - only different is running it in windows locally, and linux in ECS [06:28]
Tabmow I did find this: This is very likely related to the order in which the class files are read in line [06:28]
Tabmow Since the order of file listing (class files) is dependent on the platform, and there is no sorting done on the array, the order the classes are loaded in is dependent on how the platform returns them. [06:28]
Tabmow dir.listFiles() in PathMatchingResourcePatternResolver.doRetrieveMatchingFiles() [06:28]
Tabmow Interesting... [06:28]
fax [fax!~quassel@unaffiliated/fax] has joined ##java [06:29]
bit4man [bit4man!~plarsen@redhat/jboss/pdpc.professional.plarsen] has joined ##java [06:30]
bolovanos_ [bolovanos_!~bolovanos@unaffiliated/bolovanos] has joined ##java [06:31]
johnjay is it intentional that javac will not update the class file if it exists? [06:35]
bolt [bolt!~r00t@unaffiliated/bolt] has joined ##java [06:37]
Maldivia it will if you ask it to compile that source file [06:38]
johnjay i did javac test.java && java test and changing/saving things doesn't have any effect [06:38]
Maldivia it should [06:39]
johnjay ok it does change if i change the hello world to hello worldddd [06:39]
johnjay but not if i rename class test { to class test11 { [06:39]
Maldivia it will, but then you have to run java test11 [06:39]
johnjay i guess i'm not understanding how the class loader works [06:39]
johnjay oh right. cause the file still exists [06:40]
Maldivia java [name of class you want to run, not file] [06:40]
johnjay right. that makes more sense [06:40]
johnjay i was trying to determine what happens if you compile a file where the class is not the filename [06:40]
Maldivia if the class is a public top-level class, you'll get an error [06:40]
Inline [Inline!~Inline@2a02:908:1252:7a80:38ee:c621:70e5:5da3] has joined ##java [06:41]
Maldivia for non-public, it wors [06:41]
Maldivia works* [06:41]
johnjay i... see [06:41]
Maldivia but do yourself a favor and keep filenames and classnames in sync, even for non-public classes!! [06:41]
johnjay right. i was trying to figure out the reason [06:42]
johnjay i didn't realize it mattered if it was public for that [06:42]
johnjay ah ok. so you can only have public class if it matches. adding another class like public class blah { gives an error [06:42]
Maldivia technically, you can have multiple top-level classes in the same file, but only one of them can be public [06:42]
johnjay yes exactly [06:42]
Maldivia the compiler will still compile and generate the correctly names .class files; the reason for having the names correct in source files as well, is so that javac can find the files for classes you reference [06:43]
Maldivia if you have Foo.java: public class Foo { public static void main(String[] args) { new Bar(); } } Other.java: class Bar {} -- if you compile Other.java first, and then compile Foo.java, it will work, but if you just try to compile Foo.java, it will fail, because it cannot find the Bar class, there is no Bar.class on disk, and no Bar.java either to compile it from [06:45]
johnjay ah i see it made 2 class files even though i had both classes in the same file [06:45]
Maldivia you get a .class file PER class in your source file (sometimes more than one) [06:45]
johnjay so it would seem [06:46]
johnjay so in that situation doing java Foo.java would implicitly compile Bar.java? [06:46]
johnjay er javac Foo.java? [06:47]
johnjay or no [06:47]
Maldivia in the above example, when you run javac Foo.java, the compiler needs to know what Bar is, so it will try to find it, first it will look for a Bar class on classpath (ie a Bar.class file on disk), if it fails to find it, it will then look for a source file that contains is, so it will look for a Bar.java file [06:48]
johnjay interesting. [06:49]
Maldivia so if you have a small project with say 10 classes, and all properly named source files etc, and you just compile the Main.java class, probably all 10 classes will end up being compiled [06:50]
johnjay ah it does do that [06:51]
johnjay i suppose i would learn all this if i actually looked at the openjdk source [06:51]
Maldivia naah [06:51]
cheeser or just rtfm [06:52]
dmlloyd you would think so, but no, that'd just confuse you a lot more [06:52]
Maldivia you would learn that if you read the docs [06:52]
Maldivia and then the next day you would forget about calling javac directly yourself, and move on to using a build system, like maven or gradle :D [06:52]
johnjay so far i have the original java whitepaper, the java api, and the java oracle tutorial [06:52]
johnjay XD [06:52]
cheeser you're not starting with Plato? that's an odd choice. [06:53]
Haxxa [Haxxa!~Haxxa@89nnjg0xckz9ggn6r5xm.ip6.superloop.com] has joined ##java [06:54]
Maldivia and skipping Oak as well [06:55]
rocktop [rocktop!~rocktop@196.74.40.39] has joined ##java [06:58]
georgios [georgios!~george@unaffiliated/anaphaxeton] has joined ##java [07:02]
TideFN [TideFN!~TideFN@2601:cb:8280:9520:5541:71c3:e8ce:33cb] has joined ##java [07:08]
Tabmow [Tabmow!~tabmow@freenode/staff-emeritus/tabmow] has joined ##java [07:11]
nyxyn [nyxyn!~nyxyn@2600:1700:3db0:2540:c6:39f0:e1b5:35b6] has joined ##java [07:15]
MrFlibble [MrFlibble!Rimmer@94.14.182.161] has joined ##java [07:20]
johnjay Plato like the philosopher? i thougth socrates was the father of philosophy [07:23]
ib07 [ib07!~quassel@162.215.broadband18.iol.cz] has joined ##java [07:26]
nyxyn Plato in spanish means plate [07:29]