Trouble with Groups in Network Diagrams

0 votes
asked Feb 16 in Bug by owenfunkhouser (120 points)

Using the following code, PlantUML is not creating 3 distinct groups but instead overlapping the boxes on top of each other. Is there a way to fix this or is this a bug?

@startuml

!include <office/Servers/application_server>

!include <office/Servers/database_server>

nwdiag {

  group {

    description = "Demo 1";

    color = "#FFaaaa";

    DEMO1_PCoIP;

    DEMO1_Client;

  }

  group {

    description = "Demo 2";

    color = "#aaaaFF";

    DEMO2_PCoIP;

    DEMO2_Client;

  }

  group {

    description = "Demo 3";

    color = "#aaFFaa";

    DEMO3_PCoIP;

    DEMO3_Client;

  }

  network DEMO_VLAN {

    DEMO1_PCoIP;

    DEMO2_PCoIP;

    DEMO3_PCoIP;

  }

  network PCoIP_VLAN {

    DEMO1_PCoIP;

    DEMO1_Client;

    DEMO2_PCoIP;

    DEMO2_Client;

    DEMO3_PCoIP;

    DEMO3_Client;

  }

}

@enduml

commented Feb 16 by The-Lu (19,980 points)

Hello O. and PlantUML team,

It is a bug, here is a minimal example:

For 2 group that is OK, but as soon as there are 3 groups that is KO:

@startuml
nwdiag {
  group {
    web01;
    db01;
  }
  group {
    web02;
    db02;
  }
  group {
    web03;
    db03;
  }

  network dmz {
      web01;
      web02;
      web03;
  }
  network internal {
      web01;
      db01 ;
      web02;
      db02 ;
      web03;
      db03;
  }
}
@enduml


During testing, here are also some other observed errors:

1/ "Forget to set a network" test

@startuml
nwdiag {
  group {
    web01;
    db01;
  }
  group {
    web02;
    db02;
  }
  group {
    web03;
    db03;
  }

  network dmz {
      web01;
      web02;
      web03;
  }
}
@enduml

→ will generate a 'java.lang.NullPointerException', instead of saying 'db01, db02, db02 are not defined'

2/ Order test (if you define network before group!)

@startuml
nwdiag {

  network dmz {
      web01;
      web02;
      web03;
  }
  network internal {
      web01;
      db01 ;
      web02;
      db02 ;
      web03;
      db03;
  }

  group {
    web01;
    db01;
  }
  group {
    web02;
    db02;
  }
  group {
    web03;
    db03;
  }

}
@enduml

→ will generate also a 'java.lang.NullPointerException', contrary to the original nwdiag site that generates a good diagram.

3/ other test:

nwdiag {

  group {
    web01;
    db01;
  }
  group {
    web02;
    db02;
  }
  group {
    web03;
    db03;
  }    
    
  network dmz {
      web01;
      web05;
      web03;
  }
  network internal {
      web01;
      db01 ;
      web02;
      db02 ;
      web03;
      db03;
  }

}

→ will generate also a 'java.lang.NullPointerException', contrary to the original nwdiag site that generates a good diagram.

Thanks for your support wink,
Regards,
Th.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:

[Antispam2 Feature: please please wait 1 or 2 minutes (this message will disappear) before pressing the button otherwise it will fail](--------)
To avoid this verification in future, please log in or register.
...