Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [dtp-dev] Integration of "Work Offline" Connection State

> I've finally integrated a "work offline" connection state into the
> connection profile framework.  I've attached a patch with the changes to
> the BZ (
> Still to do:
> Add actions for "save offline" and "work offline"
> Update connected check in extension point filters to use the "connected"
> state
> as opposed to using a boolean state.
> Migrate the SQL model connection factory (ConnectionInfo) to the new
> framework.
> I should have the remaining work completed tomorrow (Thursday at the
> latest).
> Please review the patch for any potential impacts (since some of these
> changes do affect API, in an additive way).

I've completed the remaining items (listed above) and have updated the
patch file attached to the BZ entry.  I made one small change to the new
API that was included in the original patch.

The functionality is implemented in such a way that existing consumers
should not be impacted.  The deprecated IConnectionProfile.isConnected()
method will return true only if the profile is in a "connected" state.  If
the profile is in a "working offline" state, it will return false.  To
integrate your code with any profiles that provide "offline" capabilities,
you will need to use the new IConnectionProfile.getConnectionState()
method.  Currently, this is only applicable to consumers of ConnectionInfo
(the SQL model) as it is the only connection that supports offline

Offline connections can only be acquired through managed connections on the
connection profile (IConnectionProfile.getManagedConnection()).  Because of
this, offline connections are singletons.

A connection profile can be moved into an offline state from either a
connected or disconnected state.  Likewise, a profile can be moved into a
connected state from either a disconnected or offline state.  And...a
profile can be moved into a disconnected state from either an offline state
or a connected state.

I'd like to check this in early next week (after the RC0 build), barring
any negative feedback.

Please let me know if you have any questions, comments, concerns, etc.

Best regards,
Rob Cernich
DTP Connectivity Project Lead

Back to the top