* Barbara.Lundquist at Sun.COM <Barbara.Lundquist at Sun.COM> [2008-09-04 
20:23]:
> On 09/04/08 12:14, Stephen Hahn wrote:
> >  * [1]Barbara.Lundquist at sun.com [2]<Barbara.Lundquist at sun.com> 
> > [2008-09-04 18:57]:
> > > 
> > >  In this line from a sample Distro Constructor manifest, is this
> > >  URL a repository or is this URL an authority. Is there a
> > >  difference?
> > > 
> > >  <pkg_repo_default_authority>
> > >  <main url=[3]"http://indiana-build.central:10000";
> > >      authname="example.com"/>
> > >  <mirror url="" authname=""/>
> > >  </pkg_repo_default_authority>
> > > 
> > >  I'm still struggling to differentiate between a repository and an
> > >  authority.
> > 
> > 
> >    In the above example, the authority is "example.com", the
> >    packages from which are being served by the repository running at
> >    port 10000 on indiana-build.central.
> > 
> >    A book analogy might be that my copy of "The Elements of Style
> >    (illustrated)" was published by Penguin (authority) but was
> >    purchased from/shipped by Amazon (repository).
> 
>  I understand your book analogy below, but I am having trouble
>  applying that analogy to this statement from Glenn Lagasse, where
>  he's describing "default authority" and "default repository":
> 
>  Glenn states:
> >  "It's both in this instance.  You can have multiple repositories and only
> >  one default authority (which is the default repository to pull packages
> >  from).  If you only have one repository, then it's automatically the
> >  default authority."
> 
>  Can you help me extend your analogy to help understand the terms
>  "default authority" and "default repository"?

  Sure.  Let's say there's two publishers, Penguin and Puffin.  The
  example gets contrived, in that we'll pretend that I can only buy
  Penguin from Amazon and only Puffin from Borders.  If I say that
  Penguin is my *preferred* authority, then any order I might make for a
  book with some title would be looked up in Penguin's catalog first,
  and ordered from Amazon.  If Penguin doesn't have that title, I'll
  look in Puffin's--if they have it, then we'll order from Borders.

  If I have more than one non-preferred authority--if we had, say,
  Springer's catalog, then I would iterate through all those catalogs
  until giving up.

  The next step in the analogy is regarding mirrors:  I can order from
  Amazon, but my package contents could come from either their Fernley
  NV center, or the one in Kansas, or the one in Tennessee.  At present,
  we contact the *origin* repository for the package metadata (the
  "order"), but can contact any of the mirror repositories for contents.

  (There are a number of variant deployments that break or could break
  the analogy:  we could serve more than one authority from a single
  repository (which I suppose is more like the real world), we could use
  peer-to-peer transports or round-robin among mirrors--these are like
  asking different sites for individual book pages and stitching them
  together ourselves.  That's what pkg(1) already does with multiple
  mirrors, but that's not how I want my books to arrive.  :) )

  - Stephen

-- 
sch at sun.com  http://blogs.sun.com/sch/

Reply via email to