[Ns-developers] Learning Bridge has been merged

Gustavo Carneiro gjcarneiro at gmail.com
Mon Jul 21 08:32:05 PDT 2008


2008/7/21 Mathieu Lacage <mathieu.lacage at sophia.inria.fr>:

> hi gustavo,
>
> On Fri, 2008-07-18 at 12:15 +0100, Gustavo Carneiro wrote:
> > I have pushed the learning bridge code into ns-3-dev, since no more
> comments
> > were received (yes, I know mathieu is away... :)
>
> a couple of comments:
>
> 1) tom and I suggested that you do not keep
> NetDevice::SupportsPromiscuous. Please remove it. See:
> http://mailman.isi.edu/pipermail/ns-developers/2008-July/004386.html


I did that following Craig's suggestion from
http://mailman.isi.edu/pipermail/ns-developers/2008-July/004470.html

>From Craig's email:

"""There's the question of how to "turn on" the promiscuous callback.  There
should probably be a test for promiscuity in the net device
(HasPromiscuous?) since some devices won't have a meaningful concept of
promiscuous mode nor the callback."""


> In the future, please, please, either challenge the review suggestions
> or follow them: it's really a waste of time for me to check for
> conformance with previous review suggestions.


I was told that Craig was taking care of review in this area.  I am sorry
but I can't follow different reviewers with different opinions.  If I did
that I would never get anything done.


>
>
> 2) I would really appreciate that you make all new methods in NetDevice
> pure virtual rather than just virtual. We have been consistently moving
> towards this in the NetDevice class over the past couple of changes made
> to it so, I would like to try to stick to this. For Wifi, you can just
> stub the methods and I will implement them myself.


Can you tell me _one_ reason why this would be a good idea?  Because I can
give at least two reasons why this way is better:

1. Clearly not all NetDevices have to support promiscuous mode, and for this
that do not support it, it is pointless to implement those methods;

2. Pure virtual breaks the NetDevice API, and for no apparent reason.  This
when I usually say something about gratuitous API breaks...   You should be
happy that the Node protocol handlers API has already been broken, for the
sake of API cleanliness; isn't it enough?

Regards.

-- 
Gustavo J. A. M. Carneiro
INESC Porto, Telecommunications and Multimedia Unit
"The universe is always one step beyond logic." -- Frank Herbert


More information about the Ns-developers mailing list