Skip to content

Commit

Permalink
s/register_fresh_index/register_fresh_start
Browse files Browse the repository at this point in the history
  • Loading branch information
tpendragon committed Dec 4, 2024
1 parent 8073b1d commit a16ccd1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/dpul_collections/index_metrics_tracker.ex
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ defmodule DpulCollections.IndexMetricsTracker do
{:ok, %{}}
end

@spec register_fresh_index(source :: module()) :: term()
def register_fresh_index(source) do
@spec register_fresh_start(source :: module()) :: term()
def register_fresh_start(source) do
GenServer.call(__MODULE__, {:fresh_index, source})
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ defmodule DpulCollections.IndexingPipeline.DatabaseProducer do
source_module.get_cache_entries_since!(last_queried_marker, total_demand, cache_version)

if last_queried_marker == nil && length(records) > 0 do
DpulCollections.IndexMetricsTracker.register_fresh_index(source_module)
DpulCollections.IndexMetricsTracker.register_fresh_start(source_module)
end

new_state =
Expand Down
2 changes: 1 addition & 1 deletion test/dpul_collections/index_metrics_tracker_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ defmodule DpulCollections.IndexMetricsTrackerTest do
}
)

IndexMetricsTracker.register_fresh_index(HydrationProducerSource)
IndexMetricsTracker.register_fresh_start(HydrationProducerSource)
# Send an ack done with acked_count 1
:telemetry.execute(
[:database_producer, :ack, :done],
Expand Down

0 comments on commit a16ccd1

Please sign in to comment.