8

The Salesforce Integration Patterns workbook suggests the use of the Streaming API to give an customer service agent a real time notification of a client payment.

However the Streaming API is limited to 20 topics each with 20 Subscribers for each EE and UE org.

This to me seems to indicate their advice is invalid as it seems to be only suitable for limited use scenarios.

Have I misunderstood?

3
  • 2
    Nope, you have not misunderstood. The streaming API is totally unsuited for "server-to-user" scenarios unless you have a VERY small number of users. It's suitable for "server-to-server" streaming only, and even then is inexplicably crippled by the topic limit. The few times I've come across a use case for it, the limits have ruled out the streaming API.
    – jkraybill
    Commented Jan 22, 2013 at 3:44
  • Actually I've seen this been demonstrated in sever-to-user scenarios as well. So I think the messaging is a little mixed on this from Salesforce. What I have been told on occasion is that Salesforce Support will consider use cases for increasing the limit, as it is set very low at present while Salesforce measure the impact of the feature in a production environment. I've not had cause as yet to confirm this process however. Commented Jan 22, 2013 at 14:00
  • 1
    Seems pretty confirmed by @metadaddy's comment below, although as always, a PM saying "no problem" and actually getting a case through support, approved and to the right channels are not always the same thing.
    – jkraybill
    Commented Jan 28, 2013 at 1:57

4 Answers 4

15

Word direct from the API PM:

We have customers doing thousands of clients… one customer is going to do 150K clients.

Folks just need to ping us for an increase request. We like to rollout things small and grow as we move forward. We just doubled our limits. We will continue to do that.

In the mean time we can increase folks no problem.

2
  • 1
    They can go up to 150K clients?! Wish this was more well-advertised. The limits as they currently publish them really limit the usefulness of the API.
    – jkraybill
    Commented Jan 28, 2013 at 1:56
  • 1
    I've requested a note to that effect in the API docs.
    – metadaddy
    Commented Mar 9, 2014 at 6:38
5

Actually I've seen this been demonstrated in sever-to-user scenarios as well and thus this question tends arrise from those thinking ahead in the audience! As such I think the messaging is a little mixed on this from Salesforce. What I have heard being told on occasion is that Salesforce Support will consider use cases for increasing the limit, as it is set very low at present while Salesforce measure the impact of the feature in a production environment. I've not had cause as yet to confirm this process however.

2

Another angle is to use a third party web application, subscribe to the topic, and then portray that application within SFDC as a Canvas application.

Daneil Llewellyn/Kenji776 has an example here: http://iwritecrappycode.wordpress.com/2012/10/01/node-js-socket-io-and-force-com-canvas-and-you/

1

Didn't play with Streaming API yet but I guess "it depends how you'll structure your query".

If you'll want 1 query per customer/support agent - yeah, you'll run out of topics. But something like

SELECT Account__r.Name, Name, OwnerId
FROM Invoice__c 
WHERE Status__c = 'Paid' AND LastModifiedDate >= TODAY ORDER BY LastModifiedDate

might work very nicely (should change every time any record changes, right?)

I'd probably go even further and want to enable field history tracking on this payment status and query the history table to filter out subsequent updates (say "paid & closed"). I don't know if querying History tables is supported though. Could also have WHERE Payment_Date__c = TODAY?

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .