Skip to content

Commit

Permalink
Merge pull request #55 from fraunhoferfokus/development
Browse files Browse the repository at this point in the history
* use uuid V7
  • Loading branch information
JGottschick authored Dec 26, 2024
2 parents 36141e2 + 645e72f commit a578195
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion core/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.3.12
0.3.14
2 changes: 1 addition & 1 deletion templates/core/config.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func init() {
AppConfig.Service = service
AppConfig.Host, _ = os.Hostname()
AppConfig.User = os.Getenv("USER")
AppConfig.Sid = uuid.NewString()
AppConfig.Sid = uuid.Must(uuid.NewV7).String()

// parse command line arguments
flag.StringVar(&AppConfig.PortNb, "port", AppConfig.PortNb, "Port number to listen by the server")
Expand Down
2 changes: 1 addition & 1 deletion templates/rest/handler.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func init() {
func getSession(c echo.Context) (*sessions.Session, error) {
session, err := sessionStore.Get(c.Request(), "session")
if err != nil || session.IsNew {
id := uuid.NewString()
id := uuid.Must(uuid.NewV7).String()
log.Info().Str("id",id).Msg("New session")
session.Values["id"] = id
//
Expand Down

0 comments on commit a578195

Please sign in to comment.