20 lines
351 B
Go
20 lines
351 B
Go
package target
|
|
|
|
import (
|
|
"github.com/hashicorp/boundary/internal/db"
|
|
"github.com/hashicorp/boundary/internal/errors"
|
|
)
|
|
|
|
const (
|
|
TcpTargetPrefix = "ttcp"
|
|
)
|
|
|
|
func newTcpTargetId() (string, error) {
|
|
const op = "target.newTcpTargetId"
|
|
id, err := db.NewPublicId(TcpTargetPrefix)
|
|
if err != nil {
|
|
return "", errors.Wrap(err, op)
|
|
}
|
|
return id, nil
|
|
}
|