On Wed, Jul 10, 2013 at 04:30:42PM +0200, Ján Máté wrote:
Okej, now I understand but this idea is VERY crazy, because the client can open a contact ONLY after performs full sync with the server. So in reality it can take lot of seconds - for example if you have 1000 contacts, then it loads all of them and only then opens the "selected" contact from the URL. Another problem is, that if you click to second "contact URL" then the browser will RELOAD the whole software, re-syncs all contacts and only then opens the second contact.
but it wouldn't take longer than opening caldavmate directly, would it? (as it would happen with a "see it's a contact" / "open carddavmate" / "look it up there" workflow)
enhancements in caching could reduce that time, but for the time being, loading the complete calendar would be completely acceptable in my setup.
As you see the login name is REALLY required in the UID because it must be globally unique. Heuristic search on the UID value is VERY bad idea, because it requires sequential search and for performance reason I use hash - the key is the UID and the value is the destination object.
it would be possible to work with a complete url too. (for the time being, there could be a generic "web-access" user.) if the base hook is implemented, i might be able to use it as a starting point and experiment with optimizations that would work without sequential search.
(my javascript is a little rusty, especially when it comes to interfacing with the web browser part, but when it comes to algorithms, it's just another programming language.)
best regards chrysn