<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
On 08/13/2012 11:05 AM, Dmitri Dolguikh wrote:
<blockquote cite="mid:502917A3.6050905@redhat.com" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
Could a couple of folks on Katello team spend an hour or so and
take a look at the architectural changes I propose in
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<a moz-do-not-send="true"
href="https://www.redhat.com/archives/katello-devel/2012-August/msg00102.html">https://www.redhat.com/archives/katello-devel/2012-August/msg00102.html</a>?<br>
<br>
<br>
Much appreciated,<br>
-d<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
katello-devel mailing list
<a class="moz-txt-link-abbreviated" href="mailto:katello-devel@redhat.com">katello-devel@redhat.com</a>
<a class="moz-txt-link-freetext" href="https://www.redhat.com/mailman/listinfo/katello-devel">https://www.redhat.com/mailman/listinfo/katello-devel</a></pre>
</blockquote>
<br>
A couple of thoughts. As we discussed previously productContent
does not have a 1-1 mapping to a pulp repo, so with that in mind:<br>
<br>
1. Pulp::Repos is a module made up of product and content related
items in relation to pulp. I understand that product may not be the
best fit for this, however sticking it within repo really isn't
either (I would be 100% against this). Potentially breaking it up
into product related items and product content related items would
make the most sense.<br>
<br>
2. I don't see how repositories are tied to environments in this
diagram. How would i go about getting all the repositories for a
product within an environment? <br>
<br>
3. Data level organization is great and all, but if the code isn't
more readable (or at least isn't less readable) its all for
nothing. Its been my experience that rarely within the code do we
need all the repos for a product content within an environment (I
don''t know that i've ever needed that information). This is how
you've proposed to organize the data however. So if i have to do
something like my_product.product_content.collect{|pc|
pc.repositories}.flatten in order to get the list of repos in a
product, it would not be worth it. I believe the current structure
came out of the lack of a need for product content within katello
itself (as a user facing object). Try to keep the scopes within
product as they are today as much as possible. (i.e. I should still
be able to do my_product.repos(my_environment) as that is much
nicer :} ). I understand that candlepin relies on product content
for lots of things, but katello itself really doesn't care about
product content. I'm hesitant to make it a first class model
citizen in katello as it could make a lot of code more complicated,
but as long as that's kept to a minimum, I'm ok with it.<br>
<br>
I would say as part of this if you find yourself replacing lots of
db queries/AR lookups with longer statements, step back and ask
yourself how to simplify it.<br>
<br>
4. I would like to see a new proposed diagram with some of these
concerns (#1 & #2 & the fact that productContent and repos
are not 1-1 mapped) addressed.<br>
<br>
Thanks,<br>
<br>
-Justin<br>
<br>
<br>
</body>
</html>