eclipse communications framework · 9 ecf | eclipse communications framework ... communications ui...

21
© 2005 by Scott Lewis; made available under the EPL v1.0 | 2/25/05 | Eclipse Communications Framework http://www.eclipse.org/ecf John Beatty Ken Gilmer Scott Lewis Pete Mackie Peter Nehrer Mary Ruddy Rhett Savage Paul Trevithick

Upload: others

Post on 25-May-2020

13 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

© 2005 by Scott Lewis; made available under the EPL v1.0 | 2/25/05 |

Eclipse Communications Frameworkhttp://www.eclipse.org/ecf

John BeattyKen GilmerScott LewisPete MackiePeter NehrerMary RuddyRhett SavagePaul Trevithick

Page 2: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

2 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Eclipse ArchitectureEcosystem

Tools Platform

Frameworks

Java Dev Tools C/C++ Dev Tools

Modeling Frameworks

Graphical Frameworks

Business Intelligence & Reporting

Test and Performance

Web Tools

Project Model

Rich Client PlatformRuntime(OSGi)

Generic Workbench Update

Page 3: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

3 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

ECF Containers

Java Dev Tools

C/C++ Dev Tools

Modeling Frameworks

Graphical Frameworks

Business Intelligence & Reporting

Test and Performance

Web Tools

Ecosystem

Runtime(OSGi)

Generic Workbench Update

Project Model

Native

XMPP

JMS

SIP

ECF Containers

...

Network Providers

SO

SO

SO

SO

ECF Containers

SO

ECF Network

Providers

Page 4: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

4 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Why Another Framework/Abstraction Layer?

Answer: Communications InteroperabilityGoals

Isolate protocols from component and/or application codeIntroduce 'lightweight container' No client-server assumption...assume only dynamically changing 'group of peers'Peers all potentially contribute state (and code) to distributed app – via shared objectsConsistent session, messaging, and reliability semantics

Eclipse-based clients that use multiple-protocols-per-app

Try to make (reliable) distributed applications development mucheasier

Page 5: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

5 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

How: A higher-level comm APISimple/Minimal/Small (< 100K for core interfaces/classes)

Join/Leave/Group membership info...that's it!Open Implementations

Anyone can implement a provider as extension

Existing protocols can be implemented open source or not Runtime Extensible

Adapters

Page 6: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

6 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Container-Provided ServicesGroup Join/Leave

joinGroup(), leaveGroup()Group Membership/Failure Detection

getGroupMemberIDs(), getGroupID()

Critical for reliabilityLifecycle and context for SharedObjects

createSharedObject(), addSharedObject(), removeSharedObject()

Event NotificationaddListener/removeListener

Asynch events: ISharedObject.handleEvent(Event)

Page 7: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

7 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Example Client Code// Create container instance via named providerISharedObjectContainer container = SharedObjectContainerFactory.makeSharedObjectContainer(“org.eclipse.ecf.provider.generic.Client”);

// Create service idID groupID = IDFactory.makeStringID(“ecftcp://composent.com:3282/server”);

// Connectcontainer.joinGroup(groupID,null);

// Create/add ISharedObjectISharedObject sharedObject = new HelloSharedObject();

container.getSharedObjectManager().addSharedObject(IDFactory.makeGUID(), sharedObject, new Properties(),null);// shared object component communicates here

// Disconnect/Disposecontainer.dispose(0);

Page 8: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

8 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Shared Objectpublic class HelloSharedObject implements ISharedObject {

ISharedObjectConfig config = null;

public void init(ISharedObjectConfig config) throws SharedObjectInitException {this.config = config;

}

public void handleEvents(Event event) {

// Handle all container-provided events here!System.out.println(“got event: “+event);

// Send message to all in groupISharedObjectContext context =

config.getContext().sendMessage(null,”hello world”);}

public void dispose(ID container) { config = null; }}

Page 9: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

9 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

ECF Providers

Implement ECF core Extension Points: containerFactory, namespaceImplemented so far: ECF Generic, XMPP/JabberPlanned: SIP, JMS, JXTA, JGroups, Bitorrent, ...Can support both open and proprietary network protocols (legacy and new)Appeal

1st choice: Consider implementing your favorite provider and contributing to ECF2nd choice: Ask us to do it for you

Page 10: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

10 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Provider Implementation// In your plugin.xml

<extensionpoint="org.eclipse.ecf.containerFactory">

<containerFactoryclass="com.myco.MyContainerInstantiator" name=”generic”>

</containerFactory></extension>

public class MyContainerInstantiator implements ISharedObjectContainerInstantiator {

public ISharedObjectContainer makeInstance(SharedObjectContainerDescription description,

Class[] argTypes,Object[] args)

throws SharedObjectContainerInstantiationException {

// Make new container instance here of appropriate typereturn new FrobozSharedObjectContainer();

}}

SharedObjectContainerFactory.makeSharedObjectContainer(“generic”)

Page 11: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

11 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Applications: Human-Human Communication

File SharingIM/ChatApp SharingVOIPConferencingDrawing/WhiteboardMulti-Player Games??

Page 12: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

12 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Tool Communication (plugin-to-plugin)

GraphShare: Shared Model EditingShared Debuggers/SimulationWorkflowCollaborative Content Creation/Mgmt??

Page 13: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

13 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Existing Codebase: Core Plugins

org.eclipse.ecfFramework interfaces, factories, and exception classes

org.eclipse.ecf.providerECF provider interfaces and classes

Runtime Requirements: JRE 1.4+, OSGI 3.0 only

Page 14: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

14 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Other Infrastructure Plugins

org.eclipse.ecf.sdoGraph share framework – talk about this shortly

org.eclipse.ecf.uiCommunications UI code: e.g. Abstract 'Buddy List View'

org.eclipse.ecf.docEclipse help docs: API docs, overview docs, etc

Page 15: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

15 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Example App Pluginsorg.eclipse.ecf.example.collab

Real-time collaboration application (url sharing, file sharing, chat, etc)

org.eclipse.ecf.example.sdo.editorGraph share example application

Coming (very) soonJabber Provider: org.eclipse.ecf.provider.xmppApps

Shared Editor for Team Outlining (SETO)(Distributed) Team Project Planning Tool

Page 16: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

16 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

What is GraphShare?

Replicating graph data structuresSDO Data Graphs (using EMF ref impl)Serialized Form is XMLParticipants distribute and then receive updates, apply changes to local replicationFramework supports extension/customization of

Replication algorithm – when and whereChange propagation -- whenConflict resolution – how to resolveAdding extension points to org.eclipse.ecf.sdo right now

Page 17: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

17 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Default Graph Share Implementation

Updates optimistically – any participant may commit at any timeUpdates must be received in sequence

Otherwise, all subsequent updates to the replica fail

Clients handle this (e.g., re-subscribe)New group members are initialized arbitrarily

All members send their Data Graph copy

The first one received is acceptedNo server/coordinator required

Page 18: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

18 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Default Update Provider

EMFUpdateProviderUses EMF-SDO API to

Extract local changesSerializeDeserialize on other endApply to remote replicas

Reverses local changes when applying remote updates (this may be configurable in the future)

Page 19: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

19 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

Example: Shared Model Editing

Extended SDOEditorSupports editing of arbitrary EMF models with SDO supportWhen saving, broadcasts changes to group membersRemote updates immediately savedShared models are identified by their workspace-relative path

Page 20: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

20 ECF | Eclipse Communications Framework | © 2005 by Scott Lewis; made available under the EPL v1.0

FutureRespond to Community FeedbackMore Providers: JMS, JXTA, Jgroups, SIP, your favoriteMore Applications: GEF Graph Share, VOIP, yourfavoriteIntegration with RCP appsIntegration with Eclipse Trust FrameworkMore/Better Libraries for Protocol Patterns

e.g. Both optimistic and pessimistic protocols...e.g. transactions

Replicated Data Structures (e.g distributed hashtable)Layered APIs for user presence, other comm/collab componentryDynamic Lookup and Discovery (?)Others Requests (?)

Page 21: Eclipse Communications Framework · 9 ECF | Eclipse Communications Framework ... Communications UI code: e.g. Abstract 'Buddy List View' org.eclipse.ecf.doc Eclipse help docs: API

© 2005 by Scott Lewis; made available under the EPL v1.0 | 2/25/05 |

Consider Participating!!

Special Thanks

Feedback from you on Desired DirectionsBuild Communications Components (shared objects) and Apps

– License them if you want to!Implement Containers/ProvidersContact: http://www.eclipse.org/ecf newsgroup, OR

[email protected], [email protected]

Eclipse Foundation: Mike M, Bjorn FB, Brian B, John WOTBC: Open Technology Business CenterIBM Jazz Team: Li-Te Cheng, John PattersonAll Team Members: They are doing on own dime/timeThanks to All Families