very large diagram

0 votes
asked Aug 15, 2016 in Closed question / help by cgoguyer (400 points)
Hello,

Is there a limit on the number of components in a diagram with plantuml.war?

I'm trying to generate a large component diagram with about 730 components and 670 links !

I get this error:

août 16, 2016 12:12:12 AM org.apache.coyote.ajp.AjpProcessor process
SEVERE: Error processing request
java.lang.ArrayIndexOutOfBoundsException: 8192

Is there a way to generate it ?

Thx.

1 Answer

0 votes
answered Aug 20, 2016 by plantuml (294,960 points)
Hi,

There should not be such limit.

Could you send us (by mail) your diagram so that we check this.

Thanks!
commented Aug 22, 2016 by cgoguyer (400 points)
I've just replied by private mail.
thx for your help
commented Aug 23, 2016 by plantuml (294,960 points)
I've tested your diagram adding a scale command at the beginning, just to reduce the image size.
(see http://plantuml.com/commons.html )

@startuml
scale 0.1
hide stereotype
skinparam rectangle {
FontSize 12
StereotypeFontSize 12
FontStyle bold
...

The generated image is still big, but it seems to work.

However, I realize now that your are using the server with a .war

I think that the issue comes from the limitation of the URL size (which may be 8192).
The text diagram is about 100k long. So when it's coded as an URL, it give a very long URL, too long to be useful.

So you have to install PlantUML locally if you want to use such large diagram.
Sorry about that!
commented Aug 23, 2016 by cgoguyer (400 points)
So is there a way to increase this limitation or another way to send the uml command to bypass the url size (soap,rest,etc.)?

I'm currently using php server to generate the uml scripts and plantuml on tomcat to generate the image on the fly.
commented Aug 23, 2016 by plantuml (294,960 points)
Bypassing the URL size will be difficult with the current .war implementation.
We could indeed build some soap server, but that's another story.

Since you are using PHP, you could launch PlantUML by command line (instead of using PlantUML on tomcat).
You can copy the function "renderPlantUML" from
https://github.com/pjkersten/PlantUML/blob/master/PlantUML.php
commented Aug 23, 2016 by cgoguyer (400 points)
Thank you for your help.
I will try this and still open a feature request on plantuml server github site for a soap feature :-)
...