Resolving the Source of Truth Conflict in 4 Clicks
One of the best TrailheaDX sessions was their traditional Meet the Developers panel. As always, the panel included some great audience questions and an oppotrunity to learn about the vision and future roadmap of the Force.com platform. Towards the end of the panel, a very interesting question arose:
The question, edited lightly for clarity:
…I understand from this conference…[that]… now that the real source of truth is my Git…maybe you can correct me if I’m wrong. Eventually the org is the source of truth because if I change something in my org eventually this is the source of truth. And what I am expecting is this thing should be more of a sync between my org and my Git. Something like that. First question, am I right and second question, if I am right is there some kind of change [coming]?
The bravery of the question is evidenced by the initial response: “He’s admitting to making production changes, that’s what he’s doing.”
But the audience persists and reminds the panel that an admin or a developer might be doing something as simple as changing an email template in a sandbox. This is a change most easily made directly in an org rather than putting it into source control. Thus, it can be difficult to get these kinds of declarative or point and click changes into source control.
We have talked to a lot 1-2 developer teams. There are many people who can make changes in their orgs who do not have adequate training or background in source control or Git. These teams often find that work will be changed directly on a sandbox without having first gone through source control. Maybe an admin just needed to quickly update a field. Maybe a sales operations specialist was asked by a frantic Sales VP to change a workflow at the end of a quarter. Who knows? But these are realistic scenarios in which the org remains the source of truth.
Salesforce DX makes a bold and important claim: source control is now the source of truth. But there is an issue here. Unlike other platforms where it might be difficult to actually make changes on the fly in prod, it’s easy to do so in Salesforce. This is even one of the purported benefits of using the clicks not code platform. Starting to use source control is great, but it’s still possible to make changes in prod and sometimes even desirable. Despite the claim that it is a best practice to make source control the truth, the fact of the matter is that whatever is running in production is running in production. We have to be honest about how flexible Salesforce is and the fact that so many people can make changes to an org is a major part of it’s appeal.
We built Blue Canvas because we had the same question as the gentlemen before the panel. In order to leverage the awesome benefit of Salesforce DX you will need to treat source control as the source of truth. Blue Canvas makes this easy to achieve for your entire team because it automatically and continuously checks your orgs for changes and commits them into a Git repo as they happen in real time. Blue Canvas even includes time stamps and the commit author by grabbing the Salesforce username of the user who made the change. The fact that this is done automatically makes it possible to finally treat your source control repository as the source of truth because you know that what is in source control accurately reflects what is going on in your orgs. This is extremely comforting.
Blue Canvas requires no training. You can set it up in 4 clicks using the Salesforce OAuth flow. Once that’s done you will have an answer to the question posed and the ability to know exactly what is happening in your orgs.