Don’t do it – for several reasons
[1] Unnecessary in 4340. It defeats the purpose. 4340 is a deep (below the surface, that is) hardening steel, therefore only a slow quench (a good thing) is necessary for transforming the austenite to martensite. It all has to do with the way those expensive alloys in 4340 affect the thermodynamics of the transformation.
[2] Machine two pieces because the first one might crack. Quenching thick sections like this causes steep thermal gradients, internal stresses, and possible quench cracks from tensile forces, esp on the surface. Water is a faster quenchant than oil, so the cracking tendency is worsened.
[3] Also, investigate if an air-quench (i.e. Normalizing), rather than water quench & temper, would give you the desired mechanical properties.
Sorry, got carried away. To respond to your question, if you really must do this, put a big radius at the bottom of the slot and chamfer the exterior corners in order to attain a constant thickness throughout the cross section. Use a big bucket of very hot water, drop the part in – vertically constrained. NDI it afterward for cracks that you hope are not there. Letting it air-cool for a few minutes (check a CTT diagram for 4340), before the quench, probably wouldn’t hurt. If the center core gets to < 800F in < 10 minutes, or so, the part should be thru hardened. (Check a metals book, e.g., Reed-Hill – Physical Metallurgical Principles, 3rd Ed.)
Also fyi, spec AMS-H-6875 recommends Austenitizing at 1500-1550F, Oil Quench, then temper 850-1200F depending on toughness/strength requirements.
Good luck. Try it.