 |
Take that .NET!
Posted by cajo on June 08, 2006 at 10:21 AM | Comments (18)
I felt as if a gauntlet had been thrown down before me. How could I profess that Java truly makes the network the computer, if it can not match the functionality of .NET remoting? While I am not yet convinced .NET is going about remoting in the best way, it is definitely very intuitive. Surely Java must be able to do it like that too... right?
Well friends, I am happy to say that the challenge has been both accepted, and met! I welcome you to have a look at the newest wiki page of the cajo project. Even if you have never developed using distributed computing before, this can literally have you up and running, in minutes.
For those of you who are tired of hearing about how new and powerful .NET is, and how Java cannot possibly match its "advanced" functionality; this page will certainly bring a smile to your face.
Take that .NET! ;-)
Bookmark blog post: del.icio.us Digg DZone Furl Reddit
Comments
Comments are listed in date ascending order (oldest first) | Post Comment
-
Hi John,
One thing I'm unclear about with your project: is it really just for client/server applications (with near-transparent remote procedure calls) or can it be used in peer-to-peer applications, say implementing a server cluster than can share information between "n" server nodes (or even better, perform self-discovery)?
I had a quick look on the project page, I didn't see the answer to that (although maybe I missed it).
Thanks,-Chris
Posted by: chris_e_brown on June 09, 2006 at 02:19 AM
-
John,
Can you explain how do you compare Cajo with Jini?
Regards,
Maurizio
Posted by: mkj6 on June 09, 2006 at 03:01 AM
-
@chris: The project can be used for both client/server or p2p, yet it is not constrained by either architecture. Its purpose is to make two or more JVMs work together seamlessly, as one. It is especially ideal for clusters, and grid computing. Dynamic discovery is also supported, just as simply.
@Maurizio: Jini is an architecture, a structured approach to distributed computing. Applications must be designed to it, and are thus "Jini Applications". This project does not impose architectural requirements, i.e. you don't write a "cajo application".
Put another way; you have to formally 'learn' Jini; whereas this approach is more intuitive, and architecturally transparent. While the capabilities, and functionality of both technologies are quite similar, they are Yin and Yang approaches: Explict vs. Implicit. Each school of thought has its adherents. Choice is good.
John
Posted by: cajo on June 09, 2006 at 06:24 AM
-
John,Sweet example...But does it swim like a duck?-JohnR
Posted by: johnreynolds on June 09, 2006 at 06:48 AM
-
Adding swim is left as an exercise for the reader. ;-)
Posted by: cajo on June 09, 2006 at 06:52 AM
-
Anyone interested should read up on .NET remoting and proxies here: http://blogs.msdn.com/cbrumme/archive/2003/07/14/51495.aspx (and the very rest of this exceptional blog). You will understand how much deeper proxying is integrated into the CLR and that .NET addresses a number of questions a lot more thouroughly than Java.
Posted by: mernst on June 09, 2006 at 08:54 AM
-
Matthias,
My experience tells me that deeply integrating remoting functionality is not as good a design decision as layering it atop a more general architecture.
Also, I did not see any questions that .NET addressed more thouroughly Java. Could you please tell me them?
John
Posted by: cajo on June 09, 2006 at 02:22 PM
-
Let's see: .NET does proxying for classes (no need to derive an interface first) and even field accesses (debatable but more holistic). And they can do it at the VM leven and don't need to do code generation (you know that DynamicProxy generates a new class in bytecode for every interface you proxy).
So .NET has the TransparentProxy built in; the remoting infrastructure is layered on top whereas DynamicProxy is an afterthought.
Yet, not to be misunderstood: I believe the path in Java works very well! Restriction to Interfaces actually isn't a restriction for remoting.
Posted by: mernst on June 09, 2006 at 11:59 PM
-
Thanks for responding Matthias,
It is clear both approaches have the same final functional result. However I much prefer remoting to interfaces, to decouple the client from the server class implementation.
On the other hand: In the cajo project proper, common interfaces are not required, and a client can even invoke the static methods of remoted objects, which is not possible in .NET. But this of course is starting to get a little off topic.
Thanks again,
John
Posted by: cajo on June 10, 2006 at 03:42 AM
-
John, I had heard about Cajo from your posts on JavaLobby, but I hadn't looked at it before. It looks like you have removed a lot of weaknesses in RMI - need to generate stubs/skeletons, need for a separate rmiregistry process (which needed the stubs in its CLASSPATH!!!), and having to extend an RMI class. Fantastic. Is that how you look at it - or is there more to it than being a 'better' RMI?
Posted by: manjuka on June 11, 2006 at 08:14 PM
-
Hi Manjuka,
Thanks for looking into the project! Yes, you have a good understanding of the major goals. In addition the project provides the ability to remote graphical user interfaces transparently, as applets and via WebStart.
Initially the graphical part was just to demonstrate the functionality of the framework, but now there are a significant number of developers using the project primarily for that feature.
I was plesantly surprised by that.
Posted by: cajo on June 12, 2006 at 06:42 AM
-
John, one thing is not clear after going through the docs.. when methods in the remote object returns other objects, how do you know if it is returning by value (a copy) or a reference? In RMI, if the returned object implements java.rmi.Remote we get a reference, otherwise it is returned by value (should implement java.io.Serializable). Does it work the same way?
Posted by: manjuka on June 13, 2006 at 05:41 PM
-
This is a very good question Manjuka.
In the FAQ this was addressed, unfortunately as the second part to a similar question.
I understand why it would be difficult to find:
https://cajo.dev.java.net/faq.html#19
Documentation is a difficult task, but I have come to understand, it is definitely worth the effort!
Posted by: cajo on June 13, 2006 at 07:03 PM
-
John, I've only recently discovered Cajo after reading about RMI. One of the major frustrations I had with RMI was the callback problem. I just wanted to design a very simple chat server and chat client in RMI. Since most of my friends sit behind firewalls, my server callback always failed to connect to the clients. After reading "FirewalledClients" on the wiki, it looks like cajo has a simple solution for this. I'm really looking forward to learning more about it. Anyway, thanks for your effort on this. Documenation looks good so far!
By the way, how do you pronounce cajo? I looked in the faq but didn't see it.
Steve
Posted by: sjohnston on June 13, 2006 at 10:28 PM
-
Hi Steve,
The first time the question came up, I was ironically unprepared .
You have a good idea about putting it in the FAQ, though I'm not sure I have a good answer.
Good luck with your study of the project, I hope it goes very quickly and smoothly.
If you have any questions feel free to ask.
John
Posted by: cajo on June 14, 2006 at 06:30 AM
-
Is there some answer to the message posted by chris_e_brown on June 09, 2006 at 02:19 AM?
"One thing I'm unclear about with your project: is it really just for client/server applications (with near-transparent remote procedure calls) or can it be used in peer-to-peer applications, say implementing a server cluster than can share information between "n" server nodes (or even better, perform self-discovery)?
I had a quick look on the project page, I didn't see the answer to that (although maybe I missed it)."
Thanks,
Rick
Posted by: baldi on January 30, 2007 at 03:06 AM
-
Hi Rick,The project can allow you to quickly build massively scalabale p2p applications, very easily.If you have some specific questions, I would be most happy to help you with them.John
Posted by: cajo on January 30, 2007 at 05:52 AM
-
Hi John,
I'm trying to make communicate directly 2 "peers" (client) behind firewall/NAT through cajo. It has been created also a public server which can pass objects (through cajo) to these two clients. It is possible for these clients to communicate directly?And so, how?
Posted by: ribaldo on February 10, 2007 at 03:29 AM
|