Skip to content

Commit 7c391f2

Browse files
committed
Remove GCP support from Functionbeat (#28253)
(cherry picked from commit 3754124)
1 parent 0d33d3b commit 7c391f2

38 files changed

Lines changed: 218 additions & 2437 deletions

CHANGELOG.next.asciidoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,9 @@ to `legacy`. {pull}28538[28538]
9191

9292
*Functionbeat*
9393

94+
- Support for Google Cloud Functions have been removed, as it has been in Beta for a long time and been broken
95+
for a few releases. Please use other tools provided by Elastic to fetch data from GCP (e.g. Filebeat).
96+
9497

9598
==== Bugfixes
9699

NOTICE.txt

Lines changed: 212 additions & 212 deletions
Large diffs are not rendered by default.

go.mod

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ require (
66
cloud.google.com/go v0.83.0
77
cloud.google.com/go/bigquery v1.8.0
88
cloud.google.com/go/pubsub v1.3.1
9-
cloud.google.com/go/storage v1.10.0
109
code.cloudfoundry.org/go-diodes v0.0.0-20190809170250-f77fb823c7ee // indirect
1110
code.cloudfoundry.org/go-loggregator v7.4.0+incompatible
1211
code.cloudfoundry.org/rfc5424 v0.0.0-20180905210152-236a6d29298a // indirect

x-pack/functionbeat/Jenkinsfile.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ stages:
3131
parameters:
3232
- "armTest"
3333
unitTest:
34-
mage: "mage build unitTest && GO_VERSION=1.13.1 mage testGCPFunctions"
34+
mage: "mage build unitTest"
3535
stage: mandatory
3636
goIntegTest:
3737
mage: "mage goIntegTest"

x-pack/functionbeat/Makefile

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,3 @@ ES_BEATS?=../../
88
# Includes
99
#
1010
include $(ES_BEATS)/dev-tools/make/mage.mk
11-
12-
.PHONY: test-gcp-functions
13-
test-gcp-functions: mage
14-
mage testGCPFunctions

x-pack/functionbeat/_meta/config/beat.reference.yml.tmpl

Lines changed: 0 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -295,111 +295,3 @@ functionbeat.provider.aws.functions:
295295

296296
# Set to true to publish fields with null values in events.
297297
#keep_null: false
298-
299-
# Configure functions to run on Google Cloud Platform, currently we assume that the credentials
300-
# are present in the environment to correctly create the function when using the CLI.
301-
#
302-
# Configure which region your project is located in.
303-
functionbeat.provider.gcp.location_id: "europe-west2"
304-
# Configure which Google Cloud project to deploy your functions.
305-
functionbeat.provider.gcp.project_id: "my-project-123456"
306-
# Configure the Google Cloud Storage we should upload the function artifact.
307-
functionbeat.provider.gcp.storage_name: "functionbeat-deploy"
308-
309-
functionbeat.provider.gcp.functions:
310-
# Define the list of function availables, each function required to have a unique name.
311-
# Create a function that accepts events coming from Google Pub/Sub.
312-
- name: pubsub
313-
enabled: false
314-
type: pubsub
315-
316-
# Description of the method to help identify them when you run multiples functions.
317-
description: "Google Cloud Function for Pub/Sub"
318-
319-
# The maximum memory allocated for this function.
320-
# Default is 256MB.
321-
#memory_size: 256MB
322-
323-
# Execution timeout in seconds. If the function does not finish in time,
324-
# it is considered failed and terminated. Default is 60s.
325-
#timeout: 60s
326-
327-
# Email of the service account of the function. Defaults to {projectid}@appspot.gserviceaccount.com
328-
#service_account_email: {projectid}@appspot.gserviceaccount.com
329-
330-
# Labels of the function.
331-
#labels:
332-
# mylabel: label
333-
334-
# VPC Connector this function can connect to.
335-
# Format: projects/*/locations/*/connectors/* or fully-qualified URI
336-
#vpc_connector: ""
337-
338-
# Number of maximum instances running at the same time. Default is unlimited.
339-
#maximum_instances: 0
340-
341-
trigger:
342-
resource: "projects/_/pubsub/myPubSub"
343-
#service: "pubsub.googleapis.com"
344-
345-
# Set to true to publish fields with null values in events.
346-
#keep_null: false
347-
348-
# Optional fields that you can specify to add additional information to the
349-
# output. Fields can be scalar values, arrays, dictionaries, or any nested
350-
# combination of these.
351-
#fields:
352-
# env: staging
353-
354-
# Define custom processors for this function.
355-
#processors:
356-
# - dissect:
357-
# tokenizer: "%{key1} %{key2}"
358-
359-
# Create a function that accepts events coming from Google Cloud Storage.
360-
- name: storage
361-
enabled: false
362-
type: storage
363-
364-
# Description of the method to help identify them when you run multiples functions.
365-
description: "Google Cloud Function for Cloud Storage"
366-
367-
# The maximum memory allocated for this function.
368-
# Default is 256MB.
369-
#memory_size: 256MB
370-
371-
# Execution timeout in seconds. If the function does not finish in time,
372-
# it is considered failed and terminated. Default is 60s.
373-
#timeout: 60s
374-
375-
# Email of the service account of the function. Defaults to {projectid}@appspot.gserviceaccount.com
376-
#service_account_email: {projectid}@appspot.gserviceaccount.com
377-
378-
trigger:
379-
resource: "projects/my-project/buckets/my-storage"
380-
#event_type: "google.storage.object.finalize"
381-
382-
# Labels of the function.
383-
#labels:
384-
# mylabel: label
385-
386-
# VPC Connector this function can connect to.
387-
# Format: projects/*/locations/*/connectors/* or fully-qualified URI
388-
#vpc_connector: ""
389-
390-
# Number of maximum instances running at the same time. Default is unlimited.
391-
#maximum_instances: 0
392-
393-
# Set to true to publish fields with null values in events.
394-
#keep_null: false
395-
396-
# Optional fields that you can specify to add additional information to the
397-
# output. Fields can be scalar values, arrays, dictionaries, or any nested
398-
# combination of these.
399-
#fields:
400-
# env: staging
401-
402-
# Define custom processors for this function.
403-
#processors:
404-
# - dissect:
405-
# tokenizer: "%{key1} %{key2}"

x-pack/functionbeat/_meta/config/beat.yml.tmpl

Lines changed: 0 additions & 101 deletions
Original file line numberDiff line numberDiff line change
@@ -251,104 +251,3 @@ functionbeat.provider.aws.functions:
251251
# Default is 1.
252252
#parallelization_factor: 1
253253

254-
# Configure functions to run on Google Cloud Platform, currently we assume that the credentials
255-
# are present in the environment to correctly create the function when using the CLI.
256-
#
257-
# Configure which region your project is located in.
258-
functionbeat.provider.gcp.location_id: "europe-west2"
259-
# Configure which Google Cloud project to deploy your functions.
260-
functionbeat.provider.gcp.project_id: "my-project-123456"
261-
# Configure the Google Cloud Storage we should upload the function artifact.
262-
functionbeat.provider.gcp.storage_name: "functionbeat-deploy"
263-
264-
functionbeat.provider.gcp.functions:
265-
# Define the list of function availables, each function required to have a unique name.
266-
# Create a function that accepts events coming from Google Pub/Sub.
267-
- name: pubsub
268-
enabled: false
269-
type: pubsub
270-
271-
# Description of the method to help identify them when you run multiples functions.
272-
description: "Google Cloud Function for Pub/Sub"
273-
274-
# The maximum memory allocated for this function.
275-
# Default is 256MB.
276-
#memory_size: 256MB
277-
278-
# Execution timeout in seconds. If the function does not finish in time,
279-
# it is considered failed and terminated. Default is 60s.
280-
#timeout: 60s
281-
282-
# Email of the service account of the function. Defaults to {projectid}@appspot.gserviceaccount.com
283-
#service_account_email: {projectid}@appspot.gserviceaccount.com
284-
285-
# Labels of the function.
286-
#labels:
287-
# mylabel: label
288-
289-
# VPC Connector this function can connect to.
290-
# Format: projects/*/locations/*/connectors/* or fully-qualified URI
291-
#vpc_connector: ""
292-
293-
# Number of maximum instances running at the same time. Default is unlimited.
294-
#maximum_instances: 0
295-
296-
trigger:
297-
resource: "projects/_/pubsub/myPubSub"
298-
#service: "pubsub.googleapis.com"
299-
300-
# Define custom processors for this function.
301-
#processors:
302-
# - dissect:
303-
# tokenizer: "%{key1} %{key2}"
304-
305-
# Create a function that accepts events coming from Google Cloud Storage.
306-
- name: storage
307-
enabled: false
308-
type: storage
309-
310-
# Description of the method to help identify them when you run multiples functions.
311-
description: "Google Cloud Function for Cloud Storage"
312-
313-
# The maximum memory allocated for this function.
314-
# Default is 256MB.
315-
#memory_size: 256MB
316-
317-
# Execution timeout in seconds. If the function does not finish in time,
318-
# it is considered failed and terminated. Default is 60s.
319-
#timeout: 60s
320-
321-
# Email of the service account of the function. Defaults to {projectid}@appspot.gserviceaccount.com
322-
#service_account_email: {projectid}@appspot.gserviceaccount.com
323-
324-
trigger:
325-
resource: "projects/my-project/buckets/my-storage"
326-
#event_type: "google.storage.object.finalize"
327-
328-
# Labels of the function.
329-
#labels:
330-
# mylabel: label
331-
332-
# VPC Connector this function can connect to.
333-
# Format: projects/*/locations/*/connectors/* or fully-qualified URI
334-
#vpc_connector: ""
335-
336-
# Number of maximum instances running at the same time. Default is unlimited.
337-
#maximum_instances: 0
338-
339-
# Optional fields that you can specify to add additional information to the
340-
# output. Fields can be scalar values, arrays, dictionaries, or any nested
341-
# combination of these.
342-
#fields:
343-
# env: staging
344-
345-
# Define custom processors for this function.
346-
#processors:
347-
# - dissect:
348-
# tokenizer: "%{key1} %{key2}"
349-
#==================== Elasticsearch template setting ==========================
350-
351-
setup.template.settings:
352-
index.number_of_shards: 1
353-
#index.codec: best_compression
354-
#_source.enabled: false

x-pack/functionbeat/dev-tools/packaging/packages.yml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -65,18 +65,6 @@ shared:
6565
pkg/functionbeat-aws:
6666
source: 'provider/aws/build/golang-crossbuild/aws-linux-amd64'
6767
mode: 0755
68-
pkg/pubsub/vendor:
69-
source: 'provider/gcp/build/pubsub/vendor'
70-
mode: 0644
71-
pkg/storage/vendor:
72-
source: 'provider/gcp/build/storage/vendor'
73-
mode: 0644
74-
pkg/pubsub/pubsub.go:
75-
source: 'provider/gcp/pubsub/pubsub.go'
76-
mode: 0655
77-
pkg/storage/storage.go:
78-
source: 'provider/gcp/storage/storage.go'
79-
mode: 0655
8068

8169
# specs is a list of named packaging "flavors".
8270
specs:

0 commit comments

Comments
 (0)