As you cast Lightning Bolt or Chain Lightning (and now, with the Improved Lightning Shield perk, Lava Burst too) you will generate a Lightning Shield Charge via the Fulmination passive for every target hit. This includes from Multistrikes, so one Lightning Bolt can generate potentially 3 Charges, and one Lava Burst can potentially generate 4.
When you cast Earth Shock, it will deal its damage, plus the damage of every single Lightning Shield charge you have above the first, resetting you back to 1 charge. This is, when used at high charges, our hardest hitting spell. The reason this is lower in priority than Lava Burst however, is that you have some leeway with it, in that assuming you cast it once it is above 15 Stacks and Lava Burst is on cooldown, you are unlikely to waste stacks, whilst if you cast it at above 15 Stacks but with Lava Burst off cooldown, you could be wasting Lava Surge procs.
The counter to this, however, is that now Lava Burst can generate stacks itself, you can cap out from the Lava Burst casts, especially with Lava Surge procs and with the Echo of the Elements talent. However, even if you do cap out on stacks, it is still not worth delaying the use of Lava Burst to dump your stacks.