<p>Based on the docs that I've read, there are 3 methods of patching:</p>
<ul>
<li>patches</li>
<li>patchesStrategicMerge</li>
<li>patchesJson6902.</li>
</ul>
<p>The difference between <code>patchesStrategicMerge</code> and <code>patchesJson6902</code> is obvious. <code>patchesStrategicMerge</code> requires a duplicate structure of the kubernetes resource to identify the base resource that is being patched followed by the modified portion of the spec to denote what gets changed (or deleted).</p>
<p><code>patchesJson6902</code> defines a 'target' attribute used to specify the kubernetes resource with a 'path' attribute that specifies which attribute in the resource gets modified, added, or removed.</p>
<p>However, what is not clear to me is the difference between <code>patches</code> and <code>patchesJson6902</code>. They seem to be very similar in nature. Both specify a 'target' attribute and operation objects which describes what gets modified.</p>
<p>The only difference I've noticed is that <code>patches</code> does not require a 'group' attribute while <code>patchesJson6902</code> does; The reason for this is unknown.</p>
<p>So why the difference between the two? How do I determine which one to use?</p>

Alex
<p>The explanation for this is <a href="https://github.com/kubernetes-sigs/kustomize/issues/2705#issuecomment-659012281" rel="noreferrer">here</a>.</p>
<p>To summarize, <code>patchJson6902</code> is an older keyword which can only match one resource via <code>target</code> (no wildcards), and accepts only Group-version-kind (GVK), namespace, and name.</p>
<p>The <code>patches</code> directive is newer and accepts more elements (annotation selector and label selector as well). In addition, namespace and name can be regexes. The target for <code>patches</code> can match more than one resource, all of which will be patched.</p>
<p>In addition, with <code>patches</code>, it will attempt to parse patch files as a Json6902 patch, and if that does not work, it will fall back to attempting the patch as a strategic merge. Therefore, in many cases <code>patches</code> can obviate the need of using <code>patchesStrategicMerge</code> as well.</p>
<p>Overall, it seems as if <code>patches</code> should work pretty universally for new projects.</p>
<p>Upstream documentation for these key words:</p>
<ul>
<li><a href="https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/patches/" rel="noreferrer">patches</a></li>
<li><a href="https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/patchesjson6902/" rel="noreferrer">patchesJson6902</a></li>
<li><a href="https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/patchesstrategicmerge/" rel="noreferrer">patchesStrategicMerge</a></li>
</ul>
