-
gsvelto
julienw_afk, ping
-
julienw
hey gsvelto
-
gsvelto
julienw, hey
-
gsvelto
julienw, so I was thinking, for the sake of this FxOS-lite project
-
gsvelto
julienw, why don't we have a look at migrating the SMS database do IDB in the next few weeks so we get rid of a nasty dependency?
-
gsvelto
I know this is not a priority but it's been on our list for so long
-
gsvelto
and now we don't really care if the work's not perfect (i.e. doesn't startup as fast, etc...)
-
gsvelto
we just want to not depend on the current in-gecko database
-
gsvelto
(nevermind the contacts, I'm not sure how we'll solve that one yet)
-
julienw
my main issue is that we need to improve the API to make sure the DB is consistent :/
-
julienw
we'll also need the API to be able to migrate BTW
-
gsvelto
julienw, yeah, my idea about that is to have a process that syncs the DB with the results from the API, with the DB acting as some sort of cache
-
gsvelto
so we read it first, then sync with the API
-
gsvelto
once the API is gone we'll just use the DB
-
gsvelto
but I wanted to know if you want to spend some time on it (reviewing, etc...) before writing any code
-
gsvelto
personally I'd be really happy if some of our core apps are kept alive in an almost web-compatible way
-
julienw
I'm all for that, but please think through all cases, especially look at some etherpads we created in the past. it's not _that_ easy...
-
julienw
think what happens when we receive a messgae for example
-
gsvelto
I know it's not easy and the biggest issue is synchronization
-
julienw
(and consider the app can be killed between receiving the system message and saving the new message to the db)
-
gsvelto
yep
-
gsvelto
we'll have to cut some corners IMHO
-
julienw
that's why we designed the APIv2
-
gsvelto
but if there's a chance we keep the app around and maybe even evolve the gecko API (though in a different context) that's it
-
julienw
in the past
-
julienw
<gsvelto> we'll have to cut some corners IMHO <= but resulting to data loss ?
-
gsvelto
we're facing data-loss anyway
-
gsvelto
IMHO the biggest issue would be with the following scenario
-
gsvelto
app is not launched
-
gsvelto
and it has not yet populated the database
-
gsvelto
a message arrives, the app is launched and starts populating the database
-
gsvelto
another message arrives while we're still iterating over existing data
-
gsvelto
-> we lose the incoming message / end up in an inconsistent state
-
julienw
not sure I get you here :)
-
gsvelto
I think that's the biggest issue
-
gsvelto
<gsvelto> but if there's a chance we keep the app around and maybe even evolve the gecko API (though in a different context) that's it
-
gsvelto
sorry, ctrl-V accidentally
-
julienw
an incoming message yields an event on mozMobileMessage
-
julienw
so...
-
julienw
we'd have it here
-
julienw
:)
-
julienw
-
firebot
Bug 898364 — NEW, nobody⊙mo — [Messages] Implement a Database inside Gaia to hold messages and threads information
-
gsvelto
yeah but we have to make our read-from-the-API-and-write-to-the-database logic aware of that
-
julienw
there is especially some code from me in Gaia
-
julienw
(not ready at all)
-
gsvelto
starting point :)
-
julienw
I was experimenting around a nice API
-
julienw
but was not really satisfied yet
-
julienw
there is a dependency to the API change
-
gsvelto
understood
-
gsvelto
well, I'll see what can be done in the current scenario
-
gsvelto
and if it's feasible
-
julienw
all I'm saying is that it's not an easy task at all
-
julienw
and you'll need to consider whether it's worth it
-
julienw
that's my biggest concern ...
-
gsvelto
yeah
-
julienw
what we wanted is a transaction manager in the mozAPI
-
julienw
so that gaia can tell the API "ack, I wrote down this information"
-
julienw
otherwise the API would send it back the next time gaia asks
-
julienw
francisco, BTW, will we disable rich paste then ?
-
francisco
julienw: don't know, wish we could have disable it by app
-
julienw
I don't think we can
-
julienw
(and honestly I don't think 2.6 will ever ship so we can just disable it completely)
-
julienw
(yeah I'm depressed today :p)