Skip to content

Commit

Permalink
Fix naming for ContainerApp jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
mburumaxwell committed Oct 2, 2023
1 parent 6cb409a commit d933b96
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,9 @@ public async Task ConsumeAsync(EventContext<TriggerUpdateJobsEvent> context, Can
// create the job
job = new UpdateJob
{
// no prefixing/formatting because we use this to create azure resources which have name restrictions
Id = FlakeId.Id.Create().ToString(),
// we use this to create azure resources which have name restrictions
// alphanumeric, starts with a letter, does not contain "--", upto 32 characters
Id = $"job-{FlakeId.Id.Create()}", // flake is 19 chars, total is 23 chars

Created = DateTimeOffset.UtcNow,
Status = UpdateJobStatus.Scheduled,
Expand Down

0 comments on commit d933b96

Please sign in to comment.