Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3373E186CC for ; Thu, 12 Nov 2015 11:11:10 +0000 (UTC) Received: (qmail 56547 invoked by uid 500); 12 Nov 2015 11:11:07 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 56482 invoked by uid 500); 12 Nov 2015 11:11:07 -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 56471 invoked by uid 99); 12 Nov 2015 11:11:07 -0000 Received: from Unknown (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 12 Nov 2015 11:11:07 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id DCF71C6021 for ; Thu, 12 Nov 2015 11:11:06 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.9 X-Spam-Level: ** X-Spam-Status: No, score=2.9 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=3] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id XURIctKQapxn for ; Thu, 12 Nov 2015 11:10:52 +0000 (UTC) Received: from mail-wm0-f46.google.com (mail-wm0-f46.google.com [74.125.82.46]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with ESMTPS id 9EF4B43DAB for ; Thu, 12 Nov 2015 11:10:51 +0000 (UTC) Received: by wmww144 with SMTP id w144so83283862wmw.0 for ; Thu, 12 Nov 2015 03:10:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=HZLlh1cSdkbHdlesJPUXLBwoG55kustJg/+Qd0DxB3A=; b=C/kzG36J2FsGEYZL+vIaiM1JzxcVcOFIQl0oqx25v6vCRCe/pM9Xfhggt5PTA4Bu9w 1sP1cyyg9TeHAOXvv8DOzCh3tuJ1tVffTjhMeHhItKChaGoCXf5ZZAfh0joLPp510uFo 5sRFjRW2S645ZAzX1HwmveDHT9cVRPJR4/iTVrmcQyyXA0nTklXjhiGHpscOuTt8MEC2 BajUSlrN8/0tyHIpI4usBIVxI2yQ8KHERdXuJZ3q9M4onFqILBPBRIcNAVZjZ1pD2plZ rnclUft4CMMfVnKOfOkw0jGky7C/YsRPhung+dvckrv3GfoIM25Ulh1DJbChiewPkd55 Uapw== MIME-Version: 1.0 X-Received: by 10.194.84.4 with SMTP id u4mr15609391wjy.149.1447326650899; Thu, 12 Nov 2015 03:10:50 -0800 (PST) Received: by 10.194.67.4 with HTTP; Thu, 12 Nov 2015 03:10:50 -0800 (PST) Date: Thu, 12 Nov 2015 13:10:50 +0200 Message-ID: Subject: env-entry with mapped-name From: Andrei Ivanov To: users@tomcat.apache.org Content-Type: multipart/alternative; boundary=047d7bb04d36e6a403052455fe0a --047d7bb04d36e6a403052455fe0a Content-Type: text/plain; charset=UTF-8 Hi, After reading https://bitbucket.org/sgarlick/demo/wiki/JNDI, I tried to apply that to my app deployed on Tomcat: Tomcat context.xml has this entry: The application web.xml has this entry: spring.profiles.active java.lang.String java:comp/env/env/enss/profile >From what I understand, when Spring looks up java:comp/env/spring.profiles.active Tomcat should find it using the value provided in the mapped-name. It doesn't work and by looking at the Tomcat 8.0.28 sources, the mapped-name is just added in the properties of ContextEnvironment, but it's never used. Did I misunderstand what the mapped-name should do? Or is it a bug in Tomcat that it doesn't use mapped-name for anything? Thank you --047d7bb04d36e6a403052455fe0a--