glassfish

EJB dependency injection of remote service fails on Glassfish

I am unable to get dependency injection to work for my remote service and I cannot figure out why. I want an instance of RemoteService so I wrote. @EJB(name="RemoteService") private RemoteService service; And the Bean itself is defined with mappedName="RemoteService: @Stateless(mappedName = "RemoteService") public class RemoteService...

GlassFish deployment Invalid content was found starting with element 'url-pattern'

I am trying to deploy my war to GlassFish (works fine in JBoss). GlassFish fails to deploy with this message. [#|2010-09-23T15:49:00.609-0400|SEVERE|glassfish3.0.1|javax.enterprise.system.tools.deployment.org.glassfish.deployment.common|_ThreadID=24;_ThreadName=Thread-1;|DPL8015: Invalid Deployment Descriptors in Deployment descriptor ...

GlassFish: Can HttpSessions be pasivated when runinng low of memory?

Hi, Whenever we run a load test we run out of memory. We have realized that GlassFish doesn't serialize the http sessions to disk even if memory usage is 100%. Is there a way for us to set a max idle timeout and min idle timeout for sessions like we do in tomcat. So if the container is running out of memory, it can start by serializing...

What is the easiest application server to implement with Java-based clients?

Intro We have a project to design and implement this semester. For our project, we chose to create an inventory system that uses Android phones for clients. More information on that portion of the project. The Problem The next problem that we have run into is that we are to design some kind of intermediary server that authenticates u...

Glassfish 3: Why do I have to deploy all my libraries into domains/lib/ to get it to work?

hey Guys: I just got handed over a project from another group. EJB session bean / web service. It deployed without any issue on JavaCAPS 6. However, on Oralce Glassfish V3 (3.0.1 Build 22), when I deployed the jar file (Applicaton / EJB Module), it kept complaining certain external libraries (which is included in the jar), can not be...

Glassfish v3.0 Open Source Edition Hosting

Where can i find affordable glassfish hosting for my webapp? I saw one vendor who charges $33/month for a VPS. If you guys don't have any better suggestions, I'll go with this vendor. This is for a personal project btw. Hosting at home is not an option. ...

Suddenly a NoClassDefFoundError when running Glassfish from NetBeans

I have been working on a demo project all day and everything went just fine. Suddenly (and, as it seems, unrelated to any of my actions) my application fails with a NoClassDefFoundError somewhere in the CDI internals. Strangely it worked before but I just cannot get it to work again. I am using a rather fresh NB 6.9.1 install without a...

What is a good way to handle slf4j logging in a web app deployed in Glassfish 3.0.1?

I have a quite ordinary web application which logs with slf4j, which is fine, and I have used several slf4j backends without any problems. Under Tomcat I just told logback to point at a location in the filesystem and log there, but now I want to deploy several independent instances of this application each in its own domain in a single ...

@Asynchronous private method in EJB

I have an asynchronous method in my EJB singleton that's called from another method in the same class. I already know that I can't call the asynchronous method directly, I have to obtain an EJB proxy. The problem is, I don't want the asynchronous method to be visible outside the class; but when I make it private, it's not executed asynch...

IntelliJ, Glassfish, JRebel - Slow deploys and jsps/tags require redeploy

I am developing a J2EE application using IntelliJ and deploying to Glassfish. I am also using JRebel which hasn't seemed to help reduce the need to redeploy. Changes to JPA entities still requires redeploying as do changes to JSPs or Tags. What configuration options in either IntelliJ, Glassfish, or JRebel should I be looking into so t...

What is difference between Tomcat and JBoss and Glassfish?

I am starting to look into Enterprise Java and the book I am following mentions that it will use JBoss. Netbeans ships with Glassfish. I have used Tomcat in the past. What are the differences between these three programs? ...

Why does Glassfish appear to require much more memory in Linux than in Windows?

I've been tinkering with GlassFish 2.1.1 lately, on both an Unbuntu Linux box as well as a Windows XP one. Looking at the "java" processes representing asadmin, JavaDB server, and the GlassFish app server domain itself on Windows (using the Task Manager), they add up to just over 100 MB of memory. However, looking at the same proce...

getting message "The module has not been deployed." when doing deploy app to Glassfish from NetBeans

NetBeans 6.9 GlassFish 3.1 I created a web application project on NetBean and try to deploy this on build-in glassfish. but getting following message. anyone have solution to this? redeploy?name=Z_LAB_JFREECHART&properties=keepSessions=true failed on GlassFish Server 3 1 C:\My Documents\NetBeansProjects\Z_LAB_JFREECHART\nbproject\build...

How to stop handled Exceptions from being logged?

I have just implemented exception handling for a unique-constraint of a JPA entity. It is working as I want it to, but when triggered dumps the handled exceptions to the container logfile. A JPA entity is managed by a SLSB (Service Façade). The Service Façade is called from another SLSB, which provides remoting capabilities based on JA...

How to deploy Web Services in GlassFish?

I am using NetBeans6.9.1. When I test my Web Services using "Test RESTful Web Services" inside NetBeans, the web services were properly deployed and I was able to do GET from my web services. I thought when I deploy my EAR (which contains those web services and other ejb and web stuff), the web services would be automatically deployed, b...

How to change the Admin port on Glassfish inside a script

Got a weird Glassfish issue here. Here's how to reproduce it: (1) Install Glassfish v3 (2) Start your default domain: $GLASSFISH_HOME/bin/asadmin start-domain domain1 (3) Change the admin port (you'll need to enter admin uid & password, in our script we use the -u & -W parameters): $GLASSFISH_HOME/bin/asadmin set configs.config.se...

Glassfish 2.1.1 - Session Beans repeatedly call init() and destroy()

I have a Web Application that I'm trying to move from Sun Application Server V9 to Glassfish V2.1.1 I'm using Netbeans 6.0.1 to develop the App, and it's using JSP, SessionBeans and JDBC to connect to MySQL. I've made good progress and can compile and deploy the App. to Glassfish OK. The App starts and I takes me to my login page, wher...

Add Security Role References programmatically (without using declarative EJB Deployment Descriptor)

I'm developing a Java EE 6 application using Glassfish 3.1, B06. To secure my app, i'm using a JDBCRealm and programmatic security. This works fine to check username and password. But when it comes to declaring security roles, i have a problem: To use Security Roles in Java EE 6, i have to declare those roles both in the EJB deployment ...

Problem Deploying Wicket/JPA (EclipseLink) App to Glassfish

Hi, I have a small Wicket app that I can deploy to Glassfish v3 without any problems. I also have a JAX-RS webservice that includes a jar file that contains JPA entity beans and stateless service beans that deploys successfully. However, when I try to deploy a different Wicket application that makes use of the same entity/service jar,...

Upgrade Glassfish v2 to JPA 2.0?

Hi, I'm trying to use Hibernate 3.5.5 with Spring HibernateJpaVendorAdapter on Glassfish V2 but I'm getting the following exception when the Spring context is initialised: java.lang.NoSuchMethodError: javax.persistence.spi.PersistenceUnitInfo.getSharedCacheMode()Ljavax/persistence/SharedCacheMode; at org.hibernate.ejb.util.LogHelper....