Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/GoogleCloudPlatform/golang-samples
/ functions
Functions
5,023 in github.com/GoogleCloudPlatform/golang-samples
⨍
Functions
5,023
◇
Types & classes
329
↓ 1 callers
Function
initAssetForManipulation
()
securitycenter/securitymarksv2/assets_test.go:123
↓ 1 callers
Function
initAssetForManipulation
()
securitycenter/assets/assets_test.go:123
↓ 1 callers
Function
initBackupTest
(t *testing.T, id, instName string)
spanner/spanner_snippets/spanner/integration_test.go:107
↓ 1 callers
Method
initCounter
[END firestore_solution_sharded_counter_custom_type] [START firestore_solution_sharded_counter_create] initCounter creates a given number of shards as
firestore/solution_counters.go:46
↓ 1 callers
Function
initInstancePartitionTest
(t *testing.T, id string)
spanner/spanner_snippets/spanner/integration_test.go:116
↓ 1 callers
Function
initializeClients
[END getting_started_background_translate_setup] [START getting_started_background_translate_init] initializeClients creates translateClient and fires
getting-started/background/translate.go:64
↓ 1 callers
Function
initializeCredentials
initializeCredentials will generate a downscoped token using the provided Access Boundary Rules.
auth/downscoping/credential_initialization.go:31
↓ 1 callers
Function
initializeRedis
initializeRedis initializes and returns a connection pool
functions/memorystore/redis/visitcount.go:40
↓ 1 callers
Function
inputStages
(w io.Writer, client *firestore.Client)
firestore/pipeline_snippets_general.go:1773
↓ 1 callers
Function
insertRows
insertRows demonstrates inserting data into a table using the streaming insert mechanism.
bigquery/snippets/table/bigquery_table_insert_rows.go:41
↓ 1 callers
Function
insertingDataTypes
insertingDataTypes demonstrates inserting data into a table using the streaming insert mechanism.
bigquery/snippets/table/bigquery_inserting_data_types.go:46
↓ 1 callers
Function
inspectAugmentInfoTypes
inspectAugmentInfoTypes performs info type augmentation using Google Cloud DLP. It enhances data inspection by supplementing existing info types with
dlp/snippets/inspect/inspect_augment_infotypes.go:30
↓ 1 callers
Function
inspectBigQuerySendToScc
inspectBigQuerySendToScc configures the inspection job that instructs Cloud DLP to scan data stored in BigQuery, and also instructs Cloud DLP to save
dlp/snippets/inspect/inspect_bigquery_send_to_scc.go:28
↓ 1 callers
Function
inspectBigQueryTableWithSampling
inspectBigQueryTableWithSampling inspect bigQueries for sensitive data with sampling
dlp/snippets/inspect/inspect_bigquery_with_sampling.go:29
↓ 1 callers
Function
inspectBigquery
inspectBigquery searches for the given info types in the given Bigquery dataset table.
dlp/snippets/inspect/inspect_bigquery.go:31
↓ 1 callers
Function
inspectDataStoreSendToScc
inspectDataStoreSendToScc inspects sensitive data in a Datastore and sends the results to Google Cloud Security Command Center (SCC).
dlp/snippets/inspect/inspect_datastore_send_to_scc.go:28
↓ 1 callers
Function
inspectDataToHybridJobTrigger
inspectDataToHybridJobTrigger uses the Data Loss Prevention API to inspect sensitive information using Hybrid jobs trigger that scans payloads of data
dlp/snippets/inspect/inspect_send_data_to_hybrid_job_trigger.go:31
↓ 1 callers
Function
inspectDatastore
inspectDatastore searches for the given info types in the given dataset kind.
dlp/snippets/inspect/inspect_datastore.go:31
↓ 1 callers
Function
inspectGCSFile
inspectGCSFile searches for the given info types in the given file.
dlp/snippets/inspect/inspect_gcs.go:31
↓ 1 callers
Function
inspectGCSFileSendToScc
inspectGCSFileSendToScc inspects sensitive data in a Google Cloud Storage (GCS) file and sends the inspection results to Google Cloud Security Command
dlp/snippets/inspect/inspect_gcs_send_to_scc.go:28
↓ 1 callers
Function
inspectGcsFileWithSampling
inspectGcsFileWithSampling inspects a storage with sampling
dlp/snippets/inspect/inspect_gcs_with_sampling.go:30
↓ 1 callers
Function
inspectImageFile
inspectImageFile inspects an image file for sensitive data
dlp/snippets/inspect/inspect_image_file.go:28
↓ 1 callers
Function
inspectImageFileAllInfoTypes
inspectImageFileAllInfoTypes inspects a image for sensitive data with infoTypes
dlp/snippets/inspect/inspect_image_all_infotypes.go:28
↓ 1 callers
Function
inspectImageFileListedInfoTypes
inspectImageFileListedInfoTypes inspects an image for sensitive data listed infoTypes.
dlp/snippets/inspect/inspect_image_listed_infotypes.go:28
↓ 1 callers
Function
inspectPhoneNumber
inspectPhoneNumber demonstrates a simple scan request to the Cloud DLP API. Notice that the PHONE_NUMBER detector is specified in inspectConfig, which
dlp/snippets/inspect/inspect_phone_number.go:29
↓ 1 callers
Function
inspectString
inspectString inspects the a given string, and prints results.
dlp/snippets/inspect/inspect_string.go:28
↓ 1 callers
Function
inspectStringCustomExcludingSubstring
inspectStringCustomExcludingSubstring inspects a string for sensitive data, excluding a custom substring
dlp/snippets/inspect/inspect_string_excluding_substring.go:28
↓ 1 callers
Function
inspectStringCustomHotWord
inspectStringCustomHotWord inspects a string from sensitive data by using a custom hot word
dlp/snippets/inspect/inspect_string_custom_hotword.go:28
↓ 1 callers
Function
inspectStringCustomOmitOverlap
inspectStringCustomOmitOverlap inspects a string for sensitive data with omitting custom matches
dlp/snippets/inspect/inspect_string_custom_omit_overlap.go:27
↓ 1 callers
Function
inspectStringMultipleRules
inspectStringMultipleRules inspects the provided text, avoiding matches specified in the exclusion list. this function implements the both exclusion a
dlp/snippets/inspect/inspect_string_multiple_rules.go:30
↓ 1 callers
Function
inspectStringOmitOverlap
inspectStringOmitOverlap inspects a string for sensitive data and omitting overlapping matches on person and email
dlp/snippets/inspect/inspect_string_omit_overlap.go:28
↓ 1 callers
Function
inspectStringRep
inspectString inspects the a given string, and prints results.
dlp/snippets/inspect/inspect_string_rep.go:29
↓ 1 callers
Function
inspectStringWithExclusionDictSubstring
inspectStringWithExclusionDictSubstring inspects a string with an exclusion dictionary substring
dlp/snippets/inspect/inspect_string_with_exclusion_dict_substring.go:28
↓ 1 callers
Function
inspectStringWithExclusionDictionary
inspectStringWithExclusionDictionary inspects a string for sensitive data using exclusion dictionary, here the function omits a specific email address
dlp/snippets/inspect/inspect_string_with_exclusion_dict.go:30
↓ 1 callers
Function
inspectStringWithExclusionRegex
inspectStringWithExclusionRegex inspects a string excluding REGEX matches in this function specifically the function omits email addresses ending with
dlp/snippets/inspect/inspect_string_with_exclusion_regex.go:30
↓ 1 callers
Function
inspectStringWithoutOverlap
inspectStringWithoutOverlap inspects a string for sensitive data and omit overlapping matches on domain and email
dlp/snippets/inspect/inspect_string_without_overlap.go:29
↓ 1 callers
Function
inspectTable
inspectTable inspects a table for sensitive content
dlp/snippets/inspect/inspect_table.go:27
↓ 1 callers
Function
inspectTableWithCustomHotword
inspectTableWithCustomHotword Sets the match likelihood of a table column to customize data inspection results. This example showcases how you can adj
dlp/snippets/inspect/inspect_column_values_w_custom_hotwords.go:31
↓ 1 callers
Function
inspectTextFile
inspectTextFile inspects a text file at a given filePath, and prints results.
dlp/snippets/inspect/inspect_text_file.go:29
↓ 1 callers
Function
inspectWithCustomRegex
inspectWithCustomRegex inspect a data with custom regex pattern
dlp/snippets/inspect/inspect_with_custom_regex.go:28
↓ 1 callers
Function
inspectWithHotWordRules
inspectWithHotWordRules inspects data with hot word rule, it uses custom regex with a hot word rule to increase the likelihood match
dlp/snippets/inspect/inspect_hotword_rule.go:29
↓ 1 callers
Function
inspectWithStoredInfotype
inspectWithStoredInfotype inspects the given text using the specified stored infoType detector.
dlp/snippets/inspect/inspect_with_stored_infotype.go:28
↓ 1 callers
Function
instantiateInlineWorkflowTemplate
(w io.Writer, projectID, region string)
dataproc/instantiate_inline_workflow_template.go:31
↓ 1 callers
Function
isSpotVM
isSpotVM checks if a given instance is a Spot VM or not.
compute/instances/spot/spot_check.go:29
↓ 1 callers
Function
jobTitleAutoComplete
[START job_auto_complete_job_title] jobTitleAutoComplete suggests the job titles of the given companyName based on query.
jobs/v3/howto/auto_complete_sample.go:30
↓ 1 callers
Function
jobTitleAutocomplete
jobTitleAutoComplete suggests the job titles of the given company identifier on query.
jobs/v4/howto/auto_complete_sample.go:29
↓ 1 callers
Function
jobsGet
jobsGet gets an inspection job using jobName
dlp/snippets/jobs/get.go:28
↓ 1 callers
Function
keywordLocationSearch
[END job_broadening_location_search] [START job_keyword_location_search] keywordLocationSearch searches for jobs with given keyword and within the dis
jobs/v3/howto/location_based_search_sample.go:213
↓ 1 callers
Function
kgSearch
kgSearch uses the Knowledge Graph API to search for a query provided by a Slack command.
functions/functionsv2/slack/search.go:68
↓ 1 callers
Function
labelGceInstance
Cloud Function that receives GCE instance creation Audit Logs, and adds a `creator` label to the instance.
functions/functionsv2/label_gce_instance/label_gce_instance.go:63
↓ 1 callers
Function
labelURI
[START video_analyze_labels_gcs]
videointelligence/video_analyze/video_analyze_gcs.go:29
↓ 1 callers
Function
languageCodeSearch
[END job_discovery_date_range_filter_search] [START job_discovery_language_code_filter_search] languageCodeSearch searches for jobs on language code.
jobs/v3/howto/general_search_sample.go:256
↓ 1 callers
Function
lease
(ctx context.Context, duration string)
testing/gimmeproj/main.go:225
↓ 1 callers
Function
lessThanFunction
(w io.Writer, client *firestore.Client)
firestore/pipeline_snippets_comparison.go:82
↓ 1 callers
Function
lessThanOrEqualToFunction
(w io.Writer, client *firestore.Client)
firestore/pipeline_snippets_comparison.go:101
↓ 1 callers
Function
lightComputation
()
functions/tips/scope.go:53
↓ 1 callers
Function
likeFunction
(w io.Writer, client *firestore.Client)
firestore/pipeline_snippets_string.go:101
↓ 1 callers
Function
limitSyntaxExample
(w io.Writer, client *firestore.Client)
firestore/pipeline_snippets_general.go:1463
↓ 1 callers
Function
lineNumber
()
internal/testutil/retry.go:110
↓ 1 callers
Function
list
(projectID string)
pubsub/v1samples/topics/list_topics.go:26
↓ 1 callers
Function
list
(projectID string)
pubsub/v1samples/subscriptions/list.go:26
↓ 1 callers
Function
list
(projectID string)
pubsub/subscriptions/list.go:27
↓ 1 callers
Function
list
[END monitoring_uptime_check_create] [START monitoring_uptime_check_list_configs] list is an example of listing the uptime checks in projectID.
monitoring/uptime/uptime.go:119
↓ 1 callers
Function
listAlertPolicies
[START monitoring_alert_list_policies] listAlertPolicies lists the alert policies in the project.
monitoring/alert/alert.go:37
↓ 1 callers
Function
listAllAssets
listAllAssets prints every asset to w for orgID. orgID is the numeric Organization ID.
securitycenter/assets/list_all_assets.go:30
↓ 1 callers
Function
listAllInstances
listAllInstances prints all instances present in a project, grouped by their zone.
compute/list_all_instances.go:30
↓ 1 callers
Function
listAllModels
listAllModels lists all of the Vertex AI models in a project for a specific region.
aiplatform/snippets/list_models.go:31
↓ 1 callers
Function
listAllProjectAssets
listAllProjectAssets lists all current GCP project assets in orgID and prints out results to w. orgID is the numeric organization ID of interest.
securitycenter/assets/list_all_project_assets.go:30
↓ 1 callers
Function
listAllProjectAssetsAndStateChanges
listAllProjectAssetsAndStateChange lists all current GCP project assets in orgID and prints the projects and there change from a day ago out to w. org
securitycenter/assets/list_project_assets_and_state_changes.go:33
↓ 1 callers
Function
listAssets
listAssets lists all assets for a given location.
media/livestream/list_assets.go:30
↓ 1 callers
Function
listAssetsWithMarks
listAssetsWithMarks prints assets that have a mark of key_a equal to value_a to w for orgID. orgID is the numeric Organization ID.
securitycenter/assets/list_assets_with_security_marks.go:30
↓ 1 callers
Function
listBigQueryExport
List BigQuery exports in the given parent.
securitycenter/bigqueryv2/list_big_query_export.go:30
↓ 1 callers
Function
listBucketNotifications
listBucketNotifications lists notification configurations for a bucket.
storage/notifications/list.go:27
↓ 1 callers
Function
listBuckets
listBuckets lists buckets in the project.
storage/buckets/list_buckets.go:29
↓ 1 callers
Function
listBucketsPartialSuccess
listBucketsPartialSuccess lists buckets in the project. If ReturnPartialSuccess is true, the iterator will return reachable buckets and a list of unre
storage/buckets/list_buckets_partial_success.go:31
↓ 1 callers
Function
listCDNKeys
listCDNKeys gets all of the CDN keys for a given location.
media/videostitcher/list_cdn_keys.go:29
↓ 1 callers
Function
listCas
List all Certificate Authorities present in the given CA Pool.
privateca/list_cas.go:29
↓ 1 callers
Function
listCertificates
List Certificates present in the given CA pool.
privateca/list_certificates.go:29
↓ 1 callers
Function
listChannelEvents
listChannelEvents lists all channel events for a given channel.
media/livestream/list_channel_events.go:30
↓ 1 callers
Function
listChannels
listChannels lists all channels for a given location.
media/livestream/list_channels.go:30
↓ 1 callers
Function
listClusters
(svc *container.Service, projectID, zone string)
container/listclusters/listclusters.go:69
↓ 1 callers
Function
listClusters
(w io.Writer, projectID, region string, opts ...option.ClientOption)
managedkafka/clusters/list_clusters.go:30
↓ 1 callers
Function
listCompanies
[END job_delete_company] [START job_list_companies] listCompanies lists all companies in the project.
jobs/v3/howto/basic_company_sample.go:172
↓ 1 callers
Function
listConnectClusters
(w io.Writer, projectID, region string, opts ...option.ClientOption)
managedkafka/connect/clusters/list_connect_clusters.go:30
↓ 1 callers
Function
listConnectors
(w io.Writer, projectID, region, connectClusterID string, opts ...option.ClientOption)
managedkafka/connect/connectors/list_connectors.go:30
↓ 1 callers
Function
listConsumerGroups
(w io.Writer, projectID, region, clusterID string, opts ...option.ClientOption)
managedkafka/consumergroups/list_consumergroups.go:30
↓ 1 callers
Function
listContentCache
listContentCache shows how to retrieve details about cached content.
genai/content_cache/contentcache_list.go:30
↓ 1 callers
Function
listDICOMStores
listDICOMStores prints a list of DICOM stores to w.
healthcare/dicom_store_list.go:27
↓ 1 callers
Function
listDatabases
listDatabases gets list of all databases for an instance
spanner/spanner_snippets/spanner/spanner_list_databases.go:29
↓ 1 callers
Function
listDatasets
listDatasets demonstrates iterating through the collection of datasets in a project.
bigquery/snippets/dataset/bigquery_list_datasets.go:28
↓ 1 callers
Function
listDatasets
listDatasets demonstrates iterating through datasets.
bigquery/snippets_preview/dataset/bigquery_list_datasets.go:31
↓ 1 callers
Function
listDatasets
listDatasets prints a list of datasets to w.
healthcare/dataset_list.go:27
↓ 1 callers
Function
listDatasetsByLabel
listDatasetsByLabel demonstrates walking the collection of datasets in a project, and filtering that list to a subset that has specific label metadata
bigquery/snippets/dataset/bigquery_list_datasets_by_label.go:29
↓ 1 callers
Function
listDenyPolicies
listDenyPolicies lists all the deny policies that are attached to a resource. A resource can have up to 5 deny policies.
iam/deny/list_deny_policies.go:30
↓ 1 callers
Function
listDescendantEventThreatDetectionCustomModule
listDescendantEventThreatDetectionCustomModule lists descendant custom modules for Event Threat Detection.
securitycenter/management_api/event_threat_detection/list_descendant_event_threat_detection_custom_module.go:30
↓ 1 callers
Function
listDescendantSecurityHealthAnalyticsCustomModule
listDescendantSecurityHealthAnalyticsCustomModule creates a custom module for Security Health Analytics.
securitycenter/management_api/list_descendant_security_health_analytics_custom_module.go:30
↓ 1 callers
Function
listEffectiveEventThreatDetectionCustomModule
listEffectiveEventThreatDetectionCustomModule lists effective custom modules for Event Threat Detection.
securitycenter/management_api/event_threat_detection/list_effective_event_threat_detection_custom_module.go:30
↓ 1 callers
Function
listEffectiveSecurityHealthAnalyticsCustomModule
listEffectiveSecurityHealthAnalyticsCustomModule creates a custom module for Security Health Analytics.
securitycenter/management_api/list_effective_security_health_analytics_custom_module.go:30
↓ 1 callers
Function
listEventThreatDetectionCustomModule
listEventThreatDetectionCustomModule lists all custom modules for Event Threat Detection.
securitycenter/management_api/event_threat_detection/list_event_threat_detection_custom_module.go:30
↓ 1 callers
Function
listFHIRResourceHistory
listFHIRResourceHistory lists an FHIR resource's history.
healthcare/fhir_resource_history_list.go:27
← previous
next →
1,901–2,000 of 5,023, ranked by callers