on 01-11-2010 10:42 PM
Hi
i have a basic question regarding how file sender communication channel ( where we poll for a particular file pattern either using file/ftp types in a particular subfolder ) or a sql sender communication channel - ( selecting records from a sql source ) would work in a scenario with two active XI instances and j2EE file and sql adapter services running on both of the J2EE servers ?
1. How would the file polling from both J2EE servers - avoid a conflict looking for the same file pattern ? Is there any inbuilt mechanism from SAP to make multiple instances work with the file polling - without a confict ?
2. Simlar question for SQL sender type communication channel ?
If SAP does have a mechanism to handle multiple instance scenarios for file and sql sender adapter based communication channels, is there a link/document on this ?
Hi ,
I think in that case there will be two instance of adapter engine running on corresponding Adapter Engine, so there is no question of conflict !
Thanks,
Sunil Singh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
>
> Hi
> My question is : if two instances are polling for the same file - will it not result in a conflict - when both communication channels try to grab the file at the same time ?
if both the instances are live, and there are two CC pointing to the same file it will be a conflict.
Actually even if you have only one instance and there are two CC pointing to the same file, you will still have a conflict
Hi Shabarish
In this case, with multiple instances and the file adapter services running on all instances, what is the best way to avoid conflicts with file sender adapter communication channels ? Should we be running the file adapter services only on one of the J2EE servers to avoid conflicts in polling ?
I hope I was able to articulate my question and have been clear.
my understanding is that when using multiple instances (usually for HA or load balancing), at any one point your CC will point only to one instance. There wouldn't be a possibility of the same adapter pointing to multiple instances and the call being made.
In simple terms, unless you configure 2 CC/adapters pointing to the same file, i dont see any issues.
Hi Shabarish
Your answer -
"my understanding is that when using multiple instances (usually for HA or load balancing), at any one point your CC will point only to one instance"
Do you mean that communication channels will be active on only on J2EE server though there is a second J2EE server running ? My understanding was that - the adapter services ( ftp , sql etc ) and hence the communication channels using those services will be active on each and every J2EE server instance that is up and running .
Can you please clarify ?
Hi Karthik,
Please refer SAP NOTE 801926.
In Sender Channel, in Advanced Parameters you need to set clusterSyncMode = Lock
When this option is set, file adapter acquires a enqueue service lock which will never allow channel to work on multiple Server nodes.
This will definately solve your issue.
Hi Shabrish,
If above parameter is not configured, there is possibility that in HA environment two server nodes are trying to pull same file creating lock. We faced this issue in production and after configuring above parameter it solved our issue.
-Gouri
Hi Karthik,
You dont have to set this parameter for SQL Sender adapter. In case of SQL, DB will take care of this.
In case of SQL, u might face a problem that whatever records you are selecting same records should get modified with Update Query. In that case you need to use Serializable option from advanced parameter.
-Gouri
Gauri - I will take a look at the OSS note that you forwarded for the SQL sender adapter . When you say 'DB' will handle this, may I know what you mean by that ? Are these details addressed in the OSS note ?
Also, regarding your other point - of setting the serializable property in the sql sender adapter to ensure update statement picks up the same data set as that is being selected, this is irrespective of a cluster node scenario , right ? i.e even if there is only one instance/node, the serializable property has to be set in the communication channel to ensure update statement and select statement work as a single LUW. Am I right ?
Gouri
The OSS note 111291 does not give any specifics regarding jdbc sql sender adapter - its a generic note on the sql server locks.
I am just wondering aloud - what will happen if we use a select for update clause in the sql sender adapter communication channel - will this ensure that polling from one J2EE instance will lock the selected records so that the second instance does not select the same set of records from the sql server ? Or should we not use a select for update and use a simple select statement ?
Hi Karthik,
Please see my comments.
I am just wondering aloud - what will happen if we use a select for update clause in the sql sender adapter communication channel -
Gouri: Yes you can use select + update. In fact that is the right way.
will this ensure that polling from one J2EE instance will lock the selected records so that the second instance does not select the same set of records from the sql server ? Or should we not use a select for update and use a simple select statement ?
Gouri: Yes. SQL DB will ensure that same data will not be picked by another node. As I mentioned earlier use serilizable option from advanced mode.
-Gouri
User | Count |
---|---|
91 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.