This is an automated email from the ASF dual-hosted git repository.

nferraro pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel-k.git

commit e43ad15ad6def1dfcdae499edbc9fbbdb5926fb8
Author: lburgazzoli <[email protected]>
AuthorDate: Wed Jun 10 15:21:48 2020 +0200

    chore: fix missing imports
---
 e2e/common/run_test.go | 1 +
 pkg/trait/jvm.go       | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/e2e/common/run_test.go b/e2e/common/run_test.go
index 77ebbbc..1309bf8 100644
--- a/e2e/common/run_test.go
+++ b/e2e/common/run_test.go
@@ -24,6 +24,7 @@ package common
 import (
        "testing"
 
+       . "github.com/apache/camel-k/e2e/support"
        camelv1 "github.com/apache/camel-k/pkg/apis/camel/v1"
        . "github.com/onsi/gomega"
        v1 "k8s.io/api/core/v1"
diff --git a/pkg/trait/jvm.go b/pkg/trait/jvm.go
index 9aaa23b..62fb64c 100644
--- a/pkg/trait/jvm.go
+++ b/pkg/trait/jvm.go
@@ -22,6 +22,8 @@ import (
        "sort"
        "strings"
 
+       infp "gopkg.in/inf.v0"
+
        "github.com/pkg/errors"
        "github.com/scylladb/go-set/strset"
 
@@ -146,7 +148,7 @@ func (t *jvmTrait) Apply(e *Environment) error {
                if resource.NewScaledQuantity(300, 6).Cmp(memory) > 0 {
                        percentage = 25
                }
-               memory.AsDec().Mul(memory.AsDec(), inf.NewDec(percentage, 2))
+               memory.AsDec().Mul(memory.AsDec(), infp.NewDec(percentage, 2))
                args = append(args, fmt.Sprintf("-Xmx%dM", 
memory.ScaledValue(resource.Mega)))
        }
 

Reply via email to