• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

juarezr / spark-streaming-google-pubsub / 57

01 Oct 2026 07:02AM UTC coverage: 66.187% (-2.3%) from 68.457%
57

push

github

web-flow
fix: update AutoBatchTime logic for receiveTime estimation with write-first approach (#20)

- fix: update AutoBatchTime logic for receiveTime estimation with
write-first approach
- feat: add processingTime configuration to PubSubConfig to hint batch
interval on AutoBatchTime
- fix: remove unneded cap on writeBudget for AutoBatchTime

689 of 1169 branches covered (58.94%)

Branch coverage included in aggregate %.

232 of 354 new or added lines in 12 files covered. (65.54%)

15 existing lines in 1 file now uncovered.

1517 of 2164 relevant lines covered (70.1%)

0.7 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/main/java/io/github/juarezr/spark/pubsub/structured/PubSubScan.java
1
package io.github.juarezr.spark.pubsub.structured;
2

3
import io.github.juarezr.spark.pubsub.config.PubSubConfig;
4
import org.apache.spark.sql.connector.read.Scan;
5
import org.apache.spark.sql.connector.read.streaming.MicroBatchStream;
6
import org.apache.spark.sql.types.StructType;
7

8
/** Scan that exposes a Pub/Sub {@link MicroBatchStream}. */
9
final class PubSubScan implements Scan {
10
  private final PubSubConfig config;
11
  private final StructType readSchema;
12

13
  PubSubScan(PubSubConfig config, StructType readSchema) {
×
14
    this.config = config;
×
15
    this.readSchema = readSchema;
×
16
  }
×
17

18
  @Override
19
  public String toString() {
NEW
20
    return description();
×
21
  }
22

23
  @Override
24
  public StructType readSchema() {
25
    return readSchema;
×
26
  }
27

28
  @Override
29
  public String description() {
30
    return "Google Pub/Sub scan: " + config.subscriptionPath();
×
31
  }
32

33
  @Override
34
  public MicroBatchStream toMicroBatchStream(String checkpointLocation) {
35
    return new PubSubMicroBatchStream(config, config.numWriters(), readSchema);
×
36
  }
37
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc