Closed Bug 1130452 Opened 9 years ago Closed 9 years ago

remove Service Worker Cache "prefixMatch" option

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla39
Tracking Status
firefox39 --- fixed

People

(Reporter: bkelly, Assigned: ehsan.akhgari)

References

(Blocks 1 open bug, )

Details

Attachments

(1 file)

See:

  https://github.com/slightlyoff/ServiceWorker/issues/617

Implementing prefixMatch is hard to do efficiently without indexing a potentially large TEXT column in the sqlite database.  Its even harder when you throw in ignoreSearch.

The blink team agrees (and they haven't implemented it yet), so everyone seems in favor of simplifying and removing prefixMatch.
Blocks: 1110458
Assignee: nobody → ehsan
Requesting review from baku on the WebIDL change.
Attachment #8573537 - Flags: review?(bkelly)
(Note that I didn't change the schema to avoid stepping on Ben's toes.)
Comment on attachment 8573537 [details] [diff] [review]
Remove support for the prefixMatch option in the service worker cache code

Review of attachment 8573537 [details] [diff] [review]:
-----------------------------------------------------------------

Wow, I could have sworn I had a test that used prefixMatch.  But I guess I don't. :-\

> (Note that I didn't change the schema to avoid stepping on Ben's toes.)

Yea, before we remove the URL indices I need to write code to hash the URL for exact matching.  That's going to be a ton easier with prefix matching removed.

Thanks for doing this.
Attachment #8573537 - Flags: review?(bkelly) → review+
Attachment #8573537 - Flags: review?(amarchesini)
Comment on attachment 8573537 [details] [diff] [review]
Remove support for the prefixMatch option in the service worker cache code

Review of attachment 8573537 [details] [diff] [review]:
-----------------------------------------------------------------

::: dom/cache/DBSchema.cpp
@@ +676,5 @@
>      urlToMatch = aRequest.url();
>      query.AppendLiteral("request_url");
>    }
>  
> +  query.AppendLiteral(" =?2 GROUP BY entries.id ORDER BY entries.id;");

extra space before '='
Attachment #8573537 - Flags: review?(amarchesini) → review+
https://hg.mozilla.org/mozilla-central/rev/43d4db7da2d6
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: