3

I am very familiar with Salesforce 2 Salesforce (S2S) and it works well for sharing data going forward between production-production orgs or sandbox-sandbox orgs, either automatically or manually. In fact, I understand that it also even works with production - developer orgs too, as per: How to connect Salesforce to Salesforce in Apex.

However, there are other methods of integrating Salesforce orgs with each other, as per: Integrate two Salesforce developer orgs. The most common alternative to using S2S seems to be leveraging the REST API. This link goes into some helpful detail on that: How can i integrate one SFDC org to another SFDC using Rest Api. Also, http://amulhai.blogspot.co.uk/2015/11/salesforce-to-salesforce-integration.html.

I understand that S2S is out of the box and is the default answer when choosing to integrate two Salesforce orgs with each other. But I'm curious to know what one can do with the REST API, or another option, that one couldn't with S2S.

My question is: what are the pros and cons of using S2S over the REST API, Named Credentials or External Objects alternative methods?

3

There are no benefits to any alternatives to S2S, because S2S was purpose-built for the task, and was actually designed and included because there were other solutions out there that were not as efficient as having a native solution.

Benefits to S2S include more real-time integration than other solutions, no-code-necessary configuration and setup, built in GUI and programmatic access to the feature, doesn't consume limits, like daily asynchronous limit, API limits, email limits, has automatic retry and error handling, development time required for alternative solutions versus S2S, the list goes on and on. There is no other solution that can compare.

You may as well be asking which is more efficient for driving around town: getting a car for free that you can use to drive around town, or buying and building all the parts your own car from the frame up. Sure, you can build that car if you want to, but why would you when someone just gave you a car to use? There's some people that enjoy a challenge and want to do everything themselves, and that's okay--they can use REST, external objects, etc. For the admin who simply wants to run their business, use S2S. It's the correct tool for the job.

  • yet again, another brilliant answer. Many thanks!! 1) If an organisation has a particularly complicated requirement to connect 3..* Salesforce organisations together, what would you recommend in that use case? I suppose S2S could be used between A and B, and B and C. In this way, S2S can handle actually n..* of integrations and not just 2..2? 2) I'm also interested if there's a limit as to how many S2S integrations an org can actually have? I couldn't find this information in the docs. Lastly...3) if an org A is on EU1 and org B is on EU2, which server does the processing? Thanks :) – Andy Hitchings Nov 22 '16 at 20:36
  • 1
    @AndyHitchings (1) As far as I know, there's no limit on connections. I'd probably recommend a star topology; A should connect to B, C, D, E... so all data goes through the central point. (2) I've never run into a limit or found a documented limit. It's meant to be used as often as you need. (3) Both servers do the processing; EU1 sends it to EU2, and once approved, DML processing occurs on EU2. I'd imagine there's some staging servers inbetween that manage those data migrations, but it's not documented. – sfdcfox Nov 22 '16 at 20:45
  • 1
    @sfdcfox - It looks like s2s uses api limits. pls see help.salesforce.com/…. Can you please clarify. – ManishG Oct 22 '18 at 11:08

Not the answer you're looking for? Browse other questions tagged or ask your own question.