Message Boards

AUI libraries

avasek atok, modified 8 Years ago.

AUI libraries

Junior Member Posts: 41 Join Date: 1/9/15 Recent Posts
Is there a way to stop loading AUI libraries from custom theme in liferay.
I understand all the edit controls work are tight coupled wiht AUI, but however alteast for end user if there is a way to prevent the AUI libraries loading from liferay portal.
I am assuming this should certainly improve response times.
Please suggest if there is a way to acheive this.

Thanks
thumbnail
Olaf Kock, modified 8 Years ago.

RE: AUI libraries

Liferay Legend Posts: 6403 Join Date: 9/23/08 Recent Posts
Check the Javascript section of portal.properties and override in portal-ext.properties. Search for "barebone"
thumbnail
David H Nebinger, modified 8 Years ago.

RE: AUI libraries

Liferay Legend Posts: 14916 Join Date: 9/2/06 Recent Posts
avasek atok:
Is there a way to stop loading AUI libraries from custom theme in liferay.
I am assuming this should certainly improve response times.


Actually you are quite wrong here. Response times can be impacted by JS loads, but often poor response times are based upon what you have implemented in your portal and honestly there's other better solutions than just trying to disable AUI.

For example, just standing up a caching appliance (such as a Varnish server) can drastically improve response times without changing a line of your Liferay code or configuration.
thumbnail
Olaf Kock, modified 8 Years ago.

RE: AUI libraries

Liferay Legend Posts: 6403 Join Date: 9/23/08 Recent Posts
I'm in the mode of firing quick answers. That being said: Take my answer as an exercise to look at portal.properties and do what David says.

Are you sure that the extra time for AUI is your biggest bottleneck? If you are not 100% sure, or if it isn't your biggest bottleneck: Don't bother optimizing it, because you'll have so much test work to do. Let's say your biggest bottlenecks are allowing you to cut load times by 50%, 20%, 10% and 5%, with AUI load times being the 5% item: What would you win if you optimize it? At most 5%. Go for the elephant in the room: Unless you identify that something is breaking: Don't fix it. It will make up for more complicated maintenance long term while not gaining any value - neither short- nor long-term.
avasek atok, modified 8 Years ago.

RE: AUI libraries

Junior Member Posts: 41 Join Date: 1/9/15 Recent Posts
Thanks for your response. I was looking if there is a way to stop AUI libraries loading for public users of my application. My application does have only public pages. For admin it needs to be functional as-is, since I am aware admin activities are dependent on AUI libraries.
Please suggest.

Thanks,
thumbnail
Olaf Kock, modified 8 Years ago.

RE: AUI libraries

Liferay Legend Posts: 6403 Join Date: 9/23/08 Recent Posts
My recommendation is to only do this intervention when you've demonstrated that most of the time is actually spent in the libraries. Measure! If you don't want to measure: I've given the answer above. But I don't recommend acting on it, unless you can provide actual numbers, to compare the before/after performance.