2

I have an error when I publish the _Navigation page. After some time in rendering status it fails and give us this error:

"Error during serialization or deserialization using the JSON JavaScriptSerializer. The length of the string exceeds the value set on the maxJsonLength property."

Our CMS version is Tridion 2013 working with Java and publishing the content in DataBase. The DXA version that we use is 1.5.

If I do a preview of that page it fails with a timeout:

"The socket connection was aborted. This could be caused by an error processing your message or a receive timeout being exceeded by the remote host, or an underlying network resource issue. Local socket timeout was '00:10:00'."

It usually takes about 1 hour to publish (it only fails in the publication that save information in DataBase, in the rest of publications works), the number of Structure Groups is more than 500 and usually have 1 page in each SG (I do not know the exact number).

Someone could help me with this error?

  • Can you edit your question and add some more details about which version of DXA and CMS you are using? Also can you post details of the error when you preview the _Navigation Page in the CM? – Bart Koopman Sep 7 '16 at 10:59
  • Thanks Bart for your comment, I edited my question with more information. – dncentenero Sep 7 '16 at 11:32
  • The timeout you get sounds like rendering of the navigation page takes a long time, can you edit your question and provide some more details about how large your navigation is? Like how many Structure Groups do you have in total and how many Pages in there. Rough numbers will be enough, also which ones of those are part of the navigation (i.e. start with a three digit number)? Also are there any more details given in the event viewer log or on the Publish Transaction, since we can't seem to get these details from a preview? – Bart Koopman Sep 7 '16 at 11:43
1

Not really sure what you mean with "it only fails in the publication that save information in DataBase, in the rest of publications works", but the fact that you get a timeout during rendering of aprox. 500 Structure Groups sounds like you might have a database maintenance issue to start with.

Furthermore a Publish Transaction taking 1 hour really sounds like you are having a huge issue, that totally should not be happening. Even when you are publishing the entire Publication I would not expect it to take that long.

So to try and tackle the first issue I think that needs addressing, the database performance: The documentation has several topics on maintenance like http://docs.sdl.com/LiveContent/content/en-US/SDL%20Tridion%20full%20documentation-v1/GUID-94283420-8A51-4F2C-913E-B18455E58D74 and http://docs.sdl.com/LiveContent/content/en-US/SDL%20Tridion%20full%20documentation-v1/GUID-5863DEDC-1511-4333-A0C6-644B67403634

There is also an article on SDLs community website about database maintenance: https://community.sdl.com/products-solutions/solutions/customer_experience_cloud/digital-experience/tridion/tridion-developer/b/weblog/archive/2009/04/03/maintaining-sdl-tridion-databases

Basically it comes down to a correctly configured database server (please check the documentation of the database vendor for that) and making sure that you regularly update the statistics of the database and ensure the transaction log is properly truncated to keep it small.

For MS SQL Server, you can start with executing the following commands on the CM database:

exec sp_updatestats

And making sure the translation log is less than 1GB in size (because if it reaches that, your MS SQL Server database will become very slow).

I expect that after proper database maintenance you should see a lot better performance on Previewing and Publishing, and then we might be able to work on the problem which is reported at publish time (since the size issue will most likely still be there, but we will need more information to see how it can be solved). Please update your question and provide more details so we can continue on solving this.

0

You haven't provided much details to get a precise answer. But it looks like a mvc .net JSON serialization error. Try setting max length of json as suggested in this post https://stackoverflow.com/questions/16848289/error-the-length-of-the-string-exceeds-the-value-set-on-the-maxjsonlength-proper

Hope this helps

  • Thanks for your answer. I forgot to comment that we work with Java, I edit the question to add more information. – dncentenero Sep 7 '16 at 11:35
  • The error occurs during Publishing/Rendering, so I expect it to be thrown from the Template code, probably here github.com/sdl/dxa-content-management/blob/release/1.5/… which means we don't have a web.config where we can control this. – Bart Koopman Sep 7 '16 at 11:46
  • 3
    The configuration can be done in the web/app config of the host running the templates. For example, the Publisher Service (TcmPublisher.exe.config) , the Core Service Host (TcmServiceHost.exe.config) or the Template Debugging Host (TcmTemplateDebugHost.exe.config). – Rick Pannekoek Sep 7 '16 at 17:24
  • We added the maxJsonLength feature inside the <runtime> node in the publisher service and restarted the service, but we are still getting the same error. Do you know if this must be added in another location? – tfinez Sep 14 '16 at 7:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.