sfc-aqua / quisp

Open source implementation of quantum internet simulation package
BSD 3-Clause "New" or "Revised" License
89 stars 36 forks source link

Implement simple OSPF #526

Closed Tatzhiro closed 1 year ago

Tatzhiro commented 1 year ago

This change is Reviewable

Chibikuri commented 1 year ago

@Tatzhiro I'd like to apologize that the naming of components in QuISP is very confusing. I guess the right place you implement your code is not on Router.cc, but on RoutingDaemon... The Router under the common module is just receiving messages from outside and distributing them to components (and vice versa). Since the thing you're working on is more than that, your code should be working as a daemon process that communicates with other node and establish a topology map and so on.

Chibikuri commented 1 year ago

RoutingDaemon is the component responsible for generating, and updating the routing table. Router.cc could refer to the routing table existing in Routing Daemon, but Router is not the one that is responsible for routing table generation.

Chibikuri commented 1 year ago

Even before this pull request, Router.cc was generating routing table (I think for classical channels). RoutingDaemon also generates routing table, but it uses quantum channel information to build the table.

Reviewable status: 4 of 13 files reviewed, 4 unresolved discussions (waiting on @Chibikuri and @zigen)

_quisp/test_utils/Channel.cc line 8 at r6 (raw file):_

Previously, Chibikuri (Ryosuke Satoh (cocori)) wrote… That is correct.

@zigen @Naphann What do you think? Do we need classical OSPF here? My initial thought was routing cost was a link cost calculated by hardware monitor, but I might be wrong.

Chibikuri commented 1 year ago

One more point is that the classical path and quantum path must be the same in RuleSet scheme. So if we get different path in quantum and classical, it might be a problem in the simulation.

Naphann commented 1 year ago

@Chibikuri I haven't read the whole thread but as for the one you pinged.

The classical path and quantum path need not be the same. Each node needs to keep track of the next node in the quantum path and send the message to the correct node. So, classical and quantum can be different as long as the message is sent to the next quantum hop for the connection setup process to work.

As for the classical OSPF, I don't think we need it.

Chibikuri commented 1 year ago

@Tatzhiro What you can do is just moving your code to Routing daemon. Your implementation itself seems correct and it can be reused in quantum version by changing cost calculation (not claasical bandwidth but quantum link generation rate)