<div dir="ltr">Hi Aaron,<br><br>I appreciate your reply.<br><br>Here is some more details on what I'm trying to do:<br>I need to add new attribute to the network resource using extensions (i.e. network config profile) and use it in the mechanism driver (in the create_network_precommit/postcommit).<br>

If I use current implementation of Ml2Plugin, when a call is made to mechanism driver's create_network_precommit/postcommit the new attribute is not included in the 'mech_context'<br>Here is code from Ml2Plugin:<br>

<font face="courier new, monospace">class Ml2Plugin(...):<br>...<br>       def create_network(self, context, network):<br>            net_data = network['network']<br>...</font><div><div>  <font face="courier new, monospace">      with session.begin(subtransactions=True):</font></div>

<div><font face="courier new, monospace">            self._ensure_default_security_group(context, tenant_id)</font></div><div><font face="courier new, monospace">            result = super(Ml2Plugin, self).create_network(context, network)</font></div>

<div><font face="courier new, monospace">            network_id = result['id']</font></div><div><font face="courier new, monospace">...</font></div><font face="courier new, monospace">            mech_context = driver_context.NetworkContext(self, context, result)<br>

            self.mechanism_manager.create_network_precommit(mech_context)<br></font><br></div><div class="gmail_extra">Also need to include new extension in the  <span style="font-family:Courier;font-size:14px">_supported_extension_aliases.</span><br>

<br>So to avoid changes in the existing code, I was going to create my own plugin (which will be very similar to Ml2Plugin) and use it as core_plugin.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Please advise the right solution implementing that.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">Regards,</div><div class="gmail_extra">Nader.</div><div class="gmail_extra"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 5, 2014 at 11:49 PM, Aaron Rosen <span dir="ltr"><<a href="mailto:aaronorosen@gmail.com" target="_blank">aaronorosen@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">Hi Nader, <div><br>Devstack's default plugin is ML2. Usually you wouldn't 'inherit' one plugin in another. I'm guessing  you probably wire a driver that ML2 can use though it's hard to tell from the information you've provided what you're trying to do. </div>


<div><br></div><div>Best, </div><div><br>Aaron</div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div>On Wed, Mar 5, 2014 at 10:42 PM, Nader Lahouti <span dir="ltr"><<a href="mailto:nader.lahouti@gmail.com" target="_blank">nader.lahouti@gmail.com</a>></span> wrote:<br>


</div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div><div dir="ltr"><font color="#000000" face="Courier, sans-serif"><span style="font-size:14px">Hi All,</span></font><br>

<div>
<br></div><div><span style="font-size:14px;font-family:Courier,sans-serif">I have a question regarding ML2 plugin in neutron: </span></div>
<div><span style="font-size:14px;font-family:Courier,sans-serif">My understanding is that, 'Ml2Plugin' is the default core_plugin for neutron ML2. We can use either the default plugin or our own plugin (i.e. my_ml2_core_plugin that can be inherited from Ml2Plugin) and use it as core_plugin.</span></div>



<div><br></div><div><font color="#000000" face="Courier, sans-serif"><span style="font-size:14px">Is my understanding correct?</span></font></div><div><font color="#000000" face="Courier, sans-serif"><span style="font-size:14px"><br>



</span></font></div><div><font color="#000000" face="Courier, sans-serif"><span style="font-size:14px"><br></span></font></div><div><font color="#000000" face="Courier, sans-serif"><span style="font-size:14px">Regards,</span></font></div>



<div><font color="#000000" face="Courier, sans-serif"><span style="font-size:14px">Nader.</span></font></div></div>
<br></div></div>_______________________________________________<br>
OpenStack-dev mailing list<br>
<a href="mailto:OpenStack-dev@lists.openstack.org" target="_blank">OpenStack-dev@lists.openstack.org</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
OpenStack-dev mailing list<br>
<a href="mailto:OpenStack-dev@lists.openstack.org" target="_blank">OpenStack-dev@lists.openstack.org</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
<br></blockquote></div><br></div></div>