the cat trucks had this same problem and it had to do with the alternator overcharging, they released a service bulletin explaining on how to check the system for this condition and repair it.
The over voltage condition was causing the ecm to over compensate the over voltage condition causing it to fluctuate the fuel controls which made the engine surge.
They said it was either caused by bad grounds on the system (engine) to chassis frame or a bad alternator regulator which ultimately led to replacing the alternator.
You may want to consider this truck might be suffering from the same problem being it is basically the same nissan system in it most likely.
This is ONLY to be used to report flooding, spam, advertising and problematic (harassing, abusive or crude) posts.