The Artima Developer Community
Sponsored Link

News & Ideas Forum (Closed for new topic posts)
Sun Dreams of Jini for Web Services

6 replies on 1 page. Most recent reply: Mar 18, 2002 8:57 AM by Bill Venners

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 6 replies on 1 page
Bill Venners

Posts: 2284
Nickname: bv
Registered: Jan, 2002

Sun Dreams of Jini for Web Services Posted: Mar 7, 2002 3:59 PM
Reply to this message Reply
Advertisement
"Since 1999, Sun Microsystems Inc. has been telling the market that Jini, its dynamic network communications architecture, was designed mainly for devices. Now the company is repositioning the technology, saying that it's also a suitable framework for developing and publishing software services," says this SD Times article:

http://www.sdtimes.com/news/049/emb1.htm


Daniel Steinberg

Posts: 3
Nickname: daniel
Registered: Jan, 2002

Why Dreams of Jini Posted: Mar 17, 2002 11:41 AM
Reply to this message Reply
These last few months I've concentrated on XML and watched the industry push towards Web Services. What I don't understand is (in the Java world) what Web Services addresses that Jini doesn't already provide. Perhaps from limited devices, web services allow you to connect in ways that Jini wouldn't, but from the desktop I don't see why Jini isn't a better solution. Any thoughts?

Matt Gerrans

Posts: 1153
Nickname: matt
Registered: Feb, 2002

Re: Why Dreams of Jini Posted: Mar 17, 2002 1:13 PM
Reply to this message Reply
Jini isn't really for the web, it is for local networks. Bill and I were just discussing doing distributed gaming with Jini. Bill subsequently discovered (via the Google lookup protocol, no doubt) an article: http://www.sys-con.com/java/article.cfm?id=1357. However, the thorny issue of denial of service attacks came up. In a local network, this is not a big issue, but if you have Jini services that can go anywhere on the internet, you have a problem.

Frank Sommers

Posts: 2642
Nickname: fsommers
Registered: Jan, 2002

Re: Why Dreams of Jini Posted: Mar 17, 2002 2:43 PM
Reply to this message Reply
> Jini isn't really for the web, it is for local
> networks. Bill and I were just discussing doing
> distributed gaming with Jini. Bill subsequently
> discovered (via the Google lookup protocol, no doubt)
> an article:
> http://www.sys-con.com/java/article.cfm?id=1357.
> However, the thorny issue of denial of service
> e attacks came up. In a local network, this is not
> a big issue, but if you have Jini services that can
> go anywhere on the internet, you have a problem.

Yes, but that's a problem for any sort of distributed system. I think the heart of DOS attacks lies in a lower layer, on the level of packet routing -- as long as you flood a host with packets, that host will at some point became unavailable for further processing, if for no other reason that the network leading to it saturates (or the node's processing capability is overwhelmed, or its memory fills up, etc.) With Jini, mobile code just ads the extra twist that a VM can't negotiate with a service as to how much code it's willing to accept, etc. That sort of capability should, in my opinion, be addressed on the class loading level.

As for Web services, I certainly think that Jini is a Web-services infrastructure. The W3c organized a symposium about a year ago, with the aim to try to define Web services. The interesting thing is that they couldn't come up with a clear definition -- certainly, the use of XML is *not* a prerequisite for a software object to be called a Web service (http://www.w3c.org/2001/01/WSWS).

Actually, I think it would be hard to see why someone would like to do distributed computing outside the context of the Web (by Web, I really mean the Internet). It's similar to people talking about client-server computing -- nowadays, "client" means a browser, and server implies an application server. I could hardly imagine someone proposing a "client-server" application without that implicit meaning (e.g., proposing a VB client talking to an Oracle database). In fact, traditional "server" applications, such as DBMSs, have really evolved into application servers, and traditional "client" tools, such as VB, have evolved into browser-like components. Anyway, I think it would be a hard sell to propose Jini as anything other than a Web services infrastructure. Many people just wouldn't see the point.

