Dark Mode

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit fc38f2e

Browse files
authored
support golang 1.18 (#365)
* use go 1.18 * update ci to 1.18 * use latest golangci-lint * fix function runner build
1 parent cbd00d1 commit fc38f2e

File tree

10 files changed

+169
-87
lines changed
  • .github/workflows
    • project.yml
    • release.yml
    • test-helm-charts.yml
  • Dockerfile
  • controllers
    • function_controller_test.go
  • go.mod
  • go.sum
  • images/samples/go-function-samples
    • Dockerfile
    • func
      • go.mod
      • go.sum

10 files changed

+169
-87
lines changed

.github/workflows/project.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ jobs:
66
runs-on: ubuntu-latest
77
strategy:
88
matrix:
9-
go-version: [1.13, 1.14, 1.15, 1.16, 1.17]
9+
go-version: [1.13, 1.14, 1.15, 1.16, 1.17, 1.18]
1010
steps:
1111
- name: clean disk
1212
run: |
@@ -33,7 +33,7 @@ jobs:
3333
3434
- name: InstallTool
3535
run: |
36-
wget -O - -q https://raw.githubusercontent.com/golangci/golangci-lint/mas ter/install.sh| sh -s v1.18.0
36+
wget -O - -q https://raw.githubusercontent.com/golangci/golangci-lint/mas ter/install.sh| sh -s v1.45.2
3737
./bin/golangci-lint --version
3838
3939
- name: BuildProject

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ jobs:
2626
username: ${{ secrets.DOCKER_USER }}
2727
password: ${{ secrets.DOCKER_PASSWORD }}
2828

29-
- name: Set up GO 1.13
29+
- name: Set up GO 1.18
3030
uses: actions/setup-go@v1
3131
with:
32-
go-version: 1.13
32+
go-version: 1.18
3333
id: go
3434

3535
- name: InstallKubebuilder

.github/workflows/test-helm-charts.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,11 @@ jobs:
6868
node_image: kindest/node:v1.17.17
6969
wait: 600s
7070

71-
- name: Set up GO 1.13
71+
- name: Set up GO 1.18
7272
if: steps.list-changed.outputs.changed == 'true'
7373
uses: actions/setup-go@v1
7474
with:
75-
go-version: 1.13
75+
go-version: 1.18
7676
id: go
7777

7878
- name: setup kubebuilder 2.3.1

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Build the manager binary
2-
FROM golang:1.13 as builder
2+
FROM golang:1.18 as builder
33

44
WORKDIR /workspace
55
# Copy the Go Modules manifests

controllers/function_controller_test.go

Lines changed: 34 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ var _ = Describe("Function Controller", func() {
100100
}, 10*time.Second, 1*time.Second).Should(BeTrue())
101101
re := regexp.MustCompile("{\"configkey1\":\"configvalue1\",\"configkey2\":\"configvalue2\",\"configkey3\":\"configvalue3\"}")
102102
// Verify new config synced to pod spec
103-
Expect(len(re.FindAllString(strings.ReplaceAll(functionSts.Spec.Template.Spec.Containers[0].Command[2], "\\", ""), -1))).To(Equal(1))
103+
Expect(len(re.FindAllString(strings.ReplaceAll(functionSts.Spec.Template.Spec.Containers[0].Command[2],
104+
"\\", ""), -1))).To(Equal(1))
104105
})
105106
})
106107
})
@@ -166,6 +167,20 @@ var _ = Describe("Function Controller (builtin HPA)", func() {
166167
})
167168
})
168169

