Closed mdlnr closed 9 years ago
Any chance of seeing this merged?
:+1:
An update to the UADetectorServiceFactory with the option to set the access key (or all 3 urls) or point to a local version of the database (so people can use the free version) would be good since that's the documented way of using this library.
I thought the old and new XML database are compatible but since the DTD changed there are obviously not. When creating a CachingXmlDataStore I am getting an error when using the new udger xml in combination with the bundled old version as fallback. Error: unable to resolve remote entity, systemId = http://user-agent-string.info/rpc/uasxmldata.dtd So, one also has to create a new fallback using the new xml and here then also use http://data.udger.com/uasxmldata_old.dtd and not DEFAULT_DATA_DEF_URL as defined in DataStore.
@HaraldWalker How sad. I don't know how we should proceed with this library without a free database. I'm not very interested in the udger.com offering.
I completely understand. But a lot of projects use this library and those are now stranded. Would be good to get a least one version out that can work with udger.com. I just got it working by using tjacoby's branch and a special UdgerUADetectorServiceFactory. I could try to make a generic version of that and contribute it. But we still have the code formatting issue and various failing unit tests.
what about the suggestion in #96 to use http://browscap.org/ data. it would require a new service factory (?) though.
@jgangemi because the domain model of UADetector is bound tightly to the database of user-agent-string.info/udger. We are not completely dependent on the regex database of udget.com but any alternative would have to follow the same structure in the data model to be compatible.
@HaraldWalker Could you provide a Pull Request with all necessary changes? I would go through the broken test cases then and fix them.
@before I will try to find some time for that.
Not sure we need this pull request. The old DTD is invalid anyhow and don't think the user really needs to be able to provide the url for the DTD. Since we are bound tightly to the structure of the user-agent database, any database should follow the uasxmldata_old definition. So we can just use http://data.udger.com/uasxmldata_old.dtd as the new default value of DEFAULT_DATA_DEF_URL and then make the bundled old uas.xml compatible by changing it's DTD reference.
André Rouél » uadetector #215 FAILURE Looks like there's a problem with this pull request (what's this?)