James Gosling: on the Java Road

« JavaChina | Main | Only solve the probl... »

20050930 Friday September 30, 2005


SOA: Buzzworld Whiplash or Real Meat?

For some odd reason, long lost in the fuzzy recesses of my memory, I agreed to give a talk last week at Oracle OpenWorld on SOA. It's a topic that I'm not an expert on. There are lots of people around who know far more about it than I do. A lot of my unease about giving the talk was that I was very confused about what SOA is, and that ended up being what I spent most of my hour onstage talking about.

There are a lot of corporations, analysts, consultants, experts, "experts" and pundits saying a lot of things about SOA, without a lot of consistancy about the meaning of the term. When you expand the acronym to "Service Oriented Architecture" you get a pretty good, but broad, picture. The Wikipedia definition is one of the better ones out there. In most descriptions, SOA has become a broad cellectiom of techniques that go far beyond just architecting systems as services. The topic feels a lot like that quote from Through the Looking Glass:

'When I use a word,' Humpty Dumpty said in rather a scornful tone, 'it means just what I choose it to mean--neither more nor less.'
'The question is,' said Alice, 'whether you CAN make words mean so many different things.'
'The question is,' said Humpty Dumpty, 'which is to be master... that's all.'

There is a collection articles that insist that SOA is not OOP (or OOP-ITL [Object Oriented Programming In The Large]). They draw weird distinctions that mostly demonstrate how little they understand of OOP. A common misunderstanding is the belief that everything that can be done to an object must be a method on the object - for example that "play" must be a method on a "MusicCD" object, tying the service to the object. In this example, the right way to have done it is to represent the CD player as an object distinct from the CD itself, which would be played with a statement like "player.play(cd)". OOP is a modeling tool, how you choose to model a situation is a matter of taste, the situation at hand, and engineering judgement.

Then there's the camp that defines SOA as just being the same as OOP. I rather like this because it meshes well with the phrase "Service Oriented Architecture", which is the way that I tend to think of most good OOP designs. Using the previous example, rather than having verbs like "play" be methods on the CD object it's usually better to try to restrict methods to things that are intrinsic to the object. One could argue in this world that perhaps SOA could be thought of as a subset of OOP, since there are many other architectures that can be modeled within OOP.

One of the concepts here that is often not made clear in these discussions is the distinction between a server and a service. A server is an implementation artifact: usually a machine. A service is an abstract concept that may be implemented by some number of servers (perhaps zero, perhaps many). The mapping between services and servers should be dynamic, depending on factors like load and quality of service - implemeted in things like the N1 Service Provisioning System.

The last bit of confusion for me is that in most discussions, SOA is about more than just architecting around services. The "S" in SOA should expand to "Scale", since so much of what is talked about is how to archtect these systems for large scales. Statelessness and idempotence are techniques that have been around for years (both appear, for example, in the design of NFS from 20 years ago) are usually considered key components of SOA architectures.

In the end, there's a big bag of techniques that you may or may not want to use. Whether the collection you need fits someone's definition of SOA shouldn't matter - do what's appropriate. Statelessness and idempotence are tough and only really valuable at high levels of scale. Proper OO structuring is always a good idea.

(Mon Sep 26 10:58:42 PDT 2005)
Permalink Comments [15]

Trackback URL: http://blogs.sun.com/jag/entry/soa_buzzworld_whiplash_or_real
Comments:

If you have not already done so, for an extremely lucent and insightfull disucssion on the subject of SOAs, you might want to check out Jim Waldo's take on things at: http://www.jini.org/events/0505NYSIG/index.htm#Waldo

Posted by Ron Welch on September 30, 2005 at 02:55 PM PDT #

I like the definition of Brown et al. in http://www-128.ibm.com/developerworks/rational/library/content/03July/2000/2169/2169.pdf They make interesting points about reuse and componenet-based development. I think OO is missing the mark a bit, since method calls are typically too fine grained for SOA and use on large scale distributed networks. There are many similarities to OO, but the "RPC style of thinking" is a bit too fragile for the net. I agree that many web articles and "experts" tend to mean what they like with SOA, but there are some interesting scientific research on the subject.

Posted by oskar on October 04, 2005 at 12:44 AM PDT #

cellectiom -> collection ;)

I dont tie SOA to OO at all, I think that's a very strange way of looking at this since a SOA could be quite procedural. At this point, I'd like to avoid the procedural/OO debate.

I think ultimately SOA was adopted before business owners knew what it meant. In a lot of cases, the backlash is a bunch people trying to get away from the heavy architectures they've created for reasons they didn't quite understand for a need they didn't really have.

To me, the benefits of SOA in general are wonderful with regard to exposing functionality to some sort of public domain, as well as setting up abstractions for legacy applications, both on and offline.

SOA also has a modern connotation that implies XML, and http. I don't view http as a necessary component, but xml definitely. What better way to communicate data between two systems than an extensible document format in a standardized encoding?

Posted by Ivan on October 05, 2005 at 08:30 AM PDT #

>I think OO is missing the mark a bit, since method >calls are typically too fine grained for SOA and >use on large scale distributed networks. There are >many similarities to OO, but the "RPC style of >thinking" is a bit too fragile for the net. I agree >that many web articles and "experts" tend to mean >what they like with SOA, but there are some >interesting scientific research on the subject. Many people have the OO == CORBA mentality. What many miss out on with Jini is the fact that Jini uses the RMI model provided by the Java platform. With mobile code, an RPC call can carry with it, a huge amount of implementation detail and state to optimize the local interactions. Since the contract between the client and service is a Java interface name, the implementation can change dynamically. When you look at what is happening with web-services, and the whole document based exchange, you can see that people want to send a lot of information, to optimize the network transit latency. With the RMI programming model, you could send a smart proxy that already had the first 1/3 of the data that the user might need, and show that to them, but then start downloading/retrieving the other data as needed. This is just like the google-maps and other AJAX implementations. They are in fact using mobile code so that they can optimize the users experience, and make it more seemless. With CORBA, you could send simple data types or composites as described in the IDL. With Java and the RMI programming model, you can send anything that implements the interface or other programming interface contract that the service is defined under. So, smart-proxies can abound. That means that if you want to take a single service and composite it across multiple, physical servers or multiple logical services, you can do that dynamically. You can even create versions of the service by adding another interface to the service proxy so that new implementations might get a different set of features while still providing backward compatible services to old users. To do that with web-services, you have to send the whole composite document. You can't optimize with a smart proxy in a SOAP environment. You must always send all data, even if the client just needs 1/100th of the data sent. There are often many optimizations to be made by allowing fine grain access too.

Posted by Gregg Wonderly on October 05, 2005 at 09:50 AM PDT #

At the recent Javazone 2005, probably the best developer conference in Europe, leading systems architect Johannes Broadwall gave a talk on "Why I hate SOA". He made several points, some of the centered around that SOA is everything or nothing or just vapor, and that all the benefits proclaimed to come out of soa must come from your system design, not the products. <p/> Both before and after the conference, this has led to a discussion among the nation's leading system architects in several magazines and forums in Norway. <p/> You can find the video of that talk available as a torrent stream (divx/mp3) from www.javazone.no or www.java.no. While the websites both are in norwegian, the talk was given in english.

Posted by Eirik Maus on October 05, 2005 at 12:49 PM PDT #

Equating SOA to OOP makes it out to be more than it acually is and saying OOP is a superset of SOA is comparing apples to oranges. The concepts are very similar, however they are applied at different levels and not all concepts of OOP equate to SOA. For example, I don't think it makes sense to apply OO principles like inheritance and polymorphism to SOA. SOA makes most sense by equating it to just interfaces.

SOA is applying interfaces at an architectural level. The goals of SOA are the same to the goals of interfaces. You create an abstraction of a business concept by defining the interface used to implement that business need. All the benifits of an interfaces now exist for the system that implements that interface.

I think its easier to picture SOA when you describe it in terms of a business concept and not an object like a CD. An example I like is the business concept of charging a credit card. It makes sense to encapsulate the functionality for charging credit cards, so you can create an interface to do that: BillingSystem.charge, BillingSystem.refund, etc.

Now, if you only have 1 system then you would not create an entire separate enterprise system to do this, you can implement it using OOP and use it from the one system. If you have many systems in your company, however, that want to charge credit cards, then you create a separate system. You apply SOA to define an "interface" and implement it using your choice of tools (Web Services, EJB, Corba, EDI)

I think the most common misunderstanding of SOA is at what level it is applied. If you are creating a single system, you are not using SOA. You may be creating interfaces and applying similar concepts to SOA, but it is really OOP. Once you get to the system level and you are architecting the various systems that need to interact with eachother, then you are applying SOA principles.

If you boil it down to this you'll notice that SOA doesn't mean much and it does add much that is new. The only thing new are some of the tools that are being used to implement the concept (Web Services) and a renewed interest in better organizing the enterprise as a whole.

Posted by Kris Huggins on October 05, 2005 at 09:08 PM PDT #

Trackback: <A title="SOA: SO or OO - How You Gonna Get There?" HREF="http://blogs.sun.com/roller/page/alur?entry=soa_oo_or_so">SOA: SO or OO - How You Gonna Get There? at <A title="SOA: SO or OO - How You Gonna Get There?" HREF="http://blogs.sun.com/roller/page/alur?entry=soa_oo_or_so">http://blogs.sun.com/roller/page/alur?entry=soa_oo_or_so

Posted by Deepak Alur on October 18, 2005 at 01:24 PM PDT #

I think James' idea is that OOP is a platform where you can do SOA. not that SOA is a sub set of OOP.

I liken OOP to a world and SOA is the architecture of a building in the world. You can have many different kinds of buildings with the same architecture and many different architectures in the same world.

To tie it in-line, you can also have the same architecture(SOA) in different worlds(OOP, procedural etc) So SOA would be like a architecture of an inter-dimentional portal that allows different buildings in any world to communicate.

Posted by Choon Whee on October 18, 2005 at 08:07 PM PDT #

James,

I think you get OO's connection with SOA very well but I'm not sure everyone reading your blog is getting it (or maybe I'm misunderstanding your intent and everyone else is reading your mind!). In my view, the relationship between OO and SOA is that OO provides both the fundamental design principles for SOA (that is, service/state encapsulation and loose-coupling) as well as providing a natural development style to implement SOA. However in relation to your closing comments, I think statelessness and idempotence are design characteristics supporting scalability and fault-tolerance, not service-orientation per se.

I say more about this perspective on SOA over on blogs.sun.com (March '05) and colmsmyth.blogspot.com (just now).

(BTW, I find your blog quite illuminating but the light refraction diagrams in the background are distracting!)

All the best,

Colm.

Posted by Colm Smyth on October 19, 2005 at 12:03 PM PDT #

<html>

Based on the wikipedia definitions of OOP and SOA, comparison between OOP and SOA is like comparing an architectural methodology with a programming model.

I think Colm is correct that OOP provides concepts used for SOA and that SOA is not a subset of OOP per se.

Also, the third diagram shows that OOP-ITL is subset of SOA. Maybe that is a correct representation (or maybe I misunderstood the diagram)!

Regards Anil </html>

Posted by Anil Jeswani on November 30, 2005 at 03:58 AM PST #

Now I:m on research how to convert bpmn to bpel4ws,It:s all based on sop.

Posted by glen on March 12, 2006 at 09:23 PM PST #

Dear Mr. Gosling. I've just read an article about JEE 5 that about to be dying in SOA world (the article). I am quite agree with that, because of how the JCP disagree with Rod Johnson's Spring Framework. I think the Spring Communities must be taken seriously by The Sun because the Lightversion (or, the Agile) Java should be taken into account as the JEE Saviour. Using that starting point, currently I am reading the Anil Hemrajani, Agile Java, Spring, Hibernate and Eclipse Book ((the book)). And wish me luck in my journey to strengthen my knowledge of ... Neo JAVA With love, Eko SW JUG in Indonesia I love the Community sooo much!!! Thanks Mr. Gosling...

Posted by Eko Suprapto Wibowo on July 28, 2006 at 07:28 PM PDT #

手机铃声下载 免费铃声下载 手机铃声免费下载 免费铃声 免费手机铃声 三星铃声诺基亚手机铃声 特效铃声 和弦铃声 移动铃声 nokia铃声 波导手机铃声 nec手机铃声下载 联想手机铃声 摩托罗拉铃声 手机彩铃下载 炫铃 酷铃 手机铃声制作 小灵通铃声 移动手机铃声 手机短信 手机动画 手机彩图 手机铃音 短信铃声 来电铃声 音乐铃声 歌曲铃声 铃声试听 手机壁纸 v3铃声下载 手机待机图片 免费手机图片手机游戏 手机电影夏新手机铃声 松下手机铃声 cect手机铃声 和炫和旋铃声 海尔手机铃声 索爱手机铃声 康佳手机铃声下载 手机彩信 真人真唱铃声 mmf铃声 lg手机铃声 tcl手机铃声 手机图片 图铃下载 联通铃声下载 mp3铃声 三星手机铃声 mp3铃声下载 诺基亚铃声 midi铃声 搞笑铃声 mid铃声 原唱铃声 amr铃声 联通彩铃下载 联通炫铃下载 联通手机图片 韩国电影 两性知识 性爱图片 最新电影 宽带电影 经典电影 恐怖电影 十八电影网 人体艺术 美女图片 美女走光 美腿图片 强奸小电影 美女祼体图片 黄色电影下载 免费色情电影 两性生活 性教育片 激情电影 免费黄色电影 成人性爱电影 免费小电影 免费性电影 免费成人电影 免费电影在线观看 免费影片 最新大片 美女写真 性感美女图片 做爱图片 美少女图片 日本av电影 情色电影 激情视频下载 明星露点图片 激情写真 阴部图片 乳房图片 全裸美女 淫荡小说 淫乱图片 美女脱衣 裸体女人 女性手淫图片 波霸美女 淫水美女鲍鱼 阴户阴道臀部 美女图库 美女口交 免费电影下载 免费在线电影 看免费电影 免费电影网站 明星裸照 性爱视频 偷拍图片 泳装美女 美女内衣内裤 性爱贴图 性生活图片 作爱图片 性交姿势 做爱电影 性福联盟 人体摄影 裸女图片 乱伦小说 强暴电影 轮奸视频 迷奸图片 乳房写真 性爱小说 美眉写真 激情贴图 两性性生活 作爱图库 性交图片 做爱图片 人体摄影 美女裸照 全裸女 黄色小说 成人小说 强暴少女 轮奸美女 泳装图片

Posted by 天天免费电影 on August 05, 2006 at 12:54 AM PDT #

[url=http://www.fuwu818.com/wlgg/index.htm ] 装饰公司[/url]
[url=http://www.fuwu818.com/wlgg/index.htm ] 装修公司[/url]
[url=http://www.fuwu818.com/wlgg/index.htm ] 酒店装饰[/url]
[url=http://www.fuwu818.com/wlgg/index.htm ] 宾馆装饰[/url]
[url=http://www.fuwu818.com/wlgg/index.htm ] 餐厅装修[/url]

Posted by ryry on September 21, 2008 at 06:10 PM PDT #

http://www.nizikaikun.com/
http://www.ms-online.co.jp/eshop/goods/ona_hole.php
http://www.ms-online.co.jp/eshop/goods/costume.php
http://www.ms-online.co.jp/eshop/goods/vibe.php
http://www.ms-shop.co.jp/shop/goods/goods.asp?category=5308
http://www.omochacha.com/
http://www.av-one.jp/zero/top.html
http://www.a-world.co.jp/
http://www.a-toy.ne.jp/
http://www.s-one-company.jp/
http://www.ec-life.co.jp/bath/index2.html
http://www.tbnetjapan.com/medlegal/
http://adultshop.co.jp/omocha.html
http://adultshop.co.jp/adultshop.html
http://adultshop.co.jp/enemagra.html
http://adultshop.co.jp/onahole.html
http://adultshop.co.jp/houkei.html
http://adultshop.co.jp/anal.html
http://adultshop.co.jp/denma.html
http://www.nicolas-dogs.com/
http://www.aqua01.net/
http://www.kabudayo.com/
http://www.fxf-business.com/
http://kaketayo.sakura.ne.jp/
http://www.11cash.net/
http://telink.jp/
http://www.complete-watch.com/

http://adultshop.co.jp/dutch.html
http://www.blyjapon.com/
http://www.achelabo.jp/
http://umanity.jp/
http://www.worldflower.net/rs/
http://furniture.michiookamoto.com/
http://www.blyjapon.com/
http://www.achelabo.jp/
http://www.open-japan.com/
http://www.open-japan.com/ideabox/index.php?category=beauty#top
http://www.open-japan.com/ideabox/index.php?category=dress#top
http://www.eic-av.com/
http://www.eic-av.com/list/fileIndex
http://www.saimu0.jp/
http://www.chasetokyo.com/charge.html
http://www.chasetokyo.com/whereabouts.html
http://www.chasetokyo.com/action.html
http://www.chasetokyo.com/immorality.html
http://www.chasetokyo.com/philippines.html
http://www.sigmac.jp/
http://www.tokei-biho.com/
http://www.rmtplusone.com/lineage2/
http://www.takumi-pg.com/
http://www.webtravel.co.jp/asia/chaina/
http://www.webtravel.co.jp/
http://www.trivy-system.com/Kekkon.htm
http://www.trivy-system.com/Sinyou.htm

Posted by thanhvn on December 18, 2008 at 07:43 AM PST #

Post a Comment:

Name:
E-Mail:
URL:

Your Comment:

HTML Syntax: NOT allowed