In fact, one of the big selling points of Jini is that it defines a Web services infrastructure, not simply an architecture. Every Web services architecture will, sooner or later, need an infrastructure as well. For example, how else do you manage stale entries in UDDI registries? How do you coordinate distributed transactions? How do you facilitate asynchronous message exhange? Remote events? All these things are issues that, sooner or later, any Web services system will have to provide for. Jini already defines these, so it's way ahead of other infrastructures.

Just to make one more point here, about Jini's specificity to Java. The .NET folks are making a whole lot of noise about their system being "language independent." Well, that claim, in my opinion, is meaningless. Distributed computing means *computing* -- at some point, somewhere, code must be crunched by some processor, and all data that code needs must, at that point, be represented in a programming language (or machine bytecode) that a (virtual) machine can crunch. For instance, in .NET, there is a "wizard" to convert a WSDL document to a C# stub, and interacting with a Web service, in fact, happens on the level of a VM that runs the C# code. Or, I heard that IBM has a tool somewhere on AlphaWorks that can take a WSDL file and make RMI-like Java stubs from them. So, again, an infrastructure *has* to facilitate the language-specific binding of data, otherwise that data can't be part of any computation. All Jini says is that APIs are easier for *programmers* to work with, since they define a specification in terms of a computation model (in terms of programming language constructs), whereas having to use some non-programming language construct to define a computation, and then convert that to a programming language, is more arbitrary. And Jini assumes that such artibrariness is not acceptable for large-scale distributed systems (i.e., the Internet), where there will be so many components that humans can no longer hope to stay involved and mitigate abiguity. So, in that sense, Jini explicitly addresses the needs of large-scale, global distributed systems, i.e., the Web.

Bill Venners

Posts: 2284
Nickname: bv
Registered: Jan, 2002

Re: Why Dreams of Jini Posted: Mar 17, 2002 4:35 PM
Reply to this message Reply
I was kind of glad to see Sun was discussing Jini in the context of web services.

One basic difference I see between Jini and UDDI/Soap is that UDDI/Soap is designed more specifically for connecting business to business services on the internet. I attempted to read through the UDDI specification a while back. I don't understand it nearly as well as the Jini lookup service. But Jini's lookup seems more generic.

The strings versus types issue that these guys are talking about is more about composition of strings versus composition of types. Jim Waldo talked about this in his interview with Frank Sommers:

http://www.artima.com/intv/waldo7.html

In UDDI, you associate semantics with strings. In Java/Jini, you associate semantics with type names. But in either case, you are really associating semantics with strings, because a Java type name is a string. org.currency.Exchanger, after all, is a string. The advantage of using types in lookup comes in the fact that a different type, say com.artima.MoneyChanger can implement org.currency.Exchanger. A client program can tell that com.artima.MoneyChanger includes an org.currency.Exchanger service, and know how to use it. Jini's lookup service allows a client to get a com.artima.MoneyChanger in return for asking for (looking up) a org.currency.Exchanger.

I think one of the big advantages of using a type system for lookups is that it helps when trying to evolve systems. This is true of monolithic object-oriented systems, and it is true of a distributed system that use objects as the nexus of contact between the various parts.

Both web services and Jini, on the other hand, use objects as the nexus between clients and services. In Jini's case, the object flies across the network and is injected into a JVM on the client. In the web services case, the object is sitting behind an HTTP server, and you invoke methods on it via SOAP calls that go through the HTTP server. I'd be interested if anyone out there more familiar with UDDI can post indicating whether I can get back a subtype when looking for a supertype in UDDI.

One big difference between Jini and web services is that Jini requires a JVM on the client to host the network-mobile service proxy. Web services use a protocol to talk across the network to a remote object. The disadvantage of Jini, then, is that it requires a JVM on the client. But the huge advantage of having a JVM on the client is you can use Java's ability to move objects. Jini leverages mobile objects to make the protocol by which a service proxy talks back to its server side part of the implementation of the proxy. That means different implementation can use different protocols. Different protocols can be used in different situations. New protocols can be invented and used over time. This yields flexibility when evolving distributed systems that I think is a big advantage of Jini's approach.

It has been a while since I looked at the UDDI spec, but my impression was that there was a lot of stuff in there that made sense in the context of connecting services business to business across the internet (and smaller networks too). Jini doesn't have that stuff. For example, I believe the UDDI spec defines a way that UDDI registries can be federated so they replicate each other, kind of like DNS servers, across the internet. There is no such thing for Jini lookup services in the Jini specs. So to really connect business to business services across the internet with Jini, I think a lot of things would need to be defined on top of Jini. Jim Waldo touched on this subject a bit as well in his interview with Frank:

http://www.artima.com/intv/waldo9.html

Basically, I think Jini would make a good core of a business to business service infrastructure, but it would require that a number of issues be resolved and some architecture on top of plain Jini be defined.

Matt Gerrans

Posts: 1153
Nickname: matt
Registered: Feb, 2002

Re: Why Dreams of Jini Posted: Mar 17, 2002 11:34 PM
Reply to this message Reply
> Basically, I think Jini would make a good core of a
> business to business service infrastructure, but it
> would require that a number of issues be resolved and
> some architecture on top of plain Jini be defined.

It seems to me there are still a few issues that Jini has, reletive to the web.

Jini uses multicast. Even if this were adapted to somehow work on a WAN or web, wouldn't it be a big performance problem? Seems like the noise of several million (billion?) services announcing themselves would overwhelm any system.

The redundancy of lookup services on a local net is a great thing, but on the web, it would be too much. Thousands or millions of lookup services with redundant information seems like too much (even DNS information is not entirely redundant, after all). If you set up a lookup service on your server, it seems that it would be quickly swamped by the large numbers of services out there (assuming Jini became ubiquitous).

Also, suppose I need (the common example) a print service. Do I want a dialog box with several million printers to choose from? How is this issue resolved when the domain is the entire web? Is Jini a technology of the future, where all devices have a GPS module that allows filtering within a 50-meter perimiter?

Another issue is renumeration. Although, come to think of it, I guess it is pretty easy to design a Jini service that requires a logon and/or payment process before rendering any service...

Maybe these issues have been addressed in the articles mentioned above -- so I better go read those, before pontificating any further...

Bill Venners

Posts: 2284
Nickname: bv
Registered: Jan, 2002

Re: Why Dreams of Jini Posted: Mar 18, 2002 8:57 AM
Reply to this message Reply
> As for Web services, I certainly think that Jini is a
> Web-services infrastructure. The W3c organized a
> symposium about a year ago, with the aim to try to
> define Web services. The interesting thing is that
> they couldn't come up with a clear definition --
> certainly, the use of XML is *not* a prerequisite for
> a software object to be called a Web service
> (http://www.w3c.org/2001/01/WSWS).
>
This is a good point. I have repeatedly asked people who claim to understand WSDL whether it would be possible to define the "protocol" of a web service to be a Jini service proxy, and most people thought it would be possible. So in other words, I think it may be possible to lookup a Jini service with UDDI. When doing that, you would get the flexibility benefits of using mobile objects as proxies, but you wouldn't get the benefits of type-based lookups, which is provided by the Jini lookup service.

The other way around is more obviously possible. I can grab a service proxy from a Jini lookup service and use it, and the service proxy's implementation could certainly include sending SOAP messages to an HTTP server somewhere behind which is sitting a web service remote object. In other words, Jini services can be implemented in terms of web services.

One of the ways I like to think about this stuff is that what I really want is services on the network. You can think of SOAP-HTTP-based web services and Jini services as different kinds of network services, or you can think of them as ways to access network services. I like to think in the second way, that Jini and web services are two different ways to access network services, where a network service is simply defined as functionality on the network.

Flat View: This topic has 6 replies on 1 page
Topic: HTTP Needs Replacing Previous Topic   Next Topic Topic: Creativity versus Copyright

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use