@@ -204,6 +204,41 @@ func NewIngesterWithConfigFile(name string, store RingStore, address, configFile
204204 )
205205}
206206
207+ func NewParquetConverter (name string , store RingStore , address string , flags map [string ]string , image string ) * CortexService {
208+ return NewParquetConverterWithConfigFile (name , store , address , "" , flags , image )
209+ }
210+
211+ func NewParquetConverterWithConfigFile (name string , store RingStore , address , configFile string , flags map [string ]string , image string ) * CortexService {
212+ if configFile != "" {
213+ flags ["-config.file" ] = filepath .Join (e2e .ContainerSharedDir , configFile )
214+ }
215+
216+ // Configure the ingesters ring backend
217+ flags ["-ring.store" ] = string (store )
218+ switch store {
219+ case RingStoreConsul :
220+ flags ["-consul.hostname" ] = address
221+ case RingStoreEtcd :
222+ flags ["-etcd.endpoints" ] = address
223+ }
224+
225+ if image == "" {
226+ image = GetDefaultImage ()
227+ }
228+
229+ return NewCortexService (
230+ name ,
231+ image ,
232+ e2e .NewCommandWithoutEntrypoint ("cortex" , e2e .BuildArgs (e2e .MergeFlags (map [string ]string {
233+ "-target" : "parquet-converter" ,
234+ "-log.level" : "warn" ,
235+ }, flags ))... ),
236+ e2e .NewHTTPReadinessProbe (httpPort , "/ready" , 200 , 299 ),
237+ httpPort ,
238+ grpcPort ,
239+ )
240+ }
241+
207242func NewQueryFrontend (name string , flags map [string ]string , image string ) * CortexService {
208243 return NewQueryFrontendWithConfigFile (name , "" , flags , image )
209244}
0 commit comments