Expiration bundle deletes too early?

90 views
Skip to first unread message

Daniel Lidström

unread,
Jul 14, 2012, 10:37:15 AM7/14/12
to rav...@googlegroups.com
Hello

Check out this query to the expiration bundle index:

http://localhost:8081/indexes/Raven/DocumentsByExpirationDate?query=Expiry%253A%255B*%2520TO%252020120714142000%255D&start=0&pageSize=30&aggregation=None&noCache=2121082165;

The query is Expiry:[* TO 20120714142000]. The result of the query can be seen below:

{
    "IdsToInclude": [],
    "Results": [{
        "ApplicationName": "Snittlistan",
        "Created": "2012-07-14T14:27:31.9505674Z"
,
        "Expires": "2012-08-13T14:27:35.1347495Z",
        "LockDate": "2012-07-14T14:27:34.8857352Z",
        "LockId": 4,
        "Locked": false,
        "SessionItems": "",
        "Flags": "None",
        "@metadata": {
            "Raven-Entity-Name": "SessionStates",
            "Raven-Expiration-Date": "2012-08-13T14:27:35.1347495Z",
            "Raven-Clr-Type": "Snittlistan.Infrastructure.SessionProvider.SessionState, Snittlistan",
            "Last-Modified": "2012-07-14T14:27:35.1550000",
            "Non-Authoritative-Information": false,
            "@id": "l5w10ni0oozab03fj1yv3cxe",
            "Temp-Index-Score": 1.0,
            "@etag": "00000000-0000-1900-0000-0000000000c5"
        }
    }],
    "Includes": [],
    "IsStale": false,
    "IndexTimestamp": "2012-07-14T14:27:35.1550000",
    "TotalResults": 1,
    "SkippedResults": 0,
    "IndexName": "Raven/DocumentsByExpirationDate",
    "IndexEtag": "00000000-0000-1900-0000-0000000000c5",
    "ResultEtag": "9c400c47-1c99-2387-d4aa-cf4adda2de6f",
    "NonAuthoritativeInformation": false
}

Apparently this query by the expiration bundle finds an entity that should expire in 30 days, and subsequently deletes it.
What's going on here? I am using unstable 2033.

/Daniel

Oren Eini (Ayende Rahien)

unread,
Jul 15, 2012, 3:56:33 AM7/15/12
to rav...@googlegroups.com
Can you reproduce this?

Daniel Lidström

unread,
Jul 15, 2012, 6:55:46 AM7/15/12
to rav...@googlegroups.com
Here's a repro. I am using unstable 2033 and I've put the expiry bundle in Server/Plugins. The attached program shows that the document is deleted when the expiry bundle is activated. The output is this:

2012-07-15 12:25:21: Found document SessionStates/1
2012-07-15 12:25:41: Found document SessionStates/1
2012-07-15 12:26:01: Found document SessionStates/1
2012-07-15 12:26:21: Found document SessionStates/1
2012-07-15 12:26:41: Found document SessionStates/1
2012-07-15 12:27:01: Found document SessionStates/1
2012-07-15 12:27:21: Found document SessionStates/1
2012-07-15 12:27:41: Found document SessionStates/1
2012-07-15 12:28:01: Found document SessionStates/1
2012-07-15 12:28:21: Found document SessionStates/1
2012-07-15 12:28:41: Found document SessionStates/1
2012-07-15 12:29:01: Found document SessionStates/1
2012-07-15 12:29:21: Found document SessionStates/1
2012-07-15 12:29:41: Found document SessionStates/1
2012-07-15 12:30:01: Found document SessionStates/1
Document deleted early!

/Daniel

2012/7/15 Oren Eini (Ayende Rahien) <aye...@ayende.com>



--
Daniel
2012-07-15.log
Program.cs

Oren Eini (Ayende Rahien)

unread,
Jul 15, 2012, 8:40:47 AM7/15/12
to rav...@googlegroups.com
Hi,
Reproduced, I think the reason is that we didn't update the expiration bundle to support the new index date time format. 
Checking now and a fix will be in the next build

Daniel Lidström

unread,
Jul 15, 2012, 11:24:27 AM7/15/12
to rav...@googlegroups.com
Ok, thanks
--
Daniel
Reply all
Reply to author
Forward
0 new messages