cancel
Showing results for 
Search instead for 
Did you mean: 

CIFS performance issue after upgrade from 32r to 40d

mlagneaux
Champ on-the-rise
Champ on-the-rise
Hello,

I've made an upgrade of a customised Alfresco from 3.2r to 4.0d and I've major performance issues with CIFS.
Since the upgrade, opening a document from Windows Explorer takes about 30 seconds. Same time when saving a document.

There's about 300 Gb in Alfresco. Note that if I test with an empty repository, I do not have these problems.

In terms of customization, we have:
- A specific data model;
- Permissions assigned dynamically (dynamicAuthority);
- Use of different behaviours (onCreateNode, beforeDeleteNode, onCopyComplete, …);
- Jobs;
- Ibatis queries.

I've added logs in the most part of my code but it didn't help me to find the problem: for example, we only spend a total of 3 seconds total in dynamicAuthority when saving a document.

Do you have any ideas to help me to solve this problem?
Thank you in advance for your help.
4 REPLIES 4

afaust
Legendary Innovator
Legendary Innovator
Hello,

have you tried running a profile like JProfile or YourKit against your Alfresco installation? This should give you excellent information on what part of your system is taking up the most time.

From my experience, dynamic authorities and policies are the usual major suspects for long running actions. Between 3.2 and 4.0, there have been some changes in the way policies are executed - one in particular can have a serious impact on performance: policy collection now correctly handles type hierarchies (was not 100 % the case before), so - depending on your customizations - you may up running more policies than before in a particular event. In one of my migration projects from 3.2 to 3.4, we ended up running 3 of our policies 4 times each time a certain object was created due to the type hierarchy and the change I explained.
Three seconds for a dynamic authority is quite a long time - what are you doing with it? A dynamic authority - especially if is relevant for a common permission - should execute in just a couple of milliseconds, since it will be called quite a lot and individual times soon add up to a huge delay.

Regards
Axel

mlagneaux
Champ on-the-rise
Champ on-the-rise
Thanks for the answer.

I totally agree with you when you say that dynamic authorities and policies are the usual major suspects : that was my first idea.

To make things clear, when I say that dynamicAuthorities take 3 seconds, that's a total of 3 seconds when I save a document over CIFS. For all my dynamic authorities, one execution doesn't take more than few milliseconds. I've tried to disable them and restore Alfresco permission model but performance issue is still there.

I've also tested CIFS disabling policies and the result is the same. Is there a policy in particular that can cause problem when accessing Alfresco over CIFS ?

I'm going to try YourKit or JProfile.

mlagneaux
Champ on-the-rise
Champ on-the-rise
When a Word document is opened, Word creates a "$xxx.doc" file.

I've a "onCreateNode" policy on content nodes that updates 2 custom properties of a the created node.
I've a "onUpdateProperties" policy on content nodes that needs to work on the current version of the node (each content node is versionable, that's a mandatory aspect in my model).

I've put logs in my "onUpdateProperties" method in order to know how long it lasts and sometimes it takes about 5 seconds to execute the getCurrentVersion instruction.

Do you know how to explain that ?

I've tried Yourkit Java Profiler and I don't have the same results. The average time of "onUpdateProperties" is only 65 ms.

I've also made another test. I've disabled all my customisations except modifications on models. In the situation, CIFS performance are already bad (15s to open a document, 20s to save and close). Going further, I've seen that it comes from versionable aspect that is mandatory for content nodes in my model. Indeed, all content nodes must be versionable in my application.

Do you know why adding versionable aspect on content nodes has such a bad influence on CIFS performances ?
Do you know another way to make all content nodes versionable without impacting CIFS performances ?

mlagneaux
Champ on-the-rise
Champ on-the-rise
I've not found any solution to that problem yet. Do you have an idea (or answers to my questions) ?