glassfish

How to pick CXF over Metro on Glassfish

佐手、 提交于 2019-12-21 04:42:35
问题 I'm having the following problem (reported there by someone else) when running my enterprise application under Glassfish. Under Jetty it works fine. javax/xml/ws/spi/Provider mentions creating a META-INF/services/javax.xml.ws.spi.Provider resource, but this is already supplied with CXF and creating an additional resource file does not solve this problem under Glassfish. Does anyone know how to ensure that CXF is picked up under GlassFish? (I'm using a Maven Multi-modules project with CXF

TimeoutException on remote Glassfish v4.1 deployment

ぃ、小莉子 提交于 2019-12-21 02:55:24
问题 I have VPS on OVH, lets say it's vpsXXXX.ovh.net, with Debian 7. I've installed Java 8, Glassfish 4.1 and enabled secure admin: asadmin > change-admin-password --user admin > start-domain > enable-secure-admin # user: admin > restart-domain I've checked that vpsXXXX.ovh.net:8080 and vpsXXXX.ovh.net:4848 works. When I've uploaded my war by scp, logged on VPS by SSH and deployed by asadmin deploy JEE.war everything worked. Then I've undeployed it and tried to deploy it from remotely by command:

Creating my first JDBC Realm(Glassfish V3)

安稳与你 提交于 2019-12-21 02:44:19
问题 I want to create a JDBC Realm for my web app. Since my users are very different from each other i need to have just one table, with the usernames and passwords for the realm, i decided to create a new table in my database called ROLE(oneToOne relationship with the other users table). This is how my users domain model looks like: I am following this tutorial http://blog.gamatam.com/2009/11/jdbc-realm-setup-with-glassfish-v3.html but i am stuck, i dont know how to continue. I will post the

Java program to deliberately fill up PermGen?

自闭症网瘾萝莉.ら 提交于 2019-12-21 02:20:49
问题 Glassfish sometimes fails to stop when the PermGen is full, in this case asadmin stop-domain domain1 doesn't work. In Glassfish 2.1.1 it would just sit there forever; in 3.x it times out after AS_ADMIN_READTIMEOUT . So I am now working on my Glassfish stop script that will kill/kill -9 it after a certain timeout to guarantee it gets stopped. To fully test this I need to reproduce this PermGen full scenario. How can I deliberately fill up PermGen? I'm currently using Java 1.7.0_45 if that

Using a CommonJ implementation with GlassFish and Spring 3

左心房为你撑大大i 提交于 2019-12-21 02:03:27
问题 In my quest to unify deployment among Websphere 7 and GlassFish 3 environments, I decided to try implementing a CommonJ WorkManager and TimerManager in GlassFish. But it isn't quite working as expected. I have done the following: Use the myFOO CommonJ implementation found at: http://commonj.myfoo.de/ and include the libraries into my domain/lib folder (including the Spring libs) Added the following to the <resources> section of the glassfish domain.xml: <custom-resource res-type="commonj.work

How to run a Scheduled Method in a Cluster for one Node and for All?

我们两清 提交于 2019-12-20 20:38:45
问题 I have a Glassfish 3.1.2 that runs in a cluster and a EJB 3.1 application. And I need two kind of Scheduled Methods in my application: one kind that runs only once (on a single node) once a day and other kind that runs on all nodes (every 1-2 Minutes) -- They do NOT need to run a syncron way! The requirement is just that this kind run on every node. I have no clue how to start with this cluster - problem, is this possible with @Schedule (and how) or do I need something else? 回答1: I faced the

Customizing an Elastic Beanstalk AMI

有些话、适合烂在心里 提交于 2019-12-20 20:37:53
问题 I need to use on Elastic Beanstalk a Java application written for Glassfish server. Beacuse of Amazon doesn't let me choose an AMI with Glassfish, I choosed one with Tomcat and i modified my application to work properly on Tomcat. Now, I've seen I also needed to use a Sun JDK, while by default Elastic Beanstalk AMI comes with openjdk. I googled a lot, finding some (not so many resources) interesting posts like this answer on StackOverflow What I can't understand is this part of the answer:

How to create custom 404 messages in JSF 2.0?

人盡茶涼 提交于 2019-12-20 17:32:53
问题 Currently in my app when a user types some illegal destination in the URL bar, sees this: I would like to make it more beautiful and customize it with my own markup and a bit of css. -Do i need to program that on my app or i have to configure that in the application server? -Where should i start from if i want to do that? 回答1: You can declare custom <error-page> s in web.xml depending on <error-code> (the HTTP status code) or <exception-type> (the full qualified exception class name which was

How to create custom 404 messages in JSF 2.0?

自古美人都是妖i 提交于 2019-12-20 17:31:10
问题 Currently in my app when a user types some illegal destination in the URL bar, sees this: I would like to make it more beautiful and customize it with my own markup and a bit of css. -Do i need to program that on my app or i have to configure that in the application server? -Where should i start from if i want to do that? 回答1: You can declare custom <error-page> s in web.xml depending on <error-code> (the HTTP status code) or <exception-type> (the full qualified exception class name which was

How do I make JNDI names compatible with both GlassFish and WildFly

旧时模样 提交于 2019-12-20 15:23:17
问题 I am developing a Java EE 7 application and have a requirement for the application to be deployed onto application servers running either GlassFish 4.0 or WildFly 8.1.0. The issue I've got is GlassFish and WildFly use slightly different formats for JNDI names but I can't see how to make my application compatible with both. In GlassFish my persistence.xml file references the data source jdbc/myDataSouce, but in WildFly the data source needs to be java:/jdbc/myDataSource. The same is also true