Skip to content

Commit

Permalink
Updated StartMediaDriver for Java 21
Browse files Browse the repository at this point in the history
  • Loading branch information
talos-rob authored and aayushduwadi committed May 31, 2024
1 parent 47ea3a2 commit 678ea72
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions systests/driver/media_driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ func StartMediaDriver() (*MediaDriver, error) {
tempDir := aeronUniqueTempDir()
cmd := setupCmd(tempDir)
setupPdeathsig(cmd)
logger.Infof("Starting Media Driver with command line: %s", cmd)
if err := cmd.Start(); err != nil {
logger.Error("couldn't start Media Driver: ", err)
return nil, err
Expand Down Expand Up @@ -105,6 +106,7 @@ func aeronUniqueTempDir() string {
func setupCmd(tempDir string) *exec.Cmd {
cmd := exec.Command(
"java",
"--add-opens=java.base/sun.nio.ch=ALL-UNNAMED",
fmt.Sprintf("-D%s=%s", aeronDirPropName, tempDir),
fmt.Sprintf("-D%s=true", aeronDirDeleteStartPropName),
fmt.Sprintf("-D%s=true", aeronDirDeleteShutdownPropName),
Expand Down

0 comments on commit 678ea72

Please sign in to comment.