Skip to content

Integra Cloud: Billing FAQ

Frequently asked questions about Integra Cloud billing and metering on AWS Marketplace.


Billing Model

Q: What am I billed for?

A: You are billed for the allocated vCPU capacity, not actual CPU usage.

If you allocate 4 vCPUs to your container, you are billed for 4 vCPU-hours every hour, regardless of whether the container is using 10% or 100% of those vCPUs.

Q: How is billing calculated?

A: Billing is calculated as:

Billing Amount = vCPU Count × Hours Running × Price per vCPU-hour

Example: - Container: 4 vCPUs - Running time: 10 hours - Price: $0.10 per vCPU-hour - Total: 4 × 10 × $0.10 = $4.00

Q: What happens if I pause the container?

A: Pausing does NOT stop billing.

As long as the container has allocated vCPUs (even if paused or idle), you will continue to be billed for those vCPUs.

To stop billing: Terminate the container completely.

Q: How are fractional vCPUs handled?

A: Fractional vCPUs are always rounded UP to the nearest whole number.

Allocated Billed
0.5 vCPUs 1 vCPU-hour
1.5 vCPUs 2 vCPU-hours
2.9 vCPUs 3 vCPU-hours
4.1 vCPUs 5 vCPU-hours

Why: This prevents revenue loss and ensures fair billing for allocated resources.


Restart & Reliability

Q: Will I be double-billed if my container restarts?

A: No, you will NOT be double-billed.

All billing is aligned to hour boundaries (10:00, 11:00, 12:00, etc.). If your container restarts within the same hour, AWS Marketplace automatically deduplicates billing records with the same timestamp.

Example:

10:15 - Container starts, bills for 10:00-11:00 ✅
10:30 - Container crashes and restarts, bills for 10:00-11:00 ✅ (idempotent!)

Result: Hour 10:00-11:00 billed only once.

Q: What if my container starts at 10:59?

A: The container will bill for 11:00-12:00 (the next hour), giving you 59 minutes of free usage.

This is part of the hybrid 30-minute strategy: - Start between :00-:29 → Bill for current hour - Start between :30-:59 → Bill for next hour

This prevents double billing on container restarts.

Q: How is double billing prevented?

A: Through hour boundary alignment:

  1. All billing timestamps are aligned to hour boundaries (10:00, 11:00, etc.)
  2. AWS Marketplace deduplicates records with the same timestamp
  3. Container restarts within the same hour bill for the same hour boundary
  4. No overlap = no double billing

Monitoring & Transparency

Q: How can I check my current billing?

A: Use the metering status endpoint:

curl http://localhost:8080/v1/metering/status

Response:

{
  "vcpu_count": 2.5,
  "vcpu_hours_billed": 3,
  "start_time": "2026-02-01T10:00:00Z",
  "uptime_hours": 5.2,
  "estimated_billings": 6,
  "total_failures": 0,
  "status": "healthy"
}

Key Fields: - vcpu_count: Detected vCPUs (from cgroups) - vcpu_hours_billed: Rounded vCPU-hours billed per hour - estimated_billings: Total billing events sent - status: healthy, degraded, or failing

Q: What happens if AWS Marketplace API is down?

A: The container continues to operate, but billing fails.

Behavior: 1. Billing is retried on the next hourly cycle 2. After 3 consecutive failures, status changes to failing 3. Prometheus alerts fire (if configured) 4. Container logs the failure

Impact: You may not be billed for hours when the API is down, but the container remains operational.

Q: What timezone should I use?

A: UTC is strongly recommended for consistent billing timestamps across regions.

ENV TZ=UTC

Why: Billing timestamps are used for deduplication. Using different timezones across containers can cause billing inconsistencies.


Security & Tamper-Proofing

Q: Can the product code be changed?

A: No, the product code is hardcoded in the binary for security.

Product Code: cmwqz37gsl53mh9055e4cjsnj

Why: Prevents exploitation via environment variable manipulation. Changing the product code requires recompiling the application.

