Skip to content

Commit

Permalink
Add flink util
Browse files Browse the repository at this point in the history
  • Loading branch information
regadas committed Feb 21, 2022
1 parent c88c9ae commit 3eb17d5
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions internal/flink/util.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package flink

import (
"crypto/md5"
"encoding/hex"
)

// Deterministic job ID generation based on the input string
func GenerateJobId(str string) string {
hash := md5.Sum([]byte(str))
return hex.EncodeToString(hash[:])
}

0 comments on commit 3eb17d5

Please sign in to comment.