Wondering if Salesforce Suite supports a many-to-one configuration or if there are any significant issues using the module in this way.

I can't find this info elsewhere so apologies if this is not the ideal place to ask.

I have multiple separate Drupal 7 sites (think many chapters of an international cooperative). Profiles are standardised and I would like to sync profiles from across the sites to one instance of Salesforce without creating duplicate records in the event there are users with profiles on multiple sites (which there are).

Is this possible with Salesforce Suite?

Many thanks.

Danny.

Comments

dannybrowne created an issue. See original summary.

aaronbauman’s picture

If your use case is a bunch of Drupal sites push data to a single Salesforce instance, then yes this is workable and probably not terrible to implement.

If your use case is push and pull (ie. bi-directional sync) between multiple Drupal sites and a single Salesforce instance, you're gonna have problems. I would avoid this scenario if at all possible.

dannybrowne’s picture

Yeah, my use case is looking like the second i'm afraid.

Ideally users can login from anywhere and update account details, comms prefs etc. That data would be pushed to Salesforce and held centrally in their Salesforce contact and any updates would pushed back out to any Drupal sites where they hold an account.

Does that use case sound very difficult to implement? What kind of problems do you foresee?

Many thanks,

Danny.

aaronbauman’s picture

Yeah, i think you're gonna have problems there.

For example:
Drupal pulls data from Salesforce on a delay (via cron).
But Drupal pushes form Drupal to Salesforce (via REST) instantly.
So, let's say you cron set to run every 5 minutes.
Then you have 10 users sign up at each of your 10 different sites during that 5 minute delay.
All 10 of them get the same Drupal account id.
5 of them enter the same email address, but different profile info.
What now?
You can use an upsert key on email to minimize duplicates in Salesforce, but which profile info do you keep?
What happens to your Drupal users across sites when you merge your SF Contacts?
What happens when a Drupal user gets deleted on one of those sites?
What happens when a user changes email address to conflict with a user on a different site, which haven't synched with SF yet?

Maybe you will be able to solve these issues, but you're gonna get into the weeds pretty quickly for any substantial user volume.

An alternative architecture I might consider:
- One single Drupal instance where users authenticate, which communicates with Salesforce.
- Bakery (or other shared sign-on) between other Drupal sites, which do not communicate directly with Salesforce.

This will come with its own complications, but I think it lets you minimize the integration points.

dannybrowne’s picture

Thanks for that. Much appreciated. Your suggested architecture is interesting and even appealing.

If we were just pushing data... that would be more of a web to lead setup right? Users wouldn't be able to login and edit account details etc. and that setup would result in lots of duplicates presumably.

Is it possible to maintain a record per Drupal site (contact record for person 1 on site 1, contact record for person 1 on site 2 etc). That sounds technically less problematic but would present other in managing contact information in Salesforce.

We are trying to settle on workable flexible architecture at the moment and it seems like for any more complex configuration our Drupal sites are going to have to become very tightly coupled.

Thanks again.

Danny.

aaronbauman’s picture

Web-to-lead would be one way to implement a push-only solution, but you could do it (albeit with a bit more effort) using Contacts or Accounts or any custom object.

Hard to say what the best architecture would be for your situation without more info, but I don't think I'd want multiple Contact records for the same individuals.
If users need separate Drupal accounts across many sites, maybe Salesforce could track a master-detail (custom) object, subordinate to Contact record, representing Drupal accounts on different sites.

dannybrowne’s picture

In push only web-to-contact setup, users can't login and edit/update account info though right?

What if we were to step away from the Salesforce Suite and write custom code (or a custom module) to push and pull data asynchronously via the REST api?

Sorry... that's my last question. Thank so much for your time. Very helpful indeed.

Danny.

aaronbauman’s picture

If you implemented a push-only solution, then you could in theory give users the ability to insert as well as update.

But when you get into pulling data back to Drupal, essentially you're describing a multi-master database replication problem, which this module is really not designed to solve. You can make some assumptions to greatly simplify the problem space, but synchronous vs asynchronous doesn't get you very far.

aaronbauman’s picture

Status: Active » Closed (won't fix)

7.x is no longer supported

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.