<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<div>Yeah, the “legacy” thought is what’s making me second guess the effort. We’re still in limbo with the language focus, IMO.</div>
<div><br>
</div>
<div>Are we nearing a change in routing? I remember work being demo’d at the last summit, but I haven’t seen any of it since.</div>
<div><br>
</div>
<span id="OLK_SRC_BODY_SECTION">
<div style="font-family:Calibri; font-size:11pt; text-align:left; color:black; BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0in; PADDING-LEFT: 0in; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<span style="font-weight:bold">From: </span>Richard Jones <<a href="mailto:r1chardj0n3s@gmail.com">r1chardj0n3s@gmail.com</a>><br>
<span style="font-weight:bold">Reply-To: </span>"OpenStack Development Mailing List (not for usage questions)" <<a href="mailto:openstack-dev@lists.openstack.org">openstack-dev@lists.openstack.org</a>><br>
<span style="font-weight:bold">Date: </span>Wednesday, 2 September 2015 00:32<br>
<span style="font-weight:bold">To: </span>"OpenStack Development Mailing List (not for usage questions)" <<a href="mailto:openstack-dev@lists.openstack.org">openstack-dev@lists.openstack.org</a>><br>
<span style="font-weight:bold">Subject: </span>Re: [openstack-dev] [horizon] URL Sanity<br>
</div>
<div><br>
</div>
<div>
<div>
<div dir="ltr">Interesting idea, and in general I'm for consistency. I can't speak directly to the network/port question, though it seems to me that if ports must be attached to networks then it makes sense for the URL to reflect that.
<div><br>
</div>
<div>On the other hand, some could argue that the django URL routing is ... legacy ... and shouldn't me messed with :)</div>
<div><br>
</div>
<div>On the gripping hand, thinking about this could inform future angular routing planning...</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On 2 September 2015 at 00:39, Rob Cresswell (rcresswe) <span dir="ltr">
<<a href="mailto:rcresswe@cisco.com" target="_blank">rcresswe@cisco.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div>Hi all,</div>
<div><br>
</div>
<div>I recently started looking into properly implementing breadcrumbs to make navigation clearer, especially around nested resources (Subnets Detail page, for example). The idea is to use the request.path to form a logical breadcrumb that isn’t dependent on
 browser history ( <a href="https://review.openstack.org/#/c/129985/3/horizon/browsers/breadcrumb.py" target="_blank">https://review.openstack.org/#/c/129985/3/horizon/browsers/breadcrumb.py</a> ). Unfortunately, this breaks down quite quickly because we use
 odd patterns like `<resources>/<resource_id>/detail`, and `<resources>/<resource_id>` doesn’t exist.</div>
<div><br>
</div>
<div>This made me realise how much of an inconsistent mess the URL patterns are.  I’ve started cleaning them up, so we move from these patterns:</div>
<div><br>
</div>
<div>`/admin/networks/<network_id>/detail` - Detail page for a Network</div>
<div>`/admin/networks/<network_id>/addsubnet` - Create page for a Subnet</div>
<div><br>
</div>
<div>To patterns in line with usual CRUD usages, such as:</div>
<div><br>
</div>
<div>`/admin/networks/<network_id>` - Detail page for a Network</div>
<div>`/admin/networks/<network_id>/subnets/create` - Create page for a Subnet</div>
<div><br>
</div>
<div>This is mostly trivial, just removing extraneous words and adding consistency, with end goal being every panel following patterns like:</div>
<div><br>
</div>
<div>`/<resources>` - Index page</div>
<div>`/<resources>/<resource_id>` - Detail page for a single resource</div>
<div>`/<resources>/create` - Create new resource</div>
<div>`/<resources>/<resource_id>/update` - Update a resource </div>
<div><br>
</div>
<div>This gets a little complex around nested items. Should a Port for example, which has a unique ID, be reachable in Horizon by just its ID? Ports must always be attached to a network as I understand it. There are multiple ways to express this:</div>
<div><br>
</div>
<div>`/networks/ports/<port_id>` - Current implementation</div>
<div>`/networks/<network_id>/ports/<port_id>` - My preferred structure</div>
<div>`/ports/<port_id>` - Another option</div>
<div><br>
</div>
<div>Does anyone have any opinions on how to handle this structuring, or if it’s even necessary?</div>
<div><br>
</div>
<div>Regards,</div>
<div>Rob</div>
</div>
<br>
__________________________________________________________________________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" target="_blank">
OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
<br>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</span>
</body>
</html>