glassfish

Glassfish taking 20s to do hot deployment, is that right?

痴心易碎 提交于 2019-12-21 17:24:47
问题 I'm working in a JSF project with Eclipse and Glassfish 3.1.2 . Every time I did a minor change and save it, Glassfish do the hot deployment , but is taking too much time to do that, about 20s , at least. Can I do something do deacrease this time ? Is horrible develop something where you have to wait all time time everytime I change something. UPDATE This is how my project settings. Just open the folder below, this surprise me, is this so many .jar files, is this correct ? And this one: My

X cannot be added because it is already mapped to the entities. X entity class and the entity is not in current project source

大憨熊 提交于 2019-12-21 16:49:47
问题 I'm creating a new NetBeans EE Enterprise Application, and when I try to create Entity classes from database (Customer from the sample database), I can't select it because of this error : Any idea? I'm using NetBeans 7.3 with Glassfish 3.1.2. 回答1: I found the answer after spending the last few hours searching in Google. Delete the cache folder in the following C:\Users\yourusername\AppData\Local\NetBeans\Cache It solved the problem for me. 回答2: In case of NetBeans for Linux the answer of

How to provide access to an external resource (file) for a GlassFish web application?

落爺英雄遲暮 提交于 2019-12-21 16:48:36
问题 I am a bit of a GlassFish beginner, so please forgive my ingnorance on the subject. Basically we are serving a game website, and to make the client downloadable by our web app we copy it into a directory within domain1. The problem with this is that when redeploying the web app the client downloadable is lost and we have to copy it across again. I'd like to be able to store the client downloadable in some external location and have GlassFish provide access to it. I could just hardcode the

Why is JAXB namespace of my xml set to default ns1?

萝らか妹 提交于 2019-12-21 16:02:31
问题 I've build a war file from my web application using NetBeans 7.2 (in Windows 7 environment!), which runs correctly during test phase with GlassFish 3.1.2 server within NetBeans context. The defined namespace within the package-info.java file is correctly added to my xml file. However when I deploy the war file in a seperatetely running GlassFish server on a Linux machine the namespace is set to the default ns1 and NOT to the one defined by the package-info.java file? What am I doing wrong?

“Unable to convert ejbRef for ejb” on CDI (Weld) injection of @Stateless EJB into @SessionScoped JSF2 bean in Glassfish

99封情书 提交于 2019-12-21 12:33:10
问题 [ UPDATE : After discussion on the Glassfish forums/ML at http://forums.java.net/jive/thread.jspa?messageID=480532 a bug was filed against Glassfish https://glassfish.dev.java.net/issues/show_bug.cgi?id=13040 for this issue.] I'm trying to inject a local no-interface view of a @Stateless EJB into a JSF2 @Named @javax.enterprise.context.SessionScoped backing bean. The EJB is one of several that extend an abstract generic base class. Injection of "@Inject TheEJBClass varName" fails with "Unable

Threading in an Application Server

僤鯓⒐⒋嵵緔 提交于 2019-12-21 07:35:49
问题 I have a Java program/thread that I want to deploy into an Application Server (GlassFish). The thread should run as a "service" that starts when the Application Server starts and stops when the Application Server closes. How would I go about doing this? It's not really a Session Bean or MDB. It's just a thread. 回答1: Check out the LifecycleListener interface: http://glassfish.java.net/nonav/docs/v3/api/index.html?com/sun/appserv/server/LifecycleListener.html http://docs.oracle.com/cd/E18930_01

Storing and editing configuration for Java EE applications

流过昼夜 提交于 2019-12-21 07:29:46
问题 UPDATE : See my blog post on this topic about a year after this was written: http://blog.ringerc.id.au/2012/07/java-ee-7-needs-improvements-in-app.html ... for references to the Java EE 7 planning discussion on this topic. I've mostly finished writing a small Java EE 6 application, and am in the process of replacing the hard-coded preferences with a proper dynamic configuration interface. I'm not sure how - or, more specifically, where - to store settings. There must be some obvious,

Storing and editing configuration for Java EE applications

妖精的绣舞 提交于 2019-12-21 07:29:05
问题 UPDATE : See my blog post on this topic about a year after this was written: http://blog.ringerc.id.au/2012/07/java-ee-7-needs-improvements-in-app.html ... for references to the Java EE 7 planning discussion on this topic. I've mostly finished writing a small Java EE 6 application, and am in the process of replacing the hard-coded preferences with a proper dynamic configuration interface. I'm not sure how - or, more specifically, where - to store settings. There must be some obvious,

Cargo plugin throws CargoException when deploying on Glassfish - Deployment has failed: null

本秂侑毒 提交于 2019-12-21 07:13:42
问题 I'm trying to deploy web application using Cargo Maven plugin on remote Glassfish server (Edition 3.1.1 (build 12)). Glassfish server as well as Java code located on different Linux servers (Ubuntu). I've configured all necessary properties in pom file and tested deployment on Windows machine. It works. But it fails on Linux Ubuntu with interesting exception: 27-Jun-2012 14:36:05 [ERROR] Failed to execute goal org.codehaus.cargo:cargo-maven2-plugin:1.2.1:deploy (default-cli) on project my-web

Unable to find class 'com.sun.facelets.FaceletViewHandler'

99封情书 提交于 2019-12-21 06:20:31
问题 I have Richfaces application which I deploy to Glassfish v3. For many weeks (almost) everything works fine, but suddenly today a got following error. I have jsf-facelets-1.1.14.jar dependency in my pom.xml. I have no idea how to fix that. Help!! Source Document: jndi:/server/swmind.rcp.web/WEB-INF/faces-config.xml Cause: Unable to find class 'com.sun.facelets.FaceletViewHandler' at com.sun.faces.config.processor.AbstractConfigProcessor.createInstance(AbstractConfigProcessor.java:275) at com