users@glassfish.java.net

ACCClassLoader does not find Resourcebundle in Client-jar-File

From: <glassfish_at_javadesktop.org>
Date: Fri, 01 Oct 2010 04:14:32 PDT

The ACCClassLoader loads tsClient.jar, but does not find the Resources in it.

Sorry for my terrible English, I hope you can understand me.

So, what I'am doing.

I'am working with Glassfish-Tools-Bundle 1.2 (Glassfish, Eclipse and MySQL).
I build a Client with the name tsClient.

For internationalization I have build Resourcebundles, which resides in "tsClient" in the package lan.hbraun.ts.client.i18n.

With "package-appclient" I have build the jar-File appclient.jar and this file extracted in the directory C:\tsClient
.
After that, called "get-client-stubs"-command.
(C:\GlassFish-Tools-Bundle-1.2\glassfishv3\glassfish\bin\asadmin.bat --host=localhost --port=4860 --user=admin --passwordfile C:\Users\Braun.Harald\Projekte\ts\tsTools\glassfish\password.txt --echo=true get-client-stubs --appname ts C:\tsClient)

Now I call "appclient.bat".
(C:\tsClient\appclient\glassfish\bin\appclient.bat -client C:\tsClient\tsClient.jar -mainclass Main); Environment: VMARGS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=9009

The logging shows the following:
C:\tsClient>rem @echo off

C:\tsClient>rem/*

C:\tsClient>rem * To change this template, choose Tools | Templates

C:\tsClient>rem * and open the template in the editor.

C:\tsClient>rem *

C:\tsClient>rem * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.

C:\tsClient>rem *

C:\tsClient>rem * Copyright 1997-2009 Sun Microsystems, Inc. All rights reserved.

C:\tsClient>rem *

C:\tsClient>rem * The contents of this file are subject to the terms of either the GNU

C:\tsClient>rem * General Public License Version 2 only ("GPL") or the Common Development

C:\tsClient>rem * and Distribution License("CDDL") (collectively, the "License"). You

C:\tsClient>rem * may not use this file except in compliance with the License. You can obtain

C:\tsClient>rem * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html

C:\tsClient>rem * or glassfish/bootstrap/legal/LICENSE.txt. See the License for the specific

C:\tsClient>rem * language governing permissions and limitations under the License.

C:\tsClient>rem *

C:\tsClient>rem * When distributing the software, include this License Header Notice in each

C:\tsClient>rem * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.

C:\tsClient>rem * Sun designates this particular file as subject to the "Classpath" exception

C:\tsClient>rem * as provided by Sun in the GPL Version 2 section of the License file that

C:\tsClient>rem * accompanied this code. If applicable, add the following below the License

C:\tsClient>rem * Header, with the fields enclosed by brackets [] replaced by your own

C:\tsClient>rem * identifying information: "Portions Copyrighted [year]

C:\tsClient>rem * [name of copyright owner]"

C:\tsClient>rem *

C:\tsClient>rem * Contributor(s):

C:\tsClient>rem *

C:\tsClient>rem * If you wish your version of this file to be governed by only the CDDL or

C:\tsClient>rem * only the GPL Version 2, indicate your decision by adding "[Contributor]

C:\tsClient>rem * elects to include this software in this distribution under the [CDDL or GPL

C:\tsClient>rem * Version 2] license." If you don't indicate a single choice of license, a

C:\tsClient>rem * recipient has the option to distribute your version of this file under

C:\tsClient>rem * either the CDDL, the GPL Version 2 or to extend the choice of license to

C:\tsClient>rem * its licensees as provided above. However, if you add GPL Version 2 code

C:\tsClient>rem * and therefore, elected the GPL Version 2 license, then the option applies

C:\tsClient>rem * only if the new code is made subject to such option by the copyright

C:\tsClient>rem * holder.

C:\tsClient>rem */

C:\tsClient>setlocal

C:\tsClient>set AS_INSTALL=C:\tsClient\appclient\glassfish\bin\..

C:\tsClient>set inputArgs=-client C:\tsClient\tsClient.jar -mainclass Main

C:\tsClient>for /F "tokens=*" %a in ('cscript //nologo "C:\tsClient\appclient\glassfish\bin\..\bin\appclient.js"') do %a

