Queen or Worker
Scientific Beekeeping
Chemical Communication in the Honey Bee Society.
The hypopharangeal glands (HPG)are also found in the head under the 'forehead' or frons above the brain. The individual oval bodies are white and are set either side of a central tube. If dissecting the head of the bee this glands stretched out are longer than the bee measuring about 3cm. The secretion is clear and contains protein, fats and minerals. The outlets are into ducts from the right and left HPGs onto either side of the hypopharyngeal plate where the mouth meets the pharynx.

In queen honey bees (and drones) the HPG is vestigial (Snodgrass 1956)
The inhibiting effect of the queen bee (Apis mellifera L.) foot-print pheromone on the construction of swarming queen cups. Lensky & Slabezki, 1981
Morphology of the Dufour gland within the honey bee sting gland complex1. Martin et al 2004
Dufour's gland secretion of the queen honeybee (Apis mellifera): an egg discriminator pheromone or a queen signal? Katzav 2001
"Stress Pheromone from "Koschewnikow" Glands of the Queen Bees: Behavioural, Structural and Chemical Study"
Lensky et al 1991
A dietary phytochemical alters caste-associated gene expression in honey bees. Mao et al, 2015
The decision of whether a female egg will become a queen or a worker depends largely on what it is feed during the larval stage and this is decided by the nurse bees. After emerging the sooner the decision to produce a queen the better the specimen will be. Afterr two days the tiny larva will make a poor queen.

After 3 days the queen is fed exclusively royal jelly and no pollen or honey, as is fed to the worker larvae.

Royal jelly, however, has no detectable phenolic acids
Mandibular Gland Volatiles and Their Ontogenetic Patterns in Queen Honey Bees, Apis mellifera carnica. Franck, et al 1997, abstract only
Above is the general model of caste differentiation in Apis mellifera from the paper, the link for which is given on the left. Arrows' thickness indicates the relative action levels of the considered factors. Barchuk et al (2007) proposes an explanation of the mechanism in great detail in her paper which features this simplified explanation of caste differentiation. They proposed that the global differential programming of gene expression in the honeybee is controlled by DNA methylation mechanism in a manner similar to epigenetic transcriptional changes inducible by environmental factors in vertebrates (Maleszka et al).

Molecular determinants of caste differentiation in the highly eusocial honeybee Apis mellifera. Barchuk et al 2007