Corba and Java's combination

zhaozj2021-02-08  480

Summary: If you want to realize the application of the Web on the web / server mode,

Can choose a variety of different technologies. However, it is necessary to serve a large number of users.

Applicable, we believe that it should be the first choice of CORBA, because it has expandable and industry

Pouting support. by

The strength of CORBA can improve the performance of Java programming, and use the existing base

In standard technologies, Java developers can write a strong Web application program

. In this article, our first briefly introduced Corba, then makes this skill.

Example of example, us

Write a hand-written program programming. In addition, in the attached

We have made a comparison of several partial layers, and they are divided into CORBA.

, RMI and DCOM.

Use HTML tables and universal network access (Common Gateway Interface), users can

The server script on the web network is interactive. Many online points

This technique is used to enter the username and password. These East West Introduction Services

After the script, used for

If the user can access a certain part of the network. This process

Used HTTP, and it is an advent (stateless). Every time you download one

Page, the customer machine is completely removed from the server, and the server does not know the guest.

Machine information, more

There is no way to know the movement of the client is moving. This, even if it is

After logging into a certain network, the client program is queried to ask a page, still need

The user name and password will be transferred to the service server. In other words,

Your customer application

Interface between the program (web browser) and the servers, there is no local variable,

Method is called or is an object.

After ten years of efforts, software developers can make a generation of code

Plus the image of the like to be sealed. But yes, the current Issue mentioned, there is no doubt, I have clearly understood me.

They are refunding, because it is the countless model of the strategy, batch processing.

Of course, CGI technology is not a place. Web gave me the advantages of revolutionaryness,

That is based on standard open protocol and uniqueness of the platform. Although

Thousands of thousands of Web networks use HTTP and CGI to get user information, transported on server

Walking a piece of script, even

You can also return information to the user, but it is seen from the perspective of the transformation.

Point is not a true "application program". In addition, from HTTP and CGIs in new technologies, the code of these outlets must be overwritten. Want

For existing Web soft

Press resources to use, or write a high-quality application program, so that

Internet / Intranet is a communication main trunk, and the technological must have the following special

Sex:

曋? Hold existing C, C and COBOL code

曋? Hold Java, to build a detrimentary value, platform independent face-to-directional object

Programming

暽? Entrepreneurship, only this, the program is easy to maintain, and will not be time

Prematch.

? Promotive, enough to support large {"C , Java", "Java, Smalltalk, ADA95,

C "," Java, C ",

"Java, C ", "Java, C "},

{"http://www.expersoft.com", "http://www.iona.com",

"http://www.visigenic.com",

"http://www.software.ibm.com/ad/cb",

"http://www.sun.com/solaris/neo/solaris_neo/index.html"}}

ORBQuery (String Name) {

Super (Name);

}

Public Java.lang.String GetName (int index)

{

String name;

Name = orbvendors [index] [0];

Return Name;

}

Public Java.lang.String Getvendor (int index)

{

String vendor;

Vendor = ORBVENDORS [INDEX] [1];

Return vendor;

}

Public Java.lang.String Getos (int index)

{

String OS;

OS = ORBVENDORS [INDEX] [2];

Return OS;

}

Public Java.lang.String getLanguages ​​(int index)

{

String Languages;

Languages ​​= ORBVENDORS [INDEX] [3];

Return Languages;

}

Public java.lang.string getURL (int index)

{

String URL;

URL = ORBVENDORS [INDEX] [4];

Return URL;

}

}

At this point, we have written all the code necessary for the server, the next work

It is a small application of creating a guest, initializing the guests ORB, and hit the living and calling just just

Ended server object.

Create CORBA small application

Just as the server object wants to log in the server orb, the customer should be small application or should

The program is required to record the client ORB. When the remote CORBA object is obtained, the client machine uses an interposed method, which is notice that the customer's ORB is intended to be responsible by ORB.

ORB to ORB

News. This kind of request is implemented by the following two lines of code (in Visibroker For Java)

:

/ / Initialization ORB (use Applet)

Org.omg.corba.orb orb = org.omg.corba.orb.init (this);

/ / Retrieve the ORBINFO interface object to be called by applet

OrbinfoQuery = OrbQuery.orbinfohelper.bind (ORB, "ORBINFO");

After the Bind () method is called, our OrbinfoQuery local variables and services

ORBINFO object tied together. After this, we can adjust it.