Q: How is vCPU detection tamper-proof?

A: vCPU count is read from kernel cgroups, which are:

  1. Read-only from the container (enforced by the kernel)
  2. Cannot be manipulated via environment variables
  3. Minimum 1 vCPU enforced in the code

Detection Method: - cgroup v2: Reads /sys/fs/cgroup/cpu.max - cgroup v1: Reads /sys/fs/cgroup/cpu/cpu.cfs_quota_us - Fallback: runtime.NumCPU() (if cgroups unavailable)

Q: Can customers manipulate billing?

A: No, the billing system is designed to be tamper-proof:

  1. Product code is hardcoded (cannot be changed)
  2. vCPU count is read from kernel (cannot be faked)
  3. Fractional vCPUs always round UP (prevents under-billing)
  4. Minimum 1 vCPU enforced (prevents zero billing)
  5. Billing timestamps are server-side (cannot be manipulated)

Cost Optimization

Q: How can I reduce costs?

A: Several strategies:

  1. Right-size vCPU allocation
  2. Start small (2 vCPUs) and scale up based on actual load
  3. Monitor CPU utilization and adjust

  4. Use batch mode efficiently

  5. Process files during off-peak hours
  6. Use Spot instances for non-critical workloads
  7. Tune worker pool size to match workload

  8. Optimize output formats

  9. Use Parquet for smaller file sizes (lower S3 costs)
  10. Avoid generating unnecessary formats

  11. Scale down during idle periods

  12. Terminate containers when not in use
  13. Use auto-scaling based on queue depth

Q: What's the minimum cost?

A: The minimum billing is 1 vCPU-hour.

Even if you allocate 0.5 vCPUs, you will be billed for 1 vCPU-hour.

Example Minimum Cost: - Price: $0.10 per vCPU-hour - Minimum: 1 vCPU-hour - Minimum hourly cost: $0.10

Q: How do I track costs?

A: Use these methods:

  1. Metering Status Endpoint bash curl http://localhost:8080/v1/metering/status

  2. Prometheus Metrics ```promql # Total vCPU-hours billed sum(metering_billings_total{status="success"}) * vcpu_count

# Cost per file processed (vcpu_count * hourly_rate) / rate(integra_pipeline_files_processed_total[1h]) ```

  1. AWS Marketplace Console
  2. View usage reports
  3. Download billing data
  4. Set up cost alerts

Troubleshooting

Q: My container failed to start with "upfront billing failed"

A: This means the initial billing attempt failed.

Common Causes: 1. No AWS Marketplace permissions - Check IAM role 2. Network connectivity issues - Check security groups 3. Invalid product code - Contact support

Resolution:

# Check IAM permissions
aws sts get-caller-identity

# Check network connectivity
curl -I https://metering.marketplace.us-east-1.amazonaws.com

# Check container logs
docker logs <container-id> | grep "billing"

Q: I see "metering consecutive failures" alerts

A: This means billing has failed 3+ times in a row.

Common Causes: 1. AWS API throttling - Reduce request rate 2. Network issues - Check connectivity 3. Invalid credentials - Verify IAM role

Resolution:

# Check metering status
curl http://localhost:8080/v1/metering/status

# Check Prometheus metrics
curl http://localhost:8080/metrics | grep metering

# Review logs
docker logs <container-id> | grep "billing failed"

Q: I think I was double-billed

A: Double billing should not occur due to hour boundary alignment.

Investigation Steps: 1. Check metering status endpoint 2. Review billing logs for duplicate timestamps 3. Check for container restarts 4. Contact support with logs

Expected Behavior: - Same hour boundary appears multiple times in logs (idempotent) - AWS Marketplace deduplicates based on timestamp - No double billing occurs


Additional Resources


Support

For billing-related issues:

  1. Check Status Endpoint: GET /v1/metering/status
  2. Review Logs: docker logs <container-id> | grep metering
  3. Check Metrics: curl http://localhost:8080/metrics | grep metering
  4. Contact Support: Include status endpoint output and relevant logs