Q & A. XIII

Q:

Is there any way to directly run a Java server method on a specific Docbase service instance (in HA setup)?

I have a workaround with a job set up to run on designated target server, however I want to execute a method instantly via the “EXECUTE do_method…” call for example, instead of relying on the agent exec scheduler.

Thanks.

A:

The answer depends on what you are really want to achieve, let’s explain. When you are executing docbase method (next discourse is about Java methods only) there are at least three participants:

  1. Content server which sends http request to JMS and waits for response – your current session
  2. JMS instance that executes you docbase method – in normal situation content server always prefers “embedded” JMS instance
  3. Content serves JMS instance connects to – it depends on how your docbase method is written (for example in case of workflow and job methods content server provides -docbase_name argument using <docbase>.<server> form, so it binds JMS instances to specific content server

As regards to your problem…

If you want to stay within “EXECUTE do_method…” the answer is: “No, you can’t influence on how content server selects JMS instance, if you want to execute docbase method on specific JMS you need to connect to corresponding content server”.

However, if your objectives are something like “We need to execute com.documentum.fc.methodserver.IDfMethod on specific JMS instance”, the answer is “Yes, it is possible:

API> retrieve,c,dm_server_config
...
3d024be980000102
API> dump,c,l
...  


  app_server_name [0]: do_method
                  [1]: do_mail
                  [2]: do_bpm
                  [3]: heavy_proc <- this one runs the show
  app_server_uri  [0]: http://localhost:9080/DmMethods/servlet/DoMethod
                  [1]: http://localhost:9080/DmMail/servlet/DoMail
                  [2]: http://localhost:9080/bpm/servlet/DoMethod
                  [3]: http://localhost:8888/


~]$ nc -l 8888
... waiting ...

API> apply,c,,HTTP_POST,
      APP_SERVER_NAME,S,heavy_proc,
      ARGUMENTS,S,'
        -method_verb MyMethodClass 
        -__dm_docbase__ DCTM_DEV 
        -__dm_server_config__ DCTM_DEV 
        -docbase_name DCTM_DEV.DCTM_DEV 
        -user_name dmadmin 
      ',TRACE_LAUNCH,B,T
...
q0

~]$ nc -l 8888
POST / HTTP/1.1
User-Agent: Documentum Server 7.2.0030.0195  Linux64.Oracle (HTTP Client)
Host: localhost:8888
Connection: close
Content-Type: application/x-www-form-urlencoded
Content-Length: 567

__signature_params__=method_verb.....

One thought on “Q & A. XIII

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s