Green’s Dictionary of Slang

spencer n.

[ety. unknown; ? a local landlord or well-known drinker]

a small glass of spirits.

[UK]Sporting Mag. XXIII Jan. 220/2: A small glass of gin in St. Giles’s [is called] a Spencer.
[Ire]Spirit of Irish Wit 31: [of brandy] Ned Smith was burnt-out last week, though he could scarce take a spencers at last.