I tried to create simple vaadin portlet, but it doesn’t work on liferay 6.2 b2.
Liferay 6.2.b2 has vaadin Version 6.8.12 built on 2013-06-19 by default.
Run eclipse and set sdk and tomcat in the Windows → Preferences
File → New → Liferay Project → Portlet → Vaadin → Finish → Hello Word example has created
Run tomcat
execute ant all for vaadin portlet
Go to portal and add new portlet on any page.
Expected: To see “Hello Vaadin!”
Actual: Nothing is displayed, portlet with empty body
No errors in the log files and console.
Is it issue of liferay 6.2.b2 or I missed something?
Thanks for any help!
====================
One Answer from Liferay forum
This is a known issue. Vaadin relies on a deprecated Liferay API that was removed in Liferay 6.2. I opened a bug on this awhile ago, and Vaadin is aware of the issue. It was my understanding that they had a fix in place for V7, but I don’t know if they were planning on backfilling on the 6.8 line.
==================
Questions
Is Liferay 6.2 b2 and Vaadin 7.1.3 compatible?
Will vaadin 6.8 be adapted for liferay 6.2? when is it expected?
I could not get the liferay vaadin control panel to work in 6.2, so I compiled the widgetsets manually using the attached .bat script file named “CompileGWTWidgetSets.bat”.
e.g., “C:/Program Files/Java/jdk1.7.0_21/bin/java.exe” -Djava.awt.headless=true -Xss8M -Xmx512M -XX:MaxPermSize=512M -classpath “” com.google.gwt.dev.Compiler -war “C:\liferay\Vaadin\widgetsets” -localWorkers 4 -logLevel INFO “com.vaadin.portal.gwt.PortalDefaultWidgetSet”
I updated my portal-ext.properties file to have the vaadin properties. Mine looks like this:
jdbc.default.driverClassName=org.mariadb.jdbc.Driver
jdbc.default.url=jdbc:mariadb://localhost/lportal62test?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false
jdbc.default.username=******
jdbc.default.password=******
vaadin.resources.path=/html
vaadin.widgetset=com.vaadin.portal.gwt.PortalDefaultWidgetSet
vaadin.theme=reindeer
I created a new test Vaadin project in Eclipse (kepler version) using the following steps:
a. File->New->Other->Vaadin->Vaadin 7 Project
b. Project Name: MyTestVaadinApp
c. Target Runtime: Liferay v6.2
d. Configuration: Vaadin 7, Java 6, Servlet 3.0
e. Deployment configuration: Servlet (default)
f. Vaadin version: 7.1.5
g. Click Next
h. Click Next
i. check the Generate web.xml deployment descriptor
j. Portlet Version: Portlet 2.0
k. Click Finish
Open the generated “…/MyTestVaadinApp/WebContent/WEB-INF/liferay-portlet.xml” file and
a. add the xml tag “false”.
b. comment out the “true” tag.
c. update the doctype to something like this: “”
d. My file looks like this:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
Forgot to mention after compiling the widgetsets, I would copy them from the folder I compiled them in to …\tomcat-7.0.40\webapps\ROOT\html\VAADIN\widgetsets
Hi Dave,
I’m migrating Vaadin portlets to LF 6.2. After many problems I decided to build a simple portlet to test deployement.
After deploy I still have empty portlet. Here my code for portlet class :
[code] @Override
public void init() {
Window mainWindow = new Window(“Vaadin Test Portlet”);
VerticalLayout vl = new VerticalLayout();
vl.setHeight(600, Sizeable.UNITS_PIXELS);
vl.setWidth(900, Sizeable.UNITS_PIXELS);
Label label = new Label("Hello Vaadin user");
vl.addComponent(label);
mainWindow.setContent(vl);
setMainWindow(mainWindow);
}
Vaadin under liferay does not work like Vaadin for a servlet. I don’t even know that the standalone (self-contained) mode actually works under the 6.8 framework.
You need the old vaadin control panel, you need to update the shared vaadin environment per instructions on vaadin.com, and you have to follow the Vaadin 6 on Liferay way.
The reason of that, we are upgrading our LF installation to 6.2. We have old Vaadin6 portlets. It would be easy for us if we can continue running theses portlets in standalon mode with vaadin 6 and use Vaadin 7 in shared mode for new planned portlets.