inet-henge icon indicating copy to clipboard operation
inet-henge copied to clipboard

You can make a link of 2 parts (uplink, downlink)?

Open evgarik opened this issue 6 years ago • 8 comments

evgarik avatar May 21 '18 11:05 evgarik

Do you mean like this?

image (drawn by Google Slides)

codeout avatar May 21 '18 12:05 codeout

Better this way 111 one of two options

evgarik avatar May 21 '18 13:05 evgarik

Thanks, I believe we can do that in near future. I'm currently addressing multiple links between nodes, it should enable you to draw even two parts like you indicated. I need some time.

codeout avatar May 23 '18 00:05 codeout

Can be closed Thank

evgarik avatar Jun 04 '18 05:06 evgarik

Thanks. Let me keep it open for a while, just for a reminder.

codeout avatar Jun 05 '18 04:06 codeout

Hi, could you tell us for the progress please ? I'm trying generate json file from multiple devices files by show lldp neighbors. However, it is really tough work to merge the file, because I have to check the hostname and port for each entry to merge.

ex) SwitchA.lldp.json

{
  "ge-0/0/0": [
    {
      "hostname": "SwithB",
      "port": "ge-0/0/0.0"
    }
  ],
  "ge-0/0/1": [
    {
      "hostname": "SwithC",
      "port": "ge-0/0/1"
    }
  ]
}

SwitchB.lldp

{
  "ge-0/0/0": [
    {
      "hostname": "SwithA",
      "port": "ge-0/0/0"
    }
  ],
  "ge-0/0/1": [
    {
      "hostname": "SwithD",
      "port": "ge-0/0/1"
    }
  ]
}

Expected.json

{
  "nodes": [
    {
      "name": "SwithA",
      "icon": "./images/switch.png"
    },
    {
      "name": "SwithB",
      "icon": "./images/switch.png"
    },
    {
      "name": "SwithC",
      "icon": "./images/switch.png"
    },
    {
      "name": "SwithD",
      "icon": "./images/switch.png"
    }
  ],
  "links": [
    {
      "source": "SwitchA",
      "target": "SwitchB",
      "meta": {
        "interface": {
          "source": "ge-0/0/0",
          "target": "ge-0/0/0"
        }
      }
    },
    {
      "source": "SwitchA",
      "target": "SwitchC",
      "meta": {
        "interface": {
          "source": "ge-0/0/1",
          "target": "ge-0/0/1"
        }
      }
    },
    {
      "source": "SwitchB",
      "target": "SwitchD",
      "meta": {
        "interface": {
          "source": "ge-0/0/1",
          "target": "ge-0/0/1"
        }
      }
    }
  ]
}

If it is hard to update the feature, I make the code to merge multiple files.

Best regards,

ainamori avatar Feb 05 '21 14:02 ainamori

Sorry for my late reply. It's almost done implementing arrow style lines, I still need to do:

  • Make the code pluggable
  • Adjust arrowhead position
  • LAG support - much complicated to draw two arrows on each LAG member

https://user-images.githubusercontent.com/921696/107654656-3432c900-6cc6-11eb-89e7-b036fb5bef41.mov

codeout avatar Feb 11 '21 15:02 codeout

Hi @evgarik @ainamori, This took a long time but I finished rearranging my code as a plugin.

image

See https://github.com/codeout/inet-henge/tree/master/plugins/arrows_link for details.

codeout avatar Sep 27 '21 06:09 codeout