Check DB schema version on startup
Upgrade DB schema
Add README for DB schema versioning
DB cleanup at startup
Populate in_reply_to column when inserting new items
Don't write subscription stanzas in items table
Fix updating items
Temporary subscriptions

Based on previous code by Denis Washington.

This makes it possible to have temporary subscriptions as specified by XEP 0060
§12.4. Temporary subscriptions are notified to other servers by adding a
"temporary='1'" attribute to subscription notifications. Temporary subscriptions
to private nodes are not allowed, and they are not included in the results of
subscriptions/affiliations queries.
Claim we support subscription options
Cleanup offline users
Only send notifications about temporary subscriptions to remote listeners
Client and server must speak the same language
Don't send any notification for temporary subscriptions

Notification (<message><event/></message>) are pointless for temporary
subscriptions: clients already get an iq answer from their inbox server, and
servers from remote services.

This partially reverts e84c3845 and fully reverts c2bef5df, and that's good news
for my mental health :)
Don't delete temporary subscriptions during sync

If picard@enterprise.sf does a temporary subscription to sisko@ds9.sf and is the
first user from enterprise.sf to do so, enterprise.sf will start syncing
sisko@ds9.sf locally. During this process it will delete all subscriptions and
replace them by those exposed by ds9.sf. But this doesn't include temporary
subscriptions.

This commit fixes this by not removing temporary subscriptions during sync.
I'm dumb
Offline user cleanup: do real unsubscribe operations

Making a remote server remove a subscription with a simple PubSub event doesn't
feel right, a real <unsubscribe/> is better. And this works both for remote and
local subscriptions.
Don't notify unsubscribe when it was a temporary subscription
Make server features discoverable
Client can check for server features before sending an IQ
Check if remote supports temporary subscription before sending a tempsub request

This avoids temporary subscription requests from new servers being considered as
normal subscriptions by old servers.