檔案上傳至 Cloud Storage 值區時,Cloud Run 函式會觸發工作流程,執行以下工作流程:使用 Cloud Natural Language API 辨識文字;使用 Cloud Vision API 和 Cloud Video Intelligence API 辨識圖片和影片;將標記儲存並寫入 Firestore。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["難以理解","hardToUnderstand","thumb-down"],["資訊或程式碼範例有誤","incorrectInformationOrSampleCode","thumb-down"],["缺少我需要的資訊/範例","missingTheInformationSamplesINeed","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-09-04 (世界標準時間)。"],[],[],null,["# Choose Workflows or Application Integration\n\nAlthough Application Integration and Workflows\nshare some similar capabilities, they are targeted for different uses, and are\ndelivered differently.\n\nIf you're integrating business systems or implementing a business process,\nconsider using Application Integration. If you're orchestrating\nservices for application development, pipelines, or infrastructure automation,\nconsider using Workflows. You can also use both together; for\nexample, to orchestrate a pipeline that updates an integrated third-party\nbusiness system.\n\nThe following use case-based guidance, examples, and diagrams can help you\nchoose a solution.\n\nUse Application Integration\n---------------------------\n\n**If you are an enterprise architect, integration developer, or business\nanalyst, who needs a way to connect, map, transform, and integrate data between\nbusiness systems like Salesforce, ServiceNow, or a Cloud SQL database:**\n\n- Application Integration is ideal for integrating\n applications that have differing data structures and for exchanging data. It\n provides built-in\n [transformation functions](/application-integration/docs/data-mapping-functions-reference)\n that let you convert the source application data to fit the destination\n application schema.\n\n- Consider using Application Integration for real-time\n business transactions, or processing business transactions in small batches. Or,\n if you have existing Google Cloud applications and are facing\n connectivity challenges as the result of a large number of SaaS applications.\n\n- Application Integration offers a\n [drag-and-drop visual interface](/application-integration/docs/integrations-ui-layout)\n that lets you create an entire integration flow with little or no code.\n Connectors also allow you to call and perform operations on various entities.\n\n**If you need a connector that can be used to integrate and map\ndata between a Google Cloud service such as BigQuery and a\nthird-party service such as ServiceNow:**\n\n- An Application Integration connector hides the complexity of application-specific data structures and protocols. It provides a standard interface to perform create, read, update, and delete operations on application data.\n- For example, a Spanner connection lets you insert, read, update and delete rows in a Spanner table and use the resulting output in an integration. Or, the Oracle DB connector lets you connect to an Oracle database instance and perform the supported database operations.\n- See the list of [supported connectors](/integration-connectors/docs/connector-reference-overview).\n\n### Example: Using Application Integration to map and extract data\n\nThe following diagram shows an example of using Application Integration\nto map and extract data from an external system:\n\nA Salesforce trigger is subscribed to the Salesforce opportunity channel. Data\nchanges to the Salesforce opportunity invokes\nApplication Integration which extracts the status of the\nSalesforce opportunity. If the status is closed, the integration extracts the\nopportunity details and writes the data to a Cloud SQL instance using\na connector. If there is a data change, but the status remains open, the\nintegration sends a message to a Pub/Sub topic using a connector.\n\nUse Workflows\n-------------\n\n**If you are a developer, data engineer, or cloud platform team, who needs a\nway to orchestrate services together to build applications, process automations,\nor implement data and machine learning pipelines:**\n\n- Workflows is ideal if you want to separate the logic that\n sequences and links your services together from your core business logic. A\n workflow can perform a sequence of operations across multiple systems, waiting\n for all operations to complete, and it can be event-driven.\n\n- Consider using Workflows if you want to write less code to\n specify your application infrastructure and execute loosely-coupled services in\n an order that you define: a *workflow*. These workflows can combine the services\n of any HTTP-based API, making service dependencies explicit and observable\n end-to-end.\n\n- A workflow consists of a series of steps described using the\n Workflows [syntax](/workflows/docs/reference/syntax),\n and can be written in either YAML or JSON. Workflows\n [standard library](/workflows/docs/reference/stdlib/overview) functions\n and built-in environment variables allow you to easily construct arguments and\n process responses. Connectors can be used to interact with other\n Google Cloud products.\n\n**If you need a connector that can be used to simplify calling and integrating\nwith other Google Cloud APIs such as Cloud Run functions or\nFirestore within a workflow:**\n\n- Workflows publishes lightweight, serverless connectors that can be used to connect to other Google Cloud APIs within a workflow, and to integrate your workflows with those Google Cloud products. They simplify calling services because they handle the formatting of requests for you, and provide methods and arguments so that you don't need to know the details of a Google Cloud API.\n- For example, you can create a workflow that use the Cloud Translation API connector to translate files to other languages in asynchronous batch mode and save the results in a Cloud Storage bucket. Or, you can execute a workflow that runs multiple BigQuery query jobs serially, one after the other.\n- Supported connectors include a [connector to Application Integration](/workflows/docs/reference/googleapis/integrations/Overview) so that you can use both products together; in this document, see [Use Application Integration and Workflows together](#use-both). For example, you can create a workflow that triggers and waits for an integration, or any other operation such as updating a Salesforce instance.\n- See the list of [supported connectors](/workflows/docs/reference/googleapis).\n\n| **Note:** To deploy ETL/ELT data pipelines, we recommend using [Cloud Data Fusion](/data-fusion).\n\n### Example: Using Workflows for lightweight service orchestration\n\nThe following diagram shows an example of using Workflows to\norchestrate services:\n\nWhen a file is uploaded to a Cloud Storage bucket, a\nCloud Run function triggers Workflows to execute a\nworkflow: text is recognized using the Cloud Natural Language API; images and videos are\nrecognized using the Cloud Vision API and Cloud Video Intelligence API; and tags\nare saved and written to Firestore.\n\nUse Application Integration and Workflows together\n--------------------------------------------------\n\nYou can use Application Integration and\nWorkflows together to orchestrate applications and services.\nWorkflows supports a\n[connector to Application Integration](/workflows/docs/reference/googleapis/integrations/Overview)\nso that you can use both products together. For example, you can perform an\naction in a third-party business system from Workflows using\nApplication Integration. Or, you can connect with custom\ndevelopment from Application Integration using\nWorkflows.\n\n### Example: Using Application Integration and Workflows to perform an action in a third-party business system\n\nIn the following diagram, a refund for digital content is requested through a\nmobile app. Workflows removes the content and\ninitiates a refund process in Application Integration,\nusing heuristic methods and potentially human approval. Based on the result from\nApplication Integration, Workflows either\ngrants a refund or restores the content.\n\nWhat's next\n-----------\n\n- [Learn more about Application Integration](/application-integration/docs/overview).\n- [Learn more about Workflows](/workflows/docs/overview)."]]