Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 JBus, A Platform Independent Publish/Subscribe Bus for CWave 2000 M.S. Thesis Defense Joseph W. Longson March 30, 2000.

Similar presentations


Presentation on theme: "1 JBus, A Platform Independent Publish/Subscribe Bus for CWave 2000 M.S. Thesis Defense Joseph W. Longson March 30, 2000."— Presentation transcript:

1 1 JBus, A Platform Independent Publish/Subscribe Bus for CWave 2000 M.S. Thesis Defense Joseph W. Longson March 30, 2000

2 2 Publish / Subscribe bus Bus Client Bus Client Bus Client Pub/Sub bus l Implementation is like a chat room –Each member uses a room number for communication (topic) –Allows multiple clients in the same room (topic) –Transmit strings, pictures, sounds, etc (data) Introduction

3 3 Platform Independent l Code does not rely upon a platform –Implemented for a virtual platform –Multiple Operating Systems for clients (Mac, Windows, UNIX, etc) –Multiple Hardware Platforms for clients (Mac, PC, SGI, SUN, etc) Introduction UNIX Platform Mac Platform Windows Platform Bus Client Bus Client Bus Client Pub/Sub bus

4 4 CWave 2000 Toolkit l Toolkit containing many components including –Environment for setting up bus clients –Publish Subscribe bus implementation l Includes a Publish / Subscribe bus implementation –Based on Microsoft’s COM/DCOM, limited to the Windows platform –Allows process and machine independent client interaction Introduction VB Program C++ Program MS Java Program Windows Platform Windows Platform Windows Platform CWave bus

5 5 Problem Statement l Problem: CWave 2000 not platform independent. –Limited to the Windows OS, on the PC platform –Uses DCOM, which is designed for a LAN, not for the Internet l Solution: –Extend CWave 2000’s Publish / Subscribe bus –Allow communication from other operating systems –Allow non-COM languages to communicate with bus Introduction

6 6 JBus l Provides a platform independent Publish / Subscribe bus –Implemented in Java for the Java Virtual Machine –Interfaces available for Java, C, and C++ l Compatible with the CWave 2000 System –But not dependent on it Introduction VB Program C++ Program MS Java Program Windows Platform Windows Platform Windows Platform C Program Java Program Windows Platform UNIX Platform Mac Platform JBus Java Pub/Sub busCWave Pub/Sub bus C++ Program

7 7 Primary Design Constraints l Platform independence –Hard to achieve completely, so this will used as a guideline l Leverage the Internet for communication –Using HTTP and XML for message Transport l Maintain compatibility with CWave 2000 –Compatible but not dependent on CWave l Modular design –Allows bus implementation to be easily replaced Introduction

8 8 Secondary Design Constraints l Have a small memory and disk space footprint –This allows JBus clients such as Web Browsers to be developed l Platform independent data marshalling –This is a hard constraint that may not be solved l Support new and existing C/C++ clients –Extends the languages available for JBus client implementation l Entire system should perform at an interactive level –Performance will be tuned to a usable level Introduction

9 9 Related Work Introduction

10 10 Java Bus Implementation

11 11 JBus Representation l Provided the illusion of a single omnipresent bus –Platform independent (using Java) –Topic based communication JBus Java Client Machine 1, WindowsMachine 3, Web Browser Web Client Java Client Machine 2, UNIX C++ Client Phase 1

12 12 JBus Implementation l Implemented as a set of connected local buses –Each client has a local bus instance –Transport objects used for communication between buses –Each local bus acts as either a Server or Proxy Phase 1 Machine 2, UNIX JBus Java Client Machine 1, Windows C++ Client Transport JBus

13 13 JBus Architecture Bus Client Interface Message Filtering Message Transport l Bus Client Interface –Used to get a JBus instance –Publish/Subscribe methods l Message Filtering –Routes messages to Bus Clients –Filtering of messages l Message Transport –Implemented as Bus Client –Can have local filtering –Communicates using desired medium (e.g. HTTP, SSL) Phase 1

14 14 JBus Client Example l Case 1, Java Client –Connects as a Bus Server –Installs an HTTP Server on the local machine l Case 2, C/C++ Client –Connects as a Bus Proxy –Remotely connects to a machine using the HTTP protocol Phase 1

15 15 2 Bus Factory Java Client (1) - Java Client asks Bus Factory to create a Bus Server HTTP Server Bus Server (2) - Bus factory creates Bus Server and HTTP Server (3) - HTTP Server subscribes to bus and begins communicating with bus (4) - Client begins communicating with bus 4 3 Phase 1 Bus Factory 1 JBus Client Example Case 1: Java Client Machine 1

16 16 Bus Factory 5 6 Bus Factory (5) - C/C++ Client asks Bus Factory to create a Bus Proxy to a Server (6) - Bus Factory creates a local Bus Proxy and a local Transport object (8) - Communication commences between Transport Objects Java Client HTTP Server Bus Server C/C++ Client Bus Proxy Transport (7) - Remote HTTP Server creates a Transport Object for proxy connection (9) - Client and Transports begin communicating with their buses Transport 7 8 9 Phase 1 JBus Client Example Case 2: C/C++ Client with Transports Machine 1 Machine 2

17 17 JBus Client Example Case 1 and 2 in action

18 18 CWave 2000 Gateway Object

19 19 Gateway Object Representation l Interfaces between the JBus and CWave 2000 –Transparent to the client –Allows communication from either implementation Phase 2 JBus CWave 2000 Gateway JBus interface CWave interface Java Client CWave Client

20 20 Gateway Object Implementation l Implemented as a JBus object –This provides a transparent interface for JBus clients l Uses Microsoft’s Extensions for Java –This allows communication with the CWave 2000 bus Phase 2

21 21 JBus Client Example l Case 3, CWave Client –Uses the Gateway Object –Connects as a Bus Proxy –Begins communicating with JBus or CWave bus clients Phase 1

22 22 10 Bus Factory (11) - Bus Factory creates Gateway and Transports. Transports connect and begin communicating Java Client HTTP Server Bus Server C/C++ Client Bus Proxy Transport (10) - CWave Client asks Bus Factory to create a Gateway Proxy to Server (12) - Client and Transports begin communicating with their buses Transport Phase 1 JBus Client Example Case 3: CWave Client with Gateway CWave Client JBus Gateway Transport 12 Machine 1 Machine 2 Machine 3 Bus Factory 11

23 23 JBus Client Example Case 3 in action

24 24 Data Marshaling with XML

25 25 Data Marshaling l What is Data Marshaling? –The translation of data from one form to another l Where is it used? –Between Transport Objects –Between Programming Languages l What options do we have? –BINARY –ASCII –XML Phase 3 01 10110111 04 01011011 BINARY 183 c ASCII 183 c XML

26 26 XML l Similar to HTML –ASCII format –Uses the concept of Tags l Structure of XML –Stores the format with the data –Multiple formats can be intermixed in a transmission l Why use? –Flexible –Platform Independent –Many parser implementations available. World World 3.14159 Phase 3

27 27 What to Marshall? EasyHard Primitives: Int, Float, Char, etc Multi-element A: AnEvent, Java Vector Complex: Struct, Class Subtyping: Inherited classes, Multiple class instances JBus 1.0 Multi-element B: general collection classes Phase 3

28 28 Bus Factory Java Client HTTP Server Bus Server C/C++ Client Bus Proxy Transport (13) - Properly Marshal data between the Client and the bus, and between Transports Transport Phase 1 JBus Client Example with Data Marshaling CWave Client JBus Gateway Transport Machine 1 Machine 2 Machine 3 13

29 29 JBus Client Example with Data Marshaling in action

30 30 Performance Results

31 31 Preliminary Performance

32 32 Preliminary Performance

33 33 Preliminary Performance

34 34 Conclusion

35 35 Contributions l Platform independent extension to CWave 2000 –Extends client implementation choice –Extends CWave communication to the Internet l Message Transport using XML over HTTP –Allows more Platform independent data marshaling l Can function with or without CWave 2000 –Allows use of the JBus beyond CWave 2000 l Modular bus design –More flexible for bus experimentation Conclusion

36 36 Future Research l Performance Tuning l Better data marshaling for complex data types l Enhance the ability for thin clients to use the JBus Conclusion

37 37 Questions? Thank you!

38 38 Preliminary Performance 2

39 39 Preliminary Performance 2

40 40 Preliminary Performance 2

41 41 Extensions C/C++ Extension Web Extension

42 42 JBus++ Extension (C/C++) l Extension to the JBus Client Interface –Allows C or C++ clients to use the JBus functionality –Relies upon the JNI from Sun l Data Marshaling –XML –JNI Data Types JBus Client Interface Message Filtering Message Transport JBus++ Client Interface Extensions

43 43 Web Extension l HTTP Transport –Allows Firewall Penetration –Works with Proxy Servers l Web Clients –Create a Web Server –Serves Web pages with embedded Applets l Thin Clients –Use the JME (Java Micro Edition) –Download Applets Extensions

44 44 Research Progression l Phase 1 –Java version of the bus –Simple TCP/IP communication l Phase 2 –CWave 2000 Gateway l Phase 3 –Data Marshalling using XML –HTTP communication Introduction l Extensions –C/C++ clients –Web Interface


Download ppt "1 JBus, A Platform Independent Publish/Subscribe Bus for CWave 2000 M.S. Thesis Defense Joseph W. Longson March 30, 2000."

Similar presentations


Ads by Google