dotCMS 4.3.2 - Portlet Plugin

54 views
Skip to first unread message

Muneeswari Ramanathan

unread,
May 24, 2018, 8:19:33 AM5/24/18
to dotCMS User Group
Hi team,
I am using the dotCMS version 4.3.2. I downloaded the dotCMS plugin-seeds from the GitHub which is the latest 4.3.2. I am in need of creating a new struts portlet so I have taken the com.dotcms.portlet plugin.
The jar is built by the gradlew command and the jar is deployed into my local dotcms server. The state of the plugin is Active. I added my portlet under Contents Tab. When I click on my portlet, I get a blank page. When I check the dotcms.log file, the following exceptions are logged.


[24/05/18 14:13:28:804 IST] ERROR portlet.Activator: bytebuddy ClassReloadingStrategy not set [java agent not set?]
[24/05/18 14:13:28:815 IST]  INFO portlet.Activator: Added Struts Action Mapping: com.dotmarketing.osgi.portlet.HelloWorldAction
[24/05/18 14:13:29:000 IST]  INFO portlet.Activator: Added Portlet: PORTLET_432
[24/05/18 14:13:29:000 IST] ERROR job.Activator: Error reading ClassReloadingStrategy from bytebuddy [java agent not set?]
java.lang.IllegalStateException: The Byte Buddy agent is not installed or not accessible
at net.bytebuddy.dynamic.loading.ClassReloadingStrategy.fromInstalledAgent(ClassReloadingStrategy.java:148) ~[byte-buddy-1.6.12.jar:?]
at com.dotmarketing.osgi.GenericBundleActivator.initializeServices(GenericBundleActivator.java:129) [dotcms_4.3.2_ae725e9.jar:?]
at com.dotmarketing.osgi.job.Activator.start(Activator.java:37) [com.dotcms.job-0.1.jar:?]
at org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:697) [org.apache.felix.framework-5.6.2.jar:?]
at org.apache.felix.framework.Felix.activateBundle(Felix.java:2238) [org.apache.felix.framework-5.6.2.jar:?]
at org.apache.felix.framework.Felix.startBundle(Felix.java:2144) [org.apache.felix.framework-5.6.2.jar:?]
at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:998) [org.apache.felix.framework-5.6.2.jar:?]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1253) [org.apache.felix.fileinstall-3.5.8.jar:3.5.8]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1225) [org.apache.felix.fileinstall-3.5.8.jar:3.5.8]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:512) [org.apache.felix.fileinstall-3.5.8.jar:3.5.8]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:361) [org.apache.felix.fileinstall-3.5.8.jar:3.5.8]
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:312) [org.apache.felix.fileinstall-3.5.8.jar:3.5.8]
Caused by: java.lang.ClassNotFoundException: net.bytebuddy.agent.Installer
at java.net.URLClassLoader.findClass(URLClassLoader.java:381) ~[?:1.8.0_91]
at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[?:1.8.0_91]
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) ~[?:1.8.0_91]
at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:1.8.0_91]
at net.bytebuddy.dynamic.loading.ClassReloadingStrategy.fromInstalledAgent(ClassReloadingStrategy.java:142) ~[byte-buddy-1.6.12.jar:?]
... 11 more
[24/05/18 14:13:29:000 IST] ERROR job.Activator: bytebuddy ClassReloadingStrategy not set [java agent not set?]


and, 

[24/05/18 14:15:15:602 IST] ERROR action.RequestProcessor: No action instance for path /ext/strutshello/view_hello could be created
java.lang.ClassNotFoundException: com.dotmarketing.osgi.portlet.HelloWorldAction
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1305) ~[catalina.jar:8.0.18]
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1157) ~[catalina.jar:8.0.18]
at com.dotcms.repackage.org.apache.struts.util.RequestUtils.applicationClass(RequestUtils.java:119) ~[dot.struts-1.2.4_2.jar:1.2.4]
at com.dotcms.repackage.org.apache.struts.util.RequestUtils.applicationInstance(RequestUtils.java:145) ~[dot.struts-1.2.4_2.jar:1.2.4]
at com.dotcms.repackage.org.apache.struts.action.RequestProcessor.processActionCreate(RequestProcessor.java:282) [dot.struts-1.2.4_2.jar:1.2.4]
at com.dotcms.repackage.org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:220) [dot.struts-1.2.4_2.jar:1.2.4]
at com.liferay.portal.struts.PortletRequestProcessor.process(PortletRequestProcessor.java:91) [dotcms_4.3.2_ae725e9.jar:?]
at com.liferay.portlet.StrutsPortlet.include(StrutsPortlet.java:148) [dotcms_4.3.2_ae725e9.jar:?]
at com.liferay.portlet.StrutsPortlet.doView(StrutsPortlet.java:100) [dotcms_4.3.2_ae725e9.jar:?]
at com.dotcms.repackage.javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:235) [dot.portlet-1.0_2.jar:?]
at com.dotcms.repackage.javax.portlet.GenericPortlet.render(GenericPortlet.java:163) [dot.portlet-1.0_2.jar:?]
at com.liferay.portlet.CachePortlet.render(CachePortlet.java:159) [dotcms_4.3.2_ae725e9.jar:?]
at org.apache.jsp.html.portal.layout_jsp._jspService(layout_jsp.java:618) [ROOT/:?]
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) [jasper.jar:8.0.18]
Your valuable suggestions will help me to make my custom portlet work well. 

Thank you.

Jason Tesser

unread,
May 24, 2018, 10:55:49 AM5/24/18
to dot...@googlegroups.com
seems like maybe you do not have the bytebuddy agent when starting dotCMS 

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dotcms+un...@googlegroups.com.
To post to this group, send email to dot...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/9317e944-0a4e-46d7-9864-a9aa64c6b570%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

jonathan...@dotcms.com

unread,
Jun 26, 2018, 11:16:01 PM6/26/18
to dotCMS User Group
check your settings on startup script, the java agent should looks like this:

 -javaagent:$DOTCMS_HOME/WEB-INF/lib/byte-buddy-agent-1.6.12.jar 

Reply all
Reply to author
Forward
0 new messages