It is used to realize the customer's small application with the help method. Remember, all of us completely

Use Java language

In practice, in practice, server objects can also be implemented in their words, such as: COBOL

, C , ADA and Small Talk.

in conclusion

Creating Corba Java should be slightly complex with single-pure Java small applications. Actually

This is the same as a pure Java sub-object to create a pure Java partial object to be somewhat. but

Yes, Corba and Java joints, the creation of the applications created is more powerful, more

Probiletics, this is

Single purely JDK issued unmatis-specific. In addition, now is that the business world is rarely used.

Java application program. CORBA is the choice of two full beauty, one side is allowed to develop

Use the existing code to protect the investment, and the other side can make the Java programming

The advantages of language.

Sub-formal objects, two options: DCOM and RMI

Multiple Java developers can be more familiar with DCOM and RMI, which is the two main competitions of CORBA.

Compete for his opponent. Now let me do it more than the three.

CORBA Relation

Corba has several basic advantages: unlike the development language, and the developer

Unregistered independence and uniqueness of the operation system. Corba's ORB is in front

Each main stream operation system has a real current (only for Microsoft's various operations

In general, CORBA is

The support is even over the DCOM). In addition, Corba ORB can visit a variety of words.

Realistic objects (including C , Cobol, SmallTalk and Java). Help in IIOP, somewhere

The Corba ORB that is issued by a hairpin (more visigenic) can be obtained, and his long-term

The sentients (such as Iona). Java Orb allows customers to have no installation

The Java passenger should be used in the case of any special software. (Java ORB class)

It can be downloaded with a small application, or it can be bundled with the browser. )

DCOM: Magoon of Microsoft

Popularity, Microsoft's Sub-forming Components Passage Models (Distributed Componont Object

MODEL) Only on both operations: Windows 95 and Windows NT4.

Microsoft is working with the third party to move to its operation

Uniform (including MVS and a few

A UNIX Operation System). I like CORBA, DCOM is standing alone in words, it is used

Microsoft's Password Description Language (ODL) is described with the interface to the pair of pairs.

Compared with CORBA, DCOM has three major shortcomings. First, it is from a single starter (micro

Soft) Defining and controlling this large limit for the selection of DCOMs (saying that

Development tools and winds). Second, DCOM lacks many platform support, this big way

Degree

Reuse and expandability of DCOM applications. Finally, with CORBA, DCOM is

A non-uncommon technique. Although the micro-soft use is adding messages and things for DCOM

Support, but these work can be implemented in Corba 2.0 in 1994, and

From a few different

Corba software driver's driver.

In order to make a java small application / application program to visit the DCOM object of the service end

Do not use Internet Explorer browser and Windows 95 / NT platform,

Only this can support the customer software. This limitation is cut into weak applications.

The program is on the web

Using sex. And the other side, a major advantage of DCOM is in Microsoft Windows

NT / 95 is free of charge. Have a history of history has been made, this is competing with Microsoft

Demolition.

RMI: SUN Java-Only solve

Remote Method Invocation is the important feature in the latest JDK 1.1. RMI enables Java

Customer can visit the distant service object. This seems to be ten categories similar to CORBA

But both are not. Its key is that the application program of the server is also required.

Write with Java, and only

It can make tools for use in JDK 1.1. Your root cannot add the code-making code to the new program, in addition to this, the RMI has many other defects.

Divoided with CORBA, RMI has no service. In addition, according to the Java service written by RMI

The server pairs are poor, and this shortcomings are from the Java virtual machine. ( Interestingly

The Java CORBA licensors are better than the RMI server table. ) RMI does not package

Included in Corba ORB

Motion of the object.

In practice, RMI and Java technologies can be able to close to Omg's standard, rather than back

Square. Sun has been announced, Java Transaction Serveces will be established.

Object Transaction Serveces (Object Transaction Serveces). The company also

Its long-distance plan:

Make RMI objects to communicate with IIOP.

In summary, RMI is a small-scale approach to a small-scale model written by pure Java,

A can be used. However, CORBA provides a collection of funds, which refers to the new opening.

The code and the integrated integration of an existing object, will be allowed to expand. Make

Take this

Before you choose, you must weigh the various factors on the upper surface and carefully review each technique.

status quo.

转载请注明原文地址:https://www.9cbs.com/read-899.html

New Post(0)