170+
var _ = Describe("Function Controller (Stateful Function)", func() {
171+
Context("Simple Function Item with builtin HPA", func() {
172+
r := int32(100)
173+
function := makeFunctionSample(TestFunctionBuiltinHPAName)
174+
function.Spec.MaxReplicas = &r
175+
function.Spec.Pod.BuiltinAutoscaler = []v1alpha1.BuiltinHPARule{
176+
v1alpha1.AverageUtilizationCPUPercent20,
177+
v1alpha1.AverageUtilizationMemoryPercent20,
178+
}
179+
180+
createFunction(function)
181+
})
182+
})
183+
169184
func createFunction(function *v1alpha1.Function) {
170185

171186
It("Function should be created", func() {
@@ -233,23 +248,28 @@ func createFunction(function *v1alpha1.Function) {
233248
key, err := client.ObjectKeyFromObject(function)
234249
Expect(err).To(Succeed())
235250

236-
log.Info("deleting resource", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
251+
log.Info("deleting resource", "namespace", key.Namespace, "name", key.Name, "test",
252+
CurrentGinkgoTestDescription().FullTestText)
237253
Expect(k8sClient.Delete(context.Background(), function)).To(Succeed())
238254

239-
log.Info("waiting for resource to disappear", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
255+
log.Info("waiting for resource to disappear", "namespace", key.Namespace, "name", key.Name, "test",
256+
CurrentGinkgoTestDescription().FullTestText)
240257
Eventually(func() error {
241258
return k8sClient.Get(context.Background(), key, function)
242259
}, timeout, interval).Should(HaveOccurred())
243-
log.Info("deleted resource", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
260+
log.Info("deleted resource", "namespace", key.Namespace, "name", key.Name, "test",
261+
CurrentGinkgoTestDescription().FullTestText)
244262

245263
statefulsets := new(appsv1.StatefulSetList)
246264
err = k8sClient.List(context.Background(), statefulsets, client.InNamespace(function.Namespace))
247265
Expect(err).Should(BeNil())
248266
for _, item := range statefulsets.Items {
249-
log.Info("deleting statefulset resource", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
267+
log.Info("deleting statefulset resource", "namespace", key.Namespace, "name", key.Name, "test",
268+
CurrentGinkgoTestDescription().FullTestText)
250269
Expect(k8sClient.Delete(context.Background(), &item)).To(Succeed())
251270
}
252-
log.Info("waiting for StatefulSet resource to disappear", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
271+
log.Info("waiting for StatefulSet resource to disappear", "namespace", key.Namespace, "name", key.Name, "test",
272+
CurrentGinkgoTestDescription().FullTestText)
253273
Eventually(func() bool {
254274
err := k8sClient.List(context.Background(), statefulsets, client.InNamespace(function.Namespace))
255275
log.Info("delete statefulset result", "err", err, "statefulsets", statefulsets)
@@ -261,22 +281,26 @@ func createFunction(function *v1alpha1.Function) {
261281
}
262282
return err == nil && !containsFunction
263283
}, timeout, interval).Should(BeTrue())
264-
log.Info("StatefulSet resource deleted", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
284+
log.Info("StatefulSet resource deleted", "namespace", key.Namespace, "name", key.Name, "test",
285+
CurrentGinkgoTestDescription().FullTestText)
265286

266287
hpas := new(autov2beta2.HorizontalPodAutoscalerList)
267288
err = k8sClient.List(context.Background(), hpas, client.InNamespace(function.Namespace))
268289
Expect(err).Should(BeNil())
269290
for _, item := range hpas.Items {
270-
log.Info("deleting HPA resource", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
291+
log.Info("deleting HPA resource", "namespace", key.Namespace, "name", key.Name, "test",
292+
CurrentGinkgoTestDescription().FullTestText)
271293
log.Info("deleting HPA", "item", item)
272294
Expect(k8sClient.Delete(context.Background(), &item)).To(Succeed())
273295
}
274-
log.Info("waiting for HPA resource to disappear", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
296+
log.Info("waiting for HPA resource to disappear", "namespace", key.Namespace, "name", key.Name, "test",
297+
CurrentGinkgoTestDescription().FullTestText)
275298
Eventually(func() bool {
276299
err := k8sClient.List(context.Background(), hpas, client.InNamespace(function.Namespace))
277300
return err == nil && len(hpas.Items) == 0
278301
}, timeout, interval).Should(BeTrue())
279-
log.Info("HPA resource deleted", "namespace", key.Namespace, "name", key.Name, "test", CurrentGinkgoTestDescription().FullTestText)
302+
log.Info("HPA resource deleted", "namespace", key.Namespace, "name", key.Name, "test",
303+
CurrentGinkgoTestDescription().FullTestText)
280304

281305
})
282306
}

go.mod

Lines changed: 72 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/streamnative/function-mesh
22

3-
go 1.13
3+
go 1.18
44

55
require (
66
github.com/ghodss/yaml v1.0.0
@@ -9,7 +9,6 @@ require (
99
github.com/golang/protobuf v1.4.3
1010
github.com/onsi/ginkgo v1.14.2
1111
github.com/onsi/gomega v1.10.4
12-
github.com/prometheus/client_golang v1.7.1 // indirect
1312
github.com/streamnative/pulsarctl v0.4.3-0.20220104092115-5af28d815290
1413
github.com/stretchr/testify v1.6.1
1514
google.golang.org/protobuf v1.25.0
@@ -20,3 +19,74 @@ require (
2019
k8s.io/client-go v0.18.6
2120
sigs.k8s.io/controller-runtime v0.6.2
2221
)
22+
23+
require (
24+
cloud.google.com/go v0.65.0 // indirect
25+
github.com/99designs/keyring v1.1.6 // indirect
26+
github.com/apache/pulsar-client-go/oauth2 v0.0.0-20211108044248-fe3b7c4e445b // indirect
27+
github.com/beorn7/perks v1.0.1 // indirect
28+
github.com/cespare/xxhash/v2 v2.1.1 // indirect
29+
github.com/danieljoos/wincred v1.0.2 // indirect
30+
github.com/davecgh/go-spew v1.1.1 // indirect
31+
github.com/dvsekhvalnov/jose2go v0.0.0-20200901110807-248326c1351b // indirect
32+
github.com/evanphx/json-patch v4.5.0+incompatible // indirect
33+
github.com/fatih/color v1.7.0 // indirect
34+
github.com/form3tech-oss/jwt-go v3.2.3+incompatible // indirect
35+
github.com/fsnotify/fsnotify v1.4.9 // indirect
36+
github.com/go-logr/zapr v0.1.0 // indirect
37+
github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect
38+
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e // indirect
39+
github.com/google/go-cmp v0.5.1 // indirect
40+
github.com/google/gofuzz v1.1.0 // indirect
41+
github.com/google/uuid v1.1.1 // indirect
42+
github.com/googleapis/gnostic v0.3.1 // indirect
43+
github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect
44+
github.com/hashicorp/golang-lru v0.5.4 // indirect
45+
github.com/imdario/mergo v0.3.9 // indirect
46+
github.com/inconshreveable/mousetrap v1.0.0 // indirect
47+
github.com/json-iterator/go v1.1.10 // indirect
48+
github.com/keybase/go-keychain v0.0.0-20190712205309-48d3d31d256d // indirect
49+
github.com/kris-nova/logger v0.0.0-20181127235838-fd0d87064b06 // indirect
50+
github.com/kris-nova/lolgopher v0.0.0-20180921204813-313b3abb0d9b // indirect
51+
github.com/magiconair/properties v1.8.0 // indirect
52+
github.com/mattn/go-colorable v0.1.2 // indirect
53+
github.com/mattn/go-isatty v0.0.8 // indirect
54+
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
55+
github.com/mitchellh/go-homedir v1.1.0 // indirect
56+
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
57+
github.com/modern-go/reflect2 v1.0.1 // indirect
58+
github.com/mtibben/percent v0.2.1 // indirect
59+
github.com/nxadm/tail v1.4.4 // indirect
60+
github.com/pkg/errors v0.9.1 // indirect
61+
github.com/pmezard/go-difflib v1.0.0 // indirect
62+
github.com/prometheus/client_golang v1.7.1 // indirect
63+
github.com/prometheus/client_model v0.2.0 // indirect
64+
github.com/prometheus/common v0.10.0 // indirect
65+
github.com/prometheus/procfs v0.1.3 // indirect
66+
github.com/spf13/cobra v0.0.5 // indirect
67+
github.com/spf13/pflag v1.0.5 // indirect
68+
go.uber.org/atomic v1.4.0 // indirect
69+
go.uber.org/multierr v1.1.0 // indirect
70+
go.uber.org/zap v1.10.0 // indirect
71+
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 // indirect
72+
golang.org/x/net v0.0.0-20210220033124-5f55cee0dc0d // indirect
73+
golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93 // indirect
74+
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68 // indirect
75+
golang.org/x/text v0.3.3 // indirect
76+
golang.org/x/time v0.0.0-20191024005414-555d28b269f0 // indirect
77+
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
78+
gomodules.xyz/jsonpatch/v2 v2.0.1 // indirect
79+
google.golang.org/appengine v1.6.7 // indirect
80+
gopkg.in/inf.v0 v0.9.1 // indirect
81+
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
82+
gopkg.in/yaml.v2 v2.3.0 // indirect
83+
k8s.io/apiextensions-apiserver v0.18.6 // indirect
84+
k8s.io/klog v1.0.0 // indirect
85+
k8s.io/klog/v2 v2.0.0 // indirect
86+
k8s.io/kube-openapi v0.0.0-20200410145947-61e04a5be9a6 // indirect
87+
k8s.io/utils v0.0.0-20200603063816-c1c6865ac451 // indirect
88+
sigs.k8s.io/structured-merge-diff/v3 v3.0.0 // indirect
89+
sigs.k8s.io/yaml v1.2.0 // indirect
90+
)
91+
92+
replace golang.org/x/sys => golang.org/x/sys v0.0.0-20220422013727-9388b58f7150

go.sum

Lines changed: 2 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -560,55 +560,8 @@ golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJ
560560
golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
561561
golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
562562
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
563-
golang.org/x/sys v0.0.0-20170830134202-bb24a47a89ea/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
564-
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
565-
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
566-
golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
567-
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
568-
golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
569-
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
570-
golang.org/x/sys v0.0.0-20181228144115-9a3f9b0469bb/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
571-
golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
572-
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
573-
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
574-
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
575-
golang.org/x/sys v0.0.0-20190321052220-f7bb7a8bee54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
576-
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
577-
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
578-
golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
579-
golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
580-
golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
581-
golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
582-
golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
583-
golang.org/x/sys v0.0.0-20190712062909-fae7ac547cb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
584-
golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
585-
golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
586-
golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
587-
golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
588-
golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
589-
golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
590-
golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
591-
golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
592-
golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
593-
golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
594-
golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
595-
golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
596-
golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
597-
golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
598-
golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
599-
golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
600-
golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
601-
golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
602-
golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
603-
golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
604-
golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
605-
golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
606-
golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
607-
golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
608-
golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
609-
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
610-
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68 h1:nxC68pudNYkKU6jWhgrqdreuFiOQWj1Fs7T3VrH4Pjw=
611-
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
563+
golang.org/x/sys v0.0.0-20220422013727-9388b58f7150 h1:xHms4gcpe1YE7A3yIllJXP16CMAGuqwO2lX1mTyyRRc=
564+
golang.org/x/sys v0.0.0-20220422013727-9388b58f7150/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
612565
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
613566
golang.org/x/text v0.0.0-20160726164857-2910a502d2bf/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
614567
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=

images/samples/go-function-samples/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
ARG PULSAR_IMAGE_TAG
2-
FROM golang:1.13 as builder
2+
FROM golang:1.18 as builder
33

44
WORKDIR /workspace
55
# Copy the Go Modules manifests

images/samples/go-function-samples/func/go.mod

Lines changed: 51 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,55 @@
11
module github.com/apache/pulsar/pulsar-function-go/examples
22

3-
go 1.13
3+
go 1.18
44

55
require github.com/apache/pulsar/pulsar-function-go v0.0.0-20211119145922-f78fdacdfbf9
6+
7+
require (
8+
github.com/99designs/keyring v1.1.5 // indirect
9+
github.com/AthenZ/athenz v1.10.15 // indirect
10+
github.com/DataDog/zstd v1.4.6-0.20210211175136-c6db21d202f4 // indirect
11+
github.com/apache/pulsar-client-go v0.7.0 // indirect
12+
github.com/apache/pulsar-client-go/oauth2 v0.0.0-20201120111947-b8bd55bc02bd // indirect
13+
github.com/ardielle/ardielle-go v1.5.2 // indirect
14+
github.com/beorn7/perks v1.0.1 // indirect
15+
github.com/cespare/xxhash/v2 v2.1.1 // indirect
16+
github.com/danieljoos/wincred v1.0.2 // indirect
17+
github.com/davecgh/go-spew v1.1.1 // indirect
18+
github.com/dgrijalva/jwt-go v3.2.0+incompatible // indirect
19+
github.com/dvsekhvalnov/jose2go v0.0.0-20180829124132-7f401d37b68a // indirect
20+
github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect
21+
github.com/gogo/protobuf v1.3.2 // indirect
22+
github.com/golang/protobuf v1.4.3 // indirect
23+
github.com/golang/snappy v0.0.1 // indirect
24+
github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect
25+
github.com/keybase/go-keychain v0.0.0-20190712205309-48d3d31d256d // indirect
26+
github.com/klauspost/compress v1.10.8 // indirect
27+
github.com/konsorten/go-windows-terminal-sequences v1.0.1 // indirect
28+
github.com/linkedin/goavro/v2 v2.9.8 // indirect
29+
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
30+
github.com/mitchellh/go-homedir v1.1.0 // indirect
31+
github.com/mtibben/percent v0.2.1 // indirect
32+
github.com/pierrec/lz4 v2.0.5+incompatible // indirect
33+
github.com/pkg/errors v0.9.1 // indirect
34+
github.com/pmezard/go-difflib v1.0.0 // indirect
35+
github.com/prometheus/client_golang v1.7.1 // indirect
36+
github.com/prometheus/client_model v0.2.0 // indirect
37+
github.com/prometheus/common v0.10.0 // indirect
38+
github.com/prometheus/procfs v0.1.3 // indirect
39+
github.com/sirupsen/logrus v1.4.2 // indirect
40+
github.com/spaolacci/murmur3 v1.1.0 // indirect
41+
github.com/stretchr/testify v1.5.1 // indirect
42+
go.uber.org/atomic v1.7.0 // indirect
43+
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 // indirect
44+
golang.org/x/net v0.0.0-20201021035429-f5854403a974 // indirect
45+
golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d // indirect
46+
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f // indirect
47+
golang.org/x/text v0.3.3 // indirect
48+
google.golang.org/appengine v1.4.0 // indirect
49+
google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013 // indirect
50+
google.golang.org/grpc v1.27.0 // indirect
51+
google.golang.org/protobuf v1.25.0 // indirect
52+
gopkg.in/yaml.v2 v2.3.0 // indirect
53+
)
54+
55+
replace golang.org/x/sys => golang.org/x/sys v0.0.0-20220422013727-9388b58f7150

0 commit comments

Comments
(0)