Re: openJPA provided by Geronimo2.1.1 to run on JDk6

2008-06-18 Thread David Jencks
How are you starting geronimo?  If you use gshell (e.g. bin/gsh  
geronimo/start-server) the runtime enhancer should be working fine.


That said I would recommend build-time enhancement anyway.  Is there  
some reason you stopped build-time enhancement?


thanks
david jencks

On Jun 17, 2008, at 5:47 PM, Sai wrote:



currently our applications(webservices) running fine on JDK5,  
Geronimo 1.1.1

and OpenJPA-0.9.6.
Enhancing is done using maven plugin at build time.

We are planned to move to JDK6,Geronimo 2.1.1 (as geronimo has  
openjpa1.0.2

-planned to use the same).

I tried build webservice deployed on Geronimo.
When I put the request it says that ValueObj is not enhanced.posted  
the

stack trace as below.
Tried different ways to enhance but same issue.
Could any one advice how to enhance ,if we use openJPA at runtime  
given by

container.
Thanks  in advance.
Sai


INFO: WSSERVLET14: JAX-WS servlet initializing
17280.640: [GC [PSYoungGen: 51680K-940K(54976K)] 103983K- 
53680K(521024K),

0.04
75474 secs] [Times: user=0.02 sys=0.00, real=0.05 secs]
17-Jun-2008 8:05:44 PM abc.sun.xml.ws.server.sei.EndpointMethodHandler
invoke
SEVERE: The type class abc.efg.hello.prog.vo.ValueObj has not been  
enh
anced.; nested exception is openjpa-1.0.2-r420667:627158 fatal user  
error

org.
apache.openjpa.perhellotence.ArgumentException: The type class
abc.efg.hello.bus
iness.vo.ValueObj has not been enhanced.
org.springframework.dao.InvalidDataAccessApiUsageException: The type  
class

abc.
efg.hello.prog.vo.ValueObj has not been enhanced.; nested exception  
is

openjpa-1.0.2-r420667:627158 fatal user error
org.apache.openjpa.perhellotence.A
rgumentException: The type class abc.efg.hello.prog.vo.ValueObj  
has no

t been enhanced.
Caused by: openjpa-1.0.2-r420667:627158 fatal user error
org.apache.openjpa.pe
rhellotence.ArgumentException: The type class
abc.efg.hello.prog.vo.ValueObj has not been enhanced.
   at
org.apache.openjpa.meta.ClassMetaData.resolveMeta(ClassMetaData.java:
1639)
   at
org.apache.openjpa.meta.ClassMetaData.resolve(ClassMetaData.java:1613
)
   at
org.apache.openjpa.meta.MetaDataRepository.processBuffer(MetaDataRepo
sitory.java:675)
   at
org.apache.openjpa.meta.MetaDataRepository.resolveMeta(MetaDataReposi
tory.java:575)
   at
org.apache.openjpa.meta.MetaDataRepository.resolve(MetaDataRepository
.java:500)
   at
org.apache.openjpa.meta.MetaDataRepository.getMetaData(MetaDataReposi
tory.java:302)
   at