C:\tsClient>set javaCmd=java -Dcom.sun.aas.installRoot="C:\tsClient\appclient\glassfish\bin\.." -Djava.security.policy="C:\tsClient\appclient\glassfish\bin\..\lib\appclient\client.policy" -Djava.system.class.loader=org.glassfish.appclient.client.acc.agent.ACCAgentClassLoader -Djava.security.auth.login.config="C:\tsClient\appclient\glassfish\bin\..\lib\appclient\appclientlogin.conf" -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=9009 -Djava.endorsed.dirs="C:\tsClient\appclient\glassfish\bin\..\lib\endorsed;C:\tsClient\appclient\glassfish\bin\..\modules\endorsed";null -javaagent:"C:\tsClient\appclient\glassfish\bin\..\modules\gf-client.jar"=mode=acscript,arg=-configxml,arg="C:\tsClient\appclient\glassfish\bin\..\domains\domain1\config\sun-acc.xml",arg=-mainclass,arg=Main,client=jar=C:\tsClient\tsClient.jar -jar C:\tsClient\tsClient.jar

C:\tsClient>java -Dcom.sun.aas.installRoot="C:\tsClient\appclient\glassfish\bin\.." -Djava.security.policy="C:\tsClient\appclient\glassfish\bin\..\lib\appclient\client.policy" -Djava.system.class.loader=org.glassfish.appclient.client.acc.agent.ACCAgentClassLoader -Djava.security.auth.login.config="C:\tsClient\appclient\glassfish\bin\..\lib\appclient\appclientlogin.conf" -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=9009 -Djava.endorsed.dirs="C:\tsClient\appclient\glassfish\bin\..\lib\endorsed;C:\tsClient\appclient\glassfish\bin\..\modules\endorsed";null -javaagent:"C:\tsClient\appclient\glassfish\bin\..\modules\gf-client.jar"=mode=acscript,arg=-configxml,arg="C:\tsClient\appclient\glassfish\bin\..\domains\domain1\config\sun-acc.xml",arg=-mainclass,arg=Main,client=jar=C:\tsClient\tsClient.jar -jar C:\tsClient\tsClient.jar
ACC012: In modifying known loggers, the LogManager reported the logger name com.sun.xml.bind.v2.ContextFactory which does not have a corresponding logger; continuing
01.10.2010 12:14:52 com.sun.enterprise.transaction.JavaEETransactionManagerSimplified initDelegates
INFO: Using com.sun.enterprise.transaction.jts.JavaEETransactionManagerJTSDelegate as the delegate
addLogger(String loggerName_p, String ...) gestartet...
01.10.2010 12:14:53 lan.hbraun.util.LocLogger info
INFO: System-Locale "de_DE" gemerkt.
01.10.2010 12:14:53 lan.hbraun.util.LocLogger info
INFO: Die Anwendung wurde auf das neue Lokal "de" eingestellt!
Die Anwendung wurde auf das neue Lokal "de" eingestellt!
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
INFO: loadBundle(login) gestartet...
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
INFO: Lade lan.hbraun.ts.client.i18n.login
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
WARNUNG: Resource lan.hbraun.ts.client.i18n.login wurde über den Standard-Klassenlader nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
WARNUNG: Das Resourcebundle 'lan.hbraun.ts.client.i18n.login' wurde nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator localize
WARNUNG: ResourceBundle (login) für die Resource login.dlg.title nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
INFO: loadBundle(login) gestartet...
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
INFO: Lade lan.hbraun.ts.client.i18n.login
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
WARNUNG: Resource lan.hbraun.ts.client.i18n.login wurde über den Standard-Klassenlader nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
WARNUNG: Das Resourcebundle 'lan.hbraun.ts.client.i18n.login' wurde nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator localize
WARNUNG: ResourceBundle (login) für die Resource login.dlg.btn.anmelden nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
INFO: loadBundle(login) gestartet...
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
INFO: Lade lan.hbraun.ts.client.i18n.login
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
WARNUNG: Resource lan.hbraun.ts.client.i18n.login wurde über den Standard-Klassenlader nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator loadBundle
WARNUNG: Das Resourcebundle 'lan.hbraun.ts.client.i18n.login' wurde nicht gefunden.
01.10.2010 12:14:53 lan.hbraun.ts.client.i18n.Translator localize
WARNUNG: ResourceBundle (login) für die Resource login.dlg.btn.abbrechen nicht gefunden.
Listening for transport dt_socket at address: 9009

In "loadBundle" the method "ResourceBundle.getBundle(resource, locale)" ends with an "MissingResourceException".

Where is my mistake? What's wrong?
[Message sent by forum member 'hbraun1']

http://forums.java.net/jive/thread.jspa?messageID=484104