From users-return-268734-archive-asf-public=cust-asf.ponee.io@tomcat.apache.org Tue Nov 12 14:13:40 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 0821D180656 for ; Tue, 12 Nov 2019 15:13:39 +0100 (CET) Received: (qmail 43793 invoked by uid 500); 12 Nov 2019 14:13:36 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 43782 invoked by uid 99); 12 Nov 2019 14:13:36 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 12 Nov 2019 14:13:36 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 96BCC1A3381 for ; Tue, 12 Nov 2019 14:13:35 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.442 X-Spam-Level: ** X-Spam-Status: No, score=2.442 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.2, HTML_OBFUSCATE_20_30=2.441, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-he-de.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id KXeUhLerqELH for ; Tue, 12 Nov 2019 14:13:31 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=2607:f8b0:4864:20::72b; helo=mail-qk1-x72b.google.com; envelope-from=nedim.kulovac@gmail.com; receiver= Received: from mail-qk1-x72b.google.com (mail-qk1-x72b.google.com [IPv6:2607:f8b0:4864:20::72b]) by mx1-he-de.apache.org (ASF Mail Server at mx1-he-de.apache.org) with ESMTPS id DD86F7DD69 for ; Tue, 12 Nov 2019 14:13:30 +0000 (UTC) Received: by mail-qk1-x72b.google.com with SMTP id e2so14518046qkn.5 for ; Tue, 12 Nov 2019 06:13:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=Q/zOM3AF/VD3/Sy+udrB7vGEnWpq0HjjOaZOuOlQTzU=; b=nFlt7PRLpmLwXOB8RxP8k9758ip6ZAKCXhLq8aI4a4Fw9mNOMRvAKfNHluQbHi/4MH 2IX1ThVbigF/Ikt7ZJEGlnRJ4lokpvi2aLCvnuronjazdTD1mUTtXUW90wrKIc88JqFh vWsMh8b7S4qwd8RuY6nsdWHN1j5+3CuyWyHX+TANCXaWkkzYQltErG5rF9o0u3GdAAxF POpq2mJAioy4f9lYU+I9mOWv5oxPNTjZ9cIM2p6Act8LLjjtcRlJ60jHbzgh8JecoVJm GSn8qo6vd//FdDlcovildxD1XyVAabNucQ5ekOeSRaUeKcrfvLbDlZwhovD99DTfFt8A +Vzg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=Q/zOM3AF/VD3/Sy+udrB7vGEnWpq0HjjOaZOuOlQTzU=; b=K8QZW+ssiiNtuBHB8Xxn7E+duicJV8GgFjj2f2FBgR9VUCQfG72aXK6NWKYYx7Jk7P Cjq0WxG5CtfVvk0eKP9LGQk3CzWDReqkCSU0s1l6DPDv2oiWsh03uld7t9M/zs7aig0n tTI9bCrxu4y6LvJ6a6VW/oP9X+y1ApnQUbgoO5C3EGG8gLivA1b9dmOejieE93827ai2 rBrq5yr2QOd6rxKpUy8yNp7V0xMtLgHBzklghL1M3nLOxYzxVICatwU6VXIoL5Mhj0Hp CkCsKyM7iNXrBjs4VnxzO9Bkdpe8CCPANVMOtfyGBgDXzEmSo2m+k6eovQseYmQfQXho TqYg== X-Gm-Message-State: APjAAAVbbB/d8ezdnHKqECl6F3v4Jms9PdeKEZiPWCbu8TfEUln27ky+ 6ycqeeerJKivvB4P38t750NRlhfT4ESGKhzvc8k4TmR9Ne8= X-Google-Smtp-Source: APXvYqyjCSIYDkfbXsTXqVmhKJPA1lEIHr8OZ2L84bXfOERS/wwxDhLvTQ7BCJYXGbswp9fNXjtFNenH3E+R9WryYus= X-Received: by 2002:a05:620a:1505:: with SMTP id i5mr15768494qkk.64.1573568009561; Tue, 12 Nov 2019 06:13:29 -0800 (PST) MIME-Version: 1.0 From: Nedim Kulovac Date: Tue, 12 Nov 2019 15:13:18 +0100 Message-ID: Subject: Tomcat Loader putting my modules to module-path as unnamed module To: users@tomcat.apache.org Content-Type: multipart/alternative; boundary="0000000000003d69de059726dadc" --0000000000003d69de059726dadc Content-Type: text/plain; charset="UTF-8" Hi there. I had an issue with starting a modular Java 11 app. Basically, I was wondering why my module-info. java does not require to use 'open' directive when using Spring Framework. I posted the question here https://stackoverflow.com/questions/58737469/do-i-have-to-add-open-statement-in-module-info-java-to-open-module-for-reflectio?noredirect=1#comment103882923_58737469 and user Holger came with diagnosing that Tomcat loading my code as well as Spring through a custom class loader and that is why my modules and Spring jars are not listed when I use --show-module-resolution, neither they appear in the classpath. To inspect is custom class loading done modular or old style, he recommended putting System.out.println(SomeClass.class.getModule()); somewhere in code in the module. I did it and as a result, I got printed out 'unnamed module @595b34e5'. So the big question is: why is this happening and how can I resolve this? I want Tomcat to put my modules to module path normally, not as an unnamed module. --0000000000003d69de059726dadc--