Integration Flashcards
What is required to use Generic Streaming?
- Streaming Channel.
- Client Subscription
- Streaming Channel Push REST API
What are 1st Generation streaming services?
PushTopic (data changes), General Streaming.
Both use Streaming API. First reflect data changes specified in query (PushTopic query). Second one pushes events not tied to record changes.
What are 2st Generation streaming services?
Change Data Capture (PushTopics without queries), Platform Events (new Generic Streaming)
Where External Services can be used?
In Flows
What is max schema size for External Service?
4.0MB
What can be used to cover External Services with tests?
HttpCalloutMock
How to setup ExternalService?
An external service requires a named credential, a url and authentification settings.
It also requires to specify the schema URL path (or endpoint) or the complete schema (OpenAPI 2.0 format) while registering an external service
What is preffered to make synchronous callouts to validate / check something before proceed record in Salesforce?
Make callouts from LWC or Visualforce
Difference between @HttpPut and @HttpPatch?
@HttpPut is used in methods performing upsert-like operations. @HttpPatch is used in methods performing update operations.
Difference between @HttpPut and @HttpPatch?
@HttpPut is used in methods performing upsert-like operations. @HttpPatch is used in methods performing update operations.
How to expose class as a SOAP service?
Mark class as `global`, add `static` and `webservice` declarations to it's methods. Generate WSDL file for consuming.
How to expose class as a REST service?
Mark class as global with @RestResouce annotation with case-sensitive path in urlMapping. All methods should be static, global.
What can be used to parse emails and use data to create records?
Messaging.InboundEmailHandler
How to create InboundEmailHandler?
Create class that implements Messaging.InboundEmailHandler with global-access modifier and has handleInboundEmail(inboundEmail, inboundEnvelope) global instance method that returns InboundEmailResult.
How to return successfull InboundEmailHandler result operation?
Using InboundEmailResult.success = true
What types of return values webservice methods don’t support
- Maps.
- Sets.
- Pattern objects.
- Matcher objects
- Exception objects.
What class is used to mock webservice callout in tests?
WebServiceMock class
What can be used in Visualforce to show reports created in Salesforce?
analytics:reportChart
What Visualforce component can be used to draw the chart from supplied data?
apex:chart
What features can be implemented using External IDs?
Deep linking (links to records in external systems) and mashups (using Canvas).
What is Canvas?
Canvas enables you to easily integrate a third-party application in Salesforce. It’s a set of tools and JS APIs user can use to expose an applications as a canvas app?
It can be used with External ID to create Mashups
What is Salesforce Connect?
Salesforce Connect is used to make external records visible in Salesforce. An external data source is defined for using Salesforce Connect.
What is External Data Source?
Feature that allows to connect the content and data that is stored outside your Salesforce org?
What is required to setup External Data Source?
Specify Label, DeveloperName. Select authentification type and provide credentials
What authentification protocols are available for External Data Source?
Password Auth and OAuth 2.0
What method can be used to synchronously update collection of metadata?
SaveResult[] updateMetadata(Metadata[] metadata)
What can’t be null when creating HttpCallout?
Method and Endpoint
What method is used in generated stub class to make callout to SOAP service?
WebServiceCallout.invoke()
How to create parent and child records in one call cia SOAP API?
Create child, parent reference, parent object. Call the create() method
What is required to setup PushTopics?
Name, query, API version
Which operations PushTopic supports to notify about?
All (including delete, undelete)
At which point of setup of the PushTopic, the channel is created?
After the PushTopic is inserted, the channel is created
What format of PushTopic name?
/topic/PushTopicName
How secure outbound connection to external application in AWS VPC can be setup?
Using Private Connect (AWS PrivateLink)
What type of endpoint does Workflow Rule’s Outbound message action supports?
SOAP
What possible methods types in HTTPRequest instance?
DELETE, GET, HEAD, PATCH, POST, PUT, TRACE
Which annotation is used for Apex class to specify the contenxt if which they should be serialized/deserialized?
@JsonAccess
Structure of package xml file?
Package > Types > Members (* or Developer Name) and Name (name of metadata type, f.e CustomObject or Profile)
How compount fields should be specified in PushTopic query?
Name field optionally can have constituent fields (FirstName, LastName). They can’t be specified without compound field.
Address and Geolocation fields must be included as constituent fields with (optionally) compound field
What makes PushTopic query unsupported?
- Semi-joins/anti-joins (SELECT after WHERE).
- Aggregate functions.
- LIMIT, ORDER BY, GROUP BY, OFFSET, TYPEOF
- Formula field in WHERE clauses
For how long Salesforce store PushTopic-based event and allows to retrieve events?
24 hours
How to deactivate PushTopic?
Create PushTopic specyfing Id of existing one and set IsActive = false and use update(pt)
What is Change Data Capture?
Declarative enhancement of PushTopic that is available from Lightning UI
How to subscribe to Change Data capture?
Using CometD (EMP Connector implements)
How to capture Change Data Capture event in Apex Trigger
Create Trigger on ObjectName(__ for custom and without for standard obj)ChangeEvent.
Trigger available only after insert context
What methods are used to test ChangeEvents?
Test.enableChangeDataCapture()
Test.getEventBust().deliver()
URL format for Change Data Capture?
/data/ChangeEvent
/data/__ChangeEvent
Does Change Data Capture respects field level security?
Yes.
How to specify object name, fields and change type while subscribing to Change Data Capture?
payload. ChangeEventHeader.entityName
payload. ChangeEventHeader.changeType
payload. ChangeEventHeader.changedFields
Which fields are suported for Platform Event?
Date, DateTime, Checkbox, Number, Text, TextArea (Long)
Suffix for Platform Event obj?
__e
How Platform Events can be published?
Using Flows, Processes, Apex, API
How to subscribe to Platform Events?
Using CometD (EMP Connector), Flows, Processes, Apex Triggers, Lightning Component (empApi)