package Ġno . nav . pg i . pop p . lag re inn te kt . kafka . test environment Ċ Ċ import Ġio . con fluent . kafka . serializers . Kafka Av ro Serializer Ċ import Ġno . nav . pg i . pop p . lag re inn te kt . kafka . PG I _ IN N TE KT _ TOPIC Ċ import Ġno . nav . sam ord ning . pg i . schema . H en del se Key Ċ import Ġno . nav . sam ord ning . pg i . schema . P ens jon sg iven de In n te kt Ċ import Ġorg . apache . kafka . clients . producer . Kafka Producer Ċ import Ġorg . apache . kafka . clients . producer . Producer Config Ċ import Ġorg . apache . kafka . clients . producer . Producer Record Ċ Ċ internal Ġclass ĠIn n te kt Test Producer ( common Kafka Config : ĠMap < String , ĠString >) Ġ{ ĊĊĠĠĠ Ġprivate Ġval Ġinn te kt Test Producer Ġ= ĠKafka Producer < H en del se Key , ĠP ens jon sg iven de In n te kt >( common Kafka Config Ġ+ Ġinn te kt Test Producer Config ()) ĊĊĠĠĠ Ġinternal Ġfun Ġproduce To In n te kt Topic ( hen del se Key : ĠHen del se Key , Ġp ens jon sg iven de In n te kt : ĠP ens jon sg iven de In n te kt ) Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġrecord Ġ= ĠProducer Record ( PG I _ IN N TE KT _ TOPIC , Ġh en del se Key , Ġp ens jon sg iven de In n te kt ) ĊĠĠĠĠĠĠĠ Ġinn te kt Test Producer . send ( record ). get () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġinternal Ġfun Ġclose () Ġ{ ĊĠĠĠĠĠĠĠ Ġinn te kt Test Producer . close () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġprivate Ġfun Ġinn te kt Test Producer Config () Ġ= Ġmap Of ( ĊĠĠĠĠĠĠĠĠĠĠĠ ĠProducer Config . KEY _ SERIAL IZER _ CLASS _ CONFIG Ġto ĠKafka Av ro Serializer :: class . java , ĊĠĠĠĠĠĠĠĠĠĠĠ ĠProducer Config . VALUE _ SERIAL IZER _ CLASS _ CONFIG Ġto ĠKafka Av ro Serializer :: class . java , ĊĠĠĠĠĠĠĠĠĠĠĠ ĠProducer Config . ACK S _ CONFIG Ġto Ġ" all ", ĊĠĠĠĠĠĠĠĠĠĠĠ ĠProducer Config . RE TR IES _ CONFIG Ġto ĠInteger . MAX _ VALUE ĊĠĠĠ Ġ) Ċ }