Recurring async job runs fine twice then fails to complete

I’m writing a (hopefully) simple data capture solution which will send a request to a JSON api every minute before adding the result to a Database. Locally this runs no problem - grabs the data when I expect and keeps ticking over.

When deployed to Azure, its a different story. Twice, i can see the data is collected successfully. But when it comes to the following iterations, the job just sits each of the following tasks in processing until all workers are exhausted.

public class Startup
{
    public Startup(IConfiguration configuration)
    {
        Configuration = configuration;
    }

    public IConfiguration Configuration { get; }

    // This method gets called by the runtime. Use this method to add services to the container.
    public void ConfigureServices(IServiceCollection services)
    {
        services.AddDbContext<DbContext>(options =>
            options.UseSqlServer(Configuration.GetConnectionString("DefaultConnection")));            

        services.AddHttpClient<GeoDataClient>(client => {
            client.BaseAddress = new Uri(Configuration["APIUrl"]);
            client.Timeout = TimeSpan.FromSeconds(10);
            
        });

        services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1);          

        services.AddHangfire(x => x.UseSqlServerStorage(Configuration.GetConnectionString("DefaultConnection")));

        services.AddAutoMapper();

    }

    // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
    public void Configure(IApplicationBuilder app, IHostingEnvironment env,  ILoggerFactory loggerFactory)
    {
        loggerFactory.AddConsole(Configuration.GetSection("Logging"));
        loggerFactory.AddDebug();
        
        if (env.IsDevelopment())
        {                
            app.UseDeveloperExceptionPage();                
        }
        else
        {
            app.UseHsts();
        }

        app.UseHangfireServer();
        app.UseHangfireDashboard("/hangfire", new DashboardOptions
        {
            Authorization = new[] { new AllowAnyoneAuthenticationFilter() }
        });

        app.UseStaticFiles();

        app.UseHttpsRedirection();
        app.UseMvc(routes =>
        {
            routes.MapRoute(
                name: "default",
                template: "{controller=Home}/{action=Index}/{id?}");
        });
        RecurringJob.RemoveIfExists("Get-GeoData");
        RecurringJob.AddOrUpdate<GeoDataTask>("Get-GeoData", (x) => x.GetLatestGeoData(), Cron.MinuteInterval(7));
    }
}

The task:

public class GeoDataTask
    {
        private readonly GeoDataClient _client;
        private readonly ILogger<GeoDataTask> _logger;
        private readonly DbContext _db;
        private readonly IMapper _mapper;
      
public GeoDataTask(GeoDataClient client, 
            ILogger<GeoDataTask> logger,
            DbContext db,
            IMapper mapper)
        {
            _client = client;
            _logger = logger;
            _db = db;
            _mapper = mapper;
        }

        public async Task GetLatestGeoData()
        {
            _logger.LogInformation("Get data task started");
           
            
            var geoData = await _client.GetLatestGeoData();

            ... other processing of the data here

           
        }
    }

The client used to make the requests:

public partial class GeoDataClient
{
    private HttpClient _client;
    private ILogger<GeoDataClient> _logger;
    private readonly string _apiKey;

    public GeoDataClient(HttpClient client, ILogger<GeoDataClient> logger, IConfiguration config)
    {
        _client = client;            
        _logger = logger;
        _apiKey = config["APIKey"];
    }

    public async Task<GeoDataCollectionDTO> GetLatestGeoData()
    {
        try
        {
            var geoUrl = $"[api end point]";
            _logger.LogWarning($"HttpClient: Loading {geoUrl}");
            var res = await _client.GetAsync(geoUrl);
            res.EnsureSuccessStatusCode();
            return await res.Content.ReadAsAsync<GeoDataCollectionDTO>();
        }
        catch (HttpRequestException ex)
        {
            _logger.LogError($"An error occurred connecting to Geo API {ex.ToString()}");
            throw;
        }
    }

}

I’ve been at it for hours trying to work out why this would be the case… I’ve even tried pointing at a local JSON file to see if the problem was with the API.

I’m using .net core 2.1 preview btw.

Any assistance would be fantastic!
thanks in advance!