WURFL and SSDS, part I
Saturday, June 28th, 2008
A friend of mine asked me for some help on mobile device detection. He introduced me to WURFL, a giant database contains mobile devices information in xml format, in a single file.
First thought came to mind was: how do I store this thing in a database? I Googled around, found a couple of .NET libraries working against WURFL, but they all directly working against the xml. Queries are done against memory objects.
To store this thing in SQL 2005, would need to define a schema, too much work.
I just got access to the SSDS beta, what a perfect match:
- No need to define any schema.
- WURFL would be an Authority.
- Devices would be the container.
- Each device would be an Entity in the Devices container.
- device_Id will be the entityId
- device.Properties will hold the user_agent, fallback_id, and all the capabilities.
Within 30 minutes, I whipped up a console application, parsed the 8MB xml, and stored all the 5755 devices into SSDS.
Next, I will write a web service to query the data.
This entry is filed under .NET, Mobile, SOA, SSDS. You can follow any responses to this entry through the RSS 2.0 feed.You can leave a response, or trackback from your own site.