X-CGP-ClamAV-Result: CLEAN X-VirusScanner: Niversoft's CGPClamav Helper v1.25a (ClamAV 0.103.6/26743) X-Junk-Score: 0 [] X-KAS-Score: 0 [] Return-Path: Received: from mail-qt1-f176.google.com ([209.85.160.176] verified) by selbstdenker.ag (CommuniGate Pro SMTP 6.3.14) with ESMTPS id 29039273 for webobjects-dev@wocommunity.org; Wed, 07 Dec 2022 23:43:20 +0100 Received-SPF: pass receiver=post.selbstdenker.com; client-ip=209.85.160.176; envelope-from=recurve@cocoanutstech.com Received: by mail-qt1-f176.google.com with SMTP id a16so2232504qtw.10 for ; Wed, 07 Dec 2022 14:43:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chatnbike.com; s=chatnbike; h=to:date:message-id:subject:mime-version:content-transfer-encoding :from:from:to:cc:subject:date:message-id:reply-to; bh=zdhGcs1Hui1uLSvotkOOE8ywYFHo6DXo8tcb4/n1SjM=; b=BkqprLOG1g6MIrw6s1Az9Mbo94m0c9XjMZBaKmh9YPON/fK66EZHiOdC8z/Zsh3G4J 9QVWw88bin2Sgytv//hAuw+8Qt1alCHI/YKyNdpgtERrjkO3o11ihBKmYU1JULrJp/Jt 1ehkM9Mr2ovCc4283+xSDcmw3fjcf5twJ9DIU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:date:message-id:subject:mime-version:content-transfer-encoding :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zdhGcs1Hui1uLSvotkOOE8ywYFHo6DXo8tcb4/n1SjM=; b=qBFzoQkkUUpCl7wclRVOIuWFrqpbIb9f0+F4g/WW4dKJVMY2HpZ8SYZeun78nrmnmA tgNdVX+yzRWanjTwKmzCWfnWc1jRZCE9HyAXCopZoP8GzXksGgS2Bn4QLhC4eCkT/VpU ncNYoVUAeNmI8qHsP/Kucy4+3RFU0tqEOfVz8VqDQdlXhjMPs1O9RteCIObwi7G/Z1Ys M3tVKjTXZhyIll2WH1P6e89NDcRh6DVhBbvSP5Au60El8J+S39Ufjq0HpKqtNcWQWHu/ e3WIt5JibFwB2rIkqwkm3Ype7hFNwbUw6BuSwHxekuCgxKVRFrdt5f+Eyrv7TF+DQXV2 h3FQ== X-Gm-Message-State: ANoB5pn216fo2w6PCCKeH/rHwDRM1qEumK6+FEcCfUJJYOwpZ4GFII8E Rkht/S8ViSLrFwuORKR4e53kig4+vs2hbm06OJU= X-Google-Smtp-Source: AA0mqf7SEPQJXt1IGqsBgxTqNc/W+0Xf932xMCZaIw85rWdMxNhakn6RnmWC/3FM6yLNGp4hBzWhsA== X-Received: by 2002:ac8:5443:0:b0:3a7:e2bb:d443 with SMTP id d3-20020ac85443000000b003a7e2bbd443mr13050311qtq.358.1670452978818; Wed, 07 Dec 2022 14:42:58 -0800 (PST) Return-Path: Received: from smtpclient.apple (pool-173-79-19-72.washdc.fios.verizon.net. [173.79.19.72]) by smtp.gmail.com with ESMTPSA id h6-20020a05620a400600b006fc2e2198easm6519573qko.95.2022.12.07.14.42.58 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 07 Dec 2022 14:42:58 -0800 (PST) From: Aaron Rosenzweig Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.120.41.1.1\)) Subject: When add-exports ALL-UNNAMED is not enough (Java 17) Message-Id: Date: Wed, 7 Dec 2022 17:42:57 -0500 To: WebObjects & WOnder Development X-Mailer: Apple Mail (2.3696.120.41.1.1) Hi WOrriors,=20 I=E2=80=99m upgrading to Java 17 from Java 1.8 and have run into snags = in my local Eclipse workspace. Perhaps you=E2=80=99ve struggled with = this too?=20 In general, this VM argument is helpful but not enough: --add-exports = java.base/sun.security.action=3DALL-UNNAMED The issue has to do with changes from Java 1.8 and java modules.=20 I can use 1.8 compatibility mode with my workspace (from Java 17 VM) and = there are no errors and no problems.=20 When I change to Java 17 compatibility mode, it falls apart.=20 My java apps are ok, but many of the WOnder frameworks don=E2=80=99t = build anymore.=20 For example ERAttachment. I have this error: The package org.xml.sax is = accessible from more than one module: , java.xml To me that means that it is available in a system module =E2=80=9Cjava.xml= =E2=80=9D and also in some old jar file=E2=80=A6 two places.=20 I clicked on ERAttachment (in WO Explorer pane) and then right click to = do "build path" and then "configure build path." I then went to the last = tab "Module Dependencies" clicked "java.xml" and then clicked "remove." = It gave me warnings that other things use it but I did it anyway. Now = the errors are gone for org.xml.sax.Attributes and similar imports. Yay!=20= I=E2=80=99m not done yet but I did similar things as follows: =E2=80=A2 ERAttachment - remove java.xml =E2=80=A2 ERRest - remove java.xml =E2=80=A2 ERChangeNotificationJMS - remove java.naming =E2=80=A2 ExcelGenerator - remove java.xml =E2=80=A2 ERPDFGeneration - remove java.xml =E2=80=A2 ERSelenium - remove java.xml =E2=80=A2 ERXiss - remove java.xml =E2=80=A2 DRGrouping - remove java.xml =E2=80=A2 ERJaxWS - remove java.xml =E2=80=A2 ERProfiling - lost cause? jdk.internal.loader is = inaccessible so I closed the project in my workspace (and am not = currently using it). I=E2=80=99m still coming to grips with all this but I have following = unresolved and possibly incorrectly stated questions: 1) Do most of us run with 1.8 compatibility in newer JVMs and leave it = at that?=20 2) Do some of us run with newer VM compatibility modes (to access new = features of Java) but then use =E2=80=9CALL-UNNAMED=E2=80=9D hacks along = with removing system module hacks like I was talking about above?=20 3) Do some of us use pre-built jars of Wonder and not build from source = in our Eclipse projects to get around some of these issues? But if so, = that means it=E2=80=99s not as nice to just dive into the source code = and quickly trace / change things as we are working... 4) Should we consider putting WOnder frameworks into module friendly = configurations? Or is that not possible because we need to support Java = 1.8 too?=20 5) What is the best way to use Java 17 VM along with any new java syntax = / functionality while still using WOnder frameworks?=20 Thanks to all for reading this far :-) =E2=80=94 Aaron=