cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
614
Views
1
Helpful
5
Replies

maapi applyTrans performance issue

sm000x
Level 1
Level 1

Hi, Team:

I need help.

My project uses NSO for 10 years. There is a table (a list with single key)
grows very big during 10 years. Every time I insert or delete an entry from/to the table the maapi.applyTrans takes 2-3 minutes.

This really impacts the customers.

Is there any one has the same issue?
Any suggestions?

THX
sm000x

5 Replies 5

sm000x
Level 1
Level 1

Hi, Just add more information on my question.

(1) There is no device involved. The table is in cdb, to add/delete entry from the table does not trigger device actions. But it takes 2-3 minutes.

(2) By using "commit | details", I found the 99% time is spend on "dependency-triggered validation"

Hope this can provide more information.

THX

sm000x

What kind of validation constraints exist in your model?

Have you looked in the xpath log?

Adding items to a list is usually easier (require less validation work) than deleting items.

 

Hi, mljunggr:

Sorry for the delay.

What I found was the leafref always does a full table scan.
For example if a leaf dev-name leafref to devices/device/name, then whenever
the dev-name is used ncs does a full table scan on devices/device list. If the
devices/device list is huge (after 10 years' cumulation) then the performance is heavily impacted.
I have to take out the leafref in order to improve the performance.
After change leafref to string, the performance improved from 2-3 minutes to few
seconds.

I wish there is some way to disable the full table scan.

THX
sm000x

rogaglia
Cisco Employee
Cisco Employee

Hi,

If you are using the leafref as a way to have CLI completion and WebUI drop-downs, you can check to use "tailf:non-strict-leafref" extension. I did not check its performance in large lists.

You use it this way:

      leaf name {
        type string;
        tailf:non-strict-leafref {
          path "/ncs:devices/ncs:device/ncs:name";
        }
      }

Hi, rogaglia:

Thank you for this exiting information. I will give it a try.

THX
sm000x