org.apache.openjpa.meta.MetaDataRepository.getMetaData(MetaDataReposi
--
View this message in context: 
http://www.nabble.com/openJPA-provided-by-Geronimo2.1.1-to-run-on-JDk6-tp17957616s134p17957616.html
Sent from the Apache Geronimo - Users mailing list archive at  
Nabble.com.






Re: request.isUserInRole(some-role) always return false after @EJB injection

2008-06-18 Thread Stig Even Larsen

David Jencks wrote:

On Jun 17, 2008, at 12:35 PM, Stig Even Larsen wrote:


Quoting Stig Even Larsen [EMAIL PROTECTED]:


Stig Even Larsen wrote:

David Jencks wrote:


On Jun 17, 2008, at 12:07 AM, Stig Even Larsen wrote:



David Jencks wrote:

On Jun 16, 2008, at 1:11 PM, Stig Even Larsen wrote:

Quoting David Jencks [EMAIL PROTECTED]:



On Jun 16, 2008, at 12:30 PM, Stig Even Larsen wrote:



Quoting David Jencks [EMAIL PROTECTED]:



On Jun 16, 2008, at 10:12 AM, Kevan Miller wrote:



On Jun 16, 2008, at 7:57 AM, Stig Even Larsen wrote:


I forgot to tell that I'm using Geronimo 2.0.2 on Debian Etch.

Regards,
Stig Even Larsen




Stig Even Larsen wrote:

Hi,
After logging in via the j_security_check form I use the   
simplest  of jsp  page for testing purpose. I've defined   
several roles and  am able to check this via   
request.isUserInRole(some-role).  Everything is working  
as expected.
When I throw in a EJB via @EJB annotation or via JNDI  
lookup  request.isUserInRole(some-role) is now always  
returning false.

Is this a bug or I'm I missing something here?


Hi Stig,
I think you've run into a bug, which was recently fixed  
(revision   number 663484 for branches/2.0).


The nightly build of 2.0.3-SNAPSHOT should contain the 
fix.   You'll  find some binaries here --
http://people.apache.org/builds/geronimo/server/binaries/2.0/20080616/ 



Just for tracking purposes this is GERONIMO-4099.  This was 
the bug
that came to my mind first also, but I'm not convinced it's 
the same
problem.  Please let us know whether the 2.0.3 snapshot fixes 
the

problem you are seeing.

thanks
david jencks




--kevan


Hi,

Thanks for your reply.
Is this also an issue with 2.1.x?


GERONIMO-4099 was an issue with 2.0.x, 2.1.x, and trunk 
(2.2-SNAPSHOT).
I fixed it in all branches at the same time.  Any progress on 
seeing

if it is the problem you are running into?


Well, I'm struggeling finding an upgrade routine. Is there any?
Anyway, since I'm at CET time (GMT+1) I probably won't be able  
to doing a test

until working hours tomorrow...
I'm not sure what you are looking for.  There is no way to  
upgrade a geronimo installation from one version of geronimo to  
another in place: you have to redeploy your applications on  
the new server.  On the other hand I recommend a maven based  
workflow to build a customized server including your apps, in  
which case you'd just change the geronimo version in the  
appropriate pom.
http://cwiki.apache.org/GMOxDOC21/constructing-a-special-purpose-server-using-maven.html  
thanks

david jencks





replying to the list will get you more responses in case I'm  
not around :-)

thanks
david jencks


Sorry about that, won't happen agein ;)





Regards,
Stig Even Larsen


Regards,
Stig Even Larsen


Hi again,

In the 2.0.3 SNAPSHOT of 20080616 the malfunction is still there.  
It seems that this issue is not the same as described in  
GERONIMO-4099.

I think is time to file a detailed bug-report?


That would be great!  If you can provide a small app showing the  
problem or at least the servlet code that would be good.  I've  
just been looking at a similar case that works where there is a  
servlet and ejb, and the isUser/CallerinRole methods work: in the  
case I have, the servlet tests before calling the ejb and not  
after calling the ejb.  Maybe you are testing in the servlet after  
calling the ejb?


thanks!
david jencks




Best regards,
Stig Even Larsen


Hi David,

I've noticed something odd. After first login (first login after  
deployment) the request.isUserInRole(xxx) returns false. If a  
reload the page (eg. calling the servlet again) it returns true. If  
I then invalidate the session and login in again it returns true  
(it behaves normally).
So it is infact working :) I'll be filing that bugreport anyway so  
you can test it. It will be submitted within the next 1/2 hour.


Best regards,
Stig Even Larsen


Hi again,

It seems that its partially working in 2.0.2 also which means that the
GERONIMO-4099 has nothing to do in this scenario. I've posted
GERONIMO-4119 as a new bug.

Best regards,
Stig Even Larsen


Hi David,

Will your fix (rev 668765) be available in tonights 2.0.3 SNAPSHOT?

I just ported the fix to branches/2.0 so the next time 2.0.3-SNAPSHOT is 
built it will be included.  I'm not certain when that will be.


thanks
david jencks

Best regards,
Stig Even Larsen


Hi again,

I think I've found an related error.
I use javaBeans for wrapping Session EJB via jndi (one-to-one, method to 
method) to avoid to much java code in jsps.


request.isUserInRole() always return false no mather how many times it 
is called. Is seems like the jndi lookup prevents the isUserinRole to 
work normally.


