I have a problem in OEPE (oepe-juno-distro-win32.zip), where the Data tab in Palette shows no Managed Beans,
even if I created them in the ManagedBeans in faces-config.xml using the Faces Config Editor.
I have created a Dynamic Web Project with these Facets:
Dynamic Web Module 3.0
Java 1.7 (JDK 1.7_21)
Java Annotation Processing Support 5.0
JavaServer Faces 2.1
Oracle WebLogic Web App Extensions 12.1.1
I am using Oracle WebLogic Server 12c 12.1.1 zip distribution for hosting the application.
For example, I have a UserBean Managed Bean of Session scope, that has 3 String fields
and the respective getters and setters.
I create a "test.jspx" file, and from the Palette -> Tags tab -> JSF HTML I drag a Form into
the new file so I can connect it to UserBean and generate a form to enter its details.
I select the "Generate a form tag and content from data" and in the Choose Bean dialog
there is none of my Beans.
What could be the problem?
Thanks in advance.
Edited by: 997841 on Apr 30, 2013 6:09 PM
I forgot to mention the Oracle WebLogic Web App Extensions version 12.1.1 and that also
for JSF 2.1 the "sub-directory" Faces Configuration below the project in Project Explorer is not
existent, as in projects created with earlier versions of JSF.
Could you attach your test.jspx and faces-config.xml file?
Also, what specific version of OEPE/Juno are you using? (Help/About Eclipse Platform..., click on the OEPE button, include version of the Oracle Web Tier Tools)
There could be a number of things.
First, could you right-click on the Project and go Properties->AppXRay. Check to make sure "Disable AppXRay" is not checked. Then check the list of technologies in the table. Based on the facets you listed, you should have an entry for "WebApp 3.0", "JSF 2.1", "JSP 2.1" or "JSP 2.2". Make sure that both check boxes (for Discovery and Collection) are checked in each of these rows.
Next, just to be on the safe side, open the faces-config.xml where your Managed Beans are declared and "touch" the file (i.e. make a trivial change and click save). This shouldn't be required, but this may expose a refresh bug if there is one.
Finally, open the test.jspx file and "touch" it as well.
With all that done, click on the main menu for Project->Clean.. and do a clean build of at least the project you are working on.
Now retry your scenario. If it still doesn't work, try closing and re-opening the project.
Note: these are general workarounds and normally should not be necessary unless there is a bug in OEPE or an unsupported condition in your project.
If you can send a copy of your project to OTN support, we may be able to get it and try and debug the problem.
I forgot to mention the Oracle WebLogic Web App Extensions version 12.1.1 Facet was also
included in the project and that also for JSF 2.1 the "sub-directory" Faces Configuration below
the project in Project Explorer is not existent, but for earlier versions of JSF (<2.1) it is.
Anyway, I did what you told me with no result.
In the Properties->AppXRay of the Project I only have WebApp 3.0, JSTL 1.2 and JSP 2.2 all
checked and AppXray not disabled but there is no entry for JSF 2.1.
In the Preferences->AppXray all the entries are checked and it is enabled and also there exists
an entry for JSF 2.1.
Here are the versions for the OEPE: Oracle Enterprise Pack for Eclipse 126.96.36.199303081427 oracle.eclipse.tools.juno.oepe.product.feature.group Oracle Eclipse Platform 3.8.1.v20130118-180812-9jF7oIBFG8eU2pim-VbIlTuQjY0RWWK3x-bv4I org.eclipse.platform.feature.group Eclipse.org Java EE 5 Documentation 188.8.131.52201241920 oracle.eclipse.tools.juno.doc.javaee5.feature.group Oracle Java EE 6 Documentation 184.108.40.206201241920 oracle.eclipse.tools.juno.doc.javaee6.feature.group Oracle Oracle ADF Documentation (220.127.116.11.0) 18.104.22.168303081427 oracle.eclipse.tools.juno.adf.doc.v11114.feature.group Oracle Oracle ADF Documentation (22.214.171.124.0) 126.96.36.199303081427 oracle.eclipse.tools.juno.adf.doc.v11115.feature.group Oracle Oracle ADF Documentation (188.8.131.52.0) 184.108.40.206303081427 oracle.eclipse.tools.juno.adf.doc.v11116.feature.group Oracle Oracle ADF Documentation (220.127.116.11.0) 18.104.22.168303081427 oracle.eclipse.tools.juno.adf.doc.v11117.feature.group Oracle Oracle ADF Tools 22.214.171.124303081427 oracle.eclipse.tools.juno.adf.feature.group Oracle Oracle Cloud Tools 126.96.36.199303081427 oracle.eclipse.tools.juno.cloud.feature.group Oracle Oracle Coherence Tools 188.8.131.52303081427 oracle.eclipse.tools.juno.coherence.feature.group Oracle Oracle Common Tools 184.108.40.206303081427 oracle.eclipse.tools.juno.common.feature.group Oracle Oracle Database Tools 220.127.116.11303081427 oracle.eclipse.tools.juno.database.feature.group Oracle Oracle GlassFish Server Tools 18.104.22.168201241920 oracle.eclipse.tools.juno.glassfish.feature.group Oracle Oracle Patches 22.214.171.124303081427 oracle.eclipse.tools.juno.patches.feature.group Oracle Oracle Spring Tools 126.96.36.199303081427 oracle.eclipse.tools.juno.spring.feature.group Oracle Oracle Web Tier Tools 188.8.131.52303081427 oracle.eclipse.tools.juno.webtier.feature.group Oracle Oracle WebLogic Scripting Tools 184.108.40.206303081427 oracle.eclipse.tools.juno.weblogic.scripting.feature.group Oracle Oracle WebLogic Server Tools 220.127.116.11303081427 oracle.eclipse.tools.juno.weblogic.feature.group Oracle
Here is the link to my project exported as an archive file:
Thanks for the repro case.
It looks like the JSF libraries required for your project may not be configured. If you right-click on the project go to Properties->Project Facets and expand the tree you should see a node called "Java Server Faces". If you click on it there will be a drop down box for "Type". What is this set to? It should be selected to the WebLogic Shared Library if that's the one you want to use. Let me know what you see there.
If you are not able to correct the problem, try this workaround: in the dropdown, select "User Library". When you do this a list box should appear below the dropdown. It has two action buttons to the right of the dialog. Click on the one that looks like a floppy disk with an arrow on it (the tooltip reads "Download Library..."). You will have the option to select either Apache or Mojarra (either should work but Mojarra is a good choice if you don't have a preference since this is the "official" Oracle implementation). Then follow the dialogs to download the libraries. This will store a separate copy of just the JSF libraries on your disk and make them available to the classpath. With that done, try closing and reopening the project to be completely sure everything is refreshed.
In the Properties->Project Facets->Java Server Faces, the Type is set to
"WebLogic System Libraary (JSF2.x)" and down in the box there is "glassfish.jsf 18.104.22.168_2-1-5".
I tried what you said with both the User Libraries and none worked, the problem still persists.
After you set the library (either shared or the user one), could you look at Project Properties->Build Path and under the Libraries tab check that both JSF and JSTL libraries are listed? If not, you can try to add them manually using the "Add Library..." button. If you have configured to use the JSF User Library, it should appear in if you select "User Library" in the dialog.
With the JSF User Library configured, could you post the .classpath file from the project? It is hidden by default but will appear in the root of your project if you go to the Filters... dialog from the Navigator view menu (the little upside down triangle along the top of the Navigator or Package Explorer view) and select Filters... and uncheck the box for ".* resources"
Hmm... when I use the same .classpath as you have for User Library, it works locally.
Let's dig a bit deeper. Everything seems to point to the fact that the technology extension is not being enabled for JSF 2.1 on your project.
What is showing up in the palette? Do you see tags? When you open the Page Variables drawer in the Data tab, do you see the "msg" variable?
Could you also check the Error Log (Ctrl-3 (Win/Linux) or Command-3 (Mac), then type "Error Log") to see if there any errors that look related?
Could you try using JDK 1.6 instead of JDK 1.7? One of the other OEPE engineers had some success in reproducing a similar problem with JDK 1.7 but not with JDK 1.6.
Edited by: 683478 on May 1, 2013 4:33 PM
Ok. We took another look at it and I think we've found the root problem. There is a problem with our support for JSF 2.1 in OEPE 12.1.1. This will be corrected with the version of OEPE that ships in tandem with the next version of WLS (12.1.2) that we support.
In the mean time, if you use the JSF 2.0 facet instead of JSF 2.1 it should resolve your issue. The issue with Java 1.7 looks like it may have been a red herring.
Unfortunately, there is no way to downgrade the project version to 2.0 so you will need to recreate the project. Sorry for the inconvenience. You should still be able to use the 2.1 libraries (if you want) even when the 2.0 facet is active since there isn't much difference between those versions from the tool's perspective.
Thanks for taking the time to follow up with us and help us track down this issue.