@@ -353,6 +353,9 @@ func (p *payloadStoreRepositoryImpl) retrieve(ctx context.Context, tx sqlcv1.DBT
353353 key := ExternalPayloadLocationKey (payload .ExternalLocationKey .String )
354354 var retrieveFromExternalOpt RetrieveFromExternalOpts
355355
356+ // todo: this doesn't actually make sense, since
357+ // we'd never write the index file into the payload location directly
358+ // so we can remove this if block
356359 if strings .HasSuffix (string (key ), ".index" ) {
357360 retrieveFromExternalOpt = RetrieveFromExternalOpts {
358361 Method : RetrieveFromExternalByIndexFile ,
@@ -854,31 +857,31 @@ func (p *payloadStoreRepositoryImpl) processSinglePartition(ctx context.Context,
854857 return nil
855858 }
856859
857- connStatementTimeout := 5 * 60 * 1000 // 5 minutes
860+ // connStatementTimeout := 5 * 60 * 1000 // 5 minutes
858861
859- conn , release , err := sqlchelpers .AcquireConnectionWithStatementTimeout (ctx , p .pool , p .l , connStatementTimeout )
862+ // conn, release, err := sqlchelpers.AcquireConnectionWithStatementTimeout(ctx, p.pool, p.l, connStatementTimeout)
860863
861- if err != nil {
862- return fmt .Errorf ("failed to acquire connection with statement timeout: %w" , err )
863- }
864+ // if err != nil {
865+ // return fmt.Errorf("failed to acquire connection with statement timeout: %w", err)
866+ // }
864867
865- defer release ()
868+ // defer release()
866869
867- duplicatedExternalIds , err := p .ValidateNoDuplicateExternalIds (ctx , conn , partitionDate )
870+ // duplicatedExternalIds, err := p.ValidateNoDuplicateExternalIds(ctx, conn, partitionDate)
868871
869- if err != nil {
870- return fmt .Errorf ("failed to validate no duplicate external ids: %w" , err )
871- }
872+ // if err != nil {
873+ // return fmt.Errorf("failed to validate no duplicate external ids: %w", err)
874+ // }
872875
873- if len (duplicatedExternalIds ) > 0 {
874- var duplicatedIds []string
876+ // if len(duplicatedExternalIds) > 0 {
877+ // var duplicatedIds []string
875878
876- for _ , row := range duplicatedExternalIds {
877- duplicatedIds = append (duplicatedIds , row .ExternalId .String ())
878- }
879+ // for _, row := range duplicatedExternalIds {
880+ // duplicatedIds = append(duplicatedIds, row.ExternalId.String())
881+ // }
879882
880- return fmt .Errorf ("found duplicate external ids in partition %s. Sampled ids: %s" , partitionDate .String (), strings .Join (duplicatedIds , ", " ))
881- }
883+ // return fmt.Errorf("found duplicate external ids in partition %s. Sampled ids: %s", partitionDate.String(), strings.Join(duplicatedIds, ", "))
884+ // }
882885
883886 lastExternalId := jobMeta .LastExternalId
884887
0 commit comments