Should I file a new bug-report or is this the same problem describe with 
EJB injection?


An example.

I have an stateless session bean (EJB):
@Stateless
public class TimeUtilsBean implements TimeUtilsLocal {

public String getString() {
  

download firefox today

2008-06-18 Thread Mohammad Shamsi
Download Day is here!
Set a Guinness World Record
Enjoy a Better Web http://www.spreadfirefox.com/en-US/worldrecord/

-- 
sincerely yours
M. H. Shamsi


Redhat patch level cheatsheet?

2008-06-18 Thread Brandie.B.Huber
Anyone have a link to a cheatsheet that translates RedHat Enterprise's
backported patch levels for Apache products to Apache Geronimo's original
patch levels?  I'm not able to find it via Google or RHN.  

Thanks in advance! 
Brandie 



smime.p7s
Description: S/MIME cryptographic signature


Re: request.isUserInRole(some-role) always return false after @EJB injection

2008-06-18 Thread David Jencks

On Jun 18, 2008, at 4:31 AM, Stig Even Larsen wrote:

snip
Hi again,

I think I've found an related error.
I use javaBeans for wrapping Session EJB via jndi (one-to-one,  
method to method) to avoid to much java code in jsps.


request.isUserInRole() always return false no mather how many times  
it is called. Is seems like the jndi lookup prevents the  
isUserinRole to work normally.


Should I file a new bug-report or is this the same problem describe  
with EJB injection?


An example.

I have an stateless session bean (EJB):
@Stateless
public class TimeUtilsBean implements TimeUtilsLocal {

   public String getString() {
   return Hello from Stateless EJB!;
   }
}

A javaBean EJB wrapper:
public class EJBWrapper {

   private TimeUtilsLocal lookupTimeUtilsBean() {
   try {
   Context c = new InitialContext();
   return (TimeUtilsLocal) c.lookup(java:comp/env/ 
TimeUtilsBean);

   } catch (NamingException ne) {
System.out.println(NameingException: +ne.getMessage());
   }
   }


   public String getDate(){
   return(this.lookupTimeUtilsBean().getString());
   }
}


A form protected (j_security_check) jsp

[EMAIL PROTECTED] contentType=text/html pageEncoding=UTF-8  
import=no.nimra.ejb.wrapper.EJBWrapper %

!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
  http://www.w3.org/TR/html4/loose.dtd;
jsp:useBean id=nisAdmin class=no.nimra.ejb.wrapper.EJBWrapper  
scope=session /


html
   head
   meta http-equiv=Content-Type content=text/html;  
charset=UTF-8

   titleJSP Test/title
   /head
   body

   h2Role test/h2

   Time: %= nisAdmin.getDate() %

   %if(request.isUserInRole(partners)){%
   user is partner :)
   %}else{%
   user is NOT partner :(
   %}%
   /body
/html




My jsp deciphering skills are not the best but it looks to me as if  
the role check is done after the ejb lookup.  This is the subject to  
the same problem as in GERONIMO-4119 and ought to work properly in the  
latest code in svn (in all branches): there's a test case in trunk  
checking that this scenario works.  Which code are you seeing the  
problem with?


thanks
david jencks



How to convert from Tomcat to Geronimo

2008-06-18 Thread Tim Harsch
Hi all,

   I’m fairly new to J2EE in general, so please forgive my naïve
question.  I would like to take a simple hello world type JSP and Servlet
project running via WTP 2.0.2 on Europa.  Running on Apache Tomcat Server it
runs fine.  But then, after stopping Tomcat, when I try to right-click on
project and “Run as…”, “Run on Server” and choose Geronimo 2.1 then no
browser window will open and no page is showed.

   I can however manually start the Geronimo server in the
Servers pane, and navigate to localhost:8080 and see that the server is
running.

 

I noticed this fairly recent post, which seems very similar to my problem.

http://www.eclipse.org/newsportal/article.php?id=16603
http://www.eclipse.org/newsportal/article.php?id=16603group=eclipse.webtoo
ls#16603 group=eclipse.webtools#16603

 

Thanks,

Tim



Error opening the editor

2008-06-18 Thread Tim Harsch
Hi all,

   I get the following error when trying to open
geronimo-web.xml file:

There was an error opening the editor.  The elements in the
plan may not be qualified, do you want to try to auto-correct this?
Otherwise the default text editor will be opened.

   Googling that phrase gives no love.

 

   Here's the content of my file:

web-app xmlns=http://geronimo.apache.org/xml/ns/j2ee/web-1.1;

environment

moduleId

artifactIdGeronimo2/artifactId

/moduleId

/environment

context-root/Geronimo2/context-root

/web-app

 

Tim



Re: How to convert from Tomcat to Geronimo

2008-06-18 Thread Dain Sundstrom
I'd like to suggest you take a look at the Apache OpenEJB plugin for  
Tomcat (http://openejb.apache.org/tomcat.html).  Basically, you drop  
the openejb.war into Tomcat and you get a JEE compatible Tomcat.   
OpenEJB also has support for Collapsed EAR deployment (http://openejb.apache.org/collapsed-ear.html 
) which vastly simplifies the development and deployment of EJBs,  
persistence units and web-services (this will be most likely make it  
into the next EJB spec).


If you decide take a look and run into any problems, hit us up on the  
OpenEJB mailing list (http://openejb.apache.org/mailing-lists.html).


-dain

On Jun 18, 2008, at 4:20 PM, Tim Harsch wrote:


Hi all,
   I’m fairly new to J2EE in general, so please forgive  
my naïve question.  I would like to take a simple hello world type  
JSP and Servlet project running via WTP 2.0.2 on Europa.  Running on  
Apache Tomcat Server it runs fine.  But then, after stopping Tomcat,  
when I try to right-click on project and “Run as…”, “Run on Server”  
and choose Geronimo 2.1 then no browser window will open and no page  
is showed.
   I can however manually start the Geronimo server in  
the Servers pane, and navigate to localhost:8080 and see that the  
server is running.


I noticed this fairly recent post, which seems very similar to my  
problem.

http://www.eclipse.org/newsportal/article.php?id=16603group=eclipse.webtools#16603

Thanks,
Tim




Re: How to convert from Tomcat to Geronimo

2008-06-18 Thread Kevan Miller


On Jun 18, 2008, at 7:20 PM, Tim Harsch wrote:


Hi all,
   I’m fairly new to J2EE in general, so please forgive  
my naïve question.  I would like to take a simple hello world type  
JSP and Servlet project running via WTP 2.0.2 on Europa.  Running on  
Apache Tomcat Server it runs fine.  But then, after stopping Tomcat,  
when I try to right-click on project and “Run as…”, “Run on Server”  
and choose Geronimo 2.1 then no browser window will open and no page  
is showed.
   I can however manually start the Geronimo server in  
the Servers pane, and navigate to localhost:8080 and see that the  
server is running.


I noticed this fairly recent post, which seems very similar to my  
problem.

http://www.eclipse.org/newsportal/article.php?id=16603group=eclipse.webtools#16603


Interesting. I didn't know you could do that (I'm not much of an  
Eclipse power user), but makes sense. I've always added projects to  
the server and controlled the server in the servers tab.


I expect we'll hear shortly from someone who works on the Geronimo  
Adapter...


--kevan

java.lang.NoClassDefFoundError: org.apache.geronimo.system.rmi.RMIClassLoaderSpiImpl

2008-06-18 Thread pmavinakuli

Hello, All. 

We are facing a problem while starting our geronimo server , due to the
following problem. We have added the jar file name in metainf file. Still it
has not been able to start the geronimo without any problem. Any help would
be greatly appreciated. Thanks a lot in advance. 

Exception stack trace. 
Module 4/4 geronimo/j2ee-security/1.1.1/car  08:46:11,324 ERROR
[GBeanInstanceState] Error while starting; GBean is now in the FAILED state:
abstractName=geronimo/j2ee-security/1.1.1/car?ServiceModule=geronimo/j2ee-security/1.1.1/car,j2eeType=GBean,name=JMXService

java.lang.NoClassDefFoundError:
org.apache.geronimo.system.rmi.RMIClassLoaderSpiImpl

at
java.rmi.server.RMIClassLoader.initializeProvider(RMIClassLoader.java:668)

at
java.rmi.server.RMIClassLoader.access$000(RMIClassLoader.java:93)

at java.rmi.server.RMIClassLoader$1.run(RMIClassLoader.java:103)

at java.security.AccessController.doPrivileged(Native Method)

at
java.rmi.server.RMIClassLoader.clinit(RMIClassLoader.java:100)

at
sun.rmi.server.MarshalOutputStream.annotateClass(MarshalOutputStream.java:75)

at
java.io.ObjectOutputStream.writeNonProxyDesc(ObjectOutputStream.java:1174)

at
java.io.ObjectOutputStream.writeClassDesc(ObjectOutputStream.java:1127)

at
java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)

at
java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1079)

at
java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:302)

