Issue Details (XML | Word | Printable)

Key: JAVASERVERFACES-1828
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Manfred Riem
Reporter: omolenkamp
Votes: 3
Watchers: 4
Operations

If you were logged in you would be able to see more operations.
javaserverfaces

java.lang.ClassNotFoundException: com.sun.el.lang.VariableMapperImpl

Created: 05/Oct/10 08:28 AM   Updated: 29/Jan/13 03:55 PM   Resolved: 29/Jan/13 03:55 PM
Component/s: state saving
Affects Version/s: 2.0.3, 2.1.13
Fix Version/s: 2.1.18, 2.2.0-m09

Time Tracking:
Not Specified

File Attachments: 1. GZip Archive clientstate-testcase.tar.gz (12 kB) 05/Oct/10 08:29 AM - omolenkamp

Environment:

Operating System: All
Platform: All

Issue Links:
Related
 

Issuezilla Id: 1,828
Status Whiteboard:

size_medium importance_medium

Tags:
Participants: ernisv, Manfred Riem, niklasg, omolenkamp, Puls, rogerk, rogerkeays and SteveWoodley


 Description  « Hide

When client-side state saving is used, and a view contains a method expression
for a method of an object that is passed to a Facelets template as a variable,
restoring the view will throw a ClassNotFoundException for
com.sun.el.lang.VariableMapperImpl.

(VariableMapperImpl is used in orig.varMapper for the TagMethodExpression object
for the method expression, with orig being an instance of MethodExpressionImpl)

I'm running Mojarra on Glassfish 3.0.1.

Attached is a simple testcase: when the form in index.xhtml is submitted, an
exception will be thrown.



omolenkamp added a comment - 05/Oct/10 08:29 AM

Created an attachment (id=1300)
NetBeans project with test case


rogerk added a comment - 18/Nov/10 05:28 PM

triage


SteveWoodley added a comment - 15/Apr/11 06:56 AM - edited

I'm seeing the same thing. I'm running Mojarra 2.0.4 FCS, Glassfish 3.0.1

In my case I'm passing a CDI bean as an attribute to a custom tag. The tag contains an (Ajax) selectBooleanCheckBox which has a valueChangeListener attribute referring to a method on the CDI bean. Clicking on the check box causes the same error as above. Value expressions on the CDI bean do not cause the problem.

If I switch to server side state saving the problem does not occur.


ernisv added a comment - 21/Nov/11 09:33 PM

Looks like it depends on some libraries used by Glassfish. I have the same exception on Glassfish 3.1.1 while on Tomcat 7 it works fine.


rogerkeays added a comment - 18/Mar/12 06:44 AM

Adding this to my pom.xml fixes this issue for me on GF3.1.2

<dependency>
<groupId>com.sun.el</groupId>
<artifactId>el-ri</artifactId>
<version>1.0</version>
<scope>compile</scope>
</dependency>

Could be a problem with Glassfish?


Puls added a comment - 04/Jul/12 06:57 AM

This issue still exists on Glassfish 3.1.2 with Client-Sie-State Saving.


Manfred Riem added a comment - 08/Nov/12 09:27 PM

Can you verify if it is still a problem with the most recent 2.1 release?


Puls added a comment - 16/Nov/12 10:22 AM - edited

I can confirm that it still exists on 2.1.13 as that is our production and tetsing version.

Havent had any time to test with a newer release.


niklasg added a comment - 08/Jan/13 06:11 PM

I got a ClassNotFoundException for com.sun.el.lang.FunctionMapperImpl with Glassfish 3.1.2.2. I think the problem is that the javax.el.jar bundle exports com.sun.el but not com.sun.el.lang:

g! lb javax.el
START LEVEL 3
   ID|State      |Level|Name
  138|Active     |    1|Expression Language API 2.2 (2.2.4)
  151|Resolved   |    1|Expression Language Implementation (2.2.3)
g! inspect package capability 151
org.glassfish.web.javax.el [151] exports packages:
--------------------------------------------------
com.sun.el; version=0.0.0 imported by:
   GlassFish-Application-Common-Module [34]

After updating the manifest to export com.sun.el.lang, uninstalling the old bundle and installing the new one the problem disappeared.

Export-Package: com.sun.el;uses:="javax.el",com.sun.el.lang;uses:="ja
 vax.el"

Manfred Riem added a comment - 29/Jan/13 03:55 PM

Please see issue 2681 for resolution!