New Posts New Posts RSS Feed: 2-Tier App connect to Remote BOS
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

2-Tier App connect to Remote BOS

 Post Reply Post Reply
Author
sebma View Drop Down
Groupie
Groupie
Avatar

Joined: 19-Aug-2008
Location: Singapore
Posts: 66
Post Options Post Options   Quote sebma Quote  Post ReplyReply Direct Link To This Post Topic: 2-Tier App connect to Remote BOS
    Posted: 10-Feb-2012 at 1:52am
Hi,

I am using DevForce 6.1.5.
I have a 2-Tier application (Windows Service) that performs updates in the backend directly to database.
I now want this 2-Tier app to login to a remote BOS to perform just some specific tasks via existing RPC methods.

The following link show how to use ServiceKeys to connect to multiple BOS:
http://drc.ideablade.com/xwiki/bin/view/Documentation/connect-to-multiple-entityservers

However, I am not sure about the following config. The 2-Tier app will connect to its own local (in-process) BOS because this 2-Tier config does not set <clientSettings isDistributed="true" />

 <ideablade.configuration version="6.00" xmlns="http://schemas.ideablade.com/2010/IdeaBladeConfig">
    <objectServer remoteBaseURL="http://localhost" serverPort="9010" serviceName="LocalEntityService"/>
       <serviceKeys>     
         <serviceKey name="remoteBOS" remoteBaseURL="http://localhost" serviceName="EntityService" serverPort="9009" />
       </serviceKeys>

I know one can resort to writing own WCF.
The question is how can I use DevForce to simplify this by enabling an existing 2-Tier app to call the remote BOS specifically?

Best Regards
Seb
Back to Top
kimj View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 09-May-2007
Posts: 1391
Post Options Post Options   Quote kimj Quote  Post ReplyReply Direct Link To This Post Posted: 10-Feb-2012 at 11:02am
Hi Sebastian,
 
When you create an EntityManager it will by default use an EntityServiceOption setting which tells it to look at the clientSettings in the config file.  Here, to get your EntityManager talking to a remote BOS, you should pass an EntityServiceOption.UseDistributedService parameter into the constructor.   You don't actually need to use a serviceKey here, but can.  If you don't use a serviceKey, make sure that the settings on the objectServer are correct for the remote BOS.  (They're actually ignored altogether when running in 2-tier mode.)
 
 
Back to Top
sebma View Drop Down
Groupie
Groupie
Avatar

Joined: 19-Aug-2008
Location: Singapore
Posts: 66
Post Options Post Options   Quote sebma Quote  Post ReplyReply Direct Link To This Post Posted: 12-Feb-2012 at 8:44pm
Hi Kim,
 
Thanks for the tips. This is exactly what I wanted.
 
Thanks much!
Seb
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down