at sun.rmi.registry.RegistryImpl_Stub.bind(Unknown Source)

at
com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:116)

at
com.sun.jndi.toolkit.url.GenericURLContext.bind(GenericURLContext.java:208)

at javax.naming.InitialContext.bind(InitialContext.java:359)

at
javax.management.remote.rmi.RMIConnectorServer.bind(RMIConnectorServer.java:635)

at
javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:427)

at
org.apache.geronimo.jmxremoting.JMXConnector.doStart(JMXConnector.java:190)

at
org.apache.geronimo.gbean.runtime.GBeanInstance.createInstance(GBeanInstance.java:977)

at
org.apache.geronimo.gbean.runtime.GBeanInstanceState.attemptFullStart(GBeanInstanceState.java:267)

at
org.apache.geronimo.gbean.runtime.GBeanInstanceState.start(GBeanInstanceState.java:102)

at
org.apache.geronimo.gbean.runtime.GBeanInstanceState.startRecursive(GBeanInstanceState.java:124)

at
org.apache.geronimo.gbean.runtime.GBeanInstance.startRecursive(GBeanInstance.java:527)

at
com.businessobjects.framework.servers.common.fast.FastKernel.startRecursiveGBean(FastKernel.java:357)

at
org.apache.geronimo.kernel.config.ConfigurationUtil.startConfigurationGBeans(ConfigurationUtil.java:374)

at
org.apache.geronimo.kernel.config.KernelConfigurationManager.start(KernelConfigurationManager.java:187)

at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.startConfiguration(SimpleConfigurationManager.java:527)

at
org.apache.geronimo.kernel.config.SimpleConfigurationManager.startConfiguration(SimpleConfigurationManager.java:508)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at
org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(ReflectionMethodInvoker.java:34)

at
org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.java:122)

at
org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.java:804)

at
org.apache.geronimo.gbean.runtime.RawInvoker.invoke(RawInvoker.java:57)

at
org.apache.geronimo.kernel.basic.RawOperationInvoker.invoke(RawOperationInvoker.java:35)

at
org.apache.geronimo.kernel.basic.ProxyMethodInterceptor.intercept(ProxyMethodInterceptor.java:96)

at
org.apache.geronimo.kernel.config.EditableConfigurationManager$$EnhancerByCGLIB$$2c9ea6a1.startConfiguration(generated)

at
org.apache.geronimo.system.main.Daemon.doStartup(Daemon.java:297)

at org.apache.geronimo.system.main.Daemon.init(Daemon.java:74)

at org.apache.geronimo.system.main.Daemon.main(Daemon.java:377)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)


Re: Error opening the editor

2008-06-18 Thread Tim McConnell
Hi Tim, I think you may be using an older version of the Geronimo Eclipse Plugin 
(GEP). This was a problem in the 2.0.0 version of the GEP but has been fixed in 
the 2.1.0 release. If this is the case, could you try the newer version and let 
me know what happens ??


Tim Harsch wrote:

Hi all,

   I get the following error when trying to open 
geronimo-web.xml file:


   “ There was an error opening the editor.  The elements in 
the plan may not be qualified, do you want to try to auto-correct this? 
Otherwise the default text editor will be opened.”


   Googling that phrase gives no love.

 


   Here’s the content of my file:

web-app xmlns=http://geronimo.apache.org/xml/ns/j2ee/web-1.1;

environment

moduleId

artifactIdGeronimo2/artifactId

/moduleId

/environment

context-root/Geronimo2/context-root

/web-app

 


Tim



--
Thanks,
Tim McConnell