Please provide created_since_date in getPublishedSources

Bug #372270 reported by James Westby
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
High
Celso Providelo

Bug Description

Hi,

published_since_date is great for watching for changes in Ubuntu, but
it doesn't work for Debian as the records aren't published there.

Therefore a pending_since_date would be great for that, so I can at least
get notifications of changes, even if I have to work harder to obtain the
current state.

Thanks,

James

Tags: api lp-soyuz
Revision history for this message
Celso Providelo (cprov) wrote :

Hi James,

We know that the publishing status change in a single direction (pending, published, superseded/deleted then removed) and there is no way a pending publication will not become published in specific period of time (1 hour for PRIMARY, 20 minutes for PPAs).

So, my proposal is to replace the current 'published_since_date' by your suggested 'pending_since_date' and for callsites specifically interested in the instant a publication was available in pool/ further inspection on 'status' and 'date_published' still possible.

Changed in soyuz:
importance: Undecided → High
milestone: none → pending
status: New → Incomplete
Revision history for this message
James Westby (james-w) wrote : Re: [Bug 372270] Re: Please provide pending_since_date in getPublishedSources

On Wed, 2009-05-06 at 09:16 +0000, Celso Providelo wrote:
> Hi James,
>
> We know that the publishing status change in a single direction
> (pending, published, superseded/deleted then removed) and there is no
> way a pending publication will not become published in specific period
> of time (1 hour for PRIMARY, 20 minutes for PPAs).
>
> So, my proposal is to replace the current 'published_since_date' by your
> suggested 'pending_since_date' and for callsites specifically interested
> in the instant a publication was available in pool/ further inspection
> on 'status' and 'date_published' still possible.

So my code that currently used published_since_date, but doesn't really
care about the dates, just wants new publications since the last run
would switch to pending_since_date as well and get the same effect?

Thanks,

James

Revision history for this message
Celso Providelo (cprov) wrote : Re: Please provide pending_since_date in getPublishedSources

Exactly, it would have the same effect, except by the time offset until the files are available in the pool/ (but I think you don't need that, do you ? you use librarian files, right ?).

Using 'pending_since_date' also means you can have the same lookup for ubuntu and debian (bonus!).

Revision history for this message
James Westby (james-w) wrote : Re: [Bug 372270] Re: Please provide pending_since_date in getPublishedSources

On Wed, 2009-05-06 at 10:09 +0000, Celso Providelo wrote:
> Exactly, it would have the same effect, except by the time offset until
> the files are available in the pool/ (but I think you don't need that,
> do you ? you use librarian files, right ?).

Yeah, that would be fine.

It would also mean that the packages are available in bzr long before
being on the mirrors :-)

> Using 'pending_since_date' also means you can have the same lookup for
> ubuntu and debian (bonus!).

That will be a bonus.

Thanks,

James

Revision history for this message
Celso Providelo (cprov) wrote : Re: Please provide pending_since_date in getPublishedSources

Okay, let's do this.

Changed in soyuz:
assignee: nobody → Celso Providelo (cprov)
milestone: pending → 2.2.5
status: Incomplete → Triaged
Celso Providelo (cprov)
Changed in soyuz:
status: Triaged → In Progress
Revision history for this message
Julian Edwards (julian-edwards) wrote : Re: [Bug 372270] Re: Please provide pending_since_date in getPublishedSources

Wait a minute. What about including the pending state in the existing
published_since_date query? I'm not sure I like pending_since_date, it
doesn't make any sense outside of our unpublished Debian imports.

Revision history for this message
Celso Providelo (cprov) wrote : Re: Please provide pending_since_date in getPublishedSources

It doesn't make much sense to have 'both' filters, basically because there is no way that a just created publishing record will not be 'published' in a given interval (varies according the archive purpose, but that's constant).

For the readability, the argument is named 'created_since_date'.

'date_created' makes more sense than 'date_published' in absolutely all cases, because it doesn't include the intrinsic publication time offset, so sources uploads and copies will be identified immediately, instead of 'after one hour they were done'.

If a callsite wants to identify which records in a batch are already available in pool/ it can check their 'date_published' attribute, which is not more expensive than iterating over the elements, because the attribute is already serialized.

Revision history for this message
Julian Edwards (julian-edwards) wrote : Re: [Bug 372270] Re: Please provide pending_since_date in getPublishedSources

> For the readability, the argument is named 'created_since_date'.

That sounds much better.

Revision history for this message
Celso Providelo (cprov) wrote : Re: Please provide pending_since_date in getPublishedSources

r8350 (stable)

Changed in soyuz:
status: In Progress → Fix Committed
summary: - Please provide pending_since_date in getPublishedSources
+ Please provide created_since_date in getPublishedSources
Celso Providelo (cprov)
Changed in soyuz:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.