Writing
31 posts on four lines. The Salesforce line is where I started. The other three are what I work on now: GTM systems, data systems, and LLMs and agents.
GTM systems
Eight postsCRM platforms, quoting, territories, and the revenue systems around them, plus the integrations that keep them in step.
-
One create service for every new CRM record, agents included
Every new account and contact, from reps, imports, forms, integrations or agents, goes through one create service that normalizes, scores matches and stamps who made it.
-
Finding the CRM integration whose token dies between runs
Keep every CRM integration in a git registry and check it nightly against token history, so a job whose token dies before its next run gets flagged weeks early.
-
Moving business logic out of the CRM, one capability at a time
The strangler pattern for a heavily customized CRM: a thin router, a flag per capability, shadow runs that compare answers, and results written back.
-
Catching usage contraction before the renewal, and what the agent may do alone
Compute usage contraction in the warehouse as dollars at risk, sync three fields to the CRM account, and write down what a renewal agent may do without a named approver.
-
Quote-to-cash at a high level: where the time goes and how to get it back
A quote takes milliseconds to compute and days to produce. Where catalog, pricing, approvals, contracts, orders, and billing lose time, and how to win it back.
-
Designing a territory assignment engine
How I'd design the engine that assigns sales accounts to territories: rules as data, deterministic matching, stored explanations, dry runs, and careful publishing.
-
Keeping CRM systems in sync with events instead of batch jobs
Most sync bugs are ownership arguments nobody had out loud. Settle who owns each field, then move changes through an ordered log.
-
Converting CRM automations without changing the order they run in
A converted automation usually keeps its logic. Run order, save phase and run-as user are what move, so map every write, replay real saves in two sandboxes and gate on the diff.
Data systems
Eight postsPipelines, lakehouses, streaming, data contracts, and the definitions that analytics and agents depend on.
-
Agents ask the warehouse the same questions all day, in different words
Agent queries hide under one service account and miss the result cache. Tag them, fingerprint the history, promote the shapes that repeat, and budget the rest.
-
Data contracts between teams, and the CI rules that make them stick
A YAML contract in the producer repo, three CI rules, a registry, and a slow lane for breaking changes, so upstream edits stop breaking downstream data.
-
From the app database to the warehouse in minutes
Streaming changes from an application database into a lakehouse table: read the log, a Kafka topic per table, upsert by key, compact, and count every night.
-
Batch data pipelines that survive a bad night
The night everything works takes care of itself. Scheduled jobs built for the other night, when a broken source should end in a clean rerun.
-
Before a second engine writes to your lakehouse table
An open table format lets several engines read the same files. It doesn't decide who commits or who sees which rows, so give each table one writer and define its policies once.
-
The pipeline history your CRM doesn't keep
A CRM stores the pipeline as it is now, but forecast calls ask what changed. A daily snapshot and day-over-day change facts in the warehouse give the forecast a memory.
-
A data agent shouldn't get to guess what revenue means
A data agent picks a meaning and sounds sure either way. Make it look up every business term in a small, owned registry before it writes SQL.
-
Cheap to write, expensive to keep: the data models nobody reads
A decision brief to merge, a reconcile test to publish, and a usage ledger that retires dbt models nobody reads, judged against each model's own read cadence.
LLMs and agents
Eight postsPutting models to work on real systems: retrieval, tools, evals, cost, and the guardrails around agents.
-
Keeping LLM costs predictable as usage grows
The LLM bill that gets a meeting arrives months after launch. Pricing every call in one place, before the provider sees it, keeps that bill from being a surprise.
-
Finding out your LLM feature got worse before your users do
A golden set of real inputs, graders from cheap to slow, and a CI gate that can say no: catching an LLM feature getting worse before users do.
-
When RAG gives a wrong answer, check what it retrieved first
Wrong RAG answers usually start in the search step. A starting design with hybrid search, reranking, citations and a handoff, plus retrieval tests you can copy.
-
The architecture of a customer-support AI agent
A public support agent should answer when it has grounds to and hand the conversation to a person when it doesn't. What that takes.
-
Split the task before you run coding agents in parallel
Before running coding agents side by side, give every file one owner and commit the shared interfaces first. A path check in CI enforces the split, and a baseline prices it.
-
Putting an LLM inside the CRM, where the work already happens
An LLM feature in its own tab goes unused. Put it on the record the rep already has open, then deal with the permission and review questions that come with that.
-
Shrinking the blast radius of a coding agent
If a coding agent's session leaked tonight, what could someone do with it, and for how long? Five controls that shrink both answers, and what each costs in friction.
-
Fix your coding agent's harness before you switch models
Before paying for a bigger model, test the harness around your coding agent on your own merged PRs, one change at a time.
Salesforce platform
Seven postsApex, Visualforce, and SSO posts from 2015 and 2016. Kept for the people who still find them through search. Some details are dated.
-
Salesforce SSO Implementation
A walkthrough of federated SAML single sign-on for Salesforce: scope, as-is and to-be process, SSO settings, user Federation ID and best practices.
-
Analysis of Metadata AppExchange products
Compares three free AppExchange tools for extracting and tracking Salesforce object metadata: EasyDescribe, Object Metadata Snapshot and Config Workbook.
-
Visualforce Email template with component to render attachment
How to build a Visualforce component rendered as a PDF attachment on a Visualforce email template and send it automatically with a workflow rule.
-
Salesforce Batch class generating results as CSV
A Database.Stateful batch Apex class on Account that collects success and failure records as CSV attachments and emails them from the finish method.
-
One to One relationship in Salesforce
Shows how to enforce a one to one relationship between two Salesforce objects using configuration only, plus two trigger-based options with sample code.
-
Difference between Salesforce.com and Force.com
A plain-language comparison of Salesforce.com, the SaaS CRM, and Force.com, the PaaS platform it runs on, and what each one offers.
-
Salesforce Difference between Abstract & Virtual class and Interface
Explains how Apex interfaces, abstract classes and virtual classes differ, with code examples and the rules for implementing or extending each.