Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Service Locator EJB Component - Clustering -oracle9iAS  RSS feed

 
Viral Thakkar
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all,
Anyone has idea on how to implement the service locator (EJBHomeCache) component to make it cluster aware. I am using the oracle9iAS server.
thanks,
Viral
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What do you mean by cluster aware? If you get an EJBHome reference from the clustered JNDI tree, you shouldn't need anything else. I think. The EJBHome proxy itself should have the functionality to fallback to another server instance if the primary goes down etc.
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I can't get a response from the server. Are you sure this URL is still valid?
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, it is valid. I am able to access the site.
Try from http://otn.oracle.com/documentation/ias.html and then log into OTN.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For some reason, the firewall blocked the requests. I found the docs using the laptop... Thanks.
 
Viral Thakkar
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
by cluster aware, i mean if i get a EJB Home reference from cache (using the Service Locator component) and the server having the object, is down so here i may get some exception.. so how i should make sure in my program so that i dont get this exception..
i referred to the EJB clustering link but here nothing is mentioned about EJB reference from the cache....
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess that if you cache the ejbhome and servers in cluster are added or removed the stub will not be aware of it.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
by cluster aware, i mean if i get a EJB Home reference from cache (using the Service Locator component) and the server having the object, is down so here i may get some exception.. so how i should make sure in my program so that i dont get this exception.

Your service locator could hand out dynamic proxies, which intercept every call to the EJBHome, catch the first exception, retry after looking up a new reference from JNDI, and if it still throws an exception, rethrow it to the client.
Another possible approach has been presented in a JavaWorld article on Verified Service Locator
Pradeep, I think most containers don't have the functionality to inform existing stubs about new/dead servers but it wouldn't be that difficult to implement, I guess.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry for the duplicate post.
[ August 06, 2003: Message edited by: Lasse Koskela ]
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Weblogic server provides smart stubs.
I doubt whether ServiceLocator pattern will be useful in Oracle 9ias.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I doubt whether ServiceLocator pattern will be useful in Oracle 9ias.

Why? The performance implications of caching homes should be the same for Oracle than for BEA, IBM and others.
 
Pradeep bhatt
Ranch Hand
Posts: 8933
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I rephrase it as - "It will not able to detetct new or removed servers, since it is cached".
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!