Heroku External Objects
Last updated 27 March 2019
Heroku External Objects is available as part of Heroku Connect. It provides an oData wrapper for a Heroku Postgres database that has been configured for use with Heroku Connect. This feature allows other web services to retrieve data from within the specified Heroku Postgres database using RESTful endpoints generated by the wrapper.
Used in tandem with Salesforce Connect, the feature permits data in a Heroku Postgres database to be represented in a Salesforce deployment, where it can be viewed (including within Apex and Visualforce pages), searched, and related to other objects. It cannot be used in standard reports as the data is only available by reference.
Service Authentication
External Objects service endpoints are protected by basic authentication. Once the service is enabled, credentials can be viewed, reset, and revoked from the External Objects settings page.
When you reset your credentials, there is a 10 minute window in which both your old credentials and your new credentials will be accepted. This allows you to update the credentials of your consuming services without incurring downtime.
Resource Configuration
When the External Objects service is active for a connection, a list of available tables and views will appear in the External Objects settings page. Tables and views across all schemas within the associated connection’s database will be available, including those schema not actively managed by Heroku Connect as part of the synchronization service. Any of these tables or views can be enabled or disabled as a resource in the External Objects service by selecting the corresponding checkbox in the settings page.
Tables must contain a primary key to be enabled as an External Objects resource.
Rate limits
The External Objects service is rate-limited at 20,000 requests per service, per hour for the shield
, enterprise
, or danketsu
paid plans; rate limits can be increased on request. For the demo
plan, the limit is 1,000 requests per service, per hour. Attempting to access services after this limit has been reached will result in a 429 Too Many Requests
error. The response message will also contain information about when to expect to be able to make another API request. Rate limit throttles reset at the top of each hour.
{"message":"Request was throttled. Expected available in 1000.0 seconds."}
Logging
The External Objects service currently does not support logging of requests made into the service. Administrative changes made to configuration such as credential reset and revocation, and database object inclusion and exclusion are logged, however.
Supported Data Types
Heroku External Objects supports the following PostgreSQL data types:
bigint
boolean
bytea
-
character
/character varying
date
double precision
integer
numeric
real
smallint
text
time
timestamp
uuid
If you enable a table or view that has an unsupported data type, the unsupported field will not be included in results.
Limitations
Case-insensitive search
Searches in Salesforce for data in External Objects are done in a case-sensitive manner. Case-insensitive searching is currently not supported by Heroku External Objects.
Batch Apex
Using Batch Apex in Salesforce to query Heroku External Objects is currently not supported.
Global Search
Heroku External Objects does not presently support Global Search queries from Salesforce Connect.
Query Time Limit
Queries generated by Heroku External Objects must complete in 20 seconds or less, otherwise Heroku External Objects will return a 530 response to Salesforce Connect.
Compress Requests
Enabling the Compress Requests option for an External Data Source in Salesforce is currently not supported.