Liferay can be customized using either hook plugins or Ext plugins. best way is to try
doing all your customizations as hooks if possible.
If you find something you can’t do in a hook—maybe you need to customize a
property that isn’t yet supported by hooks, extend an internal Liferay class, implement
a custom PermissionChecker, or extend a Liferay Struts action—you can use the Ext
plugin to do this.
1. Hooks are recommended way of extension. Maintenance is easy
Ext plgin suggested when there is no way of implementing required functionality using Hooks
2. Hooks are hot deployable . Ext Plugins are not hot deployable
3. Hooks doesn't require server restart. Ext plugins requires server restart before taking into effect
4. Hooks stays as separate components. those are not overriding liferay's code. System load at runtime to override the behavior.
Ext plugins changes replaces the liferay's code directly.
5. Hooks undoing is easy.. Ext plugin undoing is not easy. Need almost fresh installation
6.in Extension , we can customize almost everything. we will have access to all Liferay's APIs
7. Ext plugin implementation is not easy as Hook plugin
8. While Liferay upgradation we may see some surprises in your ext plugin. some API might be used in liferay implemenation which is used in your Ext plugin. so you have to rewrite your ext plugin
9. And because code from Ext plugins overlays the code in Liferay, you can’t
have more than one Ext plugin that contains a struts-config-ext.xml file, and you have
to put all your portlets into one big, monolithic Ext project
10. Do You need to change the logic of a Struts action in one of the built-in portlets. ? Then we may need Ext Plugin
Nice points to remember. Thank you
ReplyDelete