package Ġcom . byte train . prod inv . client Ċ Ċ import Ġcom . byte train . prod inv . security . getCurrent User JWT Ċ import Ġfe ign . Request Interceptor Ċ import Ġfe ign . Request Template Ċ import Ġorg . springframework . stereotype . Component Ċ Ċ private Ġconst Ġval ĠAUTH ORIZ ATION _ HEADER Ġ= Ġ" Authorization " Ċ private Ġconst Ġval ĠBE AR ER _ TOKEN _ TYPE Ġ= Ġ" Bearer " Ċ Ċ @ Component Ċ class ĠUser Fe ign Client Interceptor Ġ: ĠRequest Interceptor Ġ{ ĊĊĠĠĠ Ġoverride Ġfun Ġapply ( template : ĠRequest Template ) Ġ= ĊĠĠĠĠĠĠĠ ĠgetCurrent User JWT (). if Present Ġ{ Ġs Ġ-> Ġtemplate . header ( AUTHORIZATION _ HEADER , Ġ"$ BE AR ER _ TOKEN _ TYPE Ġ$ s ") Ġ} Ċ } Ċ