Cloud Functions (2য় জেনার) , যা আপনার ফাংশনগুলিকে Cloud Run পরিষেবা হিসাবে স্থাপন করে, যা আপনাকে Eventarc এবং Pub/Sub ব্যবহার করে ট্রিগার করতে দেয়।
Cloud Functions (1ম প্রজন্ম) , সীমিত ইভেন্ট ট্রিগার এবং কনফিগারযোগ্যতা সহ ফাংশনের আসল সংস্করণ।
আমরা সুপারিশ করি যে আপনি যেখানেই সম্ভব নতুন ফাংশনের জন্য Cloud Functions (2nd gen) বেছে নিন। যাইহোক, আমরা Cloud Functions (1ম প্রজন্ম) সমর্থন করা চালিয়ে যাওয়ার পরিকল্পনা করছি।
এই পৃষ্ঠাটি Cloud Functions প্রবর্তিত বৈশিষ্ট্যগুলি বর্ণনা করে এবং দুটি পণ্য সংস্করণের মধ্যে একটি তুলনা প্রদান করে।
Cloud Functions (২য় প্রজন্ম)
Cloud Functions হল Firebase-এর পরবর্তী প্রজন্মের ফাংশন-এ-এ-সার্ভিস অফার। Cloud Run এবং Eventarc উপর নির্মিত, Cloud Functions (2nd gen) Cloud Functions উন্নত পরিকাঠামো এবং বৃহত্তর ইভেন্ট কভারেজ নিয়ে আসে, যার মধ্যে রয়েছে:
Cloud Run বিল্ট : ফাংশনগুলি Cloud Build সাথে তৈরি করা হয় এবং ডিফল্ট Cloud Run এক্সিকিউশন পরিবেশ ব্যবহার করে Cloud Run পরিষেবা হিসাবে স্থাপন করা হয়। এটি আপনাকে Cloud Run পরিষেবার মতো আপনার ফাংশন কাস্টমাইজ করার ক্ষমতা দেয়৷ আপনার পরিষেবা কনফিগার করার বিকল্পগুলি অন্বেষণ করতে Cloud Run ডকুমেন্টেশন পড়ুন, যেমন মেমরি সীমা , পরিবেশ ভেরিয়েবল ইত্যাদি।
দীর্ঘ সময়ের অনুরোধ প্রক্রিয়াকরণ : Cloud Storage বা BigQuery থেকে ডেটার বড় স্ট্রিম প্রক্রিয়াকরণের মতো দীর্ঘ-অনুরোধের কাজের চাপ চালান।
বৃহত্তর দৃষ্টান্তের আকার : বড় ইন-মেমরি, কম্পিউট-ইনটেনসিভ, এবং সমান্তরাল ওয়ার্কলোড চালান।
উন্নত সমসাময়িকতা : ঠান্ডা শুরু কমাতে এবং লেটেন্সি উন্নত করতে একটি একক ফাংশন ইন্সট্যান্স সহ একাধিক সমবর্তী অনুরোধগুলি পরিচালনা করুন।
ট্রাফিক ম্যানেজমেন্ট : বিভিন্ন ফাংশন রিভিশনের মধ্যে ট্রাফিককে বিভক্ত করুন বা একটি ফাংশনকে আগের সংস্করণে ফিরিয়ে দিন।
Eventarc ইন্টিগ্রেশন : Eventarc ট্রিগারের জন্য নেটিভ সাপোর্ট, Cloud FunctionsEventarc দ্বারা সমর্থিত 90+ ইভেন্ট সোর্স নিয়ে আসে।
বৃহত্তর ক্লাউড ইভেন্ট সমর্থন : সব ভাষার রানটাইমে শিল্প-মান ক্লাউড ইভেন্টের জন্য সমর্থন, একটি সামঞ্জস্যপূর্ণ বিকাশকারী অভিজ্ঞতা প্রদান করে।
যেহেতু Cloud FunctionsCloud Run পরিষেবা হিসাবে ফাংশন স্থাপন করে, Cloud FunctionsCloud Run সাথে সংস্থান কোটা এবং সীমা ভাগ করে। কোটা দেখুন।
তুলনা টেবিল
বৈশিষ্ট্য
Cloud Functions (1ম প্রজন্ম)
Cloud Functions
ইমেজ রেজিস্ট্রি
Container Registry বা Artifact Registry
Artifact Registry শুধুমাত্র
সময় শেষ করার অনুরোধ করুন
9 মিনিট পর্যন্ত
HTTP-ট্রিগার করা ফাংশনের জন্য 60 মিনিট পর্যন্ত
ইভেন্ট-ট্রিগার করা ফাংশনের জন্য 9 মিনিট পর্যন্ত
পরিষেবা অ্যাকাউন্ট*
Google অ্যাপ ইঞ্জিন পরিষেবা অ্যাকাউন্ট ( PROJECT_ID @ appspot.gserviceaccount.com)
Google ক্লাউড ডিফল্ট গণনা পরিষেবা অ্যাকাউন্ট ( PROJECT_NUMBER -compute@developer.gserviceaccount.com)
উদাহরণ আকার
2 vCPU সহ 8GB পর্যন্ত RAM
4 vCPU সহ 16GiB RAM পর্যন্ত
সঙ্গতি
প্রতি ফাংশন দৃষ্টান্তে 1টি সমবর্তী অনুরোধ
প্রতি ফাংশন ইন্সট্যান্সে 1000 পর্যন্ত সমবর্তী অনুরোধ
* এটি একটি চলমান ফাংশন থেকে ফায়ারবেস বা ক্লাউড এপিআই অ্যাক্সেস করতে ব্যবহৃত ডিফল্ট পরিষেবা অ্যাকাউন্ট। আপনি যখন আর্গুমেন্ট ছাড়াই শুরু করেন তখন এটি Firebase অ্যাডমিন SDK দ্বারা ব্যবহৃত হয়।
অনুরোধ করা হলে, আপনার Google ক্লাউড প্রকল্পের সাথে যুক্ত বিলিং অ্যাকাউন্ট নির্বাচন করুন।
ফিল্টার প্যানেলে, লেবেলগুলির অধীনে, কী goog-managed-by এবং মান cloudfunctions সাথে একটি লেবেল ফিল্টার যোগ করুন ৷
সীমাবদ্ধতা
Cloud Functions for FirebaseAnalytics ইভেন্টগুলির জন্য সমর্থন প্রদান করে না।
যদিও Cloud Functions for Firebase প্রমাণীকরণ ব্লকিং ইভেন্টগুলিকে সমর্থন করে, এটি 1st gen এর মতো মৌলিক Authentication ইভেন্টগুলির একই সেট সমর্থন করে না।
যাইহোক, যেহেতু 1st gen এবং 2nd gen ফাংশন একই সোর্স ফাইলে পাশাপাশি থাকতে পারে, আপনি এখনও 2nd gen ফাংশনগুলির সাথে 1st gen-এ Analytics এবং মৌলিক Authentication ট্রিগারগুলি বিকাশ এবং স্থাপন করতে পারেন৷
[[["সহজে বোঝা যায়","easyToUnderstand","thumb-up"],["আমার সমস্যার সমাধান হয়েছে","solvedMyProblem","thumb-up"],["অন্যান্য","otherUp","thumb-up"]],[["এতে আমার প্রয়োজনীয় তথ্য নেই","missingTheInformationINeed","thumb-down"],["খুব জটিল / অনেক ধাপ","tooComplicatedTooManySteps","thumb-down"],["পুরনো","outOfDate","thumb-down"],["অনুবাদ সংক্রান্ত সমস্যা","translationIssue","thumb-down"],["নমুনা / কোড সংক্রান্ত সমস্যা","samplesCodeIssue","thumb-down"],["অন্যান্য","otherDown","thumb-down"]],["2025-08-15 UTC-তে শেষবার আপডেট করা হয়েছে।"],[],[],null,["\u003cbr /\u003e\n\nThere are two versions of Cloud Functions for Firebase:\n\n- **Cloud Functions (2nd gen)** , which deploys your functions as services on Cloud Run, allowing you to trigger them using Eventarc and Pub/Sub.\n- **Cloud Functions (1st gen)**, the original version of functions with limited event triggers and configurability.\n\nWe recommend that you choose Cloud Functions (2nd gen) for new functions\nwherever possible. However, we plan to continue supporting Cloud Functions\n(1st gen).\n\nThis page describes features introduced in Cloud Functions and\nprovides a comparison between the two product versions.\n\nCloud Functions (2nd gen)\n\nCloud Functions is Firebase's next-generation\nFunctions-as-a-Service offering. Built on Cloud Run and\nEventarc, Cloud Functions (2nd gen) brings enhanced\ninfrastructure and broader event coverage to Cloud Functions, including:\n\n- **Built on Cloud Run** : Functions are built with Cloud Build and deployed as Cloud Run services using the default [Cloud Run execution environment](//cloud.google.com/run/docs/about-execution-environments). This gives you the ability to customize your function as you would a Cloud Run service. Refer to Cloud Run documentation to explore options for configuring your service, such as [memory\n limits](//cloud.google.com/run/docs/configuring/services/memory-limits), [environment variables](//cloud.google.com/run/docs/configuring/services/environment-variables), and so forth.\n- **Longer request processing times** : Run longer-request workloads such as processing large streams of data from Cloud Storage or BigQuery.\n- **Larger instance sizes**: Run larger in-memory, compute-intensive, and parallel workloads.\n- **Improved concurrency**: Handle multiple concurrent requests with a single function instance to minimize cold starts and improve latency.\n- **Traffic management**: Split traffic between different function revisions or roll a function back to a prior version.\n- **Eventarc integration** : Native support for Eventarc triggers, bringing all 90+ event sources supported by Eventarc to Cloud Functions.\n- **Broader CloudEvents support** : Support for industry-standard [CloudEvents](https://cloudevents.io/) in all language runtimes, providing a consistent developer experience.\n\nSee the [comparison table](#comparison-table) for details.\n\nBecause Cloud Functions deploys functions as services on Cloud Run,\nCloud Functions shares resource quotas and limits with\nCloud Run. See [Quotas](/docs/functions/quotas).\n\nComparison table\n\n| Feature | Cloud Functions (1st gen) | Cloud Functions |\n|-------------------|------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------|\n| Image registry | Container Registry or Artifact Registry | Artifact Registry only |\n| Request timeout | Up to 9 minutes | - Up to 60 minutes for HTTP-triggered functions - Up to 9 minutes for event-triggered functions |\n| Service account\\* | Google App Engine service account (\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e@appspot.gserviceaccount.com) | Google Cloud default compute service account (\u003cvar translate=\"no\"\u003ePROJECT_NUMBER\u003c/var\u003e-compute@developer.gserviceaccount.com) |\n| Instance size | Up to 8GB RAM with 2 vCPU | Up to 16GiB RAM with 4 vCPU |\n| Concurrency | 1 concurrent request per function instance | Up to 1000 concurrent requests per function instance |\n\n\\* This is the default service account used to access Firebase or Cloud APIs\nfrom a running function. It is used by the Firebase Admin SDK when you\n[initialize without arguments](/docs/admin/setup#initialize-sdk).\n\nPricing\n\nFor pricing information, see [Firebase pricing plans](https://firebase.google.com/pricing#cloud-functions).\n\nYou can view your costs associated with Cloud Functions as follows:\n\n1. Go to the [Cloud Billing Reports page](https://console.cloud.google.com/billing/reports) in the Google Cloud console.\n2. If prompted, select the billing account associated with your Google Cloud project.\n3. In the **Filters** panel, under **Labels** , [add a label filter](//cloud.google.com//billing/docs/how-to/reports#filters) with the key `goog-managed-by` and the value `cloudfunctions`.\n\n| **Note:** If you are using Cloud Functions for Firebase (1st gen) and are interested in Cloud Functions, see [Upgrade 1st gen Node.js functions to 2nd gen](/docs/functions/2nd-gen-upgrade).\n\nLimitations\n\nCloud Functions for Firebase (2nd gen) does not provide support for Analytics\nevents.\n\nThough Cloud Functions for Firebase (2nd gen) supports authentication blocking\nevents, it does not support the same set of basic Authentication events as\n1st gen.\n\nHowever, because 1st gen and 2nd gen\nfunctions can coexist side-by-side in the same source file, you can still\ndevelop and deploy Analytics and basic Authentication triggers in 1st gen\ntogether with 2nd gen functions."]]