#184 ✓ resolved
Nick Legg

bric_soap media update sets the current time as the media's expire date

Reported by Nick Legg | June 25th, 2010 @ 01:02 PM | in 1.10.11

Calling bric_soap media update on an exported media asset without a set expire date causes an expire date of the current time to be added to the media, so Bricolage expires the asset immediately after the update.

Stories appear to behave as expected (no expire date is set unless you set one in the XML explicitly).

This behavior is observed in Bricolage 1.10.9

Comments and changes to this ticket

  • Nick Legg

    Nick Legg June 25th, 2010 @ 01:29 PM

    Update: I just set an expire date to a specific point in the future but bric_soap media update overwrote my expire date with a new expire date of the current timestamp anyway.

  • theory

    theory July 6th, 2010 @ 09:29 PM

    • Assigned user changed from “Bugs (at bricolage)” to “theory”
    • Milestone set to 1.10.11
    • State changed from “new” to “open”
    • Milestone order changed from “0” to “0”

    I am unable to replicate this issue. Can you confirm that the expire_date column is set when you do this?

  • theory

    theory July 6th, 2010 @ 09:32 PM

    If so, please also paste an example of all the SOAP command you're using to do this: the one to export and the one to update.

    Thanks,

    David

  • Nick Legg

    Nick Legg July 7th, 2010 @ 12:49 PM

    Before SOAP export:

    bric=> select media.id,current_version,publish_date,expire_date,active,uri from media,media_uri where media.id = media_uri.media__id and media_uri.uri like '%hamster%';                                                                             
      id   | current_version |    publish_date     | expire_date | active |                   uri                   
    -------+-----------------+---------------------+-------------+--------+-----------------------------------------
     46878 |              28 | 2010-07-06 19:29:46 |             | t      | /testpages/hamster%20on%20a%20piano.jpg
    

    SOAP export:

    /usr/local/bricolage/bin/bric_soap media export media_46878 > exported_media_46878.xml

    Exported file:

    See my attachment exported_media_46878.xml (no changes were made to the file between export and update)

    SOAP update:

    /usr/local/bricolage/bin/bric_soap media update exported_media_46878.xml

    After SOAP update:

    bric=> select media.id,current_version,publish_date,expire_date,active,uri from media,media_uri where media.id = media_uri.media__id and media_uri.uri like '%hamster%';
      id   | current_version |    publish_date     |     expire_date     | active |                   uri                   
    -------+-----------------+---------------------+---------------------+--------+-----------------------------------------
     46878 |              29 | 2010-07-07 12:40:21 | 2010-07-07 12:40:21 | t      | /testpages/hamster%20on%20a%20piano.jpg
    
  • theory

    theory July 7th, 2010 @ 07:52 PM

    • State changed from “open” to “resolved”

    Thanks. Was able to replicate it by enabling EXPIRE_ON_DEACTIVATE, which is a 2.0 feature (backported to your install). Not sure why it wasn't happening to you for stories, as the code is the same. Anyway, fixed in 317a77e and backported to 2.0 in 0b6ef0e and to 1.10 in 94ee125.

    Thanks!

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

People watching this ticket

Attachments

Pages