Newer Version Available

This content describes an older version of this product. View Latest

Data Differences in Event Fields

When the updated text field value is sent as a diff, it contains the SHA-256 hash value and data differences in the unified diff format.
The field whose data is sent as a unified diff contains a value in this format.

Example

In a Pub/Sub API client, the field contains the unified diff value in this format.

And the fields whose values are sent as a unified diff are listed in diffFields in ChangeEventHeader.

In a Streaming API (CometD) client, the field contains the diff subfield, which contains the unified diff value.

This change event is received in a Pub/Sub API client after the Description field with more than 1,000 characters is updated for an account. The Description field contains the hash value after the +++ prefix followed by the data differences.

The updates made to the diff field are the following.

  • In the paragraph starting with “Business applications,” the word “applications” was replaced with “apps.”
  • In the paragraph starting with “As cloud computing grows,”, one sentence was appended at the end of the paragraph: “And keep in mind that if you have to buy and manage hardware and software, what you’re looking at isn’t really cloud computing but a false cloud.”

This event for the account creation shows the original and full values in the Description field before it was updated. If you generate the SHA-256 hash on the full value, you get the same value sent in the account update event (682b8747ccdb93b546e7bbe479b27d26ec7c38ccabb76cdd8308c6595492bffc).