Wednesday, May 13, 2009

Exercise 05

1. Investigate a simple chat client/server system. Look at some program code and describe how it works with multiple users.

To find a webpage detailing the creating a multithread client/server chat system using Java. Multiple users are handled in the following manner:

• A socket would be opened for each specified host and port connected to the server; an object ChatClient would be created for each host with their specified input and output socket stream;

• The server would keep a list of active connections in a static Vector and would synchronize the static Vector for new connections and closed connections;

• The server would monitor each ChatClient for any input socket stream. Once there are input socket stream, the server would read the stream and rebroadcast the string to output stream all the connected ChatClient.


2. Describe the important and distinguishing properties of Peer to Peer computing and the Grid. How is this peer to peer and the Grid architecture changing work flow and service-oriented applications?

Grid Computing is a parallel distributed system which facilitate the sharing, selecting, collaboration of resources distributed across different networks whereas Peer to Peer network consists of number of computers connected together to facilitate sharing of resources much data in form of files.

Main goal of Grid computing is to merge resources distributed over the connected networks to perform massive computation whereas Peer to Peer network is take advantage of the idle cycles and storage of distributed computers to enable mainly file sharing purposes (Ledlie, Shneidman, Seltzer & Huth, 2003; Cope, 2002).

With service orientated applications implemented in Grid or Peer to Peer networks, the work flow of service orientated application need to address the following requirements (Harold, N. D.):

• the mobility of objects, transaction, applications and data storage;
• to implement security measure for their components regardless of their physical location;
• to maintain referential integrity of all data regardless of their state and physical locations;
• to cope of active changes of their components at any time with the transaction integrity being maintained;
• to support multiple instance of the components;
• to facilitate real time view on details of the components at all time;
• to support failover and real time recovery of the components;
• to enable multi devices such as servers, PC and wireless appliances to access data, application logic and storage of complex transaction.

3. Frameworks for development. Compare and contrast any TWO of:
Compare Java and .Net (Wikipedia, 2008)

Item Java .Net
Market Presence Java is opening sourced and can be implemented in various operation systems and environment. Although Common Language Runtime of .Net is a cross-platform standards. The primary platform with .NET is still Windows. That is why Java’s popularity in open-sourced project is much higher than other languages.
Standardization To date, no part of Java has been standardized by Ecma, the ISO, and the ANSI. Part of the .NET executable environment (known as the Common Language Infrastructure, or CLI), and .NET executable format (known as Common Intermediate Language, or CIL) are standardized by international Standardization bodies such as Ecma, the ISO, the ANSI.
License Java’s class libraries are completely open-source except those licensed by SUN from 3rd parties. Only part of the .NET CLI executable environment and some of the corresponding class library have been standardized and can be freely implemented without a license. Other parts of the executable environment of .Net would still require license.
Community Sun’s accepts third-party contributions. Microsoft has developed C# and .NET without a formal community contribution system,

No comments:

Post a Comment