From 55eaaf96f89b6b49aab1f91b737ec3e9b6cd0072 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 02:15:39 -0500 Subject: [PATCH 01/90] New translations subgraph-studio.mdx (Arabic) --- pages/ar/studio/subgraph-studio.mdx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pages/ar/studio/subgraph-studio.mdx b/pages/ar/studio/subgraph-studio.mdx index 5b4947e89d8c..64c39dfbb174 100644 --- a/pages/ar/studio/subgraph-studio.mdx +++ b/pages/ar/studio/subgraph-studio.mdx @@ -15,9 +15,9 @@ title: كيفية استخدام Subgraph Studio - Integrate it in staging using the query URL - إنشاء وإدارة مفاتيح API الخاصة بك لـ subgraphs محددة -هنا في Subgraph Studio ، لديك سيطرة كاملة على الـ subgraphs الخاصة بك. حيث لا يمكنك فقط اختبار الـ subgraphs الخاصة بك قبل نشرها ، ولكن يمكنك أيضا تقييد مفاتيح API الخاصة بك على نطاقات محددة والسماح فقط لمفهرسين معينين بالاستعلام من مفاتيح API الخاصة بهم. +هنا في Subgraph Studio ، لديك سيطرة كاملة على الـ subgraphs الخاصة بك. حيث لا يمكنك اختبار الـ subgraphs الخاصة بك قبل نشرها فحسب، ولكن يمكنك أيضا تقييد مفاتيح API الخاصة بك على نطاقات محددة والسماح فقط لمفهرسين معينين بالاستعلام من مفاتيح API الخاصة بهم. -يولد الاستعلام عن الـ subgraphs رسوم استعلام ، وتُستخدم لمكافأة [المفهرسين](/indexing) على شبكة Graph. إذا كنت مطورا لـ dapp أو لـ subgraph ، فسيمكنك Studio من بناء subgraphs أفضل لدعم استعلاماتك أو استعلام مجتمعك. يتكون Studio من 5 أجزاء رئيسية: +يولد الاستعلام عن الـ subgraphs رسوم استعلام ، وتُستخدم لمكافأة [المفهرسين](/indexing) على شبكة Graph. إذا كنت مطورا لـ dapp أو لـ subgraph ، فيمكنك من خلال Studio بناء subgraphs أفضل لدعم استعلاماتك أو استعلام مجتمعك. يتكون Studio من 5 أجزاء رئيسية: - التحكم في حساب المستخدم الخاص بك - قائمة من الـ subgraphs التي قمت بإنشائها @@ -58,7 +58,7 @@ title: كيفية استخدام Subgraph Studio بعد إنشاء الـ subgraph الخاص بك، ستتمكن من نشره باستخدام [ CLI ](https://github.com/graphprotocol/graph-cli) أو واجهة سطر الأوامر. سيؤدي نشر subgraph باستخدام CLI إلى دفع الـ subgraph إلى Studio حيث ستتمكن من اختبار الـ subgraphs باستخدام playground. سيسمح لك هذا في النهاية بالنشر على شبكة Graph. لمزيد من المعلومات حول إعداد CLI ، [ راجع هذا](/developer/define-subgraph-hosted#install-the-graph-cli) (pst ، تأكد من توفر مفتاح النشر لديك). تذكر أن النشر(deploying)**يختلف عن** النشر(publishing). عندما تنشر (deploying) الـ subgraph، فأنت تدفعه إلى Studio حيث يمكنك اختباره. وفي المقابل ، عندما تنشر(publishing) الـ subgraph ، فإنك تنشره على السلسلة (on-chain). -## اختبار الـ Subgraph بك في Subgraph Studio +## اختبار الـ Subgraph الخاص بك في Subgraph Studio إذا كنت ترغب في اختبار الـ subgraph قبل نشره على الشبكة ، فيمكنك القيام بذلك في Subgraph **Playground** أو إلقاء نظرة على سجلاتك. ستخبرك سجلات الـ Subgraph ** أين ** يفشل الـ subgraph في حالة حدوث ذلك. @@ -73,14 +73,14 @@ title: كيفية استخدام Subgraph Studio title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen - > +> تذكر ، أثناء تقدمك في تدفق النشر ، ستتمكن من الدفع(push) إما إلى mainnet أو Rinkeby ، وهي testnet التي ندعمها. إذا كنت مطور subgraph لأول مرة ، فنحن نقترح بشدة أن تبدأ بالنشر على Rinkeby ، وهو مجاني. سيسمح لك ذلك بمعرفة كيفية عمل الـ subgraph في The Graph Explorer وسيسمح لك باختبار عناصر التنسيق. ستتمكن فقط من فهرسة البيانات من mainnet (حتى إذا تم نشر الـ subgraph الخاص بك على testnet) لأنه لا يمكن نشر سوى الـ subgraphs التي تقوم بفهرسة بيانات mainnet. وذلك لأن المفهرسين يحتاجون إلى تقديم إثبات إلزامي لسجلات الفهرسة بدءا من block hash معين. نظرًا لأن نشر subgraph هو إجراء على-سلسلة (on-chain) ، فالإجراء يمكن أن يستغرق بضع دقائق. أي عنوان تستخدمه لنشر العقد سيكون هو الوحيد القادر على نشر الإصدارات المستقبلية. لذا اختر بحكمة! -الـ Subgraphs التي لها إشارة تنسيق يتم عرضها للمفهرسين بحيث يمكن فهرستها على الشبكة اللامركزية. يمكنك نشر الـ subgraphs والإشارة إليها في إجراء واحدة ، مما يتيح لك صك أول إشارة تنسيق على الـ subgraph وتوفير تكاليف الغاز. من خلال إضافة إشارتك إلى الإشارة التي قدمها المنسقون لاحقًا ، سيكون للـ subgraph الخاص بك فرصة أكبر لتقديم الاستعلامات في النهاية. +الـ Subgraphs التي لها إشارة تنسيق يتم عرضها للمفهرسين بحيث يمكن فهرستها على الشبكة اللامركزية. يمكنك نشر الـ subgraphs والإشارة إليها في إجراء واحد ، مما يتيح لك صك أول إشارة تنسيق على الـ subgraph وتوفير تكاليف الغاز. ومن خلال إضافة إشارتك إلى الإشارة التي قدمها المنسقون لاحقًا ، سيكون للـ subgraph الخاص بك فرصة أكبر لتقديم الاستعلامات في النهاية. ** الآن بعد أن نشرت الـ subgraph الخاص بك ، دعنا ندخل في كيفية إدارتهم على أساس منتظم. ** لاحظ أنه لا يمكنك نشر الـ subgraph على الشبكة إذا قد فشلت المزامنة. يحدث هذا عادةً بسبب وجود أخطاء في الـ subgraph - ستخبرك السجلات بمكان وجود هذه المشكلات! @@ -100,7 +100,7 @@ title: كيفية استخدام Subgraph Studio ## إدارة مفاتيح API الخاصة بك -بغض النظر عما إذا كنت مطور dapp أو مطور subgraph ، فستحتاج إلى إدارة مفاتيح API الخاصة بك. وهذا مهم بالنسبة لك لتكون قادرا على الاستعلام عن الـ subgraphs لأن مفاتيح API تضمن أن الربط بين خدمات التطبيق صحيحة ومرخصة. يتضمن ذلك مصادقة المستخدم والجهاز باستخدام التطبيق. +بغض النظر عما إذا كنت مطور dapp أو مطور subgraph ، فستحتاج إلى إدارة مفاتيح API الخاصة بك. وهذا مهم بالنسبة لك لتكون قادرا على الاستعلام عن الـ subgraphs لأن مفاتيح API تضمن أن الربط بين خدمات التطبيق صحيحة ومرخصة. يتضمن ذلك مصادقة المستخدم والجهاز المستخدم للتطبيق. سيقوم Studio بسرد مفاتيح API الموجودة ، والتي ستمنحك القدرة على إدارتها أو حذفها. @@ -116,7 +116,7 @@ title: كيفية استخدام Subgraph Studio ## كيفية إدارة الـ Subgraph الخاص بك -سيكون لديك العديد من الأدوات تحت تصرفك لإدارة الـ subgraphs. ويمكنك تنظيم الـ subgraphs الخاصة بك حسب **الحالة(status)** و**الصنف(category)**. +سيكون لديك العديد من الأدوات تحت تصرفك لإدارة الـ subgraphs. ويمكنك تنظيم الـ subgraphs الخاصة بك حسب **الحالة(status)** و**الفئة(category)**. - تتيح لك علامة **Status** الاختيار من بين مجموعة متنوعة من العلامات(tags) بما في ذلك ``, ``, ``, ``, الخ. - وفي الوقت نفسه ، يسمح لك **Category** بتعيين الفئة التي يقع فيها الـ subgraph الخاص بك. وتشمل الخيارات ``, ``, ``, الخ. From 29514a17d449feb97ecf44ee12a6aaa7d91ee29c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:10 -0500 Subject: [PATCH 02/90] New translations assemblyscript-api.mdx (Arabic) --- pages/ar/developer/assemblyscript-api.mdx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pages/ar/developer/assemblyscript-api.mdx b/pages/ar/developer/assemblyscript-api.mdx index 3e5aa0b700ca..c2d82023b87f 100644 --- a/pages/ar/developer/assemblyscript-api.mdx +++ b/pages/ar/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install --save-dev @graphprotocol/graph-ts # NPM الـ `apiVersion` في الـ subgraph manifest تحدد إصدار الـ mapping API الذي يتم تشغيله بواسطة Graph Node للـ subgraph المحدد. الاصدار الحالي لـ mapping API هو 0.0.6. -| الاصدار | ملاحظات الإصدار | -| :-: | --- | -| 0.0.6 | تمت إضافة حقل `nonce` إلى كائن إجراء الـ Ethereum
تمت إضافة `baseFeePerGas` إلى كائن Ethereum Block | -| 0.0.5 | تمت ترقية AssemblyScript إلى الإصدار 0.19.10 (يرجى الاطلاع على [ `دليل الترحيل` ](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` أعيد تسميته إلى `ethereum.transaction.gasLimit` | -| 0.0.4 | تمت إضافة حقل `functionSignature` إلى كائن Ethereum SmartContractCall | -| 0.0.3 | تمت إضافةحقل `from` إلى كائن Ethereum Call
`etherem.call.address` تمت إعادة تسميته إلى `ethereum.call.to` | -| 0.0.2 | تمت إضافة حقل `input` إلى كائن إجراء Ethereum | +| الاصدار | ملاحظات الإصدار | +|:-------:| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| 0.0.6 | تمت إضافة حقل `nonce` إلى كائن إجراء الـ Ethereum
تمت إضافة `baseFeePerGas` إلى كائن Ethereum Block | +| 0.0.5 | تمت ترقية AssemblyScript إلى الإصدار 0.19.10 (يرجى الاطلاع على [ `دليل الترحيل` ](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` أعيد تسميته إلى `ethereum.transaction.gasLimit` | +| 0.0.4 | تمت إضافة حقل `functionSignature` إلى كائن Ethereum SmartContractCall | +| 0.0.3 | تمت إضافةحقل `from` إلى كائن Ethereum Call
`etherem.call.address` تمت إعادة تسميته إلى `ethereum.call.to` | +| 0.0.2 | تمت إضافة حقل `input` إلى كائن إجراء Ethereum | ### الأنواع المضمنة (Built-in) From 6ea83a02f1f9134363e91a7ee1de970de6582f94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:12 -0500 Subject: [PATCH 03/90] New translations assemblyscript-migration-guide.mdx (Arabic) --- pages/ar/developer/assemblyscript-migration-guide.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pages/ar/developer/assemblyscript-migration-guide.mdx b/pages/ar/developer/assemblyscript-migration-guide.mdx index 67578c39a65e..4acb088e8fd0 100644 --- a/pages/ar/developer/assemblyscript-migration-guide.mdx +++ b/pages/ar/developer/assemblyscript-migration-guide.mdx @@ -127,11 +127,8 @@ let a = a + b ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` - ستحتاج إلى إعادة تسمية المتغيرات المكررة إذا كان لديك variable shadowing. - ### مقارانات Null - من خلال إجراء الترقية على ال Subgraph الخاص بك ، قد تحصل أحيانًا على أخطاء مثل هذه: ```typescript @@ -140,7 +137,6 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` - لحل المشكلة يمكنك ببساطة تغيير عبارة `if` إلى شيء مثل هذا: ```typescript @@ -285,7 +281,6 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` - لإصلاح هذه المشكلة ، يمكنك إنشاء متغير للوصول إلى الخاصية حتى يتمكن المترجم من القيام بعملية التحقق من الـ nullability: ```typescript From 0b1266f348a9dba74a344ae5b8c04c71d7696a94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:13 -0500 Subject: [PATCH 04/90] New translations create-subgraph-hosted.mdx (Arabic) --- pages/ar/developer/create-subgraph-hosted.mdx | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/pages/ar/developer/create-subgraph-hosted.mdx b/pages/ar/developer/create-subgraph-hosted.mdx index 2c4c64d46737..85db0e41d388 100644 --- a/pages/ar/developer/create-subgraph-hosted.mdx +++ b/pages/ar/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ type GravatarDeclined @entity { ندعم المقاييس التالية في GraphQL API الخاصة بنا: -| النوع | الوصف | -| --- | --- | -| `Bytes` | مصفوفة Byte ، ممثلة كسلسلة سداسية عشرية. يشيع استخدامها في Ethereum hashes وعناوينه. | -| `ID` | يتم تخزينه كـ `string`. | -| `String` | لقيم `string`. لا يتم دعم اNull ويتم إزالتها تلقائيا. | -| `Boolean` | لقيم `boolean`. | -| `Int` | المواصفات الفنية لـ GraphQL تعرف `Int` بحجم 32 بايت. | -| `BigInt` | أعداد صحيحة كبيرة. يستخدم لأنواع Ethereum `uint32` ، `int64` ، `uint64` ، ... ، `uint256`. ملاحظة: كل شيء تحت `uint32` ، مثل `int32` أو `uint24` أو `int8` يتم تمثيله كـ `i32`. | -| `BigDecimal` | `BigDecimal` يتم تمثيل الكسور العشرية عالية الدقة على أنها signficand وأسس.. يتراوح نطاق الأس من −6143 إلى +6144. مقربة إلى 34 رقما. | +| النوع | الوصف | +| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `Bytes` | مصفوفة Byte ، ممثلة كسلسلة سداسية عشرية. يشيع استخدامها في Ethereum hashes وعناوينه. | +| `ID` | يتم تخزينه كـ `string`. | +| `String` | لقيم `string`. لا يتم دعم اNull ويتم إزالتها تلقائيا. | +| `Boolean` | لقيم `boolean`. | +| `Int` | المواصفات الفنية لـ GraphQL تعرف `Int` بحجم 32 بايت. | +| `BigInt` | أعداد صحيحة كبيرة. يستخدم لأنواع Ethereum `uint32` ، `int64` ، `uint64` ، ... ، `uint256`. ملاحظة: كل شيء تحت `uint32` ، مثل `int32` أو `uint24` أو `int8` يتم تمثيله كـ `i32`. | +| `BigDecimal` | `BigDecimal` يتم تمثيل الكسور العشرية عالية الدقة على أنها signficand وأسس.. يتراوح نطاق الأس من −6143 إلى +6144. مقربة إلى 34 رقما. | #### Enums @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **ملاحظة:** مصدر البيانات الجديد سيعالج فقط الاستدعاءات والأحداث للكتلة التي تم إنشاؤها فيه وجميع الكتل التالية ، ولكنه لن يعالج البيانات التاريخية ، أي البيانات الموجودة في الكتل السابقة. -> +> > إذا كانت الكتل السابقة تحتوي على بيانات ذات صلة بمصدر البيانات الجديد ، فمن الأفضل فهرسة تلك البيانات من خلال قراءة الحالة الحالية للعقد وإنشاء كيانات تمثل تلك الحالة في وقت إنشاء مصدر البيانات الجديد. ### سياق (Context) مصدر البيانات @@ -684,7 +684,7 @@ dataSources: ``` > **ملاحظة:** يمكن البحث عن كتلة إنشاء العقد بسرعة على Etherscan: -> +> > 1. ابحث عن العقد بإدخال عنوانه في شريط البحث. > 2. انقر فوق hash إجراء الإنشاء في قسم `Contract Creator`. > 3. قم بتحميل صفحة تفاصيل الإجراء(transaction) حيث ستجد كتلة البدء لذلك العقد. From 94cc924178a10045d01df833ee16d3233016901d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:15 -0500 Subject: [PATCH 05/90] New translations graphql-api.mdx (Arabic) --- pages/ar/developer/graphql-api.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/ar/developer/graphql-api.mdx b/pages/ar/developer/graphql-api.mdx index bf6cfc5221cc..d495f3edad4f 100644 --- a/pages/ar/developer/graphql-api.mdx +++ b/pages/ar/developer/graphql-api.mdx @@ -204,12 +204,12 @@ not_ends_with_ عوامل تشغيل البحث عن النص الكامل: -| رمز | عامل التشغيل | الوصف | -| --- | --- | --- | -| `&` | `And` | لدمج عبارات بحث متعددة في فلتر للكيانات التي تتضمن جميع العبارات المتوفرة | -| | | `Or` | الاستعلامات التي تحتوي على عبارات بحث متعددة مفصولة بواسطة عامل التشغيل or ستعيد جميع الكيانات المتطابقة من أي عبارة متوفرة | -| `<->` | `Follow by` | يحدد المسافة بين كلمتين. | -| `*:` | `Prefix` | يستخدم عبارة البحث prefix للعثور على الكلمات التي تتطابق بادئتها (مطلوب حرفان.) | +| رمز | عامل التشغيل | الوصف | +| ----------- | ------------ | --------------------------------------------------------------------------------------------------------------------------- | +| `&` | `And` | لدمج عبارات بحث متعددة في فلتر للكيانات التي تتضمن جميع العبارات المتوفرة | +| | | `Or` | الاستعلامات التي تحتوي على عبارات بحث متعددة مفصولة بواسطة عامل التشغيل or ستعيد جميع الكيانات المتطابقة من أي عبارة متوفرة | +| `<->` | `Follow by` | يحدد المسافة بين كلمتين. | +| `*:` | `Prefix` | يستخدم عبارة البحث prefix للعثور على الكلمات التي تتطابق بادئتها (مطلوب حرفان.) | #### أمثلة From 35cc9c78b0f82a82831f1985b7cd061b94ec6a75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:18 -0500 Subject: [PATCH 06/90] New translations subgraph-debug-forking.mdx (Arabic) --- pages/ar/developer/subgraph-debug-forking.mdx | 52 +++++++++---------- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/pages/ar/developer/subgraph-debug-forking.mdx b/pages/ar/developer/subgraph-debug-forking.mdx index 0b97a4c37735..64c970d2c421 100644 --- a/pages/ar/developer/subgraph-debug-forking.mdx +++ b/pages/ar/developer/subgraph-debug-forking.mdx @@ -1,28 +1,28 @@ --- -title: Quick and easy subgraph debugging using forks +title: تصحيح أخطاء الـ subgraph بسرعة وسهولة باستخدام forks --- > Note: this is only available from this `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) or this [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) onwards, it hasn't been yet released in a minor release (eg: 0.26.0) -As with many systems processing large amounts of data, The Graph's Indexers (Graph nodes) may take quite some time to sync-up your subgraph with the target blockchain. The discrepancy between quick changes with the purpose of debugging and long wait times needed for indexing is extremely counterproductive and we are well aware of that. This is why we are introducing **subgraph forking**, developed by [LimeChain](https://limechain.tech/), and in this article I will show you how this feature can be used to substantially speed-up subgraph debugging! +كما هو الحال مع العديد من الأنظمة التي تعالج كميات كبيرة من البيانات ، قد يستغرق مفهرسو The Graph أو (Graph nodes) بعض الوقت لمزامنة الـ subgraph الخاص بك مع blockchain الهدف. التناقض بين التغييرات السريعة بغرض تصحيح الأخطاء وأوقات الانتظار الطويلة اللازمة للفهرسة يؤدي إلى نتائج عكسية للغاية ونحن ندرك ذلك جيدًا. ولهذا السبب نقدم **subgraph forking ** ، الذي تم تطويره بواسطة [ LimeChain ](https://limechain.tech/) ، وفي هذه المقالة سنوضح لكم كيف يمكن استخدام هذه الميزة لتسريع تصحيح أخطاء الـ subgraph بشكل كبير! -## Ok, what is it? +## حسنا، ما هو؟ -**Subgraph forking** is the process of lazily fetching entities from _another_ subgraph's store (usually a remote one). +**Subgraph forking** هي عملية جلب الكيانات بشكل lazily من مخزن subgraph _آخر_ (عادةً ما يكون بعيدًا). -In the context of debugging, **subgraph forking** allows you to debug your failed subgraph at block _X_ without needing to wait to sync-up to block _X_. +يسمح لك **subgraph forking** بتصحيح أخطاء الـ subgraph الفاشل في الكتلة(block) _ X _ دون الحاجة للانتظار للمزامنة للكتلة _ X _. -## What?! How? +## ماذا؟! كيف؟ -When you deploy a subgraph to a remote Graph node for indexing and it fails at block _X_, the good news is that the Graph node will still serve GraphQL queries using its store, which is synced-up to block _X_. That's great! This means we can take advantage of this "up-to-date" store to fix the bugs arising when indexing block _X_. +عندما تنشر subgraph إلى Graph node بعيدة للفهرسة ويفشل عند الكتلة _ X _ ، فإن الخبر الجيد هو أن Graph node ستظل تقدم استعلامات GraphQL باستخدام مخزنها(store)، والذي تمت مزامنته للكتلة(block) _ X _. هذا عظيم! هذا يعني أنه يمكننا الاستفادة من هذا المخزن "المحدث" لإصلاح الأخطاء التي تظهر عند فهرسة الكتلة _ X _. In a nutshell, we are going to _fork the failing subgraph_ from a remote Graph node that is guaranteed to have the subgraph indexed up to block _X_ in order to provide the locally deployed subgraph being debugged at block _X_ an up-to-date view of the indexing state. -## Please, show me some code! +## من فضلك ، أرني بعض الأكواد! -To stay focused on subgraph debugging, let's keep things simple and run along with the [example-subgraph](https://github.com/graphprotocol/example-subgraph) indexing the Ethereum Gravity smart contract. +للاستمرار في التركيز على تصحيح أخطاء الـ subgraph ، دعنا نجعل الأمور بسيطة ونعمل مع [example-subgraph](https://github.com/graphprotocol/example-subgraph) الذي يفهرس عقد Ethereum Gravity الذكي. -Here are the handlers defined for indexing `Gravatar`s, with no bugs whatsoever: +فيما يلي المعالجات (handlers) المعرفة لفهرسة `Gravatar` ، مع عدم وجود أخطاء على الإطلاق: ```tsx export function handleNewGravatar(event: NewGravatar): void { @@ -46,41 +46,41 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -Oops, how unfortunate, when I deploy my perfect looking subgraph to the [HostedService](https://thegraph.com/hosted-service/) it fails with the _"Gravatar not found!"_ error. +عفوًا ، يا للأسف ، عندما أنشر الـ subgraph الخاص بي ذو المظهر المثالي على [ HostedService ](https://thegraph.com/hosted-service/) ، فإنه يفشل مع ظهور الخطأ _ "Gravatar not found!" _. -The usual way to attempt a fix is: +الطريقة المعتادة لمحاولة الإصلاح هي: -1. Make a change in the mappings source, which you believe will solve the issue (while I know it won't). -2. Re-deploy the subgraph to the [HostedService](https://thegraph.com/hosted-service/) (or another remote Graph node). -3. Wait for it to sync-up. -4. If it breaks again go back to 1, otherwise: Hooray! +1. إجراء تغيير في مصدر الـ mappings ، والذي تعتقد أنه سيحل المشكلة (وأنا أعلم أنه لن يحلها). +2. إعادة نشر الـ subgraph على [ HostedService ](https://thegraph.com/hosted-service/) (أو Graph node أخرى بعيدة). +3. الانتظار حتى تتم المزامنة. +4. إذا تعطل مرة أخرى ارجع إلى 1! -It is indeed pretty familiar to an ordinary debug process, but there is one step that horribly slows down the process: _3. Wait for it to sync-up._ +هذا مألوف لعملية تصحيح الأخطاء العادية ، ولكن هناك خطوة واحدة تؤدي إلى إبطاء العملية بشكل رهيب: _ 3. الانتظار حتى تتم المزامنة. _ -Using **subgraph forking** we can essentially eliminate this step. Here is how it looks: +باستخدام **subgraph forking** يمكننا التخلص من تلك الخطوة. إليك كيف يبدو: -0. Spin-up a local Graph node with the **_appropriate fork-base_** set. -1. Make a change in the mappings source, which you believe will solve the issue. +0. قم بتنشيط Graph node محلية بمجموعة **_fork-base_** مناسبة. +1. قم بإجراء تغيير في مصدر الـ mappings ، والذي تعتقد أنه سيحل المشكلة. 2. Deploy to the local Graph node, **_forking the failing subgraph_** and **_starting from the problematic block_**. -3. If it breaks again, go back to 1, otherwise: Hooray! +3. إذا تعطل مرة أخرى ارجع إلى 1! -Now, you may have 2 questions: +الآن ، قد يكون لديك سؤالان: 1. fork-base what??? 2) Forking who?! 2. Forking who?! -And I answer: +وأنا أجيب: 1. `fork-base` is the "base" URL, such that when the _subgraph id_ is appended the resulting URL (`/`) is a valid GraphQL endpoint for the subgraph's store. 2) Forking is easy, no need to sweat: -2. Forking is easy, no need to sweat: +2. الـ Forking سهل ، لا داعي للقلق: ```bash $ graph deploy --debug-fork --ipfs http://localhost:5001 --node http://localhost:8020 ``` -Also, don't forget to set the `dataSources.source.startBlock` field in the subgraph manifest to the number of the problematic block, so you can skip indexing unnecessary blocks and take advantage of the fork! +أيضًا ، لا تنس تعيين الحقل ` dataSources.source.startBlock ` في subgraph manifest لرقم الكتلة التي بها المشكلة، حتى تتمكن من تخطي فهرسة الكتل غير الضرورية والاستفادة من الـ fork! -So, here is what I do: +لذلك ، هذا ما أفعله: 0. I spin-up a local graph node ([here is how to do it](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) with the `fork-base` option set to: `https://api.thegraph.com/subgraphs/id/`, since I will fork a subgraph, the buggy one I deployed earlier, from the [HostedService](https://thegraph.com/hosted-service/). From fabd91895a808983fa8b2f1c0cd7a70cf8ddb79f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:19 -0500 Subject: [PATCH 07/90] New translations near.mdx (Arabic) --- pages/ar/supported-networks/near.mdx | 46 ++++++++++++++-------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/pages/ar/supported-networks/near.mdx b/pages/ar/supported-networks/near.mdx index d2b4820a84ec..17f14a271fc3 100644 --- a/pages/ar/supported-networks/near.mdx +++ b/pages/ar/supported-networks/near.mdx @@ -29,15 +29,15 @@ title: بناء Subgraphs على NEAR `graphprotocol/graph-ts@` هي مكتبة لأنواع خاصة بـ subgraph. -تطوير NEAR subgraph يتطلب `graph-cli` إصدارا أعلى من `0.23.0` و `graph-ts` إصدارا أعلى من `0.23.0`. +تطوير NEAR subgraph يتطلب `graph-cli` بإصدار أعلى من ` 0.23.0 ` و `graph-ts` بإصدار أعلى من ` 0.23.0 `. > بناء NEAR subgraph يشبه إلى حد كبير بناء subgraph يقوم بفهرسة الـ Ethereum. هناك ثلاثة جوانب لتعريف الـ subgraph: -**subgraph.yaml:** الـ subgraph manifest ، وتحديد مصادر البيانات ذات الأهمية ، وكيف يجب أن تتم معالجتها. NEAR هو `نوع` جديد لمصدر البيانات. +**subgraph.yaml:** الـ subgraph manifest ، وتحديد مصادر البيانات ذات الأهمية ، وكيف يجب أن تتم معالجتها.علما أن NEAR هو ` نوع ` جديد لمصدر البيانات. -**schema.graphql:** ملف مخطط يقوم بتعريف البيانات المخزنة لـ subgraph الخاص بك ، وكيفية الاستعلام عنها عبر GraphQL. تتم تغطية متطلبات NEAR subgraphs بواسطة [ الوثائق الحالية ](/developer/create-subgraph-hosted#the-graphql-schema). +**schema.graphql:** مخطط يقوم بتعريف البيانات المخزنة لـ subgraph الخاص بك ، وكيفية الاستعلام عنها عبر GraphQL. وتتم تغطية متطلبات NEAR subgraphs بواسطة [ الوثائق الحالية ](/developer/create-subgraph-hosted#the-graphql-schema). **AssemblyScript Mappings:** هو [AssemblyScript كود ](/developer/assemblyscript-api) والذي يترجم من بيانات الحدث إلى الكيانات المعرفة في مخططك. دعم NEAR يقدم أنواع بيانات خاصة بـ NEAR ووظيفة تحليل JSON جديدة. @@ -73,21 +73,21 @@ dataSources: ``` - NEAR subgraphs يقدم `نوعا ` جديدا من مصدر بيانات (`near`) -- The `network` should correspond to a network on the hosting Graph Node. On the Hosted Service, NEAR's mainnet is `near-mainnet`, and NEAR's testnet is `near-testnet` -- مصادر بيانات NEAR تقدم حقلًا اختياريًا `source.account` ، وهو ID يمكن قراءته و منسجما مع [ حساب NEAR ](https://docs.near.org/docs/concepts/account). يمكن أن يكون هذا حسابًا أو حسابًا فرعيًا. +- يجب أن يتوافق الـ `network` مع شبكة على Graph Node المضيفة. في الخدمة المستضافة ، الشبكة الرئيسية لـ NEAR هي ` near-mainnet ` ، وشبكة NEAR's testnet هي ` near-testnet ` +- مصادر بيانات NEAR تقدم حقلًا اختياريًا ` source.account ` ، وهو ID يمكن قراءته و يتوافق مع [ حساب NEAR ](https://docs.near.org/docs/concepts/account). ويمكن أن يكون ذلك حسابًا أو حسابًا فرعيًا. مصادر بيانات NEAR تدعم نوعين من المعالجات: - `blockHandlers`: يتم تشغيلها على كل كتلة NEAR جديدة. لا يتطلب `source.account`. - `receiptHandlers`: يتم تشغيلها في كل استلام حيث يكون مصدر البيانات`source.account` هو المستلم. لاحظ أنه تتم معالجة المطابقات التامة فقط (يجب إضافة حسابات فرعية [subaccounts](https://docs.near.org/docs/concepts/account#subaccounts) كمصادر بيانات مستقلة). -### تعريف المخطط +### تعريف المخطط(Schema Definition) -Schema definition describes the structure of the resulting subgraph database, and the relationships between entities. This is agnostic of the original data source. There are more details on subgraph schema definition [here](/developer/create-subgraph-hosted#the-graphql-schema). +تعريف المخطط يقوم بوصف هيكل قاعدة بيانات الـ subgraph الناتجة والعلاقات بين الكيانات. وهذا مستقل عن مصدر البيانات الأصلية. لمزيد من التفاصيل حول تعريف مخطط الـ subgraph [ هنا ](/developer/create-subgraph-hosted#the-graphql-schema). ### AssemblyScript Mappings -تمت كتابة المعالجات الخاصة بمعالجة الأحداث بـ[ AssemblyScript ](https://www.assemblyscript.org/). +تمت كتابة المعالجات(handlers) الخاصة بمعالجة الأحداث بـ[ AssemblyScript ](https://www.assemblyscript.org/). فهرسة NEAR تقدم أنواع بيانات خاصة بـ NEAR إلى [AssemblyScript API](/developer/assemblyscript-api). @@ -153,18 +153,18 @@ class ReceiptWithOutcome { يتم تمرير هذه الأنواع لمعالجات الكتلة(block) & الاستلام(receipt): -- معالجات الكتلة ستستلم `Block` -- ستستلم معالجات الاستلام `ReceiptWithOutcome` +- معالجات الكتلة ستتلقى`Block` +- معالجات الاستلام ستتلقى` ReceiptWithOutcome ` -وبخلاف ذلك ، بقية [ AssemblyScript API ](/developer/assemblyscript-api) تكون متاحة لمطوري NEAR subgraph أثناء تنفيذ الـ mapping. +وبخلاف ذلك ، فإن بقية [ AssemblyScript API ](/developer/assemblyscript-api) تكون متاحة لمطوري NEAR subgraph أثناء تنفيذ الـ mapping. -هذا يتضمن دالة تحليل JSON جديدة - يتم إرسال السجلات الموجودة على NEAR بشكل متكرر على هيئة JSONs. تتوفر دالة `(...)json.fromString` جديدة كجزء من [JSON API](/developer/assemblyscript-api#json-api) للسماح للمطورين لمعالجة هذه السجلات بسهولة. +هذا يتضمن دالة تحليل JSON جديدة - يتم إرسال السجلات الموجودة على NEAR بشكل متكرر على هيئة JSONs. تتوفر دالة ` (...)json.fromString ` جديدة كجزء من [JSON API](/developer/assemblyscript-api#json-api) للسماح للمطورين لمعالجة هذه السجلات بسهولة. ## نشر NEAR Subgraph -بمجرد امتلاكك لـ subgraph، فقد حان الوقت لنشره في Graph Node للفهرسة. يمكن نشر NEAR subgraphs في أي Graph Node `>=v0.26.x` (لم يتم وضع علامة(tag) على هذا الإصدار ولم يتم إصداره بعد). +بمجرد امتلاكك لـ subgraph، فقد حان الوقت لنشره في Graph Node للفهرسة. يمكن نشر NEAR subgraphs في اصدارات Graph Node `>=v0.26.x` (لم يتم وضع علامة(tag) على هذا الإصدار ولم يتم إصداره بعد). -تدعم Graph's Hosted Service حاليًا فهرسة NEAR mainnet و testnet في مرحلة beta، باستخدام أسماء الشبكات التالية: +تدعم Graph's Hosted Service حاليًا فهرسة NEAR mainnet و testnet في مرحلة beta، وذلك باستخدام أسماء الشبكات التالية: - `near-mainnet` - `near-testnet` @@ -208,7 +208,7 @@ graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 تشغيل Graph Node التي تقوم بفهرسة NEAR لها المتطلبات التشغيلية التالية: -- NEAR Indexer Framework with Firehose instrumentation +- NEAR Indexer Framework مع أجهزة Firehose - مكونات NEAR Firehose - تكوين Graph Node مع Firehose endpoint @@ -216,7 +216,7 @@ graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 ## الاستعلام عن NEAR Subgraph -يتم تحديد GraphQL endpoint لـ NEAR subgraphs من خلال تعريف المخطط ، بواجهة API الحالية. يرجى زيارة [ وثائق GraphQL API ](/developer/graphql-api) لمزيد من المعلومات. +يتم تحديد GraphQL endpoint لـ NEAR subgraphs من خلال تعريف المخطط ، باستخدام واجهة API الحالية. يرجى زيارة [ وثائق GraphQL API ](/developer/graphql-api) لمزيد من المعلومات. ## أمثلة على الـ Subgraphs @@ -230,7 +230,7 @@ graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 ### كيف يعمل beta ؟ -دعم NEAR في beta ، مما يعني أنه قد تكون هناك تغييرات في الـ API بينما نواصل العمل على تحسين التكامل. يرجى إرسال بريد إلكتروني إلى near@thegraph.com حتى نتمكن من دعمك في بناء NEAR subgraphs ، وإطلاعك على آخر التطورات! +يتوفر دعم NEAR في beta ، مما يعني أنه قد تكون هناك تغييرات في الـ API بينما نواصل العمل على تحسين التكامل. يرجى إرسال بريد إلكتروني إلى near@thegraph.com حتى نتمكن من دعمك في بناء NEAR subgraphs ، وإطلاعك على آخر التطورات! ### هل يمكن لـ subgraph فهرسة كلاً من سلاسل NEAR و EVM؟ @@ -240,19 +240,19 @@ graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 حاليًا ، يتم دعم مشغلات الكتلة(Block) والاستلام(Receipt). نحن نبحث في مشغلات استدعاءات الدوال لحساب محدد. نحن مهتمون أيضًا بدعم مشغلات الأحداث ، بمجرد حصول NEAR على دعم محلي للأحداث. -### هل سيتم تشغيل معالجات الاستلام للحسابات وحساباتها الفرعية؟ +### هل سيتم تشغيل(trigger) معالجات الاستلام للحسابات وحساباتها الفرعية؟ سيتم تشغيل معالجات الاستلام فقط للتطابق التام للحساب المحدد. يمكن إضافة المزيد من المرونة في المستقبل. -### Can NEAR subgraphs make view calls to NEAR accounts during mappings? +### هل يستطيع NEAR subgraphs أن يقوم بعرض استدعاءات لحسابات NEAR أثناء الـ mappings؟ -هذا غير مدعوم. نقوم بتقييم ما إذا كانت هذه الوظيفة مطلوبة للفهرسة. +هذا غير مدعوم. نحن بصدد تقييم ما إذا كانت هذه الميزة مطلوبة للفهرسة. -### هل يمكنني استخدام قوالب مصدر البيانات في NEAR subgraph الخاص بي؟ +### هل يمكنني استخدام قوالب لمصدر البيانات في NEAR subgraph الخاص بي؟ -هذا غير مدعوم حاليا. نقوم بتقييم ما إذا كانت هذه الوظيفة مطلوبة للفهرسة. +هذا غير مدعوم حاليا. نحن بصدد تقييم ما إذا كانت هذه الميزة مطلوبة للفهرسة. -### يدعم Ethereum subgraphs الإصدارات "المعلقة" و "الحالية" ، كيف يمكنني نشر إصدار "معلق" من NEAR subgraph؟ +### يدعم Ethereum subgraphs الإصدارات المعلقة "pending" و "الحالية" ، كيف يمكنني نشر إصدار "معلق" من NEAR subgraph؟ الوظيفة المعلقة ليست مدعومة لـ NEAR subgraphs. وفي غضون ذلك ، يمكنك نشر إصدار جديد على subgraph مختلف "مسمى" ، وبعد ذلك عندما تتم مزامنته مع رأس السلسلة ، يمكنك إعادة النشر إلى الـ subgraph الأساسي "المسمى" ، والذي سيستخدم نفس ID النشر الأساسي ، لذلك ستتم مزامنة الـ subgraph الرئيسي على الفور. From 0766011e70abfe16d6621460da5742bafdc20d57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Sun, 27 Feb 2022 14:19:21 -0500 Subject: [PATCH 08/90] New translations indexing.mdx (Arabic) --- pages/ar/indexing.mdx | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/pages/ar/indexing.mdx b/pages/ar/indexing.mdx index 044a6c5b00c9..7800bc514766 100644 --- a/pages/ar/indexing.mdx +++ b/pages/ar/indexing.mdx @@ -115,7 +115,7 @@ import { Difficulty } from '@/components' - **كبيرة** - مُعدة لفهرسة جميع ال subgraphs المستخدمة حاليا وأيضا لخدمة طلبات حركة مرور البيانات ذات الصلة. | Setup | (CPUs) | (memory in GB) | (disk in TBs) | (CPUs) | (memory in GB) | -| ----- | :----: | :------------: | :-----------: | :----: | :------------: | +| ----- |:------:|:--------------:|:-------------:|:------:|:--------------:| | صغير | 4 | 8 | 1 | 4 | 16 | | قياسي | 8 | 30 | 1 | 12 | 48 | | متوسط | 16 | 64 | 2 | 32 | 64 | @@ -151,20 +151,20 @@ import { Difficulty } from '@/components' #### Graph Node -| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | -| --- | --- | --- | --- | --- | -| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | http-port-- | - | -| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | ws-port-- | - | -| 8020 | JSON-RPC
(for managing deployments) | / | admin-port-- | - | -| 8030 | Subgraph indexing status API | /graphql | index-node-port-- | - | -| 8040 | Prometheus metrics | /metrics | metrics-port-- | - | +| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | +| ------ | ------------------------------------------------------- | ------------------------------------------------------------------- | ----------------- | -------------- | +| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | http-port-- | - | +| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | ws-port-- | - | +| 8020 | JSON-RPC
(for managing deployments) | / | admin-port-- | - | +| 8030 | Subgraph indexing status API | /graphql | index-node-port-- | - | +| 8040 | Prometheus metrics | /metrics | metrics-port-- | - | #### خدمة المفهرس -| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | -| --- | --- | --- | --- | --- | -| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | port-- | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus metrics | /metrics | metrics-port-- | - | +| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | +| ------ | ------------------------------------------------------------ | --------------------------------------------------------------------------- | -------------- | ---------------------- | +| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | port-- | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus metrics | /metrics | metrics-port-- | - | #### وكيل المفهرس(Indexer Agent) From 0fbc854cdba184216cc35840097367227fc71bbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 04:08:31 -0500 Subject: [PATCH 09/90] New translations graphql-api.mdx (Japanese) --- pages/ja/developer/graphql-api.mdx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/pages/ja/developer/graphql-api.mdx b/pages/ja/developer/graphql-api.mdx index 0488f36fad76..57fa7d736641 100644 --- a/pages/ja/developer/graphql-api.mdx +++ b/pages/ja/developer/graphql-api.mdx @@ -204,12 +204,12 @@ _not_ends_with フルテキスト検索オペレーター: -| シンボル | オペレーター | 説明 | -| --- | --- | --- | -| `&` | `And` | 複数の検索語を組み合わせて、指定したすべての検索語を含むエンティティをフィルタリングします。 | -| | | `Or` | 複数の検索語をオペレーターで区切って検索すると、指定した語のいずれかにマッチするすべてのエンティティが返されます。 | -| `<->` | `Follow by` | 2 つの単語の間の距離を指定します。 | -| `:*` | `Prefix` | プレフィックス検索語を使って、プレフィックスが一致する単語を検索します(2 文字必要) | +| シンボル | オペレーター | 説明 | +| ----------- | ----------- | --------------------------------------------------------- | +| `&` | `And` | 複数の検索語を組み合わせて、指定したすべての検索語を含むエンティティをフィルタリングします。 | +| | | `Or` | 複数の検索語をオペレーターで区切って検索すると、指定した語のいずれかにマッチするすべてのエンティティが返されます。 | +| `<->` | `Follow by` | 2 つの単語の間の距離を指定します。 | +| `:*` | `Prefix` | プレフィックス検索語を使って、プレフィックスが一致する単語を検索します(2 文字必要) | #### 例 @@ -264,8 +264,8 @@ GraphQL スキーマは一般に、`クエリ`、`サブスクリプション` > **注:**開発者は自分のアプリケーションから基礎となるブロックチェーンに対して直接トランザクションを発行することが期待されているため、私たちの API はミューテーションを公開していません。 -### Entities +### エンティティ -All GraphQL types with `@entity` directives in your schema will be treated as entities and must have an `ID` field. +スキーマに`@entity`ディレクティブが含まれるすべてのGraphQLタイプはエンティティとして扱われ、`ID`フィールドが必要です。 > **注:**現在、スキーマ内のすべてのタイプに`@entity` ディレクティブが必要です。将来的には、`@entity` ディレクティブを持たないタイプをバリューオブジェクトとして扱う予定ですが、これはまだサポートされていません。 From 2096b499b7a1c281cd214afa7ea53298e2622de3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 04:08:32 -0500 Subject: [PATCH 10/90] New translations subgraph-debug-forking.mdx (Arabic) --- pages/ar/developer/subgraph-debug-forking.mdx | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/pages/ar/developer/subgraph-debug-forking.mdx b/pages/ar/developer/subgraph-debug-forking.mdx index 64c970d2c421..fb86701ef8da 100644 --- a/pages/ar/developer/subgraph-debug-forking.mdx +++ b/pages/ar/developer/subgraph-debug-forking.mdx @@ -1,10 +1,10 @@ --- -title: تصحيح أخطاء الـ subgraph بسرعة وسهولة باستخدام forks +title: تصحيح أخطاء الـ subgraph بسرعة وسهولة باستخدام التفرعات (forks) --- -> Note: this is only available from this `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) or this [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) onwards, it hasn't been yet released in a minor release (eg: 0.26.0) +> ملاحظة: هذا متاح فقط من هذا `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) أو هذا [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) وصاعدا ولم يتم إصدارها بعد في إصدار ثانوي (على سبيل المثال: 0.26.0) -كما هو الحال مع العديد من الأنظمة التي تعالج كميات كبيرة من البيانات ، قد يستغرق مفهرسو The Graph أو (Graph nodes) بعض الوقت لمزامنة الـ subgraph الخاص بك مع blockchain الهدف. التناقض بين التغييرات السريعة بغرض تصحيح الأخطاء وأوقات الانتظار الطويلة اللازمة للفهرسة يؤدي إلى نتائج عكسية للغاية ونحن ندرك ذلك جيدًا. ولهذا السبب نقدم **subgraph forking ** ، الذي تم تطويره بواسطة [ LimeChain ](https://limechain.tech/) ، وفي هذه المقالة سنوضح لكم كيف يمكن استخدام هذه الميزة لتسريع تصحيح أخطاء الـ subgraph بشكل كبير! +كما هو الحال مع العديد من الأنظمة التي تعالج كميات كبيرة من البيانات ، قد يستغرق مفهرسو The Graph أو (Graph nodes) بعض الوقت لمزامنة الـ subgraph الخاص بك مع blockchain المستهدف. التناقض بين التغييرات السريعة بغرض تصحيح الأخطاء وأوقات الانتظار الطويلة اللازمة للفهرسة يؤدي إلى نتائج عكسية للغاية ونحن ندرك ذلك جيدًا. ولهذا السبب نقدم **subgraph forking ** ، الذي تم تطويره بواسطة [ LimeChain ](https://limechain.tech/) ، وفي هذه المقالة سنوضح لكم كيف يمكن استخدام هذه الميزة لتسريع تصحيح أخطاء الـ subgraph بشكل كبير! ## حسنا، ما هو؟ @@ -14,15 +14,15 @@ title: تصحيح أخطاء الـ subgraph بسرعة وسهولة باستخ ## ماذا؟! كيف؟ -عندما تنشر subgraph إلى Graph node بعيدة للفهرسة ويفشل عند الكتلة _ X _ ، فإن الخبر الجيد هو أن Graph node ستظل تقدم استعلامات GraphQL باستخدام مخزنها(store)، والذي تمت مزامنته للكتلة(block) _ X _. هذا عظيم! هذا يعني أنه يمكننا الاستفادة من هذا المخزن "المحدث" لإصلاح الأخطاء التي تظهر عند فهرسة الكتلة _ X _. +عندما تنشر subgraph إلى Graph node بعيدة للقيام بالفهرسة ويفشل عند الكتلة _ X _ ، فإن الخبر الجيد هو أن Graph node ستظل تقدم استعلامات GraphQL باستخدام مخزنها(store)، والذي تمت مزامنته للكتلة(block) _ X _. هذا عظيم! هذا يعني أنه يمكننا الاستفادة من هذا المخزن "المحدث" لإصلاح الأخطاء التي تظهر عند فهرسة الكتلة _ X _. -In a nutshell, we are going to _fork the failing subgraph_ from a remote Graph node that is guaranteed to have the subgraph indexed up to block _X_ in order to provide the locally deployed subgraph being debugged at block _X_ an up-to-date view of the indexing state. +باختصار ، سنقوم _ بتفريع (fork) الـ subgraph الفاشل _ من Graph node بعيدة والتي تضمن فهرسة الـ subgraph للكتلة * X * وذلك من أجل توفير الـ subgraph المنشور محليًا والذي يتم تصحيحه عندالكتلة_X_ مع عرض محدث لحالة الفهرسة. ## من فضلك ، أرني بعض الأكواد! للاستمرار في التركيز على تصحيح أخطاء الـ subgraph ، دعنا نجعل الأمور بسيطة ونعمل مع [example-subgraph](https://github.com/graphprotocol/example-subgraph) الذي يفهرس عقد Ethereum Gravity الذكي. -فيما يلي المعالجات (handlers) المعرفة لفهرسة `Gravatar` ، مع عدم وجود أخطاء على الإطلاق: +فيما يلي المعالجات (handlers) المعرفة لفهرسة `Gravatar` ، بدون أخطاء على الإطلاق: ```tsx export function handleNewGravatar(event: NewGravatar): void { @@ -46,23 +46,23 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -عفوًا ، يا للأسف ، عندما أنشر الـ subgraph الخاص بي ذو المظهر المثالي على [ HostedService ](https://thegraph.com/hosted-service/) ، فإنه يفشل مع ظهور الخطأ _ "Gravatar not found!" _. +للأسف ، يفشل نشر هذا الـ subgraph ذو المظهر المثالي على [ HostedService ](https://thegraph.com/hosted-service/)مع ظهور الخطأ _"Gravatar not found!"_. الطريقة المعتادة لمحاولة الإصلاح هي: 1. إجراء تغيير في مصدر الـ mappings ، والذي تعتقد أنه سيحل المشكلة (وأنا أعلم أنه لن يحلها). 2. إعادة نشر الـ subgraph على [ HostedService ](https://thegraph.com/hosted-service/) (أو Graph node أخرى بعيدة). 3. الانتظار حتى تتم المزامنة. -4. إذا تعطل مرة أخرى ارجع إلى 1! +4. إذا حدثت المشكلة مرة أخرى ، فارجع إلى 1! -هذا مألوف لعملية تصحيح الأخطاء العادية ، ولكن هناك خطوة واحدة تؤدي إلى إبطاء العملية بشكل رهيب: _ 3. الانتظار حتى تتم المزامنة. _ +كما ترى ، فهده الطريقة تشبه عملية تصحيح الأخطاء العادية ، ولكن هناك خطوة واحدة تؤدي إلى إبطاء العملية بشكل رهيب: _ 3. الانتظار حتى تتم المزامنة. _ باستخدام **subgraph forking** يمكننا التخلص من تلك الخطوة. إليك كيف يبدو: -0. قم بتنشيط Graph node محلية بمجموعة **_fork-base_** مناسبة. +0. قم بتجهيز Graph node محلية بمجموعة **_fork-base_** مناسبة. 1. قم بإجراء تغيير في مصدر الـ mappings ، والذي تعتقد أنه سيحل المشكلة. 2. Deploy to the local Graph node, **_forking the failing subgraph_** and **_starting from the problematic block_**. -3. إذا تعطل مرة أخرى ارجع إلى 1! +3. إذا حدثت المشكلة مرة أخرى ، فارجع إلى 1! الآن ، قد يكون لديك سؤالان: @@ -92,13 +92,13 @@ $ cargo run -p graph-node --release -- \ --fork-base https://api.thegraph.com/subgraphs/id/ ``` -1. After careful inspection I notice that there is a mismatch in the `id` representations used when indexing `Gravatar`s in my two handlers. While `handleNewGravatar` converts it to a hex (`event.params.id.toHex()`), `handleUpdatedGravatar` uses an int32 (`event.params.id.toI32()`) which causes the `handleUpdatedGravatar` to panic with "Gravatar not found!". I make them both convert the `id` to a hex. -2. After I made the changes I deploy my subgraph to the local Graph node, **_forking the failing subgraph_** and setting `dataSources.source.startBlock` to `6190343` in `subgraph.yaml`: +1. بعد فحص دقيق ، لاحظت أن هناك عدم تطابق في تمثيلات ` id ` المستخدمة عند فهرسة ` Gravatar ` في المعالجين الخاصين بي. بينما ` handleNewGravatar ` يحول (`event.params.id.toHex()`) إلى سداسي ، `handleUpdatedGravatar` يستخدم int32 (`event.params.id.toI32()`) مما يجعل ` handleUpdatedGravatar ` قلقا من "Gravatar غير موجود!". أنا أجعلهم كلاهما يحولان ` id ` إلى سداسي. +2. بعد إجراء التغييرات ، قمت بنشر الـ subgraph الخاص بي على Graph node المحلية **_وعمل fork لـsubgraph الفاشل_** وضبط `dataSources.source.startBlock` إلى `6190343` في `subgraph.yaml`: ```bash $ graph deploy gravity --debug-fork QmNp169tKvomnH3cPXTfGg4ZEhAHA6kEq5oy1XDqAxqHmW --ipfs http://localhost:5001 --node http://localhost:8020 ``` -3. I inspect the logs produced by the local Graph node and, Hooray!, everything seems to be working. -4. I deploy my now bug-free subgraph to a remote Graph node and live happily ever after! (no potatoes tho) -5. The end... +3. لقد قمت بفحص السجلات التي تنتجها Graph node المحلية ، ويبدو أن كل شيء يعمل بشكل جيد. +4. أقوم بنشر الـ subgraph الخاص بي الخالي من الأخطاء لـ Graph node بعيدة وأعيش في سعادة دائمة +5. النهاية... From 1c532728ec16aee880dfa1d5ab4fe5c16df138ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 04:08:36 -0500 Subject: [PATCH 11/90] New translations subgraph-debug-forking.mdx (Japanese) --- pages/ja/developer/subgraph-debug-forking.mdx | 76 +++++++++---------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/pages/ja/developer/subgraph-debug-forking.mdx b/pages/ja/developer/subgraph-debug-forking.mdx index 0b97a4c37735..24697f21ea21 100644 --- a/pages/ja/developer/subgraph-debug-forking.mdx +++ b/pages/ja/developer/subgraph-debug-forking.mdx @@ -1,28 +1,28 @@ --- -title: Quick and easy subgraph debugging using forks +title: フォークを使った迅速で簡単なサブグラフのデバッギング --- -> Note: this is only available from this `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) or this [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) onwards, it hasn't been yet released in a minor release (eg: 0.26.0) +> 注:この`graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) または、この[docker tag ](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) 以降でのみ利用可能で、マイナーリリース(例:0.26.0)ではまだリリースされていません。 -As with many systems processing large amounts of data, The Graph's Indexers (Graph nodes) may take quite some time to sync-up your subgraph with the target blockchain. The discrepancy between quick changes with the purpose of debugging and long wait times needed for indexing is extremely counterproductive and we are well aware of that. This is why we are introducing **subgraph forking**, developed by [LimeChain](https://limechain.tech/), and in this article I will show you how this feature can be used to substantially speed-up subgraph debugging! +大量のデータを処理する多くのシステムと同様に、The GraphのIndexers(グラフノード)は、サブグラフとターゲットブロックチェーンの同期にかなりの時間がかかる場合があります。デバッグを目的とした素早い変更と、インデックス作成に必要な長い待ち時間の不一致は非常に逆効果であり、私たちはそれを十分に認識しています。そこで、[LimeChain](https://limechain.tech/)が開発した**subgraph forking**を導入し、今回はこの機能を使ってサブグラフのデバッグを大幅に高速化する方法を紹介します。 -## Ok, what is it? +## さて、それは何でしょうか? -**Subgraph forking** is the process of lazily fetching entities from _another_ subgraph's store (usually a remote one). +**サブグラフのフォーク**とは、_他_のサブグラフのストア(通常はリモート) からエンティティをフェッチするプロセスです。 -In the context of debugging, **subgraph forking** allows you to debug your failed subgraph at block _X_ without needing to wait to sync-up to block _X_. +デバッグの文脈では、**サブグラフのフォーク**により、ブロック_X_への同期を待つことなく、ブロック_X_で失敗したサブグラフのデバッグを行うことができます。 -## What?! How? +## その方法は? -When you deploy a subgraph to a remote Graph node for indexing and it fails at block _X_, the good news is that the Graph node will still serve GraphQL queries using its store, which is synced-up to block _X_. That's great! This means we can take advantage of this "up-to-date" store to fix the bugs arising when indexing block _X_. +インデックス作成のためにリモートのGraphノードにサブグラフをデプロイし、ブロック_X_で失敗した場合でも、ブロック_X_と同期しているストアを使用して GraphQL クエリを提供することができます。つまり、ブロック _X_ のインデックス作成時に発生するバグを修正するために、この最新のストアを利用できるのです。 -In a nutshell, we are going to _fork the failing subgraph_ from a remote Graph node that is guaranteed to have the subgraph indexed up to block _X_ in order to provide the locally deployed subgraph being debugged at block _X_ an up-to-date view of the indexing state. +簡単に言うと、ブロック_X_でデバッグされているローカルにデプロイされたサブグラフにインデックス状態の最新のビューを提供するために、ブロック_X_までインデックスされたサブグラフを持つことが保証されているリモートGraphノードから _失敗したサブグラフをフォーク_しようとしているのです。 -## Please, show me some code! +## コードを見てみましょう -To stay focused on subgraph debugging, let's keep things simple and run along with the [example-subgraph](https://github.com/graphprotocol/example-subgraph) indexing the Ethereum Gravity smart contract. +サブグラフのデバッグに集中するために、物事をシンプルにして、Ethereum Gravityスマートコントラクトのサブグラフのインデックス作成の[例](https://github.com/graphprotocol/example-subgraph)に沿って実行しましょう。 -Here are the handlers defined for indexing `Gravatar`s, with no bugs whatsoever: +以下は、`Gravatar`のインデックスを作成するために定義されたハンドラで、バグが全くありません。 ```tsx export function handleNewGravatar(event: NewGravatar): void { @@ -46,43 +46,43 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -Oops, how unfortunate, when I deploy my perfect looking subgraph to the [HostedService](https://thegraph.com/hosted-service/) it fails with the _"Gravatar not found!"_ error. +この場合、残念なことに、この完璧に見えるサブグラフを[HostedService](https://thegraph.com/hosted-service/) にデプロイすると、_"Gravatar not found!"_というエラーで失敗してしまいます。 -The usual way to attempt a fix is: +通常の試すであろう修正方法: -1. Make a change in the mappings source, which you believe will solve the issue (while I know it won't). -2. Re-deploy the subgraph to the [HostedService](https://thegraph.com/hosted-service/) (or another remote Graph node). -3. Wait for it to sync-up. -4. If it breaks again go back to 1, otherwise: Hooray! +1. マッピングソースを変更して問題の解決を試す(解決されないことは分かっていても) +2. サブグラフを[HostedService](https://thegraph.com/hosted-service/)(または別のリモートGraphノード)に再デプロイする +3. 同期を待つ +4. 再び問題が発生した場合は、1に戻る -It is indeed pretty familiar to an ordinary debug process, but there is one step that horribly slows down the process: _3. Wait for it to sync-up._ +このように、通常のデバッグ処理とほぼ同じですが、1つだけ、処理を恐ろしく遅くするステップがあります:_3. 同期を待つ_ -Using **subgraph forking** we can essentially eliminate this step. Here is how it looks: +**サブグラフのフォーク**を利用することで、このステップを実質的に省略することができます。その方法は次の通りです: -0. Spin-up a local Graph node with the **_appropriate fork-base_** set. -1. Make a change in the mappings source, which you believe will solve the issue. -2. Deploy to the local Graph node, **_forking the failing subgraph_** and **_starting from the problematic block_**. -3. If it breaks again, go back to 1, otherwise: Hooray! +0. **_適切なフォークベース_**セットを持つローカルのグラフ・ノードをスピンアップする +1. マッピングのソースを変更し、問題を解決する +2. ローカルGraphノードにデプロイし、**_失敗したサブグラフをフォーク_**して、**_問題のブロックから開始_**する +3. もし再度、壊れる場合1に戻る -Now, you may have 2 questions: +さて、ここで2つの疑問が生じます: -1. fork-base what??? 2) Forking who?! -2. Forking who?! +1. フォークベースとは? +2. 誰がフォークするのか? -And I answer: +回答: -1. `fork-base` is the "base" URL, such that when the _subgraph id_ is appended the resulting URL (`/`) is a valid GraphQL endpoint for the subgraph's store. 2) Forking is easy, no need to sweat: -2. Forking is easy, no need to sweat: +1. `fork-base`は「ベース」URLで、_subgraph id_が追加されたときのURL (`/`) はサブグラフのストアに対する有効な GraphQL endpoint であることを示します。 +2. フォーキングは簡単であり煩雑な手間はありません ```bash $ graph deploy --debug-fork --ipfs http://localhost:5001 --node http://localhost:8020 ``` -Also, don't forget to set the `dataSources.source.startBlock` field in the subgraph manifest to the number of the problematic block, so you can skip indexing unnecessary blocks and take advantage of the fork! +また、サブグラフマニフェストの`dataSources.source.startBlock`フィールドを問題のあるブロックの番号に設定することを忘れないでください。そうすれば、不要なブロックのインデックス作成を省略して、フォークを利用することができます。 -So, here is what I do: +そこで、以下の通りです: -0. I spin-up a local graph node ([here is how to do it](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) with the `fork-base` option set to: `https://api.thegraph.com/subgraphs/id/`, since I will fork a subgraph, the buggy one I deployed earlier, from the [HostedService](https://thegraph.com/hosted-service/). +0. [こちらの方法](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)で、`fork-base` オプションをセットして、ローカルグラフノードをスピンアップします。[HostedService](https://thegraph.com/hosted-service/) から、先にデプロイしたバグのあるサブグラフをフォークするからです。 ``` $ cargo run -p graph-node --release -- \ @@ -92,13 +92,13 @@ $ cargo run -p graph-node --release -- \ --fork-base https://api.thegraph.com/subgraphs/id/ ``` -1. After careful inspection I notice that there is a mismatch in the `id` representations used when indexing `Gravatar`s in my two handlers. While `handleNewGravatar` converts it to a hex (`event.params.id.toHex()`), `handleUpdatedGravatar` uses an int32 (`event.params.id.toI32()`) which causes the `handleUpdatedGravatar` to panic with "Gravatar not found!". I make them both convert the `id` to a hex. -2. After I made the changes I deploy my subgraph to the local Graph node, **_forking the failing subgraph_** and setting `dataSources.source.startBlock` to `6190343` in `subgraph.yaml`: +1. よく調べてみると、2つのハンドラで `Gravatar` をインデックスする際に使用される `id` 表現にミスマッチがあることに気づきました。`handleNewGravatar` はそれを hex (`event.params.id.toHex()`) に変換しますが、`handleUpdatedGravatar` は int32 (`event.params.id.toI32()`) を使用するので `handleUpdatedGravatar` は "Gravatar not found!" でパニックになってしまうのです。両方とも`id`を16進数に変換するようにしています。 +2. 変更後、ローカルのGraphノードにサブグラフをデプロイし、**_失敗したサブグラフのフォーク_**と `subgraph.yaml` で `dataSources.source.startBlock` を `6190343` にセットしてください。 ```bash $ graph deploy gravity --debug-fork QmNp169tKvomnH3cPXTfGg4ZEhAHA6kEq5oy1XDqAxqHmW --ipfs http://localhost:5001 --node http://localhost:8020 ``` -3. I inspect the logs produced by the local Graph node and, Hooray!, everything seems to be working. -4. I deploy my now bug-free subgraph to a remote Graph node and live happily ever after! (no potatoes tho) -5. The end... +3. ローカルのGraphノードが出力するログを調べてみると、すべてうまくいっていることがわかります。 +4. バグのないサブグラフをリモートのGraphノードにデプロイすることができました。 +5. 完了です。 From 596b399c38aa271b478d0f9d651b5c580cf8e2cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 04:08:37 -0500 Subject: [PATCH 12/90] New translations migrating-subgraph.mdx (Japanese) --- .../ja/hosted-service/migrating-subgraph.mdx | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/pages/ja/hosted-service/migrating-subgraph.mdx b/pages/ja/hosted-service/migrating-subgraph.mdx index e77dbaff3c62..53cd30301eed 100644 --- a/pages/ja/hosted-service/migrating-subgraph.mdx +++ b/pages/ja/hosted-service/migrating-subgraph.mdx @@ -14,7 +14,7 @@ title: 既存のサブグラフをグラフネットワークに移行する - 公開はオンチェーンのアクションであり、Ethereum でのガスの支払いが必要になることを覚えておいてください。トランザクションの例は[こちら](https://etherscan.io/tx/0xd0c3fa0bc035703c9ba1ce40c1862559b9c5b6ea1198b3320871d535aa0de87b)で見れます。価格はだいたい 100gwei で 0.0425ETH くらいです。 - サブグラフをアップグレードする必要がある場合は、アップグレード料金が発生します。アップグレードとは、既存のサブグラフの別バージョンをチェーン上に公開することです。アップグレードには費用がかかりますので、メインネットにデプロイする前に、Rinkeby でサブグラフをデプロイしてテストすることを強くお勧めします。また、そのサブグラフにシグナルがない場合、場合によっては GRT が必要になることもあります。そのサブグラフのバージョンにシグナル/キュレーションがある場合(auto-migrate を使用)、税金は分割されます。 -- Indexing chains other than Ethereum mainnet. +- イーサリアムメインネット以外のチェーンをインデックス化 ### ネットワーク上のサブグラフのアップグレード @@ -90,7 +90,7 @@ graph deploy --studio ### サブグラフの安定版の維持 -An upgrade requires GRT to be migrated from the old version of the subgraph to the new version. This means that for every upgrade, a new bonding curve will be created (more on bonding curves [here](/curating#bonding-curve-101)). +アップグレードには、旧バージョンのサブグラフから新バージョンのサブグラフへのGRTの移行が必要です。つまり、アップグレードのたびに、新しいボンディングカーブが作成されます(ボンディングカーブについての詳細は[こちら](/curating#bonding-curve-101)) サブグラフに多くの変更を加えている場合、継続的にアップグレードしてアップグレード費用を負担するのは得策ではありません。サブグラフの安定した一貫性のあるバージョンを維持することは、コストの観点からだけでなく、インデクサーが自信を持って同期時間を設定できるようにするためにも重要です。アップグレードを計画する際には、インデクサーの同期時間に影響が出ないように、インデクサにフラグを立てる必要があります。Discord の[#Indexers channel](https://discord.gg/8tgJ7rKW)チャンネルを利用して、サブグラフのバージョンアップをインデクサーに知らせることができます。 @@ -98,9 +98,9 @@ An upgrade requires GRT to be migrated from the old version of the subgraph to t - ENS を設定する: https://app.ens.domains/ - ENS 名を[こちら](https://thegraph.com/explorer/settings?view=display-name)の設定に追加します。 -- The owner then has 1250 GRT burned to pay for half the fee. The owner must have this in their wallet before the upgrade, otherwise, the upgrade will not succeed. This happens in the same transaction as the upgrade. +- 所有者は料金の半分の1250GRTをバーンすることができます。アップグレードの前に、この資金をウォレットに用意しておかなければなりません。この操作は、アップグレードと同じトランザクションで行われます。 -_While this mechanism is currently live on the network, the community is currently discussing ways to reduce the cost of upgrades for subgraph developers._ +_このメカニズムは現在ネットワーク上で稼動していますが、現在コミュニティでは、サブグラフ開発者のアップグレードコストを削減する方法について議論しています。_ ### サブグラフのメタデータの更新 @@ -118,10 +118,10 @@ _While this mechanism is currently live on the network, the community is current 1. サブグラフの開発に ENS 名を活用する -- Set up your ENS: [https://app.ens.domains/](https://app.ens.domains/) -- Add your ENS name to your settings [here](https://thegraph.com/explorer/settings?view=display-name). +- ENSのセットアップ:[https://app.ens.domains/](https://app.ens.domains/) +- ENSネームの追加方法は name to your settings [こちら](https://thegraph.com/explorer/settings?view=display-name). -2. The more filled out your profiles are, the better the chances for your subgraphs to be indexed and curated. +2. プロフィールが充実しているほど、サブグラフがインデックスやキュレーションされる可能性が高くなります。 ## The Graph Network のサブグラフを廃止する @@ -133,19 +133,19 @@ The Graph Network が真の意味で分散化されるためには、プロト クエリの予算は自分で決めることができますが、インデクサーがその価格でクエリを提供してくれる保証はありません。ゲートウェイが、あなたが支払ってもよいと考えている価格以下でクエリを提供してくれるインデクサを紹介してくれた場合、あなたは予算**と**その価格の差分を支払うことになります。その結果、クエリ価格が低ければ、利用できるインデクサーの数が減り、受けるサービスの質に影響が出る可能性があります。クエリ価格が高いと、キュレーションや有名なインデクサーをサブグラフに引き寄せることができるので、有益です。 -### Estimate Query Fees on the Network +### ネットワーク上でのクエリ料の算出 これはダイナミックで成長中の市場ですが、どのように関わるかは自分でコントロールできることを忘れないでください。プロトコルにもゲートウェイにも、上限や下限の価格は指定されていません。例えば、ネットワーク上のいくつかの dapps が支払う価格(週単位)を以下に示します。最後の列は GRT でのクエリ料を示していますのでご覧ください。例えば、[Pickle Finance](https://www.pickle.finance/)は 1 秒あたり 8 回のリクエストがあり、1 週間で 2.4GRT を支払っています。 -While you get to decide on your query budget, there is no guarantee that an Indexer will be willing to serve queries at that price. If a Gateway can match you to an Indexer willing to serve a query at, or lower than, the price you are willing to pay, you will pay the delta/difference of your budget **and** their price. As a consequence, a lower query price reduces the pool of Indexers available to you, which may affect the quality of service you receive. It's beneficial to have high query fees, as that may attract curation and big-name Indexers to your subgraph. +クエリ料は各自で決定できますが、インデクサーがその価格でクエリを提供する保証はありません。もしゲートウェイが、ユーザーが支払おうとする価格か、それよりも低い価格でクエリを提供するインデクサーとマッチングできた場合、予算** と**価格の差分を支払うことになります。結果として、クエリ料が低いと、利用できるインデクサープールが減少し、受けられるサービスの品質に影響を与える可能性があります。高いクエリ料は、あなたのサブグラフにキュレーションや有名なインデクサーを引き寄せるインセンティブを持つことから、有益になります。 まだよくわからないという方も、ご安心ください。以下のリソースをチェックしたり、分散型ネットワークへのサブグラフの移行に関するビデオガイドをご覧ください: -![QueryFee](/img/QueryFee.png) +![クエリ料](/img/QueryFee.png) ## その他のリソース -If you're still confused, fear not! Check out the following resources or watch our video guide on migrating subgraphs to the decentralized network below: +まだよくわからないという方も、ご安心ください。以下のリソースをチェックしたり、分散型ネットワークへのサブグラフの移行に関するビデオガイドをご覧ください:
+>
-- [The Graph Network Contracts](https://github.com/graphprotocol/contracts) -- [Curation Contract](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - the underlying contract that the GNS wraps around - - Address - `0x8fe00a685bcb3b2cc296ff6ffeab10aca4ce1538` -- [Subgraph Studio documentation](/studio/subgraph-studio) +- [The Graph Networkのコントラクト](https://github.com/graphprotocol/contracts) +- [キュレーションコントラクト](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - GNSが包括する基本的なコントラクト + - アドレス - `0x8fe00a685bcb3b2cc296ff6ffeab10aca4ce1538` +- [Subgraph Studioドキュメント](/studio/subgraph-studio) From 9360811f0eecd1248451c89ccce2f4a1e7392d9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 04:08:39 -0500 Subject: [PATCH 13/90] New translations studio-faq.mdx (Japanese) --- pages/ja/studio/studio-faq.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pages/ja/studio/studio-faq.mdx b/pages/ja/studio/studio-faq.mdx index e8fa300eb771..b939e8f8b1ee 100644 --- a/pages/ja/studio/studio-faq.mdx +++ b/pages/ja/studio/studio-faq.mdx @@ -20,8 +20,8 @@ API キーを作成後、「セキュリティ」セクションで、特定の API キーを作成すると、自分でサブグラフを構築した場合でも、ネットワークに公開されているすべてのサブグラフにクエリを実行できることを覚えておいてください。新しい API キーを介したこれらのクエリは、ネットワーク上の他のクエリと同様に支払われます。 -### 5. How do I find query URLs for subgraphs if I’m not the developer of the subgraph I want to use? +### 5. 使用したいサブグラフのクエリURLを見つける方法は? -You can find the query URL of each subgraph in the Subgraph Details section of The Graph Explorer. When you click on the “Query” button, you will be directed to a pane wherein you can view the query URL of the subgraph you’re interested in. You can then replace the `` placeholder with the API key you wish to leverage in the Subgraph Studio. +各サブグラフのクエリ URL は、Graph Explorerの「Subgraph Details」で確認できます。「Query」をクリックすると、興味のあるサブグラフのクエリ URL が表示されます。ここで``というプレースホルダーを、Subgraph Studioで利用したい API キーに置き換えることができます。 -Remember that you can create an API key and query any subgraph published to the network, even if you build a subgraph yourself. These queries via the new API key, are paid queries as any other on the network. +APIキーを作成すると、自分でサブグラフを構築した場合でも、ネットワークに公開されているすべてのサブグラフにクエリを実行できることを覚えておいてください。新しい API キーを介したこれらのクエリは、ネットワーク上の他のクエリと同様に支払われます。 From 2d13cf2521425d5612f93fbac61e52a1e6609823 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 04:08:42 -0500 Subject: [PATCH 14/90] New translations delegating.mdx (Japanese) --- pages/ja/delegating.mdx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pages/ja/delegating.mdx b/pages/ja/delegating.mdx index 8cf7e8749dfb..1b47a11008f2 100644 --- a/pages/ja/delegating.mdx +++ b/pages/ja/delegating.mdx @@ -53,7 +53,7 @@ title: デリゲーティング ### デリゲーターの期待リターンを計算 -A Delegator has to consider a lot of factors when determining the return. These include: +デリゲーターはリターンを決定する際に多くの要素を考慮する必要があります。 これらは以下の通りです: - デリゲーターは、インデクサーが利用可能なデリゲートトークンを使用する能力にも目を向けることができます。 もしインデクサーが利用可能なトークンをすべて割り当てていなければ、彼らは自分自身やデリゲーターのために得られる最大の利益を得られないことになります。 - 現在のネットワークでは、インデクサーは 1 日から 28 日の間であればいつでも割り当てを終了して報酬を受け取ることができます。 そのため、インデクサーがまだ回収していない報酬をたくさん抱えている可能性があり、その結果、報酬の総額が少なくなっています。 これは初期の段階で考慮しておく必要があります。 @@ -68,7 +68,7 @@ A Delegator has to consider a lot of factors when determining the return. These したがって、デリゲーターは計算して、デリゲーターに 20%を提供しているインデクサーの方が、より良いリターンを提供していると判断することができます。 -![Share formula](/img/Share-Forumla.png) +![シェアの計算式](/img/Share-Forumla.png) もうひとつ考慮しなければならないのが、デリゲーション能力です。 現在、デリゲーションレシオは 16 に設定されています。 これは、インデクサーが 1,000,000GRT をステークしている場合、そのデリゲーション容量はプロトコルで使用できる 16,000,000GRT のデリゲーショントークンであることを意味します。 この量を超えるデリゲートされたトークンは、全てのデリゲーター報酬を薄めてしまいます。 @@ -80,11 +80,11 @@ A Delegator has to consider a lot of factors when determining the return. These この式を使うと、デリゲーターに 20%しか提供していないインデクサーが、デリゲーターに 90%を提供しているインデクサーよりも、デリゲーターにさらに良い報酬を与えている可能性があることがわかります。 -Therefore a Delegator should always consider the Delegation Capacity of an Indexer, and factor it into their decision making. +したがって、デリゲーターはインデクサーのデリゲーション・キャパシティを常に考慮し、意思決定に反映させる必要があります。 ## ネットワーク UI のビデオガイド -This guide provides a full review of this document, and how to consider everything in this document while interacting with the UI. +この式を使うと、デリゲーターに20%しか提供していないインデクサーが、デリゲーターに90%を提供しているインデクサーよりも、デリゲーターにさらに良い報酬を与えている可能性があることがわかります。
+>
From 0bd16a3554d9fc62f45beb5268411dd432860e7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:09 -0500 Subject: [PATCH 15/90] New translations assemblyscript-migration-guide.mdx (Spanish) --- pages/es/developer/assemblyscript-migration-guide.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pages/es/developer/assemblyscript-migration-guide.mdx b/pages/es/developer/assemblyscript-migration-guide.mdx index 05c245bae275..ceb0cd2c2298 100644 --- a/pages/es/developer/assemblyscript-migration-guide.mdx +++ b/pages/es/developer/assemblyscript-migration-guide.mdx @@ -127,11 +127,8 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` - Tendrás que cambiar el nombre de las variables duplicadas si tienes una variable shadowing. - ### Comparaciones Nulas - Al hacer la actualización en ut subgrafo, a veces pueden aparecer errores como estos: ```typescript @@ -140,7 +137,6 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` - Para solucionarlo puedes simplemente cambiar la declaracion `if` por algo así: ```typescript @@ -285,7 +281,6 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` - Para solucionar este problema, puedes crear una variable para ese acceso a la propiedad de manera que el compilador pueda hacer la magia de la comprobación de nulidad: ```typescript From 8858d71f16aa7e8672a194ce326122b0bd950009 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:11 -0500 Subject: [PATCH 16/90] New translations assemblyscript-migration-guide.mdx (Japanese) --- pages/ja/developer/assemblyscript-migration-guide.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pages/ja/developer/assemblyscript-migration-guide.mdx b/pages/ja/developer/assemblyscript-migration-guide.mdx index 962ef5160dc6..5712183d4b4d 100644 --- a/pages/ja/developer/assemblyscript-migration-guide.mdx +++ b/pages/ja/developer/assemblyscript-migration-guide.mdx @@ -127,11 +127,8 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` - 変数シャドウイングを行っていた場合は、重複する変数の名前を変更する必要があります。 - ### Null 比較 - サブグラフのアップグレードを行うと、時々以下のようなエラーが発生することがあります。 ```typescript @@ -140,7 +137,6 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` - 解決するには、 `if` 文を以下のように変更するだけです。 ```typescript @@ -285,7 +281,6 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` - この問題を解決するには、そのプロパティアクセスのための変数を作成して、コンパイラが nullability check のマジックを行うようにします。 ```typescript From e375a6d2f0f2971e54a37096d0602857edd80658 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:12 -0500 Subject: [PATCH 17/90] New translations assemblyscript-migration-guide.mdx (Korean) --- pages/ko/developer/assemblyscript-migration-guide.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pages/ko/developer/assemblyscript-migration-guide.mdx b/pages/ko/developer/assemblyscript-migration-guide.mdx index ffddd65d68ed..883f381e9941 100644 --- a/pages/ko/developer/assemblyscript-migration-guide.mdx +++ b/pages/ko/developer/assemblyscript-migration-guide.mdx @@ -127,11 +127,8 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` - Variable shadowing이 있는 경우 중복 변수의 이름을 바꿔야 합니다. - ### Null Comparisons - 서브그래프에서 업그레이드를 수행하면 때때로 다음과 같은 오류가 발생할 수 있습니다: ```typescript @@ -140,7 +137,6 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` - 이를 해결하기 위해 여러분들은 `if` 구문을 다음과 같이 간단히 변경할 수 있습니다: ```typescript @@ -285,7 +281,6 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` - 이 문제를 해결하려면 컴파일러에서 nullability 검사를 수행할 수 있도록 해당 속성 액세스에 대한 변수를 생성할 수 있습니다: ```typescript From 36b933bf4d5e06212bfd17544d4c753258bdf7b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:14 -0500 Subject: [PATCH 18/90] New translations assemblyscript-migration-guide.mdx (Chinese Simplified) --- pages/zh/developer/assemblyscript-migration-guide.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pages/zh/developer/assemblyscript-migration-guide.mdx b/pages/zh/developer/assemblyscript-migration-guide.mdx index b1129e34ccd7..324f0534aa7a 100644 --- a/pages/zh/developer/assemblyscript-migration-guide.mdx +++ b/pages/zh/developer/assemblyscript-migration-guide.mdx @@ -127,11 +127,8 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` - 如果您有变量遮蔽的情况,则需要重命名重名变量。 - ### 空值比较 - 对子图进行升级后,有时您可能会遇到如下错误: ```typescript @@ -140,7 +137,6 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` - 要解决此问题,您只需将 `if` 语句更改为如下所示代码: ```typescript @@ -285,7 +281,6 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` - 要解决此问题,您可以为该属性访问创建一个变量,以便编译器可以执行可空性检查: ```typescript From cab766ca32594cfe8ac1b231fc6154a551979a5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:15 -0500 Subject: [PATCH 19/90] New translations assemblyscript-migration-guide.mdx (Vietnamese) --- pages/vi/developer/assemblyscript-migration-guide.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pages/vi/developer/assemblyscript-migration-guide.mdx b/pages/vi/developer/assemblyscript-migration-guide.mdx index 7b27cddb3c25..39d2fcd28e06 100644 --- a/pages/vi/developer/assemblyscript-migration-guide.mdx +++ b/pages/vi/developer/assemblyscript-migration-guide.mdx @@ -127,11 +127,8 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` - Bạn sẽ cần đổi tên các biến trùng lặp của mình nếu bạn có che biến. - ### So sánh Null - Bằng cách thực hiện nâng cấp trên subgraph của bạn, đôi khi bạn có thể gặp các lỗi như sau: ```typescript @@ -140,7 +137,6 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` - Để giải quyết, bạn có thể chỉ cần thay đổi câu lệnh `if` thành một cái gì đó như sau: ```typescript @@ -285,7 +281,6 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` - Để khắc phục sự cố này, bạn có thể tạo một biến cho quyền truy cập thuộc tính đó để trình biên dịch có thể thực hiện phép thuật kiểm tra tính nullability: ```typescript From b62d626a8b2378739a4e3620bc3f029763a4af6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:16 -0500 Subject: [PATCH 20/90] New translations subgraph-debug-forking.mdx (Arabic) --- pages/ar/developer/subgraph-debug-forking.mdx | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/pages/ar/developer/subgraph-debug-forking.mdx b/pages/ar/developer/subgraph-debug-forking.mdx index fb86701ef8da..3d4a40e00987 100644 --- a/pages/ar/developer/subgraph-debug-forking.mdx +++ b/pages/ar/developer/subgraph-debug-forking.mdx @@ -61,28 +61,28 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { 0. قم بتجهيز Graph node محلية بمجموعة **_fork-base_** مناسبة. 1. قم بإجراء تغيير في مصدر الـ mappings ، والذي تعتقد أنه سيحل المشكلة. -2. Deploy to the local Graph node, **_forking the failing subgraph_** and **_starting from the problematic block_**. +2. قم بالنشر إلى Graph node محلية ، **_وقم بتفريع الـ subgraph الفاشل_**و**_ البدء من الكتلة التي بها المشكلة_**. 3. إذا حدثت المشكلة مرة أخرى ، فارجع إلى 1! الآن ، قد يكون لديك سؤالان: -1. fork-base what??? 2) Forking who?! -2. Forking who?! +1. ماهو fork-base؟؟؟ +2. ما الذي نقوم بتفريعه (Forking)؟! وأنا أجيب: -1. `fork-base` is the "base" URL, such that when the _subgraph id_ is appended the resulting URL (`/`) is a valid GraphQL endpoint for the subgraph's store. 2) Forking is easy, no need to sweat: -2. الـ Forking سهل ، لا داعي للقلق: +1. ` fork-base ` هو عنوان URL "الأساسي" ،فمثلا عند إلحاق _subgraph id_ ، يكون عنوان URL الناتج (`/`) هو GraphQL endpoint صالح لمخزن الـ subgraph. +2. الـتفريع سهل ، فلا داعي للقلق: ```bash $ graph deploy --debug-fork --ipfs http://localhost:5001 --node http://localhost:8020 ``` -أيضًا ، لا تنس تعيين الحقل ` dataSources.source.startBlock ` في subgraph manifest لرقم الكتلة التي بها المشكلة، حتى تتمكن من تخطي فهرسة الكتل غير الضرورية والاستفادة من الـ fork! +أيضًا ، لا تنس تعيين حقل ` dataSources.source.startBlock ` في subgraph manifest لرقم الكتلة(block) التي بها المشكلة، حتى تتمكن من تخطي فهرسة الكتل الغير ضرورية والاستفادة من التفريع! لذلك ، هذا ما أفعله: -0. I spin-up a local graph node ([here is how to do it](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) with the `fork-base` option set to: `https://api.thegraph.com/subgraphs/id/`, since I will fork a subgraph, the buggy one I deployed earlier, from the [HostedService](https://thegraph.com/hosted-service/). +0. أقوم بتجهيز Graph Node محلية ([هنا كيف تقوم به](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) مع تعيين خيار `fork-base` إلى `https://api.thegraph.com/subgraphs/id/` ، نظرا لأنني سأقوم بتفريع(fork) الـ subgraph الذي به أخطاء والذي نشرته سابقا من الـ [HostedService](https://thegraph.com/hosted-service/). ``` $ cargo run -p graph-node --release -- \ @@ -92,8 +92,8 @@ $ cargo run -p graph-node --release -- \ --fork-base https://api.thegraph.com/subgraphs/id/ ``` -1. بعد فحص دقيق ، لاحظت أن هناك عدم تطابق في تمثيلات ` id ` المستخدمة عند فهرسة ` Gravatar ` في المعالجين الخاصين بي. بينما ` handleNewGravatar ` يحول (`event.params.id.toHex()`) إلى سداسي ، `handleUpdatedGravatar` يستخدم int32 (`event.params.id.toI32()`) مما يجعل ` handleUpdatedGravatar ` قلقا من "Gravatar غير موجود!". أنا أجعلهم كلاهما يحولان ` id ` إلى سداسي. -2. بعد إجراء التغييرات ، قمت بنشر الـ subgraph الخاص بي على Graph node المحلية **_وعمل fork لـsubgraph الفاشل_** وضبط `dataSources.source.startBlock` إلى `6190343` في `subgraph.yaml`: +1. بعد فحص دقيق ، لاحظت أن هناك عدم تطابق في تمثيلات الـ ` id ` المستخدمة عند فهرسة ` Gravatar ` في المعالجين الخاصين بي. بينما ` handleNewGravatar ` يحول (`event.params.id.toHex()`) إلى سداسي ، `handleUpdatedGravatar` يستخدم int32 (`event.params.id.toI32()`) مما يجعل ` handleUpdatedGravatar ` قلقا من "Gravatar not found!". أنا أجعلهم كلاهما يحولان ` id ` إلى سداسي. +2. بعد إجراء التغييرات ، قمت بنشر الـ subgraph الخاص بي على Graph node المحلية **_وتفريع الـsubgraph الفاشل_** وضبط `dataSources.source.startBlock` إلى `6190343` في `subgraph.yaml`: ```bash $ graph deploy gravity --debug-fork QmNp169tKvomnH3cPXTfGg4ZEhAHA6kEq5oy1XDqAxqHmW --ipfs http://localhost:5001 --node http://localhost:8020 From 8e73dbb774ffd43d020d47171f1725029c49dfbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:17 -0500 Subject: [PATCH 21/90] New translations migrating-subgraph.mdx (Arabic) --- pages/ar/hosted-service/migrating-subgraph.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/ar/hosted-service/migrating-subgraph.mdx b/pages/ar/hosted-service/migrating-subgraph.mdx index 3e82d0a376e4..a5a3d60a6f56 100644 --- a/pages/ar/hosted-service/migrating-subgraph.mdx +++ b/pages/ar/hosted-service/migrating-subgraph.mdx @@ -137,7 +137,7 @@ _بينما تتم هذه الآلية حاليا على الشبكة ، ينا على الرغم من أن هذه ليست ميزة موجودة في واجهة مستخدم المنتج ، إلا أنه يمكنك تعيين الحد الأقصى لميزانيتك لكل استعلام وذلك عن طريق أخذ المبلغ الذي ترغب في دفعه شهريًا وتقسيمه على حجم الاستعلام المتوقع. -While you get to decide on your query budget, there is no guarantee that an Indexer will be willing to serve queries at that price. If a Gateway can match you to an Indexer willing to serve a query at, or lower than, the price you are willing to pay, you will pay the delta/difference of your budget **and** their price. As a consequence, a lower query price reduces the pool of Indexers available to you, which may affect the quality of service you receive. It's beneficial to have high query fees, as that may attract curation and big-name Indexers to your subgraph. +أثناء اتخاذ قرار بشأن ميزانية الاستعلام الخاصة بك ، ليس هناك ما يضمن أن المفهرس سيكون على استعداد لتقديم الاستعلامات بهذا السعر. إذا تمكن الـ Gateway من مطابقتك مع مفهرس يرغب في تقديم استعلام بالسعر الذي ترغب في دفعه أو أقل ، فستدفع الفرق بين ميزانيتك **و** سعرهم. ونتيجة لذلك ، فإن سعر الاستعلام المنخفض يقلل من عدد المفهرسين المتاحين لك ، مما قد يؤثر على جودة الخدمة التي تتلقاها. من المفيد أن يكون لديك رسوم استعلام مرتفع ، لأن ذلك قد يجذب التنسيق وأسماء كبيرة من المفهرسين إلى الـ subgraph الخاص بك. تذكر أنه سوق ديناميكي ومتنامي ، ولكن كيفية تفاعلك معه هو تحت سيطرتك. لا يوجد حد أقصى أو أدنى للسعر في البروتوكول أو البوابات(Gateways). على سبيل المثال ، يمكنك إلقاء نظرة أدناه على السعر الذي دفعه عدد قليل من الـ dapps على الشبكة (على أساس أسبوعي). انظر للعمود الأخير ، والذي يعرض رسوم الاستعلام كـ GRT. على سبيل المثال ، [Pickle Finance](https://www.pickle.finance/) لديه 8 طلبات في الثانية ودفع 2.4 GRT لأسبوع واحد. @@ -154,7 +154,7 @@ While you get to decide on your query budget, there is no guarantee that an Inde title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen - > +> - [عقود شبكة The Graph](https://github.com/graphprotocol/contracts) From 67054a4378bbbfa0d1533a26003564b8f6f9252e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Mon, 28 Feb 2022 16:04:18 -0500 Subject: [PATCH 22/90] New translations subgraph-studio.mdx (Arabic) --- pages/ar/studio/subgraph-studio.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ar/studio/subgraph-studio.mdx b/pages/ar/studio/subgraph-studio.mdx index 64c39dfbb174..08575d0a9653 100644 --- a/pages/ar/studio/subgraph-studio.mdx +++ b/pages/ar/studio/subgraph-studio.mdx @@ -12,7 +12,7 @@ title: كيفية استخدام Subgraph Studio - نشر subgraph باستخدام CLI - نشر subgraph باستخدام Studio UI - اختبار الـ subgraph في playground -- Integrate it in staging using the query URL +- دمجه في المنصة باستخدام عنوان URL الاستعلام - إنشاء وإدارة مفاتيح API الخاصة بك لـ subgraphs محددة هنا في Subgraph Studio ، لديك سيطرة كاملة على الـ subgraphs الخاصة بك. حيث لا يمكنك اختبار الـ subgraphs الخاصة بك قبل نشرها فحسب، ولكن يمكنك أيضا تقييد مفاتيح API الخاصة بك على نطاقات محددة والسماح فقط لمفهرسين معينين بالاستعلام من مفاتيح API الخاصة بهم. From b95f2d5349e5a3b144bf81d15fd6acf603401c20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:47 -0500 Subject: [PATCH 23/90] New translations introduction.mdx (Chinese Simplified) --- pages/zh/about/introduction.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/zh/about/introduction.mdx b/pages/zh/about/introduction.mdx index e26f12cd8076..0135265f0930 100644 --- a/pages/zh/about/introduction.mdx +++ b/pages/zh/about/introduction.mdx @@ -32,7 +32,7 @@ Graph 根据子图描述(称为子图清单)来学习什么以及如何为 ![](/img/graph-dataflow.png) -The flow follows these steps: +流程遵循这些步骤: 1. 一个去中心化的应用程序通过智能合约上的交易向以太坊添加数据。 2. 智能合约在处理交易时,会发出一个或多个事件。 From ab08d969e0630c836a4cb060538c80731702cde0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:48 -0500 Subject: [PATCH 24/90] New translations graphql-api.mdx (Chinese Simplified) --- pages/zh/developer/graphql-api.mdx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/pages/zh/developer/graphql-api.mdx b/pages/zh/developer/graphql-api.mdx index 3a2d567ba1ca..fde0e4a8d94a 100644 --- a/pages/zh/developer/graphql-api.mdx +++ b/pages/zh/developer/graphql-api.mdx @@ -204,12 +204,12 @@ _not_ends_with 全文搜索运算符: -| 符号 | 运算符 | 描述 | -| ------ | ----------- | ---------------------------------------------------------------------- | -| `&` | `And` | 用于将多个搜索词组合到包含所有提供词条的实体的过滤器中 | -| | | `Or` | 由 or 运算符分隔的多个搜索词的查询,将返回与任何提供的词匹配的所有实体 | -| `<->` | `Follow by` | 指定两个单词之间的距离。 | -| `:*` | `Prefix` | 使用前缀搜索词查找前缀匹配的单词(需要 2 个字符) | +| 符号 | 运算符 | 描述 | +| ----------- | ----------- | ------------------------------------- | +| `&` | `And` | 用于将多个搜索词组合到包含所有提供词条的实体的过滤器中 | +| | | `Or` | 由 or 运算符分隔的多个搜索词的查询,将返回与任何提供的词匹配的所有实体 | +| `<->` | `Follow by` | 指定两个单词之间的距离。 | +| `:*` | `Prefix` | 使用前缀搜索词查找前缀匹配的单词(需要 2 个字符) | #### 例子 @@ -264,8 +264,8 @@ GraphQL 模式通常定义`查询`、`订阅`和`变种`的根类型。 The Grap > **注意:**我们的 API 不提供对变种的支持,因为开发人员会从他们的应用程序中直接针对底层区块链发出交易。 -### Entities +### 实体 -All GraphQL types with `@entity` directives in your schema will be treated as entities and must have an `ID` field. +模式定义中所有带有 `@entity` 指示的 GraphQL 类型都将被视为实体,并且必须具有 `ID` 字段。 > **注意:** 目前,模式定义中的所有类型都必须具有 `@entity` 指示。 将来,我们会将没有 `@entity` 指示的类型视为值对象,但目前尚不支持。 From a250f857c91408a2248d636c5a951dfe6e61ef60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:49 -0500 Subject: [PATCH 25/90] New translations subgraph-debug-forking.mdx (Chinese Simplified) --- pages/zh/developer/subgraph-debug-forking.mdx | 76 +++++++++---------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/pages/zh/developer/subgraph-debug-forking.mdx b/pages/zh/developer/subgraph-debug-forking.mdx index 0b97a4c37735..1fda56d4b3f5 100644 --- a/pages/zh/developer/subgraph-debug-forking.mdx +++ b/pages/zh/developer/subgraph-debug-forking.mdx @@ -1,28 +1,28 @@ --- -title: Quick and easy subgraph debugging using forks +title: 使用分叉快速轻松地调试子图 --- -> Note: this is only available from this `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) or this [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) onwards, it hasn't been yet released in a minor release (eg: 0.26.0) +> 注意:这只能从这个 `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) 或这个 < a href="https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore">docker tag之后,还没有发布 在次要版本中(例如:0.26.0) -As with many systems processing large amounts of data, The Graph's Indexers (Graph nodes) may take quite some time to sync-up your subgraph with the target blockchain. The discrepancy between quick changes with the purpose of debugging and long wait times needed for indexing is extremely counterproductive and we are well aware of that. This is why we are introducing **subgraph forking**, developed by [LimeChain](https://limechain.tech/), and in this article I will show you how this feature can be used to substantially speed-up subgraph debugging! +与许多处理大量数据的系统一样,The Graph 的索引器(Graph 节点)可能需要相当长的时间才能将您的子图与目标区块链同步。 以调试为目的的快速更改与索引所需的长时间等待之间的差异非常适得其反,我们很清楚这一点。 这就是我们在本文中介绍 [LimeChain](https://limechain.tech/) 开发的 **subgraph forking** 的原因 我将向您展示如何使用此功能来显着加快子图调试! -## Ok, what is it? +## 好的,那是什么? -**Subgraph forking** is the process of lazily fetching entities from _another_ subgraph's store (usually a remote one). +**子图分叉** 是从_另一个_ 子图的存储(通常是远程存储)中延迟获取实体的过程。 -In the context of debugging, **subgraph forking** allows you to debug your failed subgraph at block _X_ without needing to wait to sync-up to block _X_. +在调试的上下文中,**subgraph forking** 允许您在块 _X_ 处调试失败的子图,而无需等待 同步以阻止 _X_。 -## What?! How? +## 什么?! 如何? -When you deploy a subgraph to a remote Graph node for indexing and it fails at block _X_, the good news is that the Graph node will still serve GraphQL queries using its store, which is synced-up to block _X_. That's great! This means we can take advantage of this "up-to-date" store to fix the bugs arising when indexing block _X_. +当您将子图部署到远程 Graph 节点以进行索引并且它在块 _X_ 处失败时,好消息是 Graph 节点仍将使用其存储服务 GraphQL 查询, 同步到阻止 _X_。 那太棒了! 这意味着我们可以利用这个“最新”存储来修复索引块 _X_ 时出现的错误。 -In a nutshell, we are going to _fork the failing subgraph_ from a remote Graph node that is guaranteed to have the subgraph indexed up to block _X_ in order to provide the locally deployed subgraph being debugged at block _X_ an up-to-date view of the indexing state. +简而言之,我们将从远程 Graph 节点 _fork 失败的子图_,该节点保证将子图索引到块 *X* 以便为在块 _X_ 处调试的本地部署的子图提供索引状态的最新视图。 -## Please, show me some code! +## 请给我看一些代码! -To stay focused on subgraph debugging, let's keep things simple and run along with the [example-subgraph](https://github.com/graphprotocol/example-subgraph) indexing the Ethereum Gravity smart contract. +为了专注于子图调试,让我们保持简单,并与索引 Ethereum Gravity 智能合约的 [example-subgraph](https://github.com/graphprotocol/example-subgraph) 一起运行。 -Here are the handlers defined for indexing `Gravatar`s, with no bugs whatsoever: +以下是为索引 `Gravatar` 定义的处理程序,没有任何错误: ```tsx export function handleNewGravatar(event: NewGravatar): void { @@ -46,43 +46,43 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -Oops, how unfortunate, when I deploy my perfect looking subgraph to the [HostedService](https://thegraph.com/hosted-service/) it fails with the _"Gravatar not found!"_ error. +糟糕,多么不幸,当我将完美的子图部署到 [HostedService](https://thegraph.com/hosted-service/) 时,它会因 *“未找到 Gravatar!”* 错误。 -The usual way to attempt a fix is: +尝试修复的常用方法是: -1. Make a change in the mappings source, which you believe will solve the issue (while I know it won't). -2. Re-deploy the subgraph to the [HostedService](https://thegraph.com/hosted-service/) (or another remote Graph node). -3. Wait for it to sync-up. -4. If it breaks again go back to 1, otherwise: Hooray! +1. 在映射源中进行更改,您认为这将解决问题(虽然我知道它不会)。 +2. 将子图重新部署到 [HostedService](https://thegraph.com/hosted-service/)(或另一个远程 Graph 节点)。 +3. 等待它同步。 +4. 如果它再次中断,则返回 1,否则:万岁! -It is indeed pretty familiar to an ordinary debug process, but there is one step that horribly slows down the process: _3. Wait for it to sync-up._ +对于一个普通的调试过程来说确实很熟悉,但是有一个步骤会严重减慢这个过程:_3。 等待它同步。_ -Using **subgraph forking** we can essentially eliminate this step. Here is how it looks: +使用 **subgraph forking** 我们可以从根本上消除这一步。 这是它的外观: -0. Spin-up a local Graph node with the **_appropriate fork-base_** set. -1. Make a change in the mappings source, which you believe will solve the issue. -2. Deploy to the local Graph node, **_forking the failing subgraph_** and **_starting from the problematic block_**. -3. If it breaks again, go back to 1, otherwise: Hooray! +0. 使用 **_适当的 fork-base_** 集启动本地 Graph 节点。 +1. 在映射源中进行更改,您认为这将解决问题。 +2. 部署到本地 Graph 节点,**_forking 失败的子图_** 和 ** _从有问题的区块开始_**。 +3. 如果它再次中断,则返回 1,否则:万岁! -Now, you may have 2 questions: +现在,您可能有 2 个问题: -1. fork-base what??? 2) Forking who?! -2. Forking who?! +1. fork-base是什么??? 2 +2. 向谁Forking?! -And I answer: +我回答: -1. `fork-base` is the "base" URL, such that when the _subgraph id_ is appended the resulting URL (`/`) is a valid GraphQL endpoint for the subgraph's store. 2) Forking is easy, no need to sweat: -2. Forking is easy, no need to sweat: +1. `fork-base` 是“基础”URL,这样当 _subgraph id_ 被附加时,结果 URL (`/`) 是子图存储的有效 GraphQL 端点。 +2. 分叉很容易,无需出汗: ```bash $ graph deploy --debug-fork --ipfs http://localhost:5001 --node http://localhost:8020 ``` -Also, don't forget to set the `dataSources.source.startBlock` field in the subgraph manifest to the number of the problematic block, so you can skip indexing unnecessary blocks and take advantage of the fork! +另外,不要忘记将子图清单中的 `dataSources.source.startBlock` 字段设置为有问题的块的编号,这样您就可以跳过索引不必要的块并利用分叉! -So, here is what I do: +所以,这就是我所做的: -0. I spin-up a local graph node ([here is how to do it](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) with the `fork-base` option set to: `https://api.thegraph.com/subgraphs/id/`, since I will fork a subgraph, the buggy one I deployed earlier, from the [HostedService](https://thegraph.com/hosted-service/). +0. 我启动了一个本地Graph节点([这里是如何做到的](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) 将 `fork-base` 选项设置为:`https://api.thegraph.com/subgraphs/id/`,因为我将分叉一个子图,我部署的那个有问题的 之前,来自 [HostedService](https://thegraph.com/hosted-service/)。 ``` $ cargo run -p graph-node --release -- \ @@ -92,13 +92,13 @@ $ cargo run -p graph-node --release -- \ --fork-base https://api.thegraph.com/subgraphs/id/ ``` -1. After careful inspection I notice that there is a mismatch in the `id` representations used when indexing `Gravatar`s in my two handlers. While `handleNewGravatar` converts it to a hex (`event.params.id.toHex()`), `handleUpdatedGravatar` uses an int32 (`event.params.id.toI32()`) which causes the `handleUpdatedGravatar` to panic with "Gravatar not found!". I make them both convert the `id` to a hex. -2. After I made the changes I deploy my subgraph to the local Graph node, **_forking the failing subgraph_** and setting `dataSources.source.startBlock` to `6190343` in `subgraph.yaml`: +1. 经过仔细检查,我注意到在我的两个处理程序中索引 `Gravatar` 时使用的 `id` 表示不匹配。 `handleNewGravatar` 将其转换为十六进制 (`event.params.id.toHex()`),而 `handleUpdatedGravatar` 使用 int32 (`event. params.id.toI32()`) 会导致 `handleUpdatedGravatar` 出现“未找到 Gravatar!”的恐慌。 我让它们都将 `id` 转换为十六进制。 +2. 进行更改后,我将子图部署到本地 Graph 节点,**_分叉失败的子图_**并设置 < `subgraph.yaml` 中的 code>dataSources.source.startBlock 到 `6190343`: ```bash $ graph deploy gravity --debug-fork QmNp169tKvomnH3cPXTfGg4ZEhAHA6kEq5oy1XDqAxqHmW --ipfs http://localhost:5001 --node http://localhost:8020 ``` -3. I inspect the logs produced by the local Graph node and, Hooray!, everything seems to be working. -4. I deploy my now bug-free subgraph to a remote Graph node and live happily ever after! (no potatoes tho) -5. The end... +3. 我检查了本地 Graph 节点生成的日志,万岁!一切似乎都在工作。 +4. 我将我现在没有错误的子图部署到远程 Graph 节点,从此过上幸福的生活! (没有土豆) +5. 结束 From 4693b7b80c2fbd56396c3a6a0c6200d9cae6c834 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:51 -0500 Subject: [PATCH 26/90] New translations migrating-subgraph.mdx (Chinese Simplified) --- .../zh/hosted-service/migrating-subgraph.mdx | 126 +++++++++--------- 1 file changed, 63 insertions(+), 63 deletions(-) diff --git a/pages/zh/hosted-service/migrating-subgraph.mdx b/pages/zh/hosted-service/migrating-subgraph.mdx index 4a326b5951ed..8cb1284f63c2 100644 --- a/pages/zh/hosted-service/migrating-subgraph.mdx +++ b/pages/zh/hosted-service/migrating-subgraph.mdx @@ -1,24 +1,24 @@ --- -title: Migrating an Existing Subgraph to The Graph Network +title: 将现有子图迁移到Graph网络 --- ## 介绍 -This is a guide on how to migrate your subgraph from the Hosted Service to The Graph Network. The migration to The Graph Network has been successful for projects like Opyn, UMA, mStable, Audius, PoolTogether, Livepeer, RAI, Enzyme, DODO, Opyn, Pickle, and BadgerDAO all of which are relying on data served by Indexers on the network. There are now over 200 subgraphs live on The Graph Network, generating query fees and actively indexing web3 data. +这是有关如何将子图从托管服务迁移到图网络的指南。 对于 Opyn、UMA、mStable、Audius、PoolTogether、Livepeer、RAI、Enzyme、DODO、Opyn、Pickle 和 BadgerDAO 等项目,向 The Graph Network 的迁移已经成功,所有这些项目都依赖于网络上索引器提供的数据。 The Graph Network 上现在有 200 多个子图,产生查询费用并积极索引 web3 数据。 -The process of migration is quick and your subgraphs will forever benefit from the reliability and performance that you can only get on The Graph Network. +迁移过程很快,您的子图将永远受益于您只能在 The Graph Network 上获得的可靠性和性能。 -### When not to Migrate? +### 什么时候不迁移? -If your subgraph is: +如果您的子图是: -- Indexing [IPFS](https://ipfs.io/). -- Using [full-text search fields](https://thegraph.com/docs/en/developer/create-subgraph-hosted/#defining-fulltext-search-fields). -- Indexing chains other than Ethereum mainnet. +- 索引 [IPFS](https://ipfs.io/)。 +- 使用 [全文搜索字段](https://thegraph.com/docs/en/developer/create-subgraph-hosted/#defining-fulltext-search-fields)。 +- 以太坊主网以外的索引链。 -### Migrating an Existing Subgraph to The Graph Network +### 将现有子图迁移到Graph网络 -1. Get the latest version of the graph-cli installed: +1. 获取已安装的最新版本的 graph-cli: ```sh npm install -g @graphprotocol/graph-cli @@ -28,26 +28,26 @@ npm install -g @graphprotocol/graph-cli yarn global add @graphprotocol/graph-cli ``` -2. Create a subgraph on the [Subgraph Studio](https://thegraph.com/studio/). Guides on how to do that can be found in the [Subgraph Studio docs](/studio/subgraph-studio) and in [this video tutorial](https://www.youtube.com/watch?v=HfDgC2oNnwo). -3. Inside the main project subgraph repository, authenticate the subgraph to deploy and build on the studio: +2. 在 [Subgraph Studio](https://thegraph.com/studio/) 上创建子图。 在 [Subgraph Studio 文档](/studio/subgraph-studio) 和 [这个视频教程](https://www.youtube.com/watch? v=HfDgC2oNnwo)。 +3. 在主项目子图存储库中,验证要在工作室上部署和构建的子图: ```sh graph auth --studio ``` -4. Generate files and build the subgraph: +4. 生成文件并构建子图: ```sh graph codegen && graph build ``` -5. Deploy the subgraph to the Studio. You can find your `` in the Studio UI, which is based on the name of your subgraph. +5. 将子图部署到 Studio。 您可以在 Studio UI 中找到您的 ``,它基于您的子图的名称。 ```sh graph deploy --studio ``` -6. Test queries on the Studio's playground. Here are some examples for the [Sushi - Mainnet Exchange Subgraph](https://thegraph.com/explorer/subgraph?id=0x4bb4c1b0745ef7b4642feeccd0740dec417ca0a0-0&view=Playground): +6. 在 Studio 的操场上测试查询。 以下是 [Sushi - Mainnet Exchange Subgraph](https://thegraph.com/explorer/subgraph?id=0x4bb4c1b0745ef7b4642feeccd0740dec417ca0a0-0&view=Playground) 的一些示例: ```sh { @@ -64,88 +64,88 @@ graph codegen && graph build } ``` -7. Fill in the description and the details of your subgraph and choose up to 3 categories. Upload a project image in the Studio if you'd like as well. -8. Publish the subgraph on The Graph's Network by hitting the "Publish" button. +7. 填写子图的描述和详细信息,最多选择 3 个类别。 如果您愿意,也可以在 Studio 中上传项目图像。 +8. 通过点击“发布”按钮在 The Graph 的网络上发布子图。 -- Remember that publishing is an on-chain action and will require gas to be paid for in Ethereum - see an example transaction [here](https://etherscan.io/tx/0xd0c3fa0bc035703c9ba1ce40c1862559b9c5b6ea1198b3320871d535aa0de87b). Prices are roughly around 0.0425 ETH at 100 gwei. -- Any time you need to upgrade your subgraph, you will be charged an upgrade fee. Remember, upgrading is just publishing another version of your existing subgraph on-chain. Because this incurs a cost, it is highly recommended to deploy and test your subgraph on Rinkeby before deploying to mainnet. It can, in some cases, also require some GRT if there is no signal on that subgraph. In the case there is signal/curation on that subgraph version (using auto-migrate), the taxes will be split. +- 请记住,发布是一种链上操作,需要在以太坊中支付 gas - 请参阅[此处](https://etherscan.io/tx/0xd0c3fa0bc035703c9ba1ce40c1862559b9c5b6ea1198b3320871d535aa0de87b)的示例交易。 价格约为 100 gwei 时的 0.0425 ETH。 +- 任何时候您需要升级您的子图,您都将被收取升级费用。 请记住,升级只是在链上发布现有子图的另一个版本。 因为这会产生成本,所以强烈建议在部署到主网之前在 Rinkeby 上部署和测试您的子图。 在某些情况下,如果该子图上没有信号,它也可能需要一些 GRT。 如果该子图版本有信号/管理(使用自动迁移),税收将被分割。 -And that's it! After you are done publishing, you'll be able to view your subgraphs live on the network via [The Graph Explorer](https://thegraph.com/explorer). +就是这样! 完成发布后,您将能够通过 [Graph Explorer](https://thegraph.com/explorer) 在网络上实时查看您的子图。 -Feel free to leverage the [#Curators channel](https://discord.gg/rC8rBuRtbH) on Discord to let Curators know that your subgraph is ready to be signaled. It would also be helpful if you share your expected query volume with them. Therefore, they can estimate how much GRT they should signal on your subgraph. +随意利用 Discord 上的 [#Curators 频道](https://discord.gg/rC8rBuRtbH) 让策展人知道您的子图已准备好发出信号。 如果您与他们分享您的预期查询量,这也会很有帮助。 因此,他们可以估计他们应该在您的子图上发出多少 GRT。 -### Upgrading a Subgraph on the Network +### 升级网络上的子图 -If you would like to upgrade an existing subgraph on the network, you can do this by deploying a new version of your subgraph to the Subgraph Studio using the Graph CLI. +如果您想升级网络上的现有子图,可以通过使用 Graph CLI 将新版本的子图部署到 Subgraph Studio 来实现。 -1. Make changes to your current subgraph. A good idea is to test small fixes on the Subgraph Studio by publishing to Rinkeby. -2. Deploy the following and specify the new version in the command (eg. v0.0.1, v0.0.2, etc): +1. 对当前子图进行更改。 一个好主意是通过发布到 Rinkeby 来测试 Subgraph Studio 上的小修复。 +2. 部署以下内容并在命令中指定新版本(例如 v0.0.1、v0.0.2 等): ```sh graph deploy --studio ``` -3. Test the new version in the Subgraph Studio by querying in the playground -4. Publish the new version on The Graph Network. Remember that this requires gas (as described in the section above). +3. 通过在 Playground 中查询,在 Subgraph Studio 中测试新版本 +4. 在 The Graph Network 上发布新版本。 请记住,这需要气体(如上一节所述)。 -### Owner Upgrade Fee: Deep Dive +### 所有者升级费用:Deep Dive -An upgrade requires GRT to be migrated from the old version of the subgraph to the new version. This means that for every upgrade, a new bonding curve will be created (more on bonding curves [here](/curating#bonding-curve-101)). +升级需要将 GRT 从旧版本的子图迁移到新版本。 这意味着每次升级都会创建一条新的结合曲线(更多关于结合曲线的信息[这里](/curating#bonding-curve-101))。 -The new bonding curve charges the 2.5% curation tax on all GRT being migrated to the new version. The owner must pay 50% of this, or 1.25%. The other 1.25% is absorbed by all the curators as a fee. This incentive design is in place to prevent an owner of a subgraph from being able to drain all their curator's funds with recursive upgrade calls. If there is no curation activity, you will have to pay a minimum of 100 GRT in order to signal your own subgraph. +新的联合曲线对迁移到新版本的所有 GRT 收取 2.5% 的管理税。 业主必须支付其中的 50%,即 1.25%。 其他 1.25% 由所有策展人作为费用吸收。 这种激励设计是为了防止子图的所有者能够通过递归升级调用耗尽其策展人的所有资金。 如果没有策展活动,您必须支付至少 100 GRT 才能显示您自己的子图。 -Let's make an example, this is only the case if your subgraph is being actively curated on: +让我们举个例子,仅当您的子图正在被积极策划时才会出现这种情况: -- 100,000 GRT is signaled using auto-migrate on v1 of a subgraph -- Owner upgrades to v2. 100,000 GRT is migrated to a new bonding curve, where 97,500 GRT get put into the new curve and 2,500 GRT is burned -- The owner then has 1250 GRT burned to pay for half the fee. The owner must have this in their wallet before the upgrade, otherwise, the upgrade will not succeed. This happens in the same transaction as the upgrade. +- 在子图的 v1 上使用自动迁移发出 100,000 GRT 信号 +- 所有者升级到 v2。 100,000 GRT 迁移到新的联合曲线,其中 97,500 GRT 进入新曲线,2,500 GRT 被烧毁 +- 然后,所有者烧毁了 1250 GRT 以支付一半的费用。 升级前所有者必须在钱包里有这个,否则升级不会成功。 这发生在与升级相同的事务中。 -_While this mechanism is currently live on the network, the community is currently discussing ways to reduce the cost of upgrades for subgraph developers._ +_虽然这种机制目前在网络上运行,但社区目前正在讨论降低子图开发人员升级成本的方法。_ -### Maintaining a Stable Version of a Subgraph +### 维护子图的稳定版本 -If you're making a lot of changes to your subgraph, it is not a good idea to continually upgrade it and front the upgrade costs. Maintaining a stable and consistent version of your subgraph is critical, not only from the cost perspective, but also so that Indexers can feel confident in their syncing times. Indexers should be flagged when you plan for an upgrade so that Indexer syncing times do not get impacted. Feel free to leverage the [#Indexers channel](https://discord.gg/rC8rBuRtbH) on Discord to let Indexers know when you're versioning your subgraphs. +如果您要对子图进行大量更改,那么不断升级它并支付升级成本并不是一个好主意。 维护子图的稳定和一致版本至关重要,不仅从成本角度来看,而且让索引器对他们的同步时间充满信心。 计划升级时应标记索引器,以免影响索引器同步时间。 随意利用 Discord 上的 [#Indexers 频道](https://discord.gg/rC8rBuRtbH) 让 Indexers 知道您何时对子图进行版本控制。 -Subgraphs are open APIs that external developers are leveraging. Open APIs need to follow strict standards so that they do not break external developers' applications. In The Graph Network, a subgraph developer must consider Indexers and how long it takes them to sync a new subgraph **as well as** other developers who are using their subgraphs. +子图是外部开发人员正在利用的开放 API。 开放 API 需要遵循严格的标准,以免破坏外部开发人员的应用程序。 在 The Graph Network 中,子图开发人员必须考虑索引器以及同步新子图 ** 以及** 使用其子图的其他开发人员需要多长时间。 -### Updating the Metadata of a Subgraph +### 更新子图的元数据 -You can update the metadata of your subgraphs without having to publish a new version. The metadata includes the subgraph name, image, description, website URL, source code URL, and categories. Developers can do this by updating their subgraph details in the Subgraph Studio where you can edit all applicable fields. +您可以更新子图的元数据,而无需发布新版本。 元数据包括子图名称、图像、描述、网站 URL、源代码 URL 和类别。 开发人员可以通过在 Subgraph Studio 中更新他们的子图详细信息来做到这一点,您可以在其中编辑所有适用的字段。 -Make sure **Update Subgraph Details in Explorer** is checked and click on **Save**. If this is checked, an on-chain transaction will be generated that updates subgraph details in the Explorer without having to publish a new version with a new deployment. +确保选中**Update Subgraph Details in Explorer**,然后点击**保存**。 如果选中此项,将生成一个链上事务,更新资源管理器中的子图详细信息,而无需发布具有新部署的新版本。 -## Best Practices for Deploying a Subgraph to The Graph Network +## 将子图部署到Graph网络的最佳实践 -1. Leveraging an ENS name for Subgraph Development: +1. 利用 ENS 名称进行子图开发: -- Set up your ENS: [https://app.ens.domains/](https://app.ens.domains/) -- Add your ENS name to your settings [here](https://thegraph.com/explorer/settings?view=display-name). +- 设置您的 ENS:[https://app.ens.domains/](https://app.ens.domains/) +- [此处](https://thegraph.com/explorer/settings?view=display-name)将您的 ENS 名称添加到您的设置中。 -2. The more filled out your profiles are, the better the chances for your subgraphs to be indexed and curated. +2. 您的个人资料填写得越多,您的子图被索引和管理的机会就越大。 -## Deprecating a Subgraph on The Graph Network +## 弃用Graph网络上的子图 -Follow the steps [here](/developer/deprecating-a-subgraph) to deprecate your subgraph and remove it from The Graph Network. +按照[此处](/developer/deprecating-a-subgraph)的步骤弃用您的子图并将其从 The Graph Network 中删除。 -## Querying a Subgraph + Billing on The Graph Network +## 在Graph网络上查询子图 + 计费 -The Hosted Service was set up to allow developers to deploy their subgraphs without any restrictions. +托管服务的设置允许开发人员不受任何限制地部署他们的子图。 -In order for The Graph Network to truly be decentralized, query fees have to be paid as a core part of the protocol's incentives. For more information on subscribing to APIs and paying the query fees, check out billing documentation [here](/studio/billing). +为了让 The Graph Network 真正去中心化,必须支付查询费用作为协议激励的核心部分。 有关订阅 API 和支付查询费用的更多信息,请查看[此处](/studio/billing)的计费文档。 -### Estimate Query Fees on the Network +### 估算网络上的查询费用 -While this is not a live feature in the product UI, you can set your maximum budget per query by taking the amount you're willing to pay per month and dividing it by your expected query volume. +虽然这不是产品 UI 中的实时功能,但您可以通过将每月愿意支付的金额除以预期查询量来设置每次查询的最大预算。 -While you get to decide on your query budget, there is no guarantee that an Indexer will be willing to serve queries at that price. If a Gateway can match you to an Indexer willing to serve a query at, or lower than, the price you are willing to pay, you will pay the delta/difference of your budget **and** their price. As a consequence, a lower query price reduces the pool of Indexers available to you, which may affect the quality of service you receive. It's beneficial to have high query fees, as that may attract curation and big-name Indexers to your subgraph. +虽然您可以决定查询预算,但不能保证索引人愿意以该价格提供查询服务。 如果网关可以将您与愿意以或低于您愿意支付的价格提供查询的索引人相匹配,您将支付预算的增量/差异**和< /strong> 他们的价格。 因此,较低的查询价格会减少可供您使用的索引人池,这可能会影响您获得的服务质量。 收取高额查询费用是有益的,因为这可能会吸引您的子图的管理和知名索引人。

-Remember that it's a dynamic and growing market, but how you interact with it is in your control. There is no maximum or minimum price specified in the protocol or the Gateways. For example, you can look at the price paid by a few of the dapps on the network (on a per-week basis), below. See the last column, which shows query fees in GRT. For example, [Pickle Finance](https://www.pickle.finance/) has 8 requests per second and paid 2.4 GRT for one week. +请记住,这是一个充满活力且不断增长的市场,但您如何与之互动是您的控制。 协议或网关中没有指定最高或最低价格。 例如,您可以查看网络上一些 dapps 支付的价格(每周),如下所示。 请参阅最后一列,它显示了 GRT 中的查询费用。 例如,[Pickle Finance](https://www.pickle.finance/) 每秒有 8 个请求,支付 2.4 GRT 一周。 -![QueryFee](/img/QueryFee.png) +![查询费](/img/QueryFee.png) -## Additional Resources +## 其他资源 -If you're still confused, fear not! Check out the following resources or watch our video guide on migrating subgraphs to the decentralized network below: +如果您仍然感到困惑,请不要害怕! 查看以下资源或观看我们的视频指南,了解将子图迁移到下面的去中心化网络:
+>
-- [The Graph Network Contracts](https://github.com/graphprotocol/contracts) -- [Curation Contract](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - the underlying contract that the GNS wraps around - - Address - `0x8fe00a685bcb3b2cc296ff6ffeab10aca4ce1538` -- [Subgraph Studio documentation](/studio/subgraph-studio) +- [The Graph网络合约](https://github.com/graphprotocol/contracts) +- [Curation Contract](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - GNS 包裹的底层合约 + - 地址 - `0x8fe00a685bcb3b2cc296ff6ffeab10aca4ce1538` +- [子图工作室文档](/studio/subgraph-studio) From 17e3dca35d91750f310072088a70420e9115744b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:54 -0500 Subject: [PATCH 27/90] New translations what-is-hosted-service.mdx (Chinese Simplified) --- .../hosted-service/what-is-hosted-service.mdx | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/pages/zh/hosted-service/what-is-hosted-service.mdx b/pages/zh/hosted-service/what-is-hosted-service.mdx index d07bcc04c1c9..b14311e2c767 100644 --- a/pages/zh/hosted-service/what-is-hosted-service.mdx +++ b/pages/zh/hosted-service/what-is-hosted-service.mdx @@ -4,17 +4,17 @@ title: 什么是托管服务? 本节将引导您将子图部署到 [托管服务](https://thegraph.com/hosted-service/) 提醒一下,托管服务不会很快关闭。 一旦去中心化网络达到托管服务相当的功能,我们将逐步取消托管服务。 您在托管服务上部署的子图在[此处](https://thegraph.com/hosted-service/)仍然可用。 -If you don't have an account on the Hosted Service, you can signup with your Github account. Once you authenticate, you can start creating subgraphs through the UI and deploying them from your terminal. Graph Node supports a number of Ethereum testnets (Rinkeby, Ropsten, Kovan) in addition to mainnet. +如果您没有托管服务帐户,您可以使用您的 Github 帐户注册。 进行身份验证后,您可以开始通过 UI 创建子图并从终端部署它们。 除了主网之外,Graph Node 还支持许多以太坊测试网(Rinkeby、Ropsten、Kovan)。 ## 创建子图 -First follow the instructions [here](/developer/define-subgraph-hosted) to install the Graph CLI. Create a subgraph by passing in `graph init --product hosted service` +首先按照[此处](/developer/define-subgraph-hosted)的说明安装Graph CLI。 通过传入 `graph init --product hosting service` 创建子图 -### From an Existing Contract +### 基于现有合约 -If you already have a smart contract deployed to Ethereum mainnet or one of the testnets, bootstrapping a new subgraph from this contract can be a good way to get started on the Hosted Service. +如果您已经将智能合约部署到以太坊主网或其中一个测试网,那么从该合约中引导一个新的子图可能是开始使用托管服务的好方法。 -You can use this command to create a subgraph that indexes all events from an existing contract. This will attempt to fetch the contract ABI from [Etherscan](https://etherscan.io/). +您可以使用此命令创建一个子图,为现有合约中的所有事件编制索引。 这将尝试从 [Etherscan](https://etherscan.io/) 获取合约 ABI。 ```sh graph init \ @@ -23,16 +23,16 @@ graph init \ / [] ``` -Additionally, you can use the following optional arguments. If the ABI cannot be fetched from Etherscan, it falls back to requesting a local file path. If any optional arguments are missing from the command, it takes you through an interactive form. +此外,您可以使用以下可选参数。 如果无法从 Etherscan 获取 ABI,它会退回到请求本地文件路径。 如果命令中缺少任何可选参数,它会带您进入交互式表单。 ```sh --network \ --abi \ ``` -The `` in this case is your github user or organization name, `` is the name for your subgraph, and `` is the optional name of the directory where graph init will put the example subgraph manifest. The `` is the address of your existing contract. `` is the name of the Ethereum network that the contract lives on. `` is a local path to a contract ABI file. **Both --network and --abi are optional.** +`` 在这种情况下是您的 github 用户或组织名称, ``是您的子图的名称,并且`` Graph初始化将放置示例子图清单的目录的可选名称。 ``是您现有合约的地址。 `` 是合约所在的以太坊网络的名称。``是合约 ABI 文件的本地路径。**Both --network 和 --abi 都是可选的。** -### From an Example Subgraph +### 基于子图示例 `graph init` 支持的第二种模式是从示例子图创建一个新项目。 以下命令执行此操作: @@ -40,7 +40,7 @@ The `` in this case is your github user or organization name, `/ [] ``` -The example subgraph is based on the Gravity contract by Dani Grant that manages user avatars and emits `NewGravatar` or `UpdateGravatar` events whenever avatars are created or updated. The subgraph handles these events by writing `Gravatar` entities to the Graph Node store and ensuring these are updated according to the events. Continue on to the [subgraph manifest](/developer/create-subgraph-hosted#the-subgraph-manifest) to better understand which events from your smart contracts to pay attention to, mappings, and more. +示例子图基于 Dani Grant 的 Gravity 合约,该合约管理用户头像并在创建或更新头像时发出 `NewGravatar` 或 `UpdateGravatar` 事件。 子图通过将 `Gravatar` 实体写入 Graph 节点存储并确保根据事件更新这些事件来处理这些事件。 继续查看[子图清单](/developer/create-subgraph-hosted#the-subgraph-manifest),以更好地了解您的智能合约中需要关注的事件、映射等。 ## 托管服务支持的网络 From dede7b5ab97afbdbf3d03c24fed17a5ec576e57b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:55 -0500 Subject: [PATCH 28/90] New translations billing.mdx (Chinese Simplified) --- pages/zh/studio/billing.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/zh/studio/billing.mdx b/pages/zh/studio/billing.mdx index cd0a7ff142e0..f83b46196159 100644 --- a/pages/zh/studio/billing.mdx +++ b/pages/zh/studio/billing.mdx @@ -46,7 +46,7 @@ title: 子图工作室的计费 title="YouTube video player" frameBorder="0" allowFullScreen - > +> ### 多重签名用户 From a73f337f39bd33bf3e7d0c8feff16be68d2c67da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:56 -0500 Subject: [PATCH 29/90] New translations multisig.mdx (Chinese Simplified) --- pages/zh/studio/multisig.mdx | 86 ++++++++++++++++++------------------ 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/pages/zh/studio/multisig.mdx b/pages/zh/studio/multisig.mdx index 41aba4457698..4a83b29f579b 100644 --- a/pages/zh/studio/multisig.mdx +++ b/pages/zh/studio/multisig.mdx @@ -1,82 +1,82 @@ --- -title: Using a Multisig Wallet +title: 使用多重签名钱包 --- -Subgraph Studio currently doesn't support signing with multisig wallets. Until then, you can follow this guide on how to publish your subgraph by invoking the [GNS contract](https://github.com/graphprotocol/contracts/blob/dev/contracts/discovery/GNS.sol) functions. +Subgraph Studio 目前不支持使用多重签名钱包进行签名。 在此之前,您可以按照本指南了解如何通过调用 [GNS 合约](https://github.com/graphprotocol/contracts/blob/dev/contracts/discovery/GNS.sol)函数来发布您的子图。 ### 创建子图 -Similary to using a regular wallet, you can create a subgraph by connecting your non-multisig wallet in Subgraph Studio. Once you connect the wallet, simply create a new subgraph. Make sure you fill out all the details, such as subgraph name, description, image, website, and source code url if applicable. +与使用普通钱包类似,您可以通过在 Subgraph Studio 中连接您的非多重签名钱包来创建子图。 连接钱包后,只需创建一个新的子图。 确保填写所有详细信息,例如子图名称、描述、图像、网站和源代码 Url(如果适用)。 -For initializing a starter subgraph, you can follow the commands shown in the UI, or simply run +要初始化起始子图,您可以按照 UI 中显示的命令进行操作,或者直接运行 ``` graph init --studio ``` -`SUBGRAPH_SLUG` is the name of your subgraph that you can copy from the UI, or from the URL in the browser. This command should create a folder in your file system with all the necessary files to start developing a subgraph. +`SUBGRAPH_SLUG` 是您可以从 UI 或浏览器中的 URL 复制的子图的名称。 此命令应在文件系统中创建一个文件夹,其中包含开始开发子图所需的所有文件。 -### Deploy a Subgraph +### 部署一个子图 -Once your subgraph is ready to be deployed to the graph node, simply follow the commands shown in the UI, or run the following command: +一旦您的子图准备好部署到图节点,只需按照 UI 中显示的命令,或运行以下命令: ``` graph deploy --studio ``` -**Note**: Make sure that you are inside of the subgraph folder before running the command. +**注意**:在运行命令之前,请确保您位于 subgraph 文件夹中。 -### Publish a Subgraph or a Version +### 发布子图或版本 -You can either publish a new subgraph to the decentralized network or publish a new version of the previously published subgraph. +您可以将新的子图发布到去中心化网络,也可以发布先前发布的子图的新版本。 -#### Publish a New Subgraph +#### 发布新子图 -There are a couple of ways to publish a subgraph using multisig wallets. Here we'll describe invoking the [`publishNewSubgraph`](https://github.com/graphprotocol/contracts/blob/dev/contracts/discovery/GNS.sol#L231) function in the [GNS contract](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825) using Etherscan. +有几种方法可以使用多重签名钱包发布子图。 在这里,我们将描述使用 Etherscan 在 [GNS 合约](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825)中调用[ publishNewSubgraph 函数](https://github.com/graphprotocol/contracts/blob/dev/contracts/discovery/GNS.sol#L231)。 -Before we use that function, we need to generate input arguments for it. Access [this page](https://thegraph.com/studio/multisig) in Subgraph Studio and provide the following: +在我们使用该函数之前,我们需要为其生成输入参数。 在 Subgraph Studio 中访问此[页面](https://thegraph.com/studio/multisig)并提供以下内容: -- Ethereum address of your multisig wallet -- Subgraph that you want to publish -- Version that you want to publish +- 你的多重签名钱包的以太坊地址 +- 您要发布的子图 +- 您要发布的版本 -After clicking on "Get Arguments", we'll generate all the contract arguments for you! +点击“获取参数”后,我们将为您生成所有合约参数! -There should be 4 arguments: +应该有4个参数: -- `graphAccount`: which is your multisig account address -- `subgraphDeploymentID`: the hex hash of the deployment ID for that subgraph -- `versionMetadata`: version metadata (label and description) that gets uploaded to IPFS. The hex hash value for that JSON file will be provided. -- `subgraphMetadata`: simlar to version metadata, subgraph metadata (name, image, description, website and source code url) gets uploaded to IPFS, and we provide the hex hash value for that JSON file +- `graphAccount`:这是您的多重签名帐户地址 +- `subgraphDeploymentID`:该子图的部署 ID 的十六进制哈希 +- `versionMetadata`:上传到 IPFS 的版本元数据(标签和描述)。 将提供该 JSON 文件的十六进制哈希值。 +- `subgraphMetadata`:类似于版本元数据,子图元数据(名称、图像、描述、网站和源代码 url)被上传到 IPFS,我们为该 JSON 文件提供十六进制哈希值 -With those 4 arguments, you should be able to: +使用这 4 个参数,您应该能够: -- Visit [our GraphProxy](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825#writeProxyContract) contract on Etherscan -- Connect to Etherscan using WalletConnect via the WalletConnect Safe app of your multisig -- Call the `publishNewSubgraph` method with the paramaters that were generated by our tool +- 在 Etherscan 上访问 [我们的 GraphProxy](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825#writeProxyContract) 合约 +- 通过您的多重签名的 WalletConnect Safe 应用程序使用 WalletConnect 连接到 Etherscan +- 使用我们的工具生成的参数调用 `publishNewS subgraph` 方法 -#### Publish a New Version +#### 发布新版本 -To publish a new version of an existing subgraph we first need to generate input arguments for it. Access [this page](https://thegraph.com/studio/multisig) in Subgraph Studio and provide: +要发布现有子图的新版本,我们首先需要为其生成输入参数。 在 Subgraph Studio 中访问 [此页面](https://thegraph.com/studio/multisig) 并提供: -- Ethereum address of your multisig wallet -- Subgraph that you want to publish -- Version that you want to publish -- The ID of the subgraph you want to update in Graph Explorer +- 你的多重签名钱包的以太坊地址 +- 您要发布的子图 +- 您要发布的版本 +- 您要在 Graph Explorer 中更新的子图的 ID -After clicking on "Get Arguments" we'll generate all the contract arguments for you! +单击“获取参数”后,我们将为您生成所有合同参数! -On the right side of the UI under the `Publish New Version` title, there should be 4 arguments: +在 UI 右侧的 `Publish New Version` 标题下,应该有 4 个参数: -- `graphAccount`: which is your Multisig account address -- `subgraphNumber`: is the number of your already published subgraph. It is a part of the subgraph id for a published subgraph queried through The Graph Network subgraph. -- `subgraphDeploymentID`: which is the hex hash of the deployment ID for that subgraph -- `versionMetadata`: version metadata (label and description) gets uploaded to IPFS, and we provide the hex hash value for that JSON file +- `graphAccount`:这是您的多重签名帐户地址 +- `subgraphNumber`:是您已经发布的子图的编号。 它是通过 The Graph Network 子图查询的已发布子图的子图 Id 的一部分。 +- `subgraphDeploymentID`:该子图的部署 ID 的十六进制哈希 +- `versionMetadata`:版本元数据(标签和描述)被上传到 IPFS,我们为该 JSON 文件提供十六进制哈希值 -Now that we generated all the arguments you are ready to proceed and call the `publishNewVersion` method. In order to do so, you should: +现在我们生成了所有参数,您可以继续并调用 `publishNewVersion` 方法。 为此,您应该: -- Visit [the GraphProxy](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825#writeProxyContract) contract on Etherscan -- Connect to Etherscan using WalletConnect via the WalletConnect Safe app of your Multisig -- Call the `publishNewVersion` method with the paramaters that were generated by our tool +- 在 Etherscan 上访问 [我们的 GraphProxy](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825#writeProxyContract) 合约 +- 通过您的多重签名的 WalletConnect Safe 应用程序使用 WalletConnect 连接到 Etherscan +- 使用我们的工具生成的参数调用 `publish Version` 方法 -Once the transaction is successful, your subgraph should have a new version of your subgraph in Graph Explorer which means that curators can start signaling on it and indexers can start indexing it. +事务成功后,您的子图应该在 Graph Explorer 中有一个新版本的子图,这意味着管理员可以开始对其发出信号,索引器可以开始对其进行索引。 From 52a95d04c2983f999236d9f9a698b7114949df6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:57 -0500 Subject: [PATCH 30/90] New translations studio-faq.mdx (Chinese Simplified) --- pages/zh/studio/studio-faq.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pages/zh/studio/studio-faq.mdx b/pages/zh/studio/studio-faq.mdx index 5fe212921a21..7cb6a7065869 100644 --- a/pages/zh/studio/studio-faq.mdx +++ b/pages/zh/studio/studio-faq.mdx @@ -20,8 +20,8 @@ title: 子图工作室常见问题 请记住,你可以创建一个 API 密钥并查询发布到网络上的任何子图,即使你自己建立了一个子图。 这些通过新的 API 密钥进行的查询,与网络上的任何其他查询一样,都是付费查询。 -### 5. How do I find query URLs for subgraphs if I’m not the developer of the subgraph I want to use? +### 5. 如果我不是我想使用的子图的开发者,我怎样才能找到子图的查询 URL? -You can find the query URL of each subgraph in the Subgraph Details section of The Graph Explorer. When you click on the “Query” button, you will be directed to a pane wherein you can view the query URL of the subgraph you’re interested in. You can then replace the `` placeholder with the API key you wish to leverage in the Subgraph Studio. +你可以在 The Graph Explorer 的 Subgraph Details 部分找到每个子图的查询 URL。 当你点击 "查询 "按钮时,你将被引导到一个窗格,在这里你可以查看你感兴趣的子图的查询 URL。 然后你可以把 `api_key` 占位符替换成你想在 Subgraph Studio 中利用的 API 密钥。 -Remember that you can create an API key and query any subgraph published to the network, even if you build a subgraph yourself. These queries via the new API key, are paid queries as any other on the network. +请记住,你可以创建一个 API 密钥并查询发布到网络上的任何子图,即使你自己建立了一个子图。 这些通过新的 API 密钥进行的查询,与网络上的任何其他查询一样,都是付费查询。 From 053e754f52bf4dbfd026bd56e1a1fdbfc8c05d71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:11:59 -0500 Subject: [PATCH 31/90] New translations subgraph-studio.mdx (Chinese Simplified) --- pages/zh/studio/subgraph-studio.mdx | 134 ++++++++++++++-------------- 1 file changed, 67 insertions(+), 67 deletions(-) diff --git a/pages/zh/studio/subgraph-studio.mdx b/pages/zh/studio/subgraph-studio.mdx index bb722e2a07cf..159e66c3684b 100644 --- a/pages/zh/studio/subgraph-studio.mdx +++ b/pages/zh/studio/subgraph-studio.mdx @@ -1,70 +1,70 @@ --- -title: How to Use the Subgraph Studio +title: 如何使用子图工作室 --- -Welcome to your new launchpad 👩🏽‍🚀 +欢迎使用您的新启动板👩🏽‍🚀 -The Subgraph Studio is your place to build and create subgraphs, add metadata, and publish them to the new decentralized Explorer (more on that [here](/explorer)). +Subgraph Studio 是您构建和创建子图、添加元数据并将其发布到新的分散式资源管理器的地方(更多关于[这里](/explorer))。 -What you can do in the Subgraph Studio: +您可以在 Subgraph Studio 中执行的操作: -- Create a subgraph through the Studio UI -- Deploy a subgraph using the CLI -- Publish a subgraph with the Studio UI -- Test it in the playground -- Integrate it in staging using the query URL -- Create and manage your API keys for specific subgraphs +- 通过 Studio UI 创建子图 +- 使用 CLI 部署子图 +- 使用 Studio UI 发布子图 +- 在面板上测试子图 +- 使用查询 URL 将其集成到暂存中 +- 为特定子图创建和管理 API 密钥 -Here in the Subgraph Studio, you have full control over your subgraphs. Not only can you test your subgraphs before you publish them, but you can also restrict your API keys to specific domains and only allow certain indexers to query from their API keys. +在 Subgraph Studio 中,您可以完全控制您的子图。 您不仅可以在发布子图之前对其进行测试,还可以将 API 密钥限制在特定域中,并且只允许某些索引器从其 API 密钥中进行查询。 -Querying subgraphs generates query fees, used to reward [indexers](/indexing) on the Graph network. If you’re a dapp developer or subgraph developer, the Studio will empower you to build better subgraphs to power your or your community’s queries. The Studio is comprised of 5 main parts: +查询子图会产生查询费,用于奖励 Graph 网络上的[索引人](/indexing)。 如果您是 dapp 开发人员或子图开发人员,Studio 将使您能够构建更好的子图来支持您或您的社区的查询。 Studio 由 5 个主要部分组成: -- Your user account controls -- A list of subgraphs that you’ve created -- A section to manage, view details, and visualize the status of a specific subgraph -- A section to manage your API keys that you will need to query a subgraph -- A section to manage your billing +- 您的用户帐户控制 +- 您创建的子图列表 +- 用于管理、查看详细信息和可视化特定子图状态的部分 +- 用于管理 API 密钥的部分,您需要查询子图 +- 管理帐单的部分 -## How to Create Your Account +## 如何创建您的帐户 -1. Sign in with your wallet - you can do this via MetaMask or WalletConnect -1. Once you sign in, you will see your unique deploy key in your account home page. This will allow you to either publish your subgraphs or manage your API keys + billing. You will have a unique deploy key that can be re-generated if you think it has been compromised. +1. 使用您的钱包登录 - 您可以通过 MetaMask 或 WalletConnect 进行此操作 +1. 登录后,您将在帐户主页中看到您唯一的部署密钥。 这将允许您发布您的子图或管理您的 API 密钥 + 计费。 如果您认为它已被泄露,您将拥有一个可以重新生成的唯一部署密钥。 -## How to Create your Subgraph in Subgraph Studio +## 如何在 Subgraph Studio 中创建子图 -The best part! When you first create a subgraph, you’ll be directed to fill out: +最好的部分! 当您第一次创建子图时,您将被指示填写: -- Your Subgraph Name -- Image +- 您的子图名称 +- 图片 - 描述 -- Categories -- Website +- 类别 +- 网站 -## Subgraph Compatibility with The Graph Network +## 子图与The Graph网络的兼容性 -The Graph Network is not yet able to support all of the data-sources & features available on the Hosted Service. In order to be supported by indexers on the network, subgraphs must: +The Graph 网络还不能支持所有的数据源和 托管服务上可用的功能。 为了被网络上的索引器支持,子图必须: -- Index mainnet Ethereum -- Must not use any of the following features: +- 索引主网以太坊 +- 不得使用以下任何功能: - ipfs.cat & ipfs.map - - Non-fatal errors + - 非致命错误 - Grafting -More features & networks will be added to The Graph Network incrementally. +更多功能和 网络将逐渐添加到 The Graph Network。 -### Subgraph lifecycle flow +### 子图生命周期流程 -![Subgraph Lifecycle](/img/subgraph-lifecycle.png) +![子图生命周期](/img/subgraph-lifecycle.png) -After you have created your subgraph, you will be able to deploy it using the [CLI](https://github.com/graphprotocol/graph-cli), or command line interface. Deploying a subgraph with the CLI will push the subgraph to the Studio where you’ll be able to test subgraphs using the playground. This will eventually allow you to publish to the Graph Network. For more information on CLI setup, [check this out](/developer/define-subgraph-hosted#install-the-graph-cli) (pst, make sure you have your deploy key on hand). Remember, deploying is **not the same as** publishing. When you deploy a subgraph, you just push it to the Studio where you’re able to test it. Versus, when you publish a subgraph, you are publishing it on-chain. +创建子图后,您将能够使用 [CLI](https://github.com/graphprotocol/graph-cli) 或命令行界面来部署它。 使用 CLI 部署子图会将子图推送到 Studio,您可以在其中使用 Playground 测试子图。 这最终将允许您发布到 Graph Network。 有关 CLI 设置的更多信息,[检查一下](/developer/define-subgraph-hosted#install-the-graph-cli)(pst,确保您手头有部署密钥). 请记住,部署是**与**发布不同。 当您部署一个子图时,您只需将其推送到您可以对其进行测试的 Studio。 相反,当你发布一个子图时,你是在链上发布它。 -## Testing your Subgraph in Subgraph Studio +## 在 Subgraph Studio 中测试您的子图 -If you’d like to test your subgraph before publishing it to the network, you can do this in the Subgraph **Playground** or look at your logs. The Subgraph logs will tell you **where** your subgraph fails in the case that it does. +如果您想在将子图发布到网络之前对其进行测试,您可以在子图 **Playground** 中执行此操作或查看您的日志。 子图日志将告诉您**在哪里**您的子图在失败的情况下失败。 -## Publish your Subgraph in Subgraph Studio +## 在 Subgraph Studio 中发布您的子图 -You’ve made it this far - congrats! Publishing your subgraph means that an IPFS hash was generated when you deployed the subgraph within the CLI and is stored in the network’s Ethereum smart contracts. In order to publish your subgraph successfully, you’ll need to go through the following steps outlined in this [blog](https://thegraph.com/blog/building-with-subgraph-studio). Check out the video overview below as well: +你已经做到了这一点 - 恭喜! 发布子图意味着当您在 CLI 中部署子图时会生成 IPFS 哈希,并存储在网络的以太坊智能合约中。 为了成功发布您的子图,您需要完成此[博客](https://thegraph.com/blog/building-with-subgraph-studio)中列出的以下步骤. 还请查看下面的视频概述:
+>
-Remember, while you’re going through your publishing flow, you’ll be able to push to either mainnet or Rinkeby, the testnet we support. If you’re a first time subgraph developer, we highly suggest you start with publishing to Rinkeby, which is free to do. This will allow you to see how the subgraph will work in The Graph Explorer and will allow you to test curation elements. +请记住,在您完成发布流程时,您将能够推送到我们支持的测试网主网或 Rinkeby。 如果您是第一次开发子图,我们强烈建议您从发布到 Rinkeby 开始,这是免费的。 这将允许您查看子图在 The Graph Explorer 中的工作方式,并允许您测试管理元素。 -You’ll only be able to index data from mainnet (even if your subgraph was published to a testnet) because only subgraphs that are indexing mainnet data can be published to the network. This is because indexers need to submit mandatory Proof of Indexing records as of a specific block hash. Because publishing a subgraph is an action taken on-chain, remember that the transaction can take up to a few minutes to go through. Any address you use to publish the contract will be the only one able to publish future versions. Choose wisely! +您只能从主网索引数据(即使您的子图已发布到测试网),因为只有索引主网数据的子图才能发布到网络。 这是因为索引人需要提交针对特定块哈希的强制性索引证明记录。 因为发布子图是在链上采取的行动,请记住,交易可能需要几分钟才能完成。 您用于发布合约的任何地址都将是唯一能够发布未来版本的地址。 做出明智的选择! -Subgraphs with curation signal are shown to Indexers so that they can be indexed on the decentralized network. You can publish subgraphs and signal in one transaction, which allows you to mint the first curation signal on the subgraph and saves on gas costs. By adding your signal to the signal later provided by Curators, your subgraph will also have a higher chance of ultimately serving queries. +具有管理信号的子图显示给索引人,以便它们可以在去中心化网络上被索引。 您可以在一个事务中发布子图和信号,这允许您在子图上创建第一个管理信号并节省气体成本。 通过将您的信号添加到策展人稍后提供的信号中,您的子图也将有更高的机会最终提供查询。 -**Now that you’ve published your subgraph, let’s get into how you’ll manage them on a regular basis.** Note that you cannot publish your subgraph to the network if it has failed syncing. This is usually because the subgraph has bugs - the logs will tell you where those issues exist! +**现在您已经发布了您的子图,让我们来看看您将如何定期管理它们。**请注意,如果您的子图有 同步失败。 这通常是因为子图有错误 - 日志会告诉您这些问题存在于哪里! -## Versioning your Subgraph with the CLI +## 使用 CLI 对子图进行版本控制 -Developers might want to update their subgraph, for a variety of reasons. When this is the case, you can deploy a new version of your subgraph to the Studio using the CLI (it will only be private at this point) and if you are happy with it, you can publish this new deployment to The Graph Explorer. This will create a new version of your subgraph that curators can start signaling on and indexers will be able to index this new version. +出于各种原因,开发人员可能想要更新他们的子图。 在这种情况下,您可以使用 CLI 将新版本的子图部署到 Studio(此时它只是私有的),如果您对它感到满意,您可以将此新部署发布到 Graph Explorer。 这将创建一个新版本的子图,策展人可以开始发出信号,索引人将能够索引这个新版本。 -Up until recently, developers were forced to deploy and publish a new version of their subgraph to the Explorer to update the metadata of their subgraphs. Now, developers can update the metadata of their subgraphs **without having to publish a new version**. Developers can update their subgraph details in the Studio (under profile picture, name, description, etc) by checking an option called **Update Details** in The Graph Explorer. If this is checked, an on-chain transaction will be generated that updates subgraph details in the Explorer without having to publish a new version with a new deployment. +直到最近,开发人员还被迫将其子图的新版本部署并发布到 Explorer 以更新其子图的元数据。 现在,开发人员可以更新其子图的元数据**而无需发布新版本**。 开发人员可以通过选中图形资源管理器中名为 **Update Details** 的选项来更新 Studio 中的子图详细信息(在个人资料图片、名称、描述等下)。 如果选中此项,将生成一个链上事务,更新资源管理器中的子图详细信息,而无需发布具有新部署的新版本。 -Please note that there are costs associated with publishing a new version of a subgraph to the network. In addition to the transaction fees, developers must also fund a part of the curation tax on auto-migrating signal. You cannot publish a new version of your subgraph if curators have not signaled on it. For more information on the risks of curation, please read more [here](/curating). +请注意,将新版本的子图发布到网络会产生成本。 除了交易费用外,开发人员还必须为自动迁移信号的一部分管理税提供资金。 如果策展人没有发出信号,您将无法发布子图的新版本。 有关策展风险的更多信息,请阅读更多[此处](/curating)。 -### Automatic Archiving of Subgraph Versions +### 子图版本的自动归档 -Whenever you deploy a new subgraph version in the Subgraph Studio, the previous version will be archived. Archived versions won't be indexed/synced and therefore cannot be queried. You can unarchive an archived version of your subgraph in the Studio UI. Please note that previous versions of non-published subgraphs deployed to the Studio will be automatically archived. +每当您在 Subgraph Studio 中部署新的子图版本时,都会归档以前的版本。 存档版本不会被索引/同步,因此无法查询。 您可以在 Studio UI 中取消存档子图的存档版本。 请注意,部署到 Studio 的以前版本的未发布子图将被自动存档。 -![Subgraph Studio - Unarchive](/img/Unarchive.png) +![Subgraph Studio - 取消归档](/img/Unarchive.png) -## Managing your API Keys +## 管理您的 API 密钥 -Regardless of whether you’re a dapp developer or a subgraph developer, you’ll need to manage your API keys. This is important for you to be able to query subgraphs because API keys make sure the connections between application services are valid and authorized. This includes authenticating the end user and the device using the application. +无论您是 dapp 开发人员还是子图开发人员,您都需要管理您的 API 密钥。 这对于您能够查询子图很重要,因为 API 密钥确保应用程序服务之间的连接有效且经过授权。 这包括验证最终用户和使用应用程序的设备。 -The Studio will list out existing API keys, which will give you the ability to manage or delete them. +Studio 将列出现有的 API 密钥,这将使您能够管理或删除它们。 -1. The **Overview** section will allow you to: - - Edit your key name - - Regenerate API keys - - View the current usage of the API key with stats: - - Number of queries - - Amount of GRT spent -2. Under **Manage Security Settings**, you’ll be able to opt into security settings depending on the level of control you’d like to have over your API keys. In this section, you can: - - View and manage the domain names authorized to use your API key - - Assign subgraphs that can be queried with your API key +1. **概述**部分将允许您: + - 编辑您的密钥名称 + - 重新生成 API 密钥 + - 使用统计信息查看 API 密钥的当前使用情况: + - 查询数 + - 花费的 GRT 金额 +2. 在**管理安全设置**下,您可以根据自己对 API 密钥的控制级别选择启用安全设置。 在本节中,您可以: + - 查看和管理授权使用您的 API 密钥的域名 + - 分配可以使用您的 API 密钥查询的子图 -## How to Manage your Subgraph +## 如何管理您的子图 -API keys aside, you’ll have many tools at your disposal to manage your subgraphs. You can organize your subgraphs by their **status** and **category**. +除了 API 密钥,您还可以使用许多工具来管理子图。 您可以按子图的**状态**和**类别**来组织子图。 -- The **Status** tag allows you to pick between a variety of tags including ``, ``, ``, ``, etc. -- Meanwhile, **Category** allows you to designate what category your subgraph falls into. Options include ``, ``, ``, etc. +- **Status** 标签允许您在各种标签之间进行选择,包括 ``、`` 、``、``等。 +- 同时,**Category** 允许您指定您的子图属于哪个类别。 选项包括``、``、``等。 From 2a755fb5099e8ba6047c0b82759d75f26811e945 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:12:01 -0500 Subject: [PATCH 32/90] New translations near.mdx (Chinese Simplified) --- pages/zh/supported-networks/near.mdx | 116 +++++++++++++-------------- 1 file changed, 58 insertions(+), 58 deletions(-) diff --git a/pages/zh/supported-networks/near.mdx b/pages/zh/supported-networks/near.mdx index 352a54c0b3c4..8f192167f8b2 100644 --- a/pages/zh/supported-networks/near.mdx +++ b/pages/zh/supported-networks/near.mdx @@ -72,24 +72,24 @@ dataSources: file: ./src/mapping.ts # link to the file with the Assemblyscript mappings ``` -- NEAR subgraphs introduce a new `kind` of data source (`near`) -- The `network` should correspond to a network on the hosting Graph Node. On the Hosted Service, NEAR's mainnet is `near-mainnet`, and NEAR's testnet is `near-testnet` -- NEAR data sources introduce an optional `source.account` field, which is a human readable ID corresponding to a [NEAR account](https://docs.near.org/docs/concepts/account). This can be an account, or a sub account. +- NEAR 子图引入了一种新的 `kind` 数据源(`near`) +- `network` 应该对应于托管图形节点上的网络。 在 Hosted Service 上,NEAR 的主网是 `near-mainnet`,NEAR 的测试网是 `near-testnet` +- NEAR 数据源引入了一个可选的 `source.account` 字段,这是一个人类可读的 ID,对应于 [NEAR 帐户](https://docs.near.org/docs/concepts/account)。 这可以是一个帐户,也可以是一个子帐户。 -NEAR data sources support two types of handlers: +NEAR 数据源支持两种类型的处理程序: -- `blockHandlers`: run on every new NEAR block. No `source.account` is required. -- `receiptHandlers`: run on every receipt where the data source's `source.account` is the recipient. Note that only exact matches are processed ([subaccounts](https://docs.near.org/docs/concepts/account#subaccounts) must be added as independent data sources). +- `blockHandlers`:在每个新的 NEAR 块上运行。 不需要 `source.account`。 +- `receiptHandlers`:在数据源的 `source.account` 为接收者的每张收据上运行。 请注意,仅处理完全匹配([子帐户](https://docs.near.org/docs/concepts/account#subaccounts)必须作为独立数据源添加)。 -### Schema Definition +### 模式定义 -Schema definition describes the structure of the resulting subgraph database, and the relationships between entities. This is agnostic of the original data source. There are more details on subgraph schema definition [here](/developer/create-subgraph-hosted#the-graphql-schema). +模式定义描述了生成的子图数据库的结构,以及实体之间的关系。 这与原始数据源无关。 [这里](/developer/create-subgraph-hosted#the-graphql-schema)有更多关于子图模式定义的细节。 -### AssemblyScript Mappings +### AssemblyScript 映射 -The handlers for processing events are written in [AssemblyScript](https://www.assemblyscript.org/). +处理事件的处理程序是用 [AssemblyScript](https://www.assemblyscript.org/) 编写的。 -NEAR indexing introduces NEAR-specific data types to the [AssemblyScript API](/developer/assemblyscript-api). +NEAR 索引将 NEAR 特定的数据类型引入 [AssemblyScript API](/developer/assemblyscript-api)。 ```typescript @@ -151,50 +151,50 @@ class ReceiptWithOutcome { } ``` -These types are passed to block & receipt handlers: +这些类型被传递给 block & 收据处理程序: -- Block handlers will receive a `Block` -- Receipt handlers will receive a `ReceiptWithOutcome` +- 块处理程序将收到一个 `Block` +- 收据处理程序将收到 `ReceiptWithOutcome` -Otherwise the rest of the [AssemblyScript API](/developer/assemblyscript-api) is available to NEAR subgraph developers during mapping execution. +否则,在映射执行期间 NEAR 子图开发人员可以使用 [AssemblyScript API](/developer/assemblyscript-api) 的其余部分。 -This includes a new JSON parsing function - logs on NEAR are frequently emitted as stringified JSONs. A new `json.fromString(...)` function is available as part of the [JSON API](/developer/assemblyscript-api#json-api) to allow developers to easily process these logs. +这包括一个新的 JSON 解析功能 - NEAR 上的日志经常作为字符串化 JSON 发出。 一个新的 `json.fromString(...)` 函数作为 [JSON API](/developer/assemblyscript-api#json-api) 的一部分提供给开发人员 轻松处理这些日志。 -## Deploying a NEAR Subgraph +## 部署 NEAR 子图 -Once you have a built subgraph, it is time to deploy it to Graph Node for indexing. NEAR subgraphs can be deployed to any Graph Node `>=v0.26.x` (this version has not yet been tagged & released). +构建子图后,就可以将其部署到 Graph Node 以进行索引了。 NEAR 子图可以部署到任何图节点 `>=v0.26.x`(此版本尚未标记和发布)。 -The Graph's Hosted Service currently supports indexing NEAR mainnet and testnet in beta, with the following network names: +Graph 的托管服务目前支持索引 NEAR 主网和 beta 测试网,具有以下网络名称: -- `near-mainnet` -- `near-testnet` +- `near主网` +- `near-测试网` -More information on creating and deploying subgraphs on the Hosted Service can be found [here](/hosted-service/deploy-subgraph-hosted). +有关在托管服务上创建和部署子图的更多信息,请参见[此处](/hosted-service/deploy-subgraph-hosted)。 -As a quick primer - the first step is to "create" your subgraph - this only needs to be done once. On the Hosted Service, this can be done from [your Dashboard](https://thegraph.com/hosted-service/dashboard): "Add Subgraph". +作为一个快速入门 - 第一步是“创建”你的子图 - 这只需要完成一次。 在托管服务上,这可以通过[您的仪表板](https://thegraph.com/hosted-service/dashboard):“添加子图”来完成。 -Once your subgraph has been created, you can deploy your subgraph by using the `graph deploy` CLI command: +创建子图后,您可以使用 `graph deploy` CLI 命令部署子图: ``` $ graph create --node subgraph/name # creates a subgraph on a local Graph Node (on the Hosted Service, this is done via the UI) $ graph deploy --node --ipfs https://api.thegraph.com/ipfs/ # uploads the build files to a specified IPFS endpoint, and then deploys the subgraph to a specified Graph Node based on the manifest IPFS hash ``` -The node configuration will depend where the subgraph is being deployed. +节点配置将取决于子图的部署位置。 -#### Hosted Service: +#### 托管服务: ``` graph deploy --node https://api.thegraph.com/deploy/ --ipfs https://api.thegraph.com/ipfs/ --access-token ``` -#### Local Graph Node (based on default configuration): +#### 本地Graph节点(基于默认配置): ``` graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 ``` -Once your subgraph has been deployed, it will be indexed by Graph Node. You can check its progress by querying the subgraph itself: +部署子图后,它将由 Graph Node 索引。 您可以通过查询子图本身来检查其进度: ``` { @@ -204,62 +204,62 @@ Once your subgraph has been deployed, it will be indexed by Graph Node. You can } ``` -### Indexing NEAR with a Local Graph Node +### 使用本地Graph节点索引 NEAR -Running a Graph Node that indexes NEAR has the following operational requirements: +运行索引 NEAR 的 Graph Node 有以下操作要求: -- NEAR Indexer Framework with Firehose instrumentation -- NEAR Firehose Component(s) -- Graph Node with Firehose endpoint configured +- 带有 Firehose 工具的 NEAR 索引人框架 +- NEAR Firehose 组件 +- 配置了 Firehose 端点的Graph节点 -We will provide more information on running the above components soon. +我们将很快提供有关运行上述组件的更多信息。 -## Querying a NEAR Subgraph +## 查询 NEAR 子图 -The GraphQL endpoint for NEAR subgraphs is determined by the schema definition, with the existing API interface. Please visit the [GraphQL API documentation](/developer/graphql-api) for more information. +NEAR 子图的 GraphQL 端点由架构定义确定,具有现有的 API 接口。 请访问 [GraphQL API 文档](/developer/graphql-api) 了解更多信息。 -## Example Subgraphs +## 示例子图 -Here are some example subgraphs for reference: +以下是一些示例子图供参考: -[NEAR Blocks](https://github.com/graphprotocol/example-subgraph/tree/near-blocks-example) +[NEAR块](https://github.com/graphprotocol/example-subgraph/tree/near-blocks-example) -[NEAR Receipts](https://github.com/graphprotocol/example-subgraph/tree/near-receipts-example) +[NEAR收据](https://github.com/graphprotocol/example-subgraph/tree/near-receipts-example) ## 常见问题 -### How does the beta work? +### 测试版是如何工作的? -NEAR support is in beta, which means that there may be changes to the API as we continue to work on improving the integration. Please email near@thegraph.com so that we can support you in building NEAR subgraphs, and keep you up to date on the latest developments! +NEAR 支持处于测试阶段,这意味着随着我们继续致力于改进集成,API 可能会发生变化。 请发送电子邮件至 near@thegraph.com,以便我们支持您构建 NEAR 子图,并让您了解最新进展! -### Can a subgraph index both NEAR and EVM chains? +### 子图可以同时索引 NEAR 和 EVM 链吗? -No, a subgraph can only support data sources from one chain / network. +不,一个子图只能支持来自一个链/网络的数据源。 -### Can subgraphs react to more specific triggers? +### 子图可以对更具体的触发器做出反应吗? -Currently, only Block and Receipt triggers are supported. We are investigating triggers for function calls to a specified account. We are also interested in supporting event triggers, once NEAR has native event support. +目前,仅支持 Block 和 Receipt 触发器。 我们正在调查对指定帐户的函数调用的触发器。 一旦 NEAR 拥有原生事件支持,我们也对支持事件触发器感兴趣。 -### Will receipt handlers trigger for accounts and their sub accounts? +### 收据处理程序会触发帐户及其子帐户吗? -Receipt handlers will only be triggered for the exact-match of the named account. More flexibility may be added in future. +收据处理程序只会在与指定帐户完全匹配的情况下触发。 未来可能会增加更多的灵活性。 -### Can NEAR subgraphs make view calls to NEAR accounts during mappings? +### NEAR 子图可以在映射期间对 NEAR 帐户进行视图调用吗? -This is not supported. We are evaluating whether this functionality is required for indexing. +这是不支持的。 我们正在评估索引是否需要此功能。 -### Can I use data source templates in my NEAR subgraph? +### 我可以在 NEAR 子图中使用数据源模板吗? -This is not currently supported. We are evaluating whether this functionality is required for indexing. +目前不支持此功能。 我们正在评估索引是否需要此功能。 -### Ethereum subgraphs support "pending" and "current" versions, how can I deploy a "pending" version of a NEAR subgraph? +### 以太坊子图支持“待定”和“当前”版本,如何部署 NEAR 子图的“待定”版本? -Pending functionality is not yet supported for NEAR subgraphs. In the interim, you can deploy a new version to a different "named" subgraph, and then when that is synced with the chain head, you can redeploy to your primary "named" subgraph, which will use the same underlying deployment ID, so the main subgraph will be instantly synced. +NEAR 子图尚不支持挂起的功能。 在此期间,您可以将新版本部署到不同的“命名”子图,然后当它与链头同步时,您可以重新部署到您的主“命名”子图,它将使用相同的底层部署 ID,所以 主子图将立即同步。 -### My question hasn't been answered, where can I get more help building NEAR subgraphs? +### 我的问题尚未得到解答,在哪里可以获得更多构建 NEAR 子图的帮助? -If it is a general question about subgraph development, there is a lot more information in the rest of the [Developer documentation](/developer/quick-start). Otherwise please join [The Graph Protocol Discord](https://discord.gg/vtvv7FP) and ask in the #near channel, or email near@thegraph.com. +如果是关于子图开发的一般性问题,[开发者文档](/developer/quick-start)的其余部分提供了更多信息。 否则,请加入 [The Graph Protocol Discord](https://discord.gg/vtvv7FP) 并在#near 频道中提问,或发送电子邮件至 near@thegraph.com。 -## References +## 参考 -- [NEAR developer documentation](https://docs.near.org/docs/develop/basics/getting-started) +- [NEAR 开发者文档](https://docs.near.org/docs/develop/basics/getting-started) From 107c98f9dea92d1ad9a8470b24314ae6f3439b72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Tue, 1 Mar 2022 04:12:03 -0500 Subject: [PATCH 33/90] New translations delegating.mdx (Chinese Simplified) --- pages/zh/delegating.mdx | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/pages/zh/delegating.mdx b/pages/zh/delegating.mdx index d63360b6a0ed..e40bb06c8497 100644 --- a/pages/zh/delegating.mdx +++ b/pages/zh/delegating.mdx @@ -1,5 +1,5 @@ --- -title: 委托 +title: 委托人 --- 委托人不能因为不良行为而被取消,但对委托有存款税,以抑制可能损害网络完整性的不良决策。 @@ -32,7 +32,9 @@ title: 委托 索引奖励分成- 索引奖励分成是指索引人将为自己保留的那部分奖励。 这意味着,如果它被设置为 100%,作为一个委托人,你将获得 0 个索引奖励。 如果你在 UI 中看到 80%,这意味着作为委托人,你将获得 20%。 一个重要的说明 -在网络的初期,索引奖励将占奖励的大部分比重。 -
请注意委托用户界面中的0.5%费用,以及28天的解约期。
+
+ 请注意委托用户界面中的0.5%费用,以及28天的解约期。 +
### 选择一个为委托人提供公平的奖励分配的值得信赖的索引人 @@ -50,7 +52,7 @@ title: 委托 ### 计算委托人的预期收益 -A Delegator has to consider a lot of factors when determining the return. These include: +委托人在确定收益时必须考虑很多因素。 这些因素解释如下 : - 有技术的委托人还可以查看索引人使用他们可用的委托代币的能力。 如果索引人没有分配所有可用的代币,他们就不会为自己或他们的委托人赚取最大利润。 - 现在在网络中,索引人可以选择关闭分配并在 1 到 28 天之间的任何时间收集奖励。 因此,索引人可能有很多尚未收集的奖励,因此他们的总奖励很低。 早期应该考虑到这一点。 @@ -77,11 +79,11 @@ A Delegator has to consider a lot of factors when determining the return. These 使用这个公式,我们可以看到实际上只向委托人提供 20%的索引人比给索引人提供 90%的索引人实际上给予委托人更好的奖励。 -Therefore a Delegator should always consider the Delegation Capacity of an Indexer, and factor it into their decision making. +因此,委托人应始终考虑索引人的接受委托数量的容量,并将其纳入决策。 ## 网络界面视频指南 -This guide provides a full review of this document, and how to consider everything in this document while interacting with the UI. +本指南提供了对本文档的完整检阅,以及如何在与 UI 交互时考虑本文档中的所有内容。
+>
From 897b9eb3d7f582b49379278ff42c82d2527ee88b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Wed, 2 Mar 2022 21:05:30 -0500 Subject: [PATCH 34/90] New translations subgraph-debug-forking.mdx (Spanish) --- pages/es/developer/subgraph-debug-forking.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pages/es/developer/subgraph-debug-forking.mdx b/pages/es/developer/subgraph-debug-forking.mdx index 03e711bc6ee9..025911c2b6d4 100644 --- a/pages/es/developer/subgraph-debug-forking.mdx +++ b/pages/es/developer/subgraph-debug-forking.mdx @@ -2,7 +2,7 @@ title: Depuración rápida y sencilla de subgrafos mediante forks --- -> Note: this is only available from this `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) or this [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) onwards, it hasn't been yet released in a minor release (eg: 0.26.0) +> Nota: este es solo disponible desde este `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) o este [docker tag](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) en adelante, todavía no se ha publicado en una versión menor (por ejemplo: 0.26.0) Al igual que con muchos sistemas que procesan grandes cantidades de datos, los indexadores de The Graph (Graph Nodes) pueden tardar bastante en sincronizar su subgrafo con la blockchain de destino. La discrepancia entre los cambios rápidos con fines de depuración y los largos tiempos de espera necesarios para la indexación es extremadamente contraproducente y somos muy conscientes de ello. Por eso introducimos **subgraph forking**, desarrollados por [LimeChain](https://limechain.tech/), y en este artículo te mostramos cómo se puede utilizar esta función para acelerar sustancialmente la depuración del subgrafo! @@ -16,7 +16,7 @@ En el contexto de la depuración, **subgraph forking** te permite depurar tu sub Cuando implementas un subgrafo en un nodo Graph remoto para la indexación y falla en el bloque _X_, la buena noticia es que el nodo Graph seguirá atendiendo consultas de GraphQL usando su tienda, que está sincronizado para bloquear _X_. ¡Genial! Esto significa que podemos aprovechar esta tienda "actualizada" para corregir los errores que surgen al indexar el bloque _X_. -En pocas palabras, vamos a _bifurcar el subgrafo fallido_ desde un nodo de Graph remoto que garantiza que el subgrafo se indexe para bloquear _X_ para proporcionar al subgrafo implementado localmente que se está depurando en el bloque _X_ una vista actualizada del estado de indexación. +En pocas palabras, vamos a _bifurcar el subgrafo fallido_ desde un nodo de Graph remoto que garantiza que el subgrafo se indexe para bloquear *X* para proporcionar al subgrafo implementado localmente que se está depurando en el bloque _X_ una vista actualizada del estado de indexación. ## ¡Por favor, muéstrame algo de código! @@ -46,7 +46,7 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -Vaya, qué desafortunado, cuando implemento mi subgrafo de aspecto perfecto en el [HostedService](https://thegraph.com/hosted-service/), falla con el _"¡Gravatar no encontrado!"_ error. +Vaya, qué desafortunado, cuando implemento mi subgrafo de aspecto perfecto en el [HostedService](https://thegraph.com/hosted-service/), falla con el *"¡Gravatar no encontrado!"* error. La forma habitual de intentar una solución es: From 250b3afce3e315b2a7a5aedb2f592fe110845f3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:03:54 -0500 Subject: [PATCH 35/90] New translations assemblyscript-migration-guide.mdx (Spanish) --- pages/es/developer/assemblyscript-migration-guide.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pages/es/developer/assemblyscript-migration-guide.mdx b/pages/es/developer/assemblyscript-migration-guide.mdx index ceb0cd2c2298..191d1afb6c4e 100644 --- a/pages/es/developer/assemblyscript-migration-guide.mdx +++ b/pages/es/developer/assemblyscript-migration-guide.mdx @@ -176,7 +176,8 @@ let c: usize = a + (b as usize) // upcasting on class inheritance class Bytes extends Uint8Array {} -let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array +let bytes = new Bytes(2) +// bytes // same as: bytes as Uint8Array ``` Hay dos escenarios en los que puede querer cast, pero usando `as`/`var` **no es seguro**: @@ -188,7 +189,8 @@ Hay dos escenarios en los que puede querer cast, pero usando `as`/`var` **no // downcasting on class inheritance class Bytes extends Uint8Array {} -let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( +let uint8Array = new Uint8Array(2) +// uint8Array // breaks in runtime :( ``` ```typescript @@ -196,7 +198,8 @@ let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( class Bytes extends Uint8Array {} class ByteArray extends Uint8Array {} -let bytes = new Bytes(2) < ByteArray > bytes // breaks in runtime :( +let bytes = new Bytes(2) +// bytes // breaks in runtime :( ``` Para esos casos, puedes usar la función `changetype`: From 90b713587cf49147dd95c32bd9d791c8346a59ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:03:55 -0500 Subject: [PATCH 36/90] New translations assemblyscript-migration-guide.mdx (Arabic) --- pages/ar/developer/assemblyscript-migration-guide.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pages/ar/developer/assemblyscript-migration-guide.mdx b/pages/ar/developer/assemblyscript-migration-guide.mdx index 4acb088e8fd0..3e5ea9d0315d 100644 --- a/pages/ar/developer/assemblyscript-migration-guide.mdx +++ b/pages/ar/developer/assemblyscript-migration-guide.mdx @@ -176,7 +176,8 @@ let c: usize = a + (b as usize) // upcasting on class inheritance class Bytes extends Uint8Array {} -let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array +let bytes = new Bytes(2) +// bytes // same as: bytes as Uint8Array ``` هناك سيناريوهين قد ترغب في ال cast ، ولكن استخدام `as`/`var` ** ليس آمنا **: @@ -188,7 +189,8 @@ let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array // downcasting on class inheritance class Bytes extends Uint8Array {} -let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( +let uint8Array = new Uint8Array(2) +// uint8Array // breaks in runtime :( ``` ```typescript @@ -196,7 +198,8 @@ let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( class Bytes extends Uint8Array {} class ByteArray extends Uint8Array {} -let bytes = new Bytes(2) < ByteArray > bytes // breaks in runtime :( +let bytes = new Bytes(2) +// bytes // breaks in runtime :( ``` في هذه الحالة يمكنك إستخدام دالة `changetype`: From 7b721fff8cd4439b8fa879be02f1fc6073c7591d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:03:57 -0500 Subject: [PATCH 37/90] New translations assemblyscript-migration-guide.mdx (Japanese) --- pages/ja/developer/assemblyscript-migration-guide.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pages/ja/developer/assemblyscript-migration-guide.mdx b/pages/ja/developer/assemblyscript-migration-guide.mdx index 5712183d4b4d..8ab20ff7685d 100644 --- a/pages/ja/developer/assemblyscript-migration-guide.mdx +++ b/pages/ja/developer/assemblyscript-migration-guide.mdx @@ -176,7 +176,8 @@ let c: usize = a + (b as usize) // upcasting on class inheritance class Bytes extends Uint8Array {} -let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array +let bytes = new Bytes(2) +// bytes // same as: bytes as Uint8Array ``` キャストしたくても、`as`/`var`を使うと**安全ではない**というシナリオが 2 つあります。 @@ -188,7 +189,8 @@ let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array // downcasting on class inheritance class Bytes extends Uint8Array {} -let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( +let uint8Array = new Uint8Array(2) +// uint8Array // breaks in runtime :( ``` ```typescript @@ -196,7 +198,8 @@ let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( class Bytes extends Uint8Array {} class ByteArray extends Uint8Array {} -let bytes = new Bytes(2) < ByteArray > bytes // breaks in runtime :( +let bytes = new Bytes(2) +// bytes // breaks in runtime :( ``` このような場合には、`changetype`関数を使用します。 From ab0b666422d162dca87cb41ed15c27f99782ea20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:03:58 -0500 Subject: [PATCH 38/90] New translations assemblyscript-migration-guide.mdx (Korean) --- pages/ko/developer/assemblyscript-migration-guide.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pages/ko/developer/assemblyscript-migration-guide.mdx b/pages/ko/developer/assemblyscript-migration-guide.mdx index 883f381e9941..1c66f3c58257 100644 --- a/pages/ko/developer/assemblyscript-migration-guide.mdx +++ b/pages/ko/developer/assemblyscript-migration-guide.mdx @@ -176,7 +176,8 @@ let c: usize = a + (b as usize) // upcasting on class inheritance class Bytes extends Uint8Array {} -let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array +let bytes = new Bytes(2) +// bytes // same as: bytes as Uint8Array ``` 어느 부분에선 캐스트하고 싶지만, `as`/`var`를 사용하는 것은 **안전하지 않은** 두 가지 시나리오가 존재합니다. @@ -188,7 +189,8 @@ let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array // downcasting on class inheritance class Bytes extends Uint8Array {} -let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( +let uint8Array = new Uint8Array(2) +// uint8Array // breaks in runtime :( ``` ```typescript @@ -196,7 +198,8 @@ let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( class Bytes extends Uint8Array {} class ByteArray extends Uint8Array {} -let bytes = new Bytes(2) < ByteArray > bytes // breaks in runtime :( +let bytes = new Bytes(2) +// bytes // breaks in runtime :( ``` 이러한 경우들에는 `changetype` 기능을 사용할 수 있습니다: From 2b7edb4d63fa931c9a2164683b146447d5e4d8e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:03:59 -0500 Subject: [PATCH 39/90] New translations assemblyscript-migration-guide.mdx (Chinese Simplified) --- pages/zh/developer/assemblyscript-migration-guide.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pages/zh/developer/assemblyscript-migration-guide.mdx b/pages/zh/developer/assemblyscript-migration-guide.mdx index 324f0534aa7a..ca5013b93cb6 100644 --- a/pages/zh/developer/assemblyscript-migration-guide.mdx +++ b/pages/zh/developer/assemblyscript-migration-guide.mdx @@ -176,7 +176,8 @@ let c: usize = a + (b as usize) // upcasting on class inheritance class Bytes extends Uint8Array {} -let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array +let bytes = new Bytes(2) +// bytes // same as: bytes as Uint8Array ``` 在两种情况下,您可能希望进行类型转换,但使用 `as`/`var` **并不安全**: @@ -188,7 +189,8 @@ let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array // downcasting on class inheritance class Bytes extends Uint8Array {} -let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( +let uint8Array = new Uint8Array(2) +// uint8Array // breaks in runtime :( ``` ```typescript @@ -196,7 +198,8 @@ let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( class Bytes extends Uint8Array {} class ByteArray extends Uint8Array {} -let bytes = new Bytes(2) < ByteArray > bytes // breaks in runtime :( +let bytes = new Bytes(2) +// bytes // breaks in runtime :( ``` 对于这些情况,您可以使用 `changetype` 函数: From 37e1bc5f5dd20f846c0e625cbc9a8696913f5e80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:04:02 -0500 Subject: [PATCH 40/90] New translations assemblyscript-migration-guide.mdx (Vietnamese) --- .../developer/assemblyscript-migration-guide.mdx | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/pages/vi/developer/assemblyscript-migration-guide.mdx b/pages/vi/developer/assemblyscript-migration-guide.mdx index 39d2fcd28e06..4358b17bc540 100644 --- a/pages/vi/developer/assemblyscript-migration-guide.mdx +++ b/pages/vi/developer/assemblyscript-migration-guide.mdx @@ -173,10 +173,11 @@ let c: usize = a + (b as usize) ``` ```typescript -// upcasting về kế thừa lớp +// upcasting on class inheritance class Bytes extends Uint8Array {} -let bytes = new Bytes(2) < Uint8Array > bytes // same as: bytes as Uint8Array +let bytes = new Bytes(2) +// bytes // same as: bytes as Uint8Array ``` Có hai trường hợp mà bạn có thể muốn ép kiểu, nhưng việc sử dụng `as`/`var` **không an toàn**: @@ -185,18 +186,20 @@ Có hai trường hợp mà bạn có thể muốn ép kiểu, nhưng việc s - Giữa hai loại chia sẻ lớp cha ```typescript -// dự báo về kế thừa lớp +// downcasting on class inheritance class Bytes extends Uint8Array {} -let uint8Array = new Uint8Array(2) < Bytes > uint8Array // breaks in runtime :( +let uint8Array = new Uint8Array(2) +// uint8Array // breaks in runtime :( ``` ```typescript -// giữa hai loại chia sẻ lớp cha +// between two types that share a superclass class Bytes extends Uint8Array {} class ByteArray extends Uint8Array {} -let bytes = new Bytes(2) < ByteArray > bytes // ngắt trong thời gian chạy :( +let bytes = new Bytes(2) +// bytes // breaks in runtime :( ``` Đối với những trường hợp đó, bạn có thể sử dụng hàm `changetype`: From d69ad2f8d5ce0ffa9f22a1c7346734cf12eee97c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:04:03 -0500 Subject: [PATCH 41/90] New translations billing.mdx (Spanish) --- pages/es/studio/billing.mdx | 66 ++++++++++++++++++------------------- 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/pages/es/studio/billing.mdx b/pages/es/studio/billing.mdx index fec638ae5c9f..674243d209d4 100644 --- a/pages/es/studio/billing.mdx +++ b/pages/es/studio/billing.mdx @@ -1,43 +1,43 @@ --- -title: Billing on the Subgraph Studio +title: Facturación en Subgraph Studio --- ### Descripción -Invoices are statements of payment amounts owed by a customer and are typically generated on a weekly basis in the system. You’ll be required to pay fees based on the query fees you generate using your API keys. The billing contract lives on the [Polygon](https://polygon.technology/) network. It’ll allow you to: +Las facturas son extractos de los importes de pago que debe un cliente y suelen generarse semanalmente en el sistema. Se te pedirá que pagues tarifas basadas en las tarifas de consulta que generes utilizando tus claves API. El contrato de facturación vive en la red [Polygon](https://polygon.technology/). Te permitirá: -- Add and remove GRT -- Keep track of your balances based on how much GRT you have added to your account, how much you have removed, and your invoices -- Automatically clear payments based on query fees generated +- Añadir y eliminar GRT +- Controla tus saldos en función de la cantidad de GRT que agregaste a tu cuenta, la cantidad que retiraste y tus facturas +- Compensar automáticamente los pagos en función de las tarifas de consulta generadas -In order to add GRT to your account, you will need to go through the following steps: +Para añadir GRT a tu cuenta, deberás seguir los siguientes pasos: -1. Purchase GRT and ETH on an exchange of your choice -2. Send the GRT and ETH to your wallet -3. Bridge GRT to Polygon using the UI +1. Compra GRT y ETH en un exchange de tu elección +2. Envía GRT y ETH a tu wallet +3. Puente de GRT a Polygon usando la UI - a) You will receive 0.001 Matic in a few minutes after you send any amount of GRT to the Polygon bridge. You can track the transaction on [Polygonscan](https://polygonscan.com/) by inputting your address into the search bar. + a) Recibirás 0,001 Matic en unos minutos después de enviar cualquier cantidad de GRT al puente del Polygon. Puedes seguir la transacción en [Polygonscan](https://polygonscan.com/) introduciendo tu dirección en la barra de búsqueda. -4. Add bridged GRT to the billing contract on Polygon. The billing contract address is: [0x10829DB618E6F520Fa3A01c75bC6dDf8722fA9fE](https://polygonscan.com/address/0x10829DB618E6F520Fa3A01c75bC6dDf8722fA9fE). +4. Añade GRT puenteado al contrato de facturación en Polygon. La dirección del contrato de facturación es: [0x10829DB618E6F520Fa3A01c75bC6dDf8722fA9fE](https://polygonscan.com/address/0x10829DB618E6F520Fa3A01c75bC6dDf8722fA9fE). - a) In order to complete step #4, you'll need to switch your network in your wallet to Polygon. You can add Polygon's network by connecting your wallet and clicking on "Choose Matic (Polygon) Mainnet" [here.](https://chainlist.org/) Once you've added the network, switch it over in your wallet by navigating to the network pill on the top right hand side corner. In Metamask, the network is called **Matic Mainnnet.** + a) Para completar el paso #4, tendrás que cambiar la red de tu wallet a Polygon. Puedes agregar la red de Polygo conectando tu wallet y haciendo clic en "Choose Matic (Polygon) Mainnet" [here.](https://chainlist.org/) Una vez que hayas añadido la red, cámbiala en tu wallet navegando hasta la pastilla de la red en la esquina superior derecha. En Metamask, la red se llama **Matic Mainnnet.** -At the end of each week, if you used your API keys, you will receive an invoice based on the query fees you have generated during this period. This invoice will be paid using GRT available in your balance. Query volume is evaluated by the API keys you own. Your balance will be updated after fees are withdrawn. +Al final de cada semana, si has utilizado tus claves API, recibirás una factura basada en las tasas de consulta que hayas generado durante este periodo. Esta factura se pagará con GRT disponible en tu saldo. El volumen de consultas se evalúa en función de las claves API que poseas. Tu saldo se actualizará una vez retiradas las tarifas. -#### Here’s how you go through the invoicing process: +#### Así es como se realiza el proceso de facturación: -There are 4 states your invoice can be in: +Hay 4 estados en los que puede estar tu factura: -1. Created - your invoice has just been created and not been paid yet -2. Paid - your invoice has been successfully paid -3. Unpaid - there is not enough GRT in your balance on the billing contract -4. Error - there is an error processing the payment +1. Creada: tu factura acaba de ser creada y aún no ha sido pagada +2. Pagada - Tu factura ha sido pagada con éxito +3. Impaga: no hay suficiente GRT en tu saldo en el contrato de facturación +4. Error - hay un error al procesar el pago -**See the diagram below for more information:** +**Consulta el siguiente diagrama para obtener más información:** -![Billing Flow](/img/billing-flow.png) +![Flujo de Facturación](/img/billing-flow.png) -For a quick demo of how billing works on the Subgraph Studio, check out the video below: +Si quieres ver una demostración rápida de cómo funciona la facturación en Subgraph Studio, mira el siguiente video:
+>
-### Multisig Users +### Usuarios Multisig -Multisigs are smart-contracts that can exist only on the network they have been created, so if you created one on Ethereum Mainnet - it will only exist on Mainnet. Since our billing uses Polygon, if you were to bridge GRT to the multisig address on Polygon the funds would be lost. +Los multisigs son contratos inteligentes que sólo pueden existir en la red en la que han sido creados, por lo que si creaste uno en Ethereum Mainnet - sólo existirá en Mainnet. Dado que nuestra facturación utiliza Polygon, si haces un puente entre GRT y la dirección de la multisig en Polygon, los fondos se perderían. -To overcome this issue, we created [a dedicated tool](https://multisig-billing.thegraph.com/) that will help you deposit GRT on our billing contract (on behalf of the multisig) with a standard wallet / EOA (an account controlled by a private key). +Para superar este problema, hemos creado [una herramienta dedicada](https://multisig-billing.thegraph.com/) que te ayudará a depositar GRT en nuestro contrato de facturación (en nombre del multisig) con una wallet estándar / EOA (una cuenta controlada por una clave privada). -You can access our Multisig Billing Tool here: https://multisig-billing.thegraph.com/ +Puedes acceder a nuestra herramienta de facturación Multisig aquí: https://multisig-billing.thegraph.com/ -This tool will guide you to go through the following steps: +Esta herramienta te guiará para realizar los siguientes pasos: -1. Connect your standard wallet / EOA (this wallet needs to own some ETH as well as the GRT you want to deposit) -2. Bridge GRT to Polygon. You will have to wait 7-8 minutes after the transaction is complete for the bridge transfer to be finalized. -3. Once your GRT is available on your Polygon balance you can deposit them to the billing contract while specifying the multisig address you are funding in the `Multisig Address` field. +1. Conecta tu wallet estándar / EOA (esta wallet necesita poseer algo de ETH así como GRT que quieres depositar) +2. Transfiere a traves del puente GRT a Polygon. Tendrás que esperar entre 7 y 8 minutos después de que se complete la transacción para que finalice la transferencia del puente. +3. Una vez que tus GRT estén disponible en tu saldo de Polygon, puedes depositarlos en el contrato de facturación mientras especificas la dirección multisig que estás financiando en el campo `Multisig Address`. -Once the deposit transaction has been confirmed you can go back to [Subgraph Studio](https://thegraph.com/studio/) and connect with your Gnosis Safe Multisig to create API keys and use them to generate queries. +Una vez confirmada la transacción de depósito, puedes volver a [Subgraph Studio](https://thegraph.com/studio/) y conectarte con tu Gnosis Safe Multisig para crear claves API y utilizarlas para generar consultas. -Those queries will generate invoices that will be paid automatically using the multisig’s billing balance. +Esas consultas generarán facturas que se pagarán automáticamente con el saldo de facturación de la multisig. From 63ff3c159b5cd1ccb9e5079a3cfd8430573d4279 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 09:04:05 -0500 Subject: [PATCH 42/90] New translations studio-faq.mdx (Spanish) --- pages/es/studio/studio-faq.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/es/studio/studio-faq.mdx b/pages/es/studio/studio-faq.mdx index e228ed8b1543..56308696424f 100644 --- a/pages/es/studio/studio-faq.mdx +++ b/pages/es/studio/studio-faq.mdx @@ -14,14 +14,14 @@ R: ¡Sí! Puedes crear varias claves API para utilizarlas en diferentes proyecto Después de crear una Clave de API, en la sección Seguridad puedes definir los dominios que pueden consultar una Clave de API específica. -### 4. ¿Cómo puedo encontrar las URL de consulta de los subgrafos si no soy el desarrollador del subgrafo que quiero utilizar? +### 4. ¿Puedo transferir mi subgrafo a otro titular? -Puedes encontrar la URL de consulta de cada subgrafo en la sección Detalles del Subgrafo de the Graph Explorer. Al hacer clic en el botón "Query", se te dirigirá a un panel en el que podrás ver la URL de consulta del subgrafo te interesa. A continuación, puedes sustituir el marcador de posición `` por la clave de la API que deseas aprovechar en el Subgraph Studio. +Sí, los subgrafos que han sido publicados en Mainnet pueden ser transferidos a una nueva wallet o a una Multisig. Puedes hacerlo haciendo clic en los tres puntos junto al botón "Publicar" en la página de detalles del subgrafo y seleccionando "Transferir propiedad". -Recuerda que puedes crear una clave API y consultar cualquier subgrafo publicado en la red, incluso si tú mismo construyes un subgrafo. Estas consultas a través de la nueva clave API, son consultas pagas como cualquier otra en la red. +Ten en cuenta que ya no podrás ver o editar el subgrafo en Studio una vez que haya sido transferido. -### 5. How do I find query URLs for subgraphs if I’m not the developer of the subgraph I want to use? +### 5. ¿Cómo puedo encontrar las URL de consulta de los subgrafos si no soy el desarrollador del subgrafo que quiero utilizar? -You can find the query URL of each subgraph in the Subgraph Details section of The Graph Explorer. When you click on the “Query” button, you will be directed to a pane wherein you can view the query URL of the subgraph you’re interested in. You can then replace the `` placeholder with the API key you wish to leverage in the Subgraph Studio. +Puedes encontrar la consulta URL de cada subgrafo en la sección Detalles del Subgrafo de The Graph Explorer. Cuando haces clic en el botón de "Query" (Consulta), serás dirigido a un panel en el que puedes ver la URL de consulta del subgrafo que te interesa. A continuación, puedes sustituir el marcador de posición `` por la clave API que deseas aprovechar en Subgraph Studio. -Remember that you can create an API key and query any subgraph published to the network, even if you build a subgraph yourself. These queries via the new API key, are paid queries as any other on the network. +Recuerda que puedes crear una clave API y consultar cualquier subgrafo publicado en la red, incluso si tú mismo construyes un subgrafo. Estas consultas a través de la nueva clave API, son consultas pagadas como cualquier otra en la red. From e2f4bf37615089b64b38dc88929675b3ab989131 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:23 -0500 Subject: [PATCH 43/90] New translations assemblyscript-api.mdx (Spanish) --- pages/es/developer/assemblyscript-api.mdx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pages/es/developer/assemblyscript-api.mdx b/pages/es/developer/assemblyscript-api.mdx index 5ae139ce8ed9..a376a0f67029 100644 --- a/pages/es/developer/assemblyscript-api.mdx +++ b/pages/es/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ La librería de `@graphprotocol/graph-ts` proporciona las siguientes APIs: La `apiVersion` en el manifiesto del subgrafo especifica la versión de la API correspondiente al mapeo que está siendo ejecutado en el Graph Node de un subgrafo en específico. La versión actual para la APÍ de mapeo es la 0.0.6. -| Version | Notas del lanzamiento | -| :-: | --- | -| 0.0.6 | Se agregó la casilla `nonce` a las Transacciones de Ethereum, se
añadió `baseFeePerGas` para los bloques de Ethereum | -| 0.0.5 | Se actualizó la versión del AssemblyScript a la v0.19.10 (esta incluye cambios importantes, recomendamos leer la [`guía de migración`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` actualizada a `ethereum.transaction.gasLimit` | -| 0.0.4 | Añadido la casilla de `functionSignature` para la función de Ethereum SmartContractCall | -| 0.0.3 | Añadida la casilla `from` para la función de Ethereum Call
`ethereum.call.address` actualizada a `ethereum.call.to` | -| 0.0.2 | Añadida la casilla de `input` para la función de Ethereum Transaction | +| Version | Notas del lanzamiento | +|:-------:| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| 0.0.6 | Se agregó la casilla `nonce` a las Transacciones de Ethereum, se
añadió `baseFeePerGas` para los bloques de Ethereum | +| 0.0.5 | Se actualizó la versión del AssemblyScript a la v0.19.10 (esta incluye cambios importantes, recomendamos leer la [`guía de migración`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` actualizada a `ethereum.transaction.gasLimit` | +| 0.0.4 | Añadido la casilla de `functionSignature` para la función de Ethereum SmartContractCall | +| 0.0.3 | Añadida la casilla `from` para la función de Ethereum Call
`ethereum.call.address` actualizada a `ethereum.call.to` | +| 0.0.2 | Añadida la casilla de `input` para la función de Ethereum Transaction | ### Built-in Types From 120146b7d44bc83e6757d7df826f5d0a76e81bc3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:29 -0500 Subject: [PATCH 44/90] New translations assemblyscript-api.mdx (Chinese Simplified) --- pages/zh/developer/assemblyscript-api.mdx | 82 +++++++++++------------ 1 file changed, 41 insertions(+), 41 deletions(-) diff --git a/pages/zh/developer/assemblyscript-api.mdx b/pages/zh/developer/assemblyscript-api.mdx index c10acf58a788..0cab89ed08d6 100644 --- a/pages/zh/developer/assemblyscript-api.mdx +++ b/pages/zh/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install --save-dev @graphprotocol/graph-ts # NPM 子图清单中的 `apiVersion` 指定了由 Graph 节点为给定子图运行的映射 API 版本。 当前的映射 API 版本是 0.0.6。 -| 版本 | Release 说明 | -| :-: | --- | -| 0.0.6 | 向 Ethereum Transaction 对象添加 `nonce` 字段
向 Ethereum Block 对象添加 `baseFeePerGas` | +| 版本 | Release 说明 | +|:-----:| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| 0.0.6 | 向 Ethereum Transaction 对象添加 `nonce` 字段
向 Ethereum Block 对象添加 `baseFeePerGas` | | 0.0.5 | AssemblyScript 升级到版本 0.19.10(这包括重大更改,参阅 [`迁移指南`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` 重命名为 `ethereum.transaction.gasLimit` | -| 0.0.4 | 向 Ethereum SmartContractCall 对象添加 `functionSignature` 字段 | -| 0.0.3 | 将 `from` 字段添加到 Ethereum Call 对象
`etherem.call.address` 重命名为 `ethereum.call.to` | -| 0.0.2 | 向 Ethereum Transaction 对象添加 `input` 字段 | +| 0.0.4 | 向 Ethereum SmartContractCall 对象添加 `functionSignature` 字段 | +| 0.0.3 | 将 `from` 字段添加到 Ethereum Call 对象
`etherem.call.address` 重命名为 `ethereum.call.to` | +| 0.0.2 | 向 Ethereum Transaction 对象添加 `input` 字段 | ### 内置类型 @@ -650,43 +650,43 @@ if (value.kind == JSONValueKind.BOOL) { ### 类型转换参考 -| 源 | 目标 | 转换函数 | -| -------------------- | -------------------- | ---------------------------- | -| Address | Bytes | none | -| Address | ID | s.toHexString() | -| Address | String | s.toHexString() | -| BigDecimal | String | s.toString() | -| BigInt | BigDecimal | s.toBigDecimal() | +| 源 | 目标 | 转换函数 | +| -------------------- | -------------------- | --------------------------- | +| Address | Bytes | none | +| Address | ID | s.toHexString() | +| Address | String | s.toHexString() | +| BigDecimal | String | s.toString() | +| BigInt | BigDecimal | s.toBigDecimal() | | BigInt | String (hexadecimal) | s.toHexString() 或 s.toHex() | -| BigInt | String (unicode) | s.toString() | -| BigInt | i32 | s.toI32() | -| Boolean | Boolean | none | -| Bytes (signed) | BigInt | BigInt.fromSignedBytes(s) | -| Bytes (unsigned) | BigInt | BigInt.fromUnsignedBytes(s) | +| BigInt | String (unicode) | s.toString() | +| BigInt | i32 | s.toI32() | +| Boolean | Boolean | none | +| Bytes (signed) | BigInt | BigInt.fromSignedBytes(s) | +| Bytes (unsigned) | BigInt | BigInt.fromUnsignedBytes(s) | | Bytes | String (hexadecimal) | s.toHexString() 或 s.toHex() | -| Bytes | String (unicode) | s.toString() | -| Bytes | String (base58) | s.toBase58() | -| Bytes | i32 | s.toI32() | -| Bytes | u32 | s.toU32() | -| Bytes | JSON | json.fromBytes(s) | -| int8 | i32 | none | -| int32 | i32 | none | -| int32 | BigInt | Bigint.fromI32(s) | -| uint24 | i32 | none | -| int64 - int256 | BigInt | none | -| uint32 - uint256 | BigInt | none | -| JSON | boolean | s.toBool() | -| JSON | i64 | s.toI64() | -| JSON | u64 | s.toU64() | -| JSON | f64 | s.toF64() | -| JSON | BigInt | s.toBigInt() | -| JSON | string | s.toString() | -| JSON | Array | s.toArray() | -| JSON | Object | s.toObject() | -| String | Address | Address.fromString(s) | -| String | BigDecimal | BigDecimal.fromString(s) | -| String (hexadecimal) | Bytes | ByteArray.fromHexString(s) | -| String (UTF-8) | Bytes | ByteArray.fromUTF8(s) | +| Bytes | String (unicode) | s.toString() | +| Bytes | String (base58) | s.toBase58() | +| Bytes | i32 | s.toI32() | +| Bytes | u32 | s.toU32() | +| Bytes | JSON | json.fromBytes(s) | +| int8 | i32 | none | +| int32 | i32 | none | +| int32 | BigInt | Bigint.fromI32(s) | +| uint24 | i32 | none | +| int64 - int256 | BigInt | none | +| uint32 - uint256 | BigInt | none | +| JSON | boolean | s.toBool() | +| JSON | i64 | s.toI64() | +| JSON | u64 | s.toU64() | +| JSON | f64 | s.toF64() | +| JSON | BigInt | s.toBigInt() | +| JSON | string | s.toString() | +| JSON | Array | s.toArray() | +| JSON | Object | s.toObject() | +| String | Address | Address.fromString(s) | +| String | BigDecimal | BigDecimal.fromString(s) | +| String (hexadecimal) | Bytes | ByteArray.fromHexString(s) | +| String (UTF-8) | Bytes | ByteArray.fromUTF8(s) | ### 数据源元数据 From 41732c5f456c134020d7502598644cac065f3204 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:30 -0500 Subject: [PATCH 45/90] New translations assemblyscript-api.mdx (Korean) --- pages/ko/developer/assemblyscript-api.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/ko/developer/assemblyscript-api.mdx b/pages/ko/developer/assemblyscript-api.mdx index 1f5ce7dc1ca1..c5eec178398a 100644 --- a/pages/ko/developer/assemblyscript-api.mdx +++ b/pages/ko/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install --save-dev @graphprotocol/graph-ts # NPM 서브그래프 매니페스트의 `apiVersion`은 주어진 서브그래프에 대해 그래프 노드가 실행하는 매핑 API 버전을 지정합니다. 현재 맵핑 API 버전은 0.0.6 입니다. -| 버전 | 릴리스 노트 | -| :-: | --- | -| 0.0.6 | 이더리움 트랜잭션 개체에 `nonce` 필드를 추가했습니다.
`baseFeePerGas`가 이더리움 블록 개체에 추가되었습니다. | +| 버전 | 릴리스 노트 | +|:-----:| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| 0.0.6 | 이더리움 트랜잭션 개체에 `nonce` 필드를 추가했습니다.
`baseFeePerGas`가 이더리움 블록 개체에 추가되었습니다. | | 0.0.5 | AssemblyScript를 버전 0.19.10으로 업그레이드했습니다(변경 내용 깨짐 포함. [`Migration Guide`](/developer/assemblyscript-migration-guide) 참조)
`ethereum.transaction.gasUsed`의 이름이 `ethereum.transaction.gasLimit`로 변경되었습니다. | -| 0.0.4 | Ethereum SmartContractCall 개체에 `functionSignature` 필드를 추가했습니다. | -| 0.0.3 | Ethereum Call 개체에 `from` 필드를 추가했습니다.
`etherem.call.address`의 이름이 `ethereum.call.to`로 변경되었습니다. | -| 0.0.2 | Ethereum Transaction 개체에 `input` 필드를 추가했습니다. | +| 0.0.4 | Ethereum SmartContractCall 개체에 `functionSignature` 필드를 추가했습니다. | +| 0.0.3 | Ethereum Call 개체에 `from` 필드를 추가했습니다.
`etherem.call.address`의 이름이 `ethereum.call.to`로 변경되었습니다. | +| 0.0.2 | Ethereum Transaction 개체에 `input` 필드를 추가했습니다. | ### 기본 제공 유형 From fa4f591ec5747a1585beb526a35fb89b4dae429c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:31 -0500 Subject: [PATCH 46/90] New translations assemblyscript-api.mdx (Japanese) --- pages/ja/developer/assemblyscript-api.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/ja/developer/assemblyscript-api.mdx b/pages/ja/developer/assemblyscript-api.mdx index 0069310090ce..4826602d3457 100644 --- a/pages/ja/developer/assemblyscript-api.mdx +++ b/pages/ja/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install -save-dev @graphprotocol/graph-ts # NPM サブグラフマニフェストの`apiVersion` は、指定されたサブグラフに対してグラフノードが実行するマッピング API のバージョンを指定します。 現在のマッピング API のバージョンは 0.0.6 です。 -| バージョン | リリースノート | -| :-: | --- | -| 0.0.6 | Ethereum Transaction オブジェクトに`nonce`フィールドを追加 イーサリアムブロックオブジェクトに
Added `baseFeePerGas`を追加 | +| バージョン | リリースノート | +|:-----:| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| 0.0.6 | Ethereum Transaction オブジェクトに`nonce`フィールドを追加 イーサリアムブロックオブジェクトに
Added `baseFeePerGas`を追加 | | 0.0.5 | AssemblyScript がバージョン 0.19.10 にアップグレード(変更点がありますので[`Migration Guide`](/developer/assemblyscript-migration-guide))をご覧ください)。
`ethereum.transaction.gasUsed`の名前が`ethereum.transaction.gasLimit`に変更 | -| 0.0.4 | Ethereum SmartContractCall オブジェクトに`functionSignature`フィールドを追加 | -| 0.0.3 | Ethereum Call オブジェクトに`from`フィールドを追加
`etherem.call.address`の名前を `ethereum.call.to`に変更 | -| 0.0.2 | Ethereum Transaction オブジェクトに `input`フィールドを追加 | +| 0.0.4 | Ethereum SmartContractCall オブジェクトに`functionSignature`フィールドを追加 | +| 0.0.3 | Ethereum Call オブジェクトに`from`フィールドを追加
`etherem.call.address`の名前を `ethereum.call.to`に変更 | +| 0.0.2 | Ethereum Transaction オブジェクトに `input`フィールドを追加 | ### 組み込み型 From 8a64803c9cf8db46dd6a2d1f6c5267b53de7ec0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:33 -0500 Subject: [PATCH 47/90] New translations assemblyscript-api.mdx (Vietnamese) --- pages/vi/developer/assemblyscript-api.mdx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pages/vi/developer/assemblyscript-api.mdx b/pages/vi/developer/assemblyscript-api.mdx index 458efa587c17..35ba6cba5f0c 100644 --- a/pages/vi/developer/assemblyscript-api.mdx +++ b/pages/vi/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ Thư viện `@graphprotocol/graph-ts` cung cấp các API sau: `apiVersion` trong tệp kê khai subgraph chỉ định phiên bản API ánh xạ được chạy bởi Graph Node cho một subgraph nhất định. Phiên bản API ánh xạ hiện tại là 0.0.6. -| Phiên bản | Ghi chú phát hành | -| :-: | --- | -| 0.0.6 | Đã thêm trường `nonce` đến đối tượng Giao dịch Ethereum
Đã thêm `baseFeePerGas`đến đối tượng Ethereum Block | -| 0.0.5 | AssemblyScript đã nâng cấp lên phiên bản 0.19.10 (điều này bao gồm các thay đổi vi phạm, vui lòng xem [`Hướng dẫn Di chuyển`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` đổi tên thành `ethereum.transaction.gasLimit` | -| 0.0.4 | Đã thêm trường `functionSignature` vào đối tượng Ethereum SmartContractCall | -| 0.0.3 | Đã thêm trường `from` vào đối tượng Ethereum Call
`etherem.call.address` đổi tên thành `ethereum.call.to` | -| 0.0.2 | Đã thêm trường `input` vào đối tượng Ethereum Transaction | +| Phiên bản | Ghi chú phát hành | +|:---------:| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| 0.0.6 | Đã thêm trường `nonce` đến đối tượng Giao dịch Ethereum
Đã thêm `baseFeePerGas`đến đối tượng Ethereum Block | +| 0.0.5 | AssemblyScript đã nâng cấp lên phiên bản 0.19.10 (điều này bao gồm các thay đổi vi phạm, vui lòng xem [`Hướng dẫn Di chuyển`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` đổi tên thành `ethereum.transaction.gasLimit` | +| 0.0.4 | Đã thêm trường `functionSignature` vào đối tượng Ethereum SmartContractCall | +| 0.0.3 | Đã thêm trường `from` vào đối tượng Ethereum Call
`etherem.call.address` đổi tên thành `ethereum.call.to` | +| 0.0.2 | Đã thêm trường `input` vào đối tượng Ethereum Transaction | ### Các loại cài sẵn From 37f88b1376bf8ee87810049cd77a866321db71cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:58 -0500 Subject: [PATCH 48/90] New translations create-subgraph-hosted.mdx (Vietnamese) --- pages/vi/developer/create-subgraph-hosted.mdx | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/pages/vi/developer/create-subgraph-hosted.mdx b/pages/vi/developer/create-subgraph-hosted.mdx index 748de8d62a00..af0ecc490f9f 100644 --- a/pages/vi/developer/create-subgraph-hosted.mdx +++ b/pages/vi/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Mỗi thực thể phải có một trường `id`, thuộc loại `ID!` (string Chúng tôi hỗ trợ các đại lượng vô hướng sau trong API GraphQL của chúng tôi: -| Loại | Miêu tả | -| --- | --- | -| `Bytes` | Mảng byte, được biểu diễn dưới dạng chuỗi thập lục phân. Thường được sử dụng cho các mã băm và địa chỉ Ethereum. | -| `ID` | Được lưu trữ dưới dạng `string`. | -| `String` | Vô hướng cho các giá trị `string`. Các ký tự rỗng không được hỗ trợ và tự động bị xóa. | -| `Boolean` | Vô hướng cho các giá trị `boolean`. | -| `Int` | Thông số GraphQL xác định `Int` có kích thước 32 byte. | -| `BigInt` | Số nguyên lớn. Được sử dụng cho các loại `uint32`, `int64`, `uint64`, ..., `uint256` của Ethereum. Lưu ý: mọi thứ dưới `uint32`, như là `int32`, `uint24` or `int8` được đại diện như là `i32`. | -| `BigDecimal` | `BigDecimal` Các số thập phân có độ chính xác cao được biểu diễn dưới dạng dấu hiệu và số mũ. Phạm vi số mũ là từ −6143 đến +6144. Được làm tròn đến 34 chữ số có nghĩa. | +| Loại | Miêu tả | +| ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `Bytes` | Mảng byte, được biểu diễn dưới dạng chuỗi thập lục phân. Thường được sử dụng cho các mã băm và địa chỉ Ethereum. | +| `ID` | Được lưu trữ dưới dạng `string`. | +| `String` | Vô hướng cho các giá trị `string`. Các ký tự rỗng không được hỗ trợ và tự động bị xóa. | +| `Boolean` | Vô hướng cho các giá trị `boolean`. | +| `Int` | Thông số GraphQL xác định `Int` có kích thước 32 byte. | +| `BigInt` | Số nguyên lớn. Được sử dụng cho các loại `uint32`, `int64`, `uint64`, ..., `uint256` của Ethereum. Lưu ý: mọi thứ dưới `uint32`, như là `int32`, `uint24` or `int8` được đại diện như là `i32`. | +| `BigDecimal` | `BigDecimal` Các số thập phân có độ chính xác cao được biểu diễn dưới dạng dấu hiệu và số mũ. Phạm vi số mũ là từ −6143 đến +6144. Được làm tròn đến 34 chữ số có nghĩa. | #### Enums @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **Lưu ý:** Nguồn dữ liệu mới sẽ chỉ xử lý các lệnh gọi và sự kiện cho khối mà nó được tạo và tất cả các khối tiếp theo, nhưng sẽ không xử lý dữ liệu lịch sử, tức là dữ liệu được chứa trong các khối trước đó. -> +> > Nếu các khối trước đó chứa dữ liệu có liên quan đến nguồn dữ liệu mới, tốt nhất là lập chỉ mục dữ liệu đó bằng cách đọc trạng thái hiện tại của hợp đồng và tạo các thực thể đại diện cho trạng thái đó tại thời điểm nguồn dữ liệu mới được tạo. ### Bối cảnh Nguồn Dữ liệu @@ -684,7 +684,7 @@ dataSources: ``` > **Lưu ý:** Khối tạo hợp đồng có thể được nhanh chóng tra cứu trên Etherscan: -> +> > 1. Tìm kiếm hợp đồng bằng cách nhập địa chỉ của nó vào thanh tìm kiếm. > 2. Nhấp vào băm giao dịch tạo trong phần `Contract Creator`. > 3. Tải trang chi tiết giao dịch nơi bạn sẽ tìm thấy khối bắt đầu cho hợp đồng đó. From f9d5824c5da3dbff72fa72c38e3453b832881c0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:58:59 -0500 Subject: [PATCH 49/90] New translations create-subgraph-hosted.mdx (Chinese Simplified) --- pages/zh/developer/create-subgraph-hosted.mdx | 64 +++++++++---------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/pages/zh/developer/create-subgraph-hosted.mdx b/pages/zh/developer/create-subgraph-hosted.mdx index 5c396c577abf..abb0402ca45f 100644 --- a/pages/zh/developer/create-subgraph-hosted.mdx +++ b/pages/zh/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Null value resolved for non-null field 'name' 我们在 GraphQL API 中支持以下标量: -| 类型 | 描述 | -| --- | --- | -| `Bytes` | 字节数组,表示为十六进制字符串。 通常用于以太坊哈希和地址。 | -| `ID` | 存储为`string`。 | -| `String` | `string` 值的标量。 不支持空字符,并会自动进行删除。 | -| `Boolean` | `boolean` 值的标量。 | -| `Int` | GraphQL 规范将 `Int` 定义为 32 字节的大小。 | -| `BigInt` | 大整数。 用于以太坊的 `uint32`、`int64`、`uint64`、...、`uint256` 类型。 注意:`uint32`以下的所有类型,例如`int32`、`uint24`或`int8`都表示为`i32`。 | -| `BigDecimal` | `BigDecimal` 表示为有效数字和指数的高精度小数。 指数范围是 -6143 到 +6144。 四舍五入到 34 位有效数字。 | +| 类型 | 描述 | +| ------------ | -------------------------------------------------------------------------------------------------------------- | +| `Bytes` | 字节数组,表示为十六进制字符串。 通常用于以太坊哈希和地址。 | +| `ID` | 存储为`string`。 | +| `String` | `string` 值的标量。 不支持空字符,并会自动进行删除。 | +| `Boolean` | `boolean` 值的标量。 | +| `Int` | GraphQL 规范将 `Int` 定义为 32 字节的大小。 | +| `BigInt` | 大整数。 用于以太坊的 `uint32`、`int64`、`uint64`、...、`uint256` 类型。 注意:`uint32`以下的所有类型,例如`int32`、`uint24`或`int8`都表示为`i32`。 | +| `BigDecimal` | `BigDecimal` 表示为有效数字和指数的高精度小数。 指数范围是 -6143 到 +6144。 四舍五入到 34 位有效数字。 | #### 枚举类型 @@ -428,33 +428,33 @@ query { 支持的语言词典: -| 代码 | 词典 | -| ------ | ---------- | -| simple | 通用 | -| da | 丹麦语 | -| nl | 荷兰语 | -| en | 英语 | -| fi | 芬兰语 | -| fr | 法语 | -| de | 德语 | -| hu | 匈牙利语 | -| it | 意大利语 | -| no | 挪威语 | -| pt | 葡萄牙语 | +| 代码 | 词典 | +| ------ | ----- | +| simple | 通用 | +| da | 丹麦语 | +| nl | 荷兰语 | +| en | 英语 | +| fi | 芬兰语 | +| fr | 法语 | +| de | 德语 | +| hu | 匈牙利语 | +| it | 意大利语 | +| no | 挪威语 | +| pt | 葡萄牙语 | | ro | 罗马尼亚语 | -| ru | 俄语 | -| es | 西班牙语 | -| sv | 瑞典语 | -| tr | 土耳其语 | +| ru | 俄语 | +| es | 西班牙语 | +| sv | 瑞典语 | +| tr | 土耳其语 | ### 排序算法 支持的排序结果算法: -| 算法 | 描述 | -| ------------- | --------------------------------------------- | +| 算法 | 描述 | +| ------------- | -------------------------- | | rank | 使用全文查询的匹配质量 (0-1) 对结果进行排序。 | -| proximityRank | 与 rank 类似,但也包括匹配的接近程度。 | +| proximityRank | 与 rank 类似,但也包括匹配的接近程度。 | ## 编写映射 @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **注意:** 新的数据源只会处理创建它的区块和所有后续区块的调用和事件,而不会处理历史数据,也就是包含在先前区块中的数据。 -> +> > 如果先前的区块包含与新数据源相关的数据,最好通过读取合约的当前状态,并在创建新数据源时创建表示该状态的实体来索引该数据。 ### 数据源上下文 @@ -684,7 +684,7 @@ dataSources: ``` > **注意:** 合约创建区块可以在 Etherscan 上快速查找: -> +> > 1. 通过在搜索栏中输入合约地址来搜索合约。 > 2. 单击 `Contract Creator` 部分中的创建交易哈希。 > 3. 加载交易详情页面,您将在其中找到该合约的起始区块。 @@ -816,7 +816,7 @@ eventHandlers: 从 `specVersion` `0.0.4` 开始,子图特征必须使用它们的 `camelCase` 名称,在清单文件顶层的 `features` 部分中显式声明,如下表所列: -| 特征 | 名称 | +| 特征 | 名称 | | --------------------------------------------------------- | ------------------------- | | [Non-fatal errors](#non-fatal-errors) | `nonFatalErrors` | | [Full-text Search](#defining-fulltext-search-fields) | `fullTextSearch` | From 981b82d37699167dc2d1cbce9219b6a9117942da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:02 -0500 Subject: [PATCH 50/90] New translations create-subgraph-hosted.mdx (Korean) --- pages/ko/developer/create-subgraph-hosted.mdx | 68 +++++++++---------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/pages/ko/developer/create-subgraph-hosted.mdx b/pages/ko/developer/create-subgraph-hosted.mdx index 3d0d11498e6c..515579710f4e 100644 --- a/pages/ko/developer/create-subgraph-hosted.mdx +++ b/pages/ko/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Null value resolved for non-null field 'name' GraphQL API에서는 다음과 같은 스칼라들을 지원합니다: -| 유형 | 설명 | -| --- | --- | -| `Bytes` | 16진수 문자열로 표시되는 바이트 배열입니다. 이더리움 해시 및 주소에 일반적으로 사용됩니다. | -| `ID` | `string`으로 저장됩니다. | -| `String` | `string` 값을 위한 스칼라. Null 문자는 지원되지 않으며 자동으로 제거됩니다. | -| `Boolean` | `boolean` 값을 위한 스칼라 | -| `Int` | GraphQL 규격은 `Int`의 크기를 32바이트로 정의합니다. | -| `BigInt` | 큰 정수. 이더리움의 `uint32`, `int64`, `uint64`, ..., `uint256` 유형에 사용됩니다. 참고: , such as `int32`, `uint24` 또는 `int8`과 같은 `uint32` 아래의 모든 항목은 `i32`로 표시됩니다. | -| `BigDecimal` | 정수부와 지수로 표현되는 `BigDecimal` 고정밀 소수. 지수 범위는 -6143 ~ +6144입니다. 34자리 유효 숫자로 반올림합니다. | +| 유형 | 설명 | +| ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------- | +| `Bytes` | 16진수 문자열로 표시되는 바이트 배열입니다. 이더리움 해시 및 주소에 일반적으로 사용됩니다. | +| `ID` | `string`으로 저장됩니다. | +| `String` | `string` 값을 위한 스칼라. Null 문자는 지원되지 않으며 자동으로 제거됩니다. | +| `Boolean` | `boolean` 값을 위한 스칼라 | +| `Int` | GraphQL 규격은 `Int`의 크기를 32바이트로 정의합니다. | +| `BigInt` | 큰 정수. 이더리움의 `uint32`, `int64`, `uint64`, ..., `uint256` 유형에 사용됩니다. 참고: , such as `int32`, `uint24` 또는 `int8`과 같은 `uint32` 아래의 모든 항목은 `i32`로 표시됩니다. | +| `BigDecimal` | 정수부와 지수로 표현되는 `BigDecimal` 고정밀 소수. 지수 범위는 -6143 ~ +6144입니다. 34자리 유효 숫자로 반올림합니다. | #### 열거형(Enums) @@ -428,33 +428,33 @@ query { 지원되는 언어 사전: -| 코드 | 사전(Dictionary) | -| ------ | ---------------- | -| simple | General | -| da | Danish | -| nl | Dutch | -| en | English | -| fi | Finnish | -| fr | French | -| de | German | -| hu | Hungarian | -| it | Italian | -| no | Norwegian | -| pt | Portugese | -| ro | Romanian | -| ru | Russian | -| es | Spanish | -| sv | Swedish | -| tr | Turkish | +| 코드 | 사전(Dictionary) | +| ------ | -------------- | +| simple | General | +| da | Danish | +| nl | Dutch | +| en | English | +| fi | Finnish | +| fr | French | +| de | German | +| hu | Hungarian | +| it | Italian | +| no | Norwegian | +| pt | Portugese | +| ro | Romanian | +| ru | Russian | +| es | Spanish | +| sv | Swedish | +| tr | Turkish | ### 순위 알고리즘 결과 정렬을 위해 지원되는 알고리즘: -| 알고리즘 | 설명 | -| ------------- | ------------------------------------------------------------------- | +| 알고리즘 | 설명 | +| ------------- | ---------------------------------------------- | | rank | 전체 텍스트 쿼리의 match quality(0-1)를 사용하여 결과를 정렬합니다. | -| proximityRank | 순위와 유사하지만 matches의 근접성도 포함합니다. | +| proximityRank | 순위와 유사하지만 matches의 근접성도 포함합니다. | ## 매핑 작성 @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **참고:**: 새 데이터 소스는 자신이 생성된 블록과 이후의 모든 블록에 대한 호출 및 이벤트만 처리하지만 과거 데이터, 즉 이전 블록에 포함된 데이터는 처리하지 않습니다. -> +> > 만약 이전 블록에 새 데이터 원본과 관련된 데이터가 포함된 경우 컨트랙트의 현재 상태를 읽고 새 데이터 원본이 생성될 때 해당 상태를 나타내는 엔터티를 만들어 해당 데이터를 인덱싱하는 것이 가장 좋습니다. ### 데이터 소스 컨텍스트 @@ -684,7 +684,7 @@ dataSources: ``` > **참고:**: Etherscan에서 컨트랙트 생성 블록을 빠르게 조회할 수 있습니다. -> +> > 1. 검색 창에 주소를 입력하여 컨트랙트를 검색합니다. > 2. `Contract Creator` 섹션에서 creation transaction hash를 클릭합니다. > 3. 해당 컨트랙트의 start block을 찾을 거래 세부 정보 페이지를 로드합니다. @@ -743,7 +743,7 @@ export function handleCreateGravatar(call: CreateGravatarCall): void { } ``` -`handleCreateGravatar` 함수는 ` @graphprotocol/graph-ts``에서 제공하는 ethereum.Call `의 하위 클래스인 새 `CreateGravatarCall`을 취하며, 여기에는 호출의 유형이 지정된 입력 및 출력이 포함됩니다. `graph codegen`을 실행할 때 CreateGravatarCall 유형이 생성됩니다. +`handleCreateGravatar` 함수는 `@graphprotocol/graph-ts``에서 제공하는 ethereum.Call`의 하위 클래스인 새 `CreateGravatarCall`을 취하며, 여기에는 호출의 유형이 지정된 입력 및 출력이 포함됩니다. `graph codegen`을 실행할 때 CreateGravatarCall 유형이 생성됩니다. ## 블록 핸들러 @@ -816,7 +816,7 @@ eventHandlers: `specVersion` `0.0.4`부터 서브그래프 기능은 매니페스트 파일의 최상위 레벨에 있는 `features` 섹션에 아래 표에 나열된 대로 그들의 `camelCase` 이름을 사용하여 명백하게 명시되어야 합니다. -| 기능 | 이름 | +| 기능 | 이름 | | --------------------------------------------------------- | ------------------------- | | [Non-fatal errors](#non-fatal-errors) | `nonFatalErrors` | | [Full-text Search](#defining-fulltext-search-fields) | `fullTextSearch` | From 8c3a18c8eeec7f584d8d8377d54b545b1f0ea6b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:03 -0500 Subject: [PATCH 51/90] New translations create-subgraph-hosted.mdx (Japanese) --- pages/ja/developer/create-subgraph-hosted.mdx | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/pages/ja/developer/create-subgraph-hosted.mdx b/pages/ja/developer/create-subgraph-hosted.mdx index deaf9bc18d11..bc903e8b549e 100644 --- a/pages/ja/developer/create-subgraph-hosted.mdx +++ b/pages/ja/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Null value resolved for non-null field 'name' GraphQL API では、以下の Scalar をサポートしています: -| タイプ | 説明 | -| --- | --- | -| `Bytes` | Byte 配列で、16 進数の文字列で表されます。Ethereum のハッシュやアドレスによく使われます。 | -| `ID` | `string`として格納されます。 | -| `String` | `string`値の Scalar であり、Null 文字はサポートされておらず、自動的に削除されます。 | -| `Boolean` | `boolean`値を表す Scalar。 | -| `Int` | Int GraphQL の仕様では、`Int`のサイズは 32 バイトと定義されています。 | -| `BigInt` | 大きな整数。Ethereum の`uint32`, `int64`, `uint64`, ..., `uint256` タイプに使用されます。注: `int32`, `uint24` `int8`など`uint32`以下のものは`i32`として表現されます。 | -| `BigDecimal` | `BigDecimal`は、高精度の 10 進数を記号と指数で表します。指数の範囲は -6143 ~ +6144 です。有効数字 34 桁にまとめられます。 | +| タイプ | 説明 | +| ------------ | --------------------------------------------------------------------------------------------------------------------------------- | +| `Bytes` | Byte 配列で、16 進数の文字列で表されます。Ethereum のハッシュやアドレスによく使われます。 | +| `ID` | `string`として格納されます。 | +| `String` | `string`値の Scalar であり、Null 文字はサポートされておらず、自動的に削除されます。 | +| `Boolean` | `boolean`値を表す Scalar。 | +| `Int` | Int GraphQL の仕様では、`Int`のサイズは 32 バイトと定義されています。 | +| `BigInt` | 大きな整数。Ethereum の`uint32`, `int64`, `uint64`, ..., `uint256` タイプに使用されます。注: `int32`, `uint24` `int8`など`uint32`以下のものは`i32`として表現されます。 | +| `BigDecimal` | `BigDecimal`は、高精度の 10 進数を記号と指数で表します。指数の範囲は -6143 ~ +6144 です。有効数字 34 桁にまとめられます。 | #### Enums @@ -428,7 +428,7 @@ query { サポートされている言語の辞書: -| コード | 辞書 | +| コード | 辞書 | | ------ | --------- | | simple | General | | da | Danish | @@ -451,10 +451,10 @@ query { サポートされている結果の順序付けのアルゴリズム: -| アルゴリズム | 説明 | -| ------------- | ------------------------------------------------------------------- | -| rank | フルテキストクエリのマッチ品質 (0-1) を使用して結果を並べ替えます。 | -| proximityRank | proximityRank rank に似ていますが、マッチの近接性も含みます。 | +| アルゴリズム | 説明 | +| ------------- | ---------------------------------------- | +| rank | フルテキストクエリのマッチ品質 (0-1) を使用して結果を並べ替えます。 | +| proximityRank | proximityRank rank に似ていますが、マッチの近接性も含みます。 | ## マッピングの記述 @@ -628,7 +628,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **注: **新しいデータソースは、作成されたブロックとそれに続くすべてのブロックのコールとイベントのみを処理しますが、過去のデータ、つまり以前のブロックに含まれているデータは処理しません。 -> +> > 以前のブロックに新しいデータソースに関連するデータが含まれている場合は、コントラクトの現在の状態を読み取り、新しいデータソースが作成された時点でその状態を表すエンティティを作成することで、そのデータにインデックスを付けることが最善です。 ### データソースコンテクスト @@ -685,7 +685,7 @@ dataSources: ``` > **注: ** コントラクト作成ブロックは、Etherscan ですぐに調べることができます: -> +> > 1. 検索バーにアドレスを入力してコントラクトを検索します。 > 2. `Contract Creator` セクションの作成トランザクションハッシュをクリックします。 > 3. トランザクションの詳細ページを読み込んで、そのコントラクトの開始ブロックを見つけます。 @@ -817,7 +817,7 @@ eventHandlers: `specVersion` `0.0.4`以降、サブグラフ機能はマニフェストファイルのトップレベルにある`features`セクションで、以下の表のように`camelCase` の名前を使って明示的に宣言する必要があります: -| 特徴 | 名前 | +| 特徴 | 名前 | | --------------------------------------------------------- | ------------------------- | | [Non-fatal errors](#non-fatal-errors) | `nonFatalErrors` | | [Full-text Search](#defining-fulltext-search-fields) | `fullTextSearch` | From 903c84b5a39e944dfc88aad4cb0dcd2d7066a7b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:04 -0500 Subject: [PATCH 52/90] New translations create-subgraph-hosted.mdx (Spanish) --- pages/es/developer/create-subgraph-hosted.mdx | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/pages/es/developer/create-subgraph-hosted.mdx b/pages/es/developer/create-subgraph-hosted.mdx index d6d8a966bcc6..142238359ffb 100644 --- a/pages/es/developer/create-subgraph-hosted.mdx +++ b/pages/es/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Cada entidad debe tener un campo `id`, que es de tipo `ID!` (string). El campo ` Admitimos los siguientes scalars en nuestra API GraphQL: -| Tipo | Descripción | -| --- | --- | -| `Bytes` | Byte array, representado como un string hexadecimal. Comúnmente utilizado para los hashes y direcciones de Ethereum. | -| `ID` | Almacenado como un `string`. | -| `String` | Scalar para valores `string`. Los caracteres null no se admiten y se eliminan automáticamente. | -| `Boolean` | Scalar para valores `boolean`. | -| `Int` | The GraphQL spec define `Int` para tener un tamano de 32 bytes. | -| `BigInt` | Números enteros grandes. Usados para los tipos `uint32`, `int64`, `uint64`, ..., `uint256` de Ethereum. Nota: Todo debajo de `uint32`, como `int32`, `uint24` o `int8` es representado como `i32`. | -| `BigDecimal` | `BigDecimal` Decimales de alta precisión representados como un signo y un exponente. El rango de exponentes va de -6143 a +6144. Redondeado a 34 dígitos significativos. | +| Tipo | Descripción | +| ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `Bytes` | Byte array, representado como un string hexadecimal. Comúnmente utilizado para los hashes y direcciones de Ethereum. | +| `ID` | Almacenado como un `string`. | +| `String` | Scalar para valores `string`. Los caracteres null no se admiten y se eliminan automáticamente. | +| `Boolean` | Scalar para valores `boolean`. | +| `Int` | The GraphQL spec define `Int` para tener un tamano de 32 bytes. | +| `BigInt` | Números enteros grandes. Usados para los tipos `uint32`, `int64`, `uint64`, ..., `uint256` de Ethereum. Nota: Todo debajo de `uint32`, como `int32`, `uint24` o `int8` es representado como `i32`. | +| `BigDecimal` | `BigDecimal` Decimales de alta precisión representados como un signo y un exponente. El rango de exponentes va de -6143 a +6144. Redondeado a 34 dígitos significativos. | #### Enums @@ -451,10 +451,10 @@ Diccionarios de idiomas admitidos: Algoritmos admitidos para ordenar los resultados: -| Algoritmos | Descripción | -| --- | --- | -| rango | Usa la calidad de coincidencia (0-1) de la consulta de texto completo para ordenar los resultados. | -| rango de proximidad | Similar al rango, pero también incluye la proximidad de los matches. | +| Algoritmos | Descripción | +| ------------------- | -------------------------------------------------------------------------------------------------- | +| rango | Usa la calidad de coincidencia (0-1) de la consulta de texto completo para ordenar los resultados. | +| rango de proximidad | Similar al rango, pero también incluye la proximidad de los matches. | ## Escribir mapeos @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **Nota:** Un nuevo origen de datos sólo procesará las llamadas y los eventos del bloque en el que fue creado y todos los bloques siguientes, pero no procesará los datos históricos, es decir, los datos que están contenidos en bloques anteriores. -> +> > Si los bloques anteriores contienen datos relevantes para la nueva fuente de datos, lo mejor es indexar esos datos leyendo el estado actual del contrato y creando entidades que representen ese estado en el momento de crear la nueva fuente de datos. ### Contexto de la fuente de datos @@ -684,7 +684,7 @@ dataSources: ``` > **Nota:** El bloque de creación del contrato se puede buscar rápidamente en Etherscan: -> +> > 1. Busca el contrato introduciendo su dirección en la barra de búsqueda. > 2. Haz clic en el hash de la transacción de creación en la sección `Contract Creator`. > 3. Carga la página de detalles de la transacción, donde encontrarás el bloque inicial de ese contrato. From 37d15e73035b776b6afeb22003171a16b329820e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:32 -0500 Subject: [PATCH 53/90] New translations graphql-api.mdx (Spanish) --- pages/es/developer/graphql-api.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/es/developer/graphql-api.mdx b/pages/es/developer/graphql-api.mdx index 5c584bc56bd0..fa335bef73d0 100644 --- a/pages/es/developer/graphql-api.mdx +++ b/pages/es/developer/graphql-api.mdx @@ -204,12 +204,12 @@ Las consultas de búsqueda de texto completo tienen un campo obligatorio, `text` Operadores de búsqueda de texto completo: -| Símbolo | Operador | Descripción | -| --- | --- | --- | -| `&` | `And` | Para combinar varios términos de búsqueda en un filtro para entidades que incluyen todos los términos proporcionados | -| | | `Or` | Las consultas con varios términos de búsqueda separados por o el operador devolverá todas las entidades que coincidan con cualquiera de los términos proporcionados | -| `<->` | `Follow by` | Especifica la distancia entre dos palabras. | -| `:*` | `Prefix` | Utilice el término de búsqueda del prefijo para encontrar palabras cuyo prefijo coincida (se requieren 2 caracteres.) | +| Símbolo | Operador | Descripción | +| ----------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `&` | `And` | Para combinar varios términos de búsqueda en un filtro para entidades que incluyen todos los términos proporcionados | +| | | `Or` | Las consultas con varios términos de búsqueda separados por o el operador devolverá todas las entidades que coincidan con cualquiera de los términos proporcionados | +| `<->` | `Follow by` | Especifica la distancia entre dos palabras. | +| `:*` | `Prefix` | Utilice el término de búsqueda del prefijo para encontrar palabras cuyo prefijo coincida (se requieren 2 caracteres.) | #### Ejemplos From 1a9d9ceb90e1abf32f17d4734ce5d6011d7af317 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:35 -0500 Subject: [PATCH 54/90] New translations graphql-api.mdx (Korean) --- pages/ko/developer/graphql-api.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/ko/developer/graphql-api.mdx b/pages/ko/developer/graphql-api.mdx index 65c0da07b871..41086bbb8627 100644 --- a/pages/ko/developer/graphql-api.mdx +++ b/pages/ko/developer/graphql-api.mdx @@ -204,12 +204,12 @@ _not_ends_with 전체 텍스트 검색 연산자: -| 심볼 | 연산자 | 설명 | -| --- | --- | --- | -| `&` | `And` | 제공된 모든 용어를 포함하는 엔터티에 대한 필터로, 여러 검색어를 결합하기 위해 사용합니다. | -| | | `Or` | the 혹은 오퍼레이터에 의해 구분된 다중 검색어들과 함께 쿼리는 제공된 어떠한 용어들로부터 일치하는 모든 엔티티들을 반환합니다. | -| `<->` | `Follow by` | 두 단어 사이의 거리를 지정합니다. | -| `:*` | `Prefix` | 접두사 검색어를 사용하여 접두사가 일치하는 단어를 찾습니다(2글자 필요). | +| 심볼 | 연산자 | 설명 | +| ----------- | ----------- | ------------------------------------------------------------------------ | +| `&` | `And` | 제공된 모든 용어를 포함하는 엔터티에 대한 필터로, 여러 검색어를 결합하기 위해 사용합니다. | +| | | `Or` | the 혹은 오퍼레이터에 의해 구분된 다중 검색어들과 함께 쿼리는 제공된 어떠한 용어들로부터 일치하는 모든 엔티티들을 반환합니다. | +| `<->` | `Follow by` | 두 단어 사이의 거리를 지정합니다. | +| `:*` | `Prefix` | 접두사 검색어를 사용하여 접두사가 일치하는 단어를 찾습니다(2글자 필요). | #### 예시 From 570d3374e8f3429b3e793014155a174d2c7d4cd4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:37 -0500 Subject: [PATCH 55/90] New translations graphql-api.mdx (Vietnamese) --- pages/vi/developer/graphql-api.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pages/vi/developer/graphql-api.mdx b/pages/vi/developer/graphql-api.mdx index 729409defd91..f2ab7b6eb8c3 100644 --- a/pages/vi/developer/graphql-api.mdx +++ b/pages/vi/developer/graphql-api.mdx @@ -204,12 +204,12 @@ Các truy vấn tìm kiếm toàn văn bản có một trường bắt buộc, ` Toán tử tìm kiếm toàn văn bản: -| Biểu tượng | Toán tử | Miêu tả | -| --- | --- | --- | -| `&` | `And` | Để kết hợp nhiều cụm từ tìm kiếm thành một bộ lọc cho các thực thể bao gồm tất cả các cụm từ được cung cấp | -| | | `Or` | Các truy vấn có nhiều cụm từ tìm kiếm được phân tách bằng toán tử hoặc sẽ trả về tất cả các thực thể có kết quả khớp với bất kỳ cụm từ nào được cung cấp | -| `<->` | `Follow by` | Chỉ định khoảng cách giữa hai từ. | -| `:*` | `Prefix` | Sử dụng cụm từ tìm kiếm tiền tố để tìm các từ có tiền tố khớp với nhau (yêu cầu 2 ký tự.) | +| Biểu tượng | Toán tử | Miêu tả | +| ----------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `&` | `And` | Để kết hợp nhiều cụm từ tìm kiếm thành một bộ lọc cho các thực thể bao gồm tất cả các cụm từ được cung cấp | +| | | `Or` | Các truy vấn có nhiều cụm từ tìm kiếm được phân tách bằng toán tử hoặc sẽ trả về tất cả các thực thể có kết quả khớp với bất kỳ cụm từ nào được cung cấp | +| `<->` | `Follow by` | Chỉ định khoảng cách giữa hai từ. | +| `:*` | `Prefix` | Sử dụng cụm từ tìm kiếm tiền tố để tìm các từ có tiền tố khớp với nhau (yêu cầu 2 ký tự.) | #### Các ví dụ From a616194fceb6be6ae2723595d60d741d8cc23f0b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 12:59:41 -0500 Subject: [PATCH 56/90] New translations matchstick.mdx (Chinese Simplified) --- pages/zh/developer/matchstick.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/zh/developer/matchstick.mdx b/pages/zh/developer/matchstick.mdx index b290daf76568..d3d0e1a213c7 100644 --- a/pages/zh/developer/matchstick.mdx +++ b/pages/zh/developer/matchstick.mdx @@ -135,7 +135,7 @@ Mapping terminated before handling trigger: oneshot canceled ### 用某种状态给商店补充 -用户能够用一组已知的实体来给商店注入水。下面是一个用 Gravatar 实体初始化商店的例子。 +用户能够用一组已知的实体来给商店注入水。下面是一个用Gravatar实体初始化商店的例子。 ```typescript let gravatar = new Gravatar('entryId') From 9f0cff9b849ef8684fdf1795ca9b8c736c13c38e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:07 -0500 Subject: [PATCH 57/90] New translations subgraph-studio.mdx (Spanish) --- pages/es/studio/subgraph-studio.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/es/studio/subgraph-studio.mdx b/pages/es/studio/subgraph-studio.mdx index 966b30ba2bac..28cfadea4edc 100644 --- a/pages/es/studio/subgraph-studio.mdx +++ b/pages/es/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ You’ve made it this far - congrats! Publishing your subgraph means that an IPF title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen - > +> Remember, while you’re going through your publishing flow, you’ll be able to push to either mainnet or Rinkeby, the testnet we support. If you’re a first time subgraph developer, we highly suggest you start with publishing to Rinkeby, which is free to do. This will allow you to see how the subgraph will work in The Graph Explorer and will allow you to test curation elements. From 28c367d2a7f1b54b381ada5430852325772244af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:09 -0500 Subject: [PATCH 58/90] New translations subgraph-studio.mdx (Japanese) --- pages/ja/studio/subgraph-studio.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/ja/studio/subgraph-studio.mdx b/pages/ja/studio/subgraph-studio.mdx index 8058d1acc22e..ade83087fe23 100644 --- a/pages/ja/studio/subgraph-studio.mdx +++ b/pages/ja/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ The Graph Network の機能やネットワークは順次追加されていき title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen - > +> 公開する際には、メインネットまたはテストネットである Rinkeby のどちらかに公開することができます。初めてサブグラフを開発される方は、まず Rinkeby への公開から始めることをお勧めします。これにより、サブグラフが The Graph Explorer でどのように動作するかを確認することができ、キュレーション要素をテストすることができます。 @@ -110,7 +110,7 @@ Dapp 開発者、サブグラフ開発者に関わらず、API キーを管理 - API キーの現在の使用状況を統計で表示: - クエリの数 - 使用した GRT の量 -2. **Manage Security Settings**では、API キーの管理レベルに応じて、セキュリティ設定を選択することができます。このセクションでは、以下のことができます: +2. **Manage Security Settings**では、APIキーの管理レベルに応じて、セキュリティ設定を選択することができます。このセクションでは、以下のことができます: - API キーの使用を許可されたドメイン名の表示と管理 - API キーでクエリ可能なサブグラフの割り当て From 59ad786c608fe5b37ec1056596ded0330b0cad68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:10 -0500 Subject: [PATCH 59/90] New translations subgraph-studio.mdx (Korean) --- pages/ko/studio/subgraph-studio.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ko/studio/subgraph-studio.mdx b/pages/ko/studio/subgraph-studio.mdx index a4e7755055c1..a8ada10bb731 100644 --- a/pages/ko/studio/subgraph-studio.mdx +++ b/pages/ko/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ The Graph 네트워크는 아직 호스팅 서비스에서 사용할 수 있는 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> 퍼블리싱 플로우를 진행하는 동안 메인넷이나 우리가 지원하는 테스트넷인 Rinkeby로 푸시할 수 있음을 기억하시기 바랍니다. 서브그래프 개발자가 처음이라면 무료인 Rinkeby에 퍼블리싱하는 것으로 시작하는 것이 좋습니다. 이를 통해 그래프 탐색기에서 서브그래프가 어떻게 작동하는지 확인하고 큐레이션 요소를 테스트할 수 있습니다. From 35ba607d02c7328d684d02a622fad1cdc7b0f030 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:12 -0500 Subject: [PATCH 60/90] New translations deploy-subgraph-studio.mdx (Arabic) --- pages/ar/studio/deploy-subgraph-studio.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ar/studio/deploy-subgraph-studio.mdx b/pages/ar/studio/deploy-subgraph-studio.mdx index 7ee7328b8c08..d89738b45b65 100644 --- a/pages/ar/studio/deploy-subgraph-studio.mdx +++ b/pages/ar/studio/deploy-subgraph-studio.mdx @@ -63,6 +63,6 @@ graph auth --studio graph deploy --studio ``` -بعد تشغيل هذا الأمر ، سيطلب الـ CLI أن تقوم بتسمية الإصدار ، ويمكنك تسميته كما تريد ، يمكنك استخدام تسميات مثل `0.1` و `0.2` أو استخدام الأحرف مثل `uniswap-v2-0.1`. ستكون هذه التسميات مرئية في Graph Explorer ويمكن استخدامها من قبل المنسقين (curators) لتقرير ما إذا كانوا يريدون الإشارة إلى هذا الإصدار أم لا ، لذا اختر بحكمة. +بعد تشغيل هذا الأمر ، سيطلب الـ CLI أن تقوم بتسمية الإصدار ، ويمكنك تسميته كما تريد ، يمكنك استخدام تسميات مثل ` 0.1 ` و ` 0.2 ` أو استخدام الأحرف مثل ` uniswap-v2-0.1 `. ستكون هذه التسميات مرئية في Graph Explorer ويمكن استخدامها من قبل المنسقين (curators) لتقرير ما إذا كانوا يريدون الإشارة إلى هذا الإصدار أم لا ، لذا اختر بحكمة. بمجرد النشر(deploy) ، يمكنك اختبار الـ subgraph الخاص بك في Subgraph Studio باستخدام playground، ونشر(deploy) إصدار آخر إذا لزم الأمر ، وتحديث البيانات الوصفية ، وعندما تكون جاهزًا ، قم بنشر(publish) الـ subgraph الخاص بك إلى Graph Explorer. From b0af990705ea96144ecd8725f36c78ae1489daa2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:14 -0500 Subject: [PATCH 61/90] New translations billing.mdx (Vietnamese) --- pages/vi/studio/billing.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/vi/studio/billing.mdx b/pages/vi/studio/billing.mdx index 8e98e0996567..d42fb8c4b92a 100644 --- a/pages/vi/studio/billing.mdx +++ b/pages/vi/studio/billing.mdx @@ -46,7 +46,7 @@ For a quick demo of how billing works on the Subgraph Studio, check out the vide title="Trình phát video YouTube" frameBorder="0" allowFullScreen - > +> ### Multisig Users From a49d0882d7d81ecb376bec788ada0c3e9a2cc808 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:17 -0500 Subject: [PATCH 62/90] New translations migrating-subgraph.mdx (Spanish) --- pages/es/hosted-service/migrating-subgraph.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/es/hosted-service/migrating-subgraph.mdx b/pages/es/hosted-service/migrating-subgraph.mdx index fb1617b67ea1..84b0def9ad1b 100644 --- a/pages/es/hosted-service/migrating-subgraph.mdx +++ b/pages/es/hosted-service/migrating-subgraph.mdx @@ -13,7 +13,7 @@ The process of migration is quick and your subgraphs will forever benefit from t If your subgraph is: - Indexing [IPFS](https://ipfs.io/). -- Using [full-text search fields](https://thegraph.com/docs/en/developer/create-subgraph-hosted/#defining-fulltext-search-fields). +- Using [full-text search fields](/developer/create-subgraph-hosted/#defining-fulltext-search-fields). - Indexing chains other than Ethereum mainnet. ### Migrating an Existing Subgraph to The Graph Network @@ -154,7 +154,7 @@ If you're still confused, fear not! Check out the following resources or watch o title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen - > +> - [The Graph Network Contracts](https://github.com/graphprotocol/contracts) From de7e5eb139d602084e0e1fd354577d211d427a75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:21 -0500 Subject: [PATCH 63/90] New translations migrating-subgraph.mdx (Korean) --- pages/ko/hosted-service/migrating-subgraph.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ko/hosted-service/migrating-subgraph.mdx b/pages/ko/hosted-service/migrating-subgraph.mdx index 6755533bcf0f..7ed6a4b8312f 100644 --- a/pages/ko/hosted-service/migrating-subgraph.mdx +++ b/pages/ko/hosted-service/migrating-subgraph.mdx @@ -154,7 +154,7 @@ If you're still confused, fear not! Check out the following resources or watch o title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> - [The Graph Network Contracts](https://github.com/graphprotocol/contracts) From 6e8355318def7866a1c6c004fc107ab64cbe4a30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:23 -0500 Subject: [PATCH 64/90] New translations migrating-subgraph.mdx (Vietnamese) --- pages/vi/hosted-service/migrating-subgraph.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/vi/hosted-service/migrating-subgraph.mdx b/pages/vi/hosted-service/migrating-subgraph.mdx index 9c2fc216a650..4843eccaa273 100644 --- a/pages/vi/hosted-service/migrating-subgraph.mdx +++ b/pages/vi/hosted-service/migrating-subgraph.mdx @@ -13,7 +13,7 @@ The process of migration is quick and your subgraphs will forever benefit from t If your subgraph is: - Indexing [IPFS](https://ipfs.io/). -- Using [full-text search fields](https://thegraph.com/docs/en/developer/create-subgraph-hosted/#defining-fulltext-search-fields). +- Using [full-text search fields](/developer/create-subgraph-hosted/#defining-fulltext-search-fields). - Indexing chains other than Ethereum mainnet. ### Migrating an Existing Subgraph to The Graph Network @@ -154,7 +154,7 @@ If you're still confused, fear not! Check out the following resources or watch o title="Trình phát video YouTube" frameBorder="0" allowFullScreen - > +> - [The Graph Network Contracts](https://github.com/graphprotocol/contracts) From 3a1300c24c386ff7a19917dfe123f2823ceb94a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:36 -0500 Subject: [PATCH 65/90] New translations billing.mdx (Arabic) --- pages/ar/studio/billing.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ar/studio/billing.mdx b/pages/ar/studio/billing.mdx index b41808395eb7..8f7568bb8907 100644 --- a/pages/ar/studio/billing.mdx +++ b/pages/ar/studio/billing.mdx @@ -46,7 +46,7 @@ title: الفوترة على Subgraph Studio title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen - > +> ### مستخدمو Multisig From eb4751b088cd0e5a896e77dee1ed914093614deb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:37 -0500 Subject: [PATCH 66/90] New translations billing.mdx (Japanese) --- pages/ja/studio/billing.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ja/studio/billing.mdx b/pages/ja/studio/billing.mdx index 5eac4d88a13d..a2250d788953 100644 --- a/pages/ja/studio/billing.mdx +++ b/pages/ja/studio/billing.mdx @@ -46,7 +46,7 @@ Subgraph Studio 上での課金機能のデモについては、以下のビデ title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen - > +> ### マルチシグユーザー From 8ea5bfb789ce79358751019f5ee68c0143a986dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:38 -0500 Subject: [PATCH 67/90] New translations billing.mdx (Korean) --- pages/ko/studio/billing.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ko/studio/billing.mdx b/pages/ko/studio/billing.mdx index 0d4433e3f939..66d3ddb46b68 100644 --- a/pages/ko/studio/billing.mdx +++ b/pages/ko/studio/billing.mdx @@ -46,7 +46,7 @@ Subgraph Studio에서 청구가 작동하는 방식에 대한 빠른 이해를 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> ### Multisig Users From a44f8b3aa4e80efb7291456fe70c810c5faf4b3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:39 -0500 Subject: [PATCH 68/90] New translations subgraph-studio.mdx (Vietnamese) --- pages/vi/studio/subgraph-studio.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/vi/studio/subgraph-studio.mdx b/pages/vi/studio/subgraph-studio.mdx index bf4f8e412b3f..570e8cac851f 100644 --- a/pages/vi/studio/subgraph-studio.mdx +++ b/pages/vi/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ You’ve made it this far - congrats! Publishing your subgraph means that an IPF title="Trình phát video YouTube" frameBorder="0" allowFullScreen - > +> Remember, while you’re going through your publishing flow, you’ll be able to push to either mainnet or Rinkeby, the testnet we support. If you’re a first time subgraph developer, we highly suggest you start with publishing to Rinkeby, which is free to do. This will allow you to see how the subgraph will work in The Graph Explorer and will allow you to test curation elements. From 223af780fb800ed697c40a0c2de22129b26a1171 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:42 -0500 Subject: [PATCH 69/90] New translations indexing.mdx (Spanish) --- pages/es/indexing.mdx | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/pages/es/indexing.mdx b/pages/es/indexing.mdx index 01cf9afbdfee..f7bf0dfa46ea 100644 --- a/pages/es/indexing.mdx +++ b/pages/es/indexing.mdx @@ -115,11 +115,11 @@ Los indexadores pueden diferenciarse aplicando técnicas avanzadas para tomar de - **Grande**: Preparado para indexar todos los subgrafos utilizados actualmente y atender solicitudes para el tráfico relacionado. | Configuración | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | -| --- | :-: | :-: | :-: | :-: | :-: | -| Pequeño | 4 | 8 | 1 | 4 | 16 | -| Estándar | 8 | 30 | 1 | 12 | 48 | -| Medio | 16 | 64 | 2 | 32 | 64 | -| Grande | 72 | 468 | 3,5 | 48 | 184 | +| ------------- |:--------------------------:|:-----------------------------------:|:---------------------------------:|:---------------------:|:------------------------------:| +| Pequeño | 4 | 8 | 1 | 4 | 16 | +| Estándar | 8 | 30 | 1 | 12 | 48 | +| Medio | 16 | 64 | 2 | 32 | 64 | +| Grande | 72 | 468 | 3,5 | 48 | 184 | ### ¿Cuáles son algunas de las precauciones de seguridad básicas que debe tomar un indexador? @@ -151,24 +151,24 @@ Nota: Para admitir el escalado ágil, se recomienda que las inquietudes de consu #### Graph Node -| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | -| --- | --- | --- | --- | --- | -| 8000 | Servidor HTTP GraphQL
(para consultas de subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(para suscripciones a subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(para administrar implementaciones) | / | --admin-port | - | -| 8030 | API de estado de indexación de subgrafos | /graphql | --index-node-port | - | -| 8040 | Métricas de Prometheus | /metrics | --metrics-port | - | +| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | +| ------ | -------------------------------------------------------------- | ---------------------------------------------------- | ----------------- | ------------------- | +| 8000 | Servidor HTTP GraphQL
(para consultas de subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(para suscripciones a subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(para administrar implementaciones) | / | --admin-port | - | +| 8030 | API de estado de indexación de subgrafos | /graphql | --index-node-port | - | +| 8040 | Métricas de Prometheus | /metrics | --metrics-port | - | #### Servicio de Indexador -| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | -| --- | --- | --- | --- | --- | -| 7600 | Servidor HTTP GraphQL
(para consultas de subgrafo pagadas) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Métricas de Prometheus | /metrics | --metrics-port | - | +| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | +| ------ | --------------------------------------------------------------------- | ----------------------------------------------------------------------- | -------------- | ---------------------- | +| 7600 | Servidor HTTP GraphQL
(para consultas de subgrafo pagadas) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Métricas de Prometheus | /metrics | --metrics-port | - | #### Agente Indexador -| Puerto | Objeto | Rutas | Argumento CLI | Variable de
Entorno | +| Puerto | Objeto | Rutas | Argumento CLI | Variable de
Entorno | | ------ | ----------------------------- | ----- | ------------------------- | --------------------------------------- | | 8000 | API de gestión de indexadores | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | From 3af1f02ef4c1e3521223cd2bf04ba86c28d6e5da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:46 -0500 Subject: [PATCH 70/90] New translations indexing.mdx (Japanese) --- pages/ja/indexing.mdx | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/pages/ja/indexing.mdx b/pages/ja/indexing.mdx index ad80d2257638..f8a0d760efae 100644 --- a/pages/ja/indexing.mdx +++ b/pages/ja/indexing.mdx @@ -114,12 +114,12 @@ Use Etherscan to call `getRewards()`: - **Medium** - 100 個のサブグラフと 1 秒あたり 200 ~ 500 のリクエストをサポートするプロダクションインデクサー - **Large** - 現在使用されているすべてのサブグラフのインデックスを作成し、関連するトラフィックのリクエストに対応します -| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | -| --- | :-: | :-: | :-: | :-: | :-: | -| Small | 4 | 8 | 1 | 4 | 16 | -| Standard | 8 | 30 | 1 | 12 | 48 | -| Medium | 16 | 64 | 2 | 32 | 64 | -| Large | 72 | 468 | 3.5 | 48 | 184 | +| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | +| -------- |:--------------------------:|:-----------------------------------:|:---------------------------------:|:---------------------:|:------------------------------:| +| Small | 4 | 8 | 1 | 4 | 16 | +| Standard | 8 | 30 | 1 | 12 | 48 | +| Medium | 16 | 64 | 2 | 32 | 64 | +| Large | 72 | 468 | 3.5 | 48 | 184 | ### インデクサーが取るべきセキュリティ対策は? @@ -151,20 +151,20 @@ Use Etherscan to call `getRewards()`: #### グラフノード -| Port | Purpose | Routes | CLI Argument | Environment Variable | -| --- | --- | --- | --- | --- | -| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(for managing deployments) | / | --admin-port | - | -| 8030 | Subgraph indexing status API | /graphql | --index-node-port | - | -| 8040 | Prometheus metrics | /metrics | --metrics-port | - | +| Port | Purpose | Routes | CLI Argument | Environment Variable | +| ---- | ------------------------------------------------------- | ------------------------------------------------------------------- | ----------------- | -------------------- | +| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(for managing deployments) | / | --admin-port | - | +| 8030 | Subgraph indexing status API | /graphql | --index-node-port | - | +| 8040 | Prometheus metrics | /metrics | --metrics-port | - | #### Indexer Service -| Port | Purpose | Routes | CLI Argument | Environment Variable | -| --- | --- | --- | --- | --- | -| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus metrics | /metrics | --metrics-port | - | +| Port | Purpose | Routes | CLI Argument | Environment Variable | +| ---- | ------------------------------------------------------------ | --------------------------------------------------------------------------- | -------------- | ---------------------- | +| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus metrics | /metrics | --metrics-port | - | #### Indexer Agent From c78aea4beb7ae2835315215183231eb7080a3f07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:47 -0500 Subject: [PATCH 71/90] New translations indexing.mdx (Korean) --- pages/ko/indexing.mdx | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/pages/ko/indexing.mdx b/pages/ko/indexing.mdx index f04d20aa1da5..7764f52318f7 100644 --- a/pages/ko/indexing.mdx +++ b/pages/ko/indexing.mdx @@ -114,12 +114,12 @@ query indexerAllocations { - **Medium** - 100개의 Subgraph 및 초당 200 - 500개의 요청을 서포트 할 수 있는 프로덕션 인덱서입니다. - **Large** - 현재 사용되는 모든 서브그래프들 및 관련 트레픽 요청의 처리에 대한 요건을 충족합니다. -| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | -| --- | :-: | :-: | :-: | :-: | :-: | -| Small | 4 | 8 | 1 | 4 | 16 | -| Standard | 8 | 30 | 1 | 12 | 48 | -| Medium | 16 | 64 | 2 | 32 | 64 | -| Large | 72 | 468 | 3.5 | 48 | 184 | +| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | +| -------- |:--------------------------:|:-----------------------------------:|:---------------------------------:|:---------------------:|:------------------------------:| +| Small | 4 | 8 | 1 | 4 | 16 | +| Standard | 8 | 30 | 1 | 12 | 48 | +| Medium | 16 | 64 | 2 | 32 | 64 | +| Large | 72 | 468 | 3.5 | 48 | 184 | ### 인덱서가 취해야 할 기본적인 보안 예방 조치는 무엇인가요? @@ -151,26 +151,26 @@ query indexerAllocations { #### 그래프 노드 -| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | -| --- | --- | --- | --- | --- | -| 8000 | GraphQL HTTP server
(서브그래프 쿼리용) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(서브그래프 구독용) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(배포 관리용) | / | --admin-port | - | -| 8030 | 서브그래프 인덱싱 상태 API | /graphql | --index-node-port | - | -| 8040 | Prometheus metrics | /metrics | --metrics-port | - | +| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | +| ---- | ------------------------------------------ | ---------------------------------------------------- | ----------------- | ----- | +| 8000 | GraphQL HTTP server
(서브그래프 쿼리용) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(서브그래프 구독용) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(배포 관리용) | / | --admin-port | - | +| 8030 | 서브그래프 인덱싱 상태 API | /graphql | --index-node-port | - | +| 8040 | Prometheus metrics | /metrics | --metrics-port | - | #### 인덱서 서비스 -| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | -| --- | --- | --- | --- | --- | -| 7600 | GraphQL HTTP server
(유료 서브그래프 쿼리용) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus metrics | /metrics | --metrics-port | - | +| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | +| ---- | ----------------------------------------------- | ----------------------------------------------------------------------- | -------------- | ---------------------- | +| 7600 | GraphQL HTTP server
(유료 서브그래프 쿼리용) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus metrics | /metrics | --metrics-port | - | #### 인덱서 에이전트 -| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | -| ---- | --------------- | ---- | ------------------------- | --------------------------------------- | -| 8000 | 인덱서 관리 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | +| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | +| ---- | ---------- | -- | ------------------------- | --------------------------------------- | +| 8000 | 인덱서 관리 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | ### Google Cloud상의 Terraform을 사용한 서버 인프라 구축 @@ -600,7 +600,7 @@ default => 0.1 * $SYSTEM_LOAD; 비용 모델 예시: -| 쿼리 | 가격 | +| 쿼리 | 가격 | | ---------------------------------------------------------------------------- | ------- | | { pairs(skip: 5000) { id } } | 0.5 GRT | | { tokens { symbol } } | 0.1 GRT | From 9752c45ecdf57d0fc4094f7ce757b2d6c96a4ea6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:49 -0500 Subject: [PATCH 72/90] New translations indexing.mdx (Chinese Simplified) --- pages/zh/indexing.mdx | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/pages/zh/indexing.mdx b/pages/zh/indexing.mdx index 1a08e70528e3..7dafdbe96174 100644 --- a/pages/zh/indexing.mdx +++ b/pages/zh/indexing.mdx @@ -115,11 +115,11 @@ query indexerAllocations { - **大型** -准备对当前使用的所有子图进行索引,并为相关流量的请求提供服务 | 类型 | (CPU 数量) | (内存 GB) | (硬盘 TB) | (CPU 数量) | (内存 GB) | -| ---- | :--------: | :-------: | :-------: | :--------: | :-------: | -| 小型 | 4 | 8 | 1 | 4 | 16 | -| 标准 | 8 | 30 | 1 | 12 | 48 | -| 中型 | 16 | 64 | 2 | 32 | 64 | -| 大型 | 72 | 468 | 3.5 | 48 | 184 | +| -- |:--------:|:-------:|:-------:|:--------:|:-------:| +| 小型 | 4 | 8 | 1 | 4 | 16 | +| 标准 | 8 | 30 | 1 | 12 | 48 | +| 中型 | 16 | 64 | 2 | 32 | 64 | +| 大型 | 72 | 468 | 3.5 | 48 | 184 | ### 索引人应该采取哪些基本的安全防范措施? @@ -151,26 +151,26 @@ query indexerAllocations { #### Graph 节点 -| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | -| --- | --- | --- | --- | --- | -| 8000 | GraphQL HTTP 服务
(用于子图查询) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(用于子图订阅) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(用于管理部署) | / | --admin-port | - | -| 8030 | 子图索引状态 API | /graphql | --index-node-port | - | -| 8040 | Prometheus 指标 | /metrics | --metrics-port | - | +| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | +| ---- | ------------------------------------ | ------------------------------------------------------------------- | ----------------- | ----- | +| 8000 | GraphQL HTTP 服务
(用于子图查询) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(用于子图订阅) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(用于管理部署) | / | --admin-port | - | +| 8030 | 子图索引状态 API | /graphql | --index-node-port | - | +| 8040 | Prometheus 指标 | /metrics | --metrics-port | - | #### 索引人服务 -| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | -| --- | --- | --- | --- | --- | -| 7600 | GraphQL HTTP 服务
(用于付费子图查询) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus 指标 | /metrics | --metrics-port | - | +| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | +| ---- | -------------------------------------- | --------------------------------------------------------------------------- | -------------- | ---------------------- | +| 7600 | GraphQL HTTP 服务
(用于付费子图查询) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus 指标 | /metrics | --metrics-port | - | #### 索引人代理 -| 端口 | 用途 | 路径 | CLI 参数 | 环境
变量 | -| ---- | -------------- | ---- | ------------------------- | --------------------------------------- | -| 8000 | 索引人管理 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | +| 端口 | 用途 | 路径 | CLI 参数 | 环境
变量 | +| ---- | --------- | -- | ------------------------- | --------------------------------------- | +| 8000 | 索引人管理 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | ### Google Cloud 上使用 Terraform 建立基础架构 @@ -600,7 +600,7 @@ default => 0.1 * $SYSTEM_LOAD; 成本模型示例: -| 询问 | 价格 | +| 询问 | 价格 | | ---------------------------------------------------------------------------- | ------- | | { pairs(skip: 5000) { id } } | 0.5 GRT | | { tokens { symbol } } | 0.1 GRT | From 81772179c22ad643ca9eb059a99b658f31093d2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:50 -0500 Subject: [PATCH 73/90] New translations indexing.mdx (Vietnamese) --- pages/vi/indexing.mdx | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/pages/vi/indexing.mdx b/pages/vi/indexing.mdx index 3c2108b02fcf..5e578fa971f9 100644 --- a/pages/vi/indexing.mdx +++ b/pages/vi/indexing.mdx @@ -114,12 +114,12 @@ Indexer có thể tự phân biệt bản thân bằng cách áp dụng các k - **Trung bình** - Công cụ indexing production hỗ trợ 100 đồ subgraph và 200-500 yêu cầu mỗi giây. - **Lớn** - Được chuẩn bị để index tất cả các subgraph hiện đang được sử dụng và phục vụ các yêu cầu cho lưu lượng truy cập liên quan. -| Cài đặt | Postgres
(CPUs) | Postgres
(bộ nhớ tính bằng GB) | Postgres
(đĩa tính bằng TB) | VMs
(CPUs) | VMs
(bộ nhớ tính bằng GB) | -| --- | :-: | :-: | :-: | :-: | :-: | -| Nhỏ | 4 | 8 | 1 | 4 | 16 | -| Tiêu chuẩn | 8 | 30 | 1 | 12 | 48 | -| Trung bình | 16 | 64 | 2 | 32 | 64 | -| Lớn | 72 | 468 | 3.5 | 48 | 184 | +| Cài đặt | Postgres
(CPUs) | Postgres
(bộ nhớ tính bằng GB) | Postgres
(đĩa tính bằng TB) | VMs
(CPUs) | VMs
(bộ nhớ tính bằng GB) | +| ----------- |:--------------------------:|:-----------------------------------------:|:--------------------------------------:|:---------------------:|:------------------------------------:| +| Nhỏ | 4 | 8 | 1 | 4 | 16 | +| Tiêu chuẩn | 8 | 30 | 1 | 12 | 48 | +| Trung bình | 16 | 64 | 2 | 32 | 64 | +| Lớn | 72 | 468 | 3.5 | 48 | 184 | ### Một số biện pháp phòng ngừa bảo mật cơ bản mà indexer nên thực hiện là gì? @@ -151,20 +151,20 @@ Lưu ý: Để hỗ trợ mở rộng quy mô nhanh, bạn nên tách các mối #### Graph Node -| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | -| --- | --- | --- | --- | --- | -| 8000 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(cho các đăng ký subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(để quản lý triển khai) | / | --admin-port | - | -| 8030 | API trạng thái lập chỉ mục Subgraph | /graphql | --index-node-port | - | -| 8040 | Số liệu Prometheus | /metrics | --metrics-port | - | +| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | +| ---- | ----------------------------------------------------------- | ---------------------------------------------------- | ----------------- | --------------- | +| 8000 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(cho các đăng ký subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(để quản lý triển khai) | / | --admin-port | - | +| 8030 | API trạng thái lập chỉ mục Subgraph | /graphql | --index-node-port | - | +| 8040 | Số liệu Prometheus | /metrics | --metrics-port | - | #### Dịch vụ Indexer -| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | -| --- | --- | --- | --- | --- | -| 7600 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph có trả phí) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Số liệu Prometheus | /metrics | --metrics-port | - | +| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | +| ---- | ---------------------------------------------------------------------- | ----------------------------------------------------------------------- | -------------- | ---------------------- | +| 7600 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph có trả phí) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Số liệu Prometheus | /metrics | --metrics-port | - | #### Đại lý Indexer From e0332dff5b8b78c2a082179fa53bfdd4fb17fcdf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:00:53 -0500 Subject: [PATCH 74/90] New translations explorer.mdx (Chinese Simplified) --- pages/zh/explorer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/zh/explorer.mdx b/pages/zh/explorer.mdx index af72c5557ff9..85698d600f9e 100644 --- a/pages/zh/explorer.mdx +++ b/pages/zh/explorer.mdx @@ -11,7 +11,7 @@ title: 浏览器 title="YouTube video player" frameBorder="0" allowFullScreen - > +> ## 子图 From b224c0bd8b16464433d3794231aeab8677de14e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:00 -0500 Subject: [PATCH 75/90] New translations explorer.mdx (Vietnamese) --- pages/vi/explorer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/vi/explorer.mdx b/pages/vi/explorer.mdx index 5c5573c0abdf..1bb93f9bc45c 100644 --- a/pages/vi/explorer.mdx +++ b/pages/vi/explorer.mdx @@ -11,7 +11,7 @@ Chào mừng bạn đến với Graph Explorer, hay như chúng tôi thường g title="Trình phát video YouTube" frameBorder="0" allowFullScreen - > +> ## Subgraphs From f2f1e9c6c677c4f5e2b9c8e79a6d4d6d34d64378 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:01 -0500 Subject: [PATCH 76/90] New translations explorer.mdx (Korean) --- pages/ko/explorer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ko/explorer.mdx b/pages/ko/explorer.mdx index b7b9d9f43930..02a0697dc6bf 100644 --- a/pages/ko/explorer.mdx +++ b/pages/ko/explorer.mdx @@ -11,7 +11,7 @@ title: 탐색기 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> ## 서브그래프 From 5726a29f4085447c359c6f53b1b1085a66ed2b23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:03 -0500 Subject: [PATCH 77/90] New translations curating.mdx (Chinese Simplified) --- pages/zh/curating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/zh/curating.mdx b/pages/zh/curating.mdx index 774fac8c90ee..f53632ba91b8 100644 --- a/pages/zh/curating.mdx +++ b/pages/zh/curating.mdx @@ -100,5 +100,5 @@ Remember that curation is risky. 请做好你的工作,确保你在你信任 title="YouTube video player" frameBorder="0" allowFullScreen - > +> From 7dbb0ba48868d654042da483ff43cf175f92ed6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:08 -0500 Subject: [PATCH 78/90] New translations curating.mdx (Spanish) --- pages/es/curating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/es/curating.mdx b/pages/es/curating.mdx index a3d986829e1d..425cb5608b6f 100644 --- a/pages/es/curating.mdx +++ b/pages/es/curating.mdx @@ -100,5 +100,5 @@ Las participaciones de un curador no se pueden "comprar" o "vender" como otros t title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen - > +> From ffd34ed18898e573c74670de5aaa9b1eeb38ac2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:09 -0500 Subject: [PATCH 79/90] New translations curating.mdx (Arabic) --- pages/ar/curating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ar/curating.mdx b/pages/ar/curating.mdx index b13e20525f2f..6e37a8776a6f 100644 --- a/pages/ar/curating.mdx +++ b/pages/ar/curating.mdx @@ -100,5 +100,5 @@ title: (التنسيق) curating title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen - > +> From 5020e32888131da67f6eb2f67cd66c732504a133 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:10 -0500 Subject: [PATCH 80/90] New translations curating.mdx (Japanese) --- pages/ja/curating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ja/curating.mdx b/pages/ja/curating.mdx index 03a6c67b0b57..06367abdcc50 100644 --- a/pages/ja/curating.mdx +++ b/pages/ja/curating.mdx @@ -100,5 +100,5 @@ The Graph の場合は、 [Bancor が実装しているボンディングカー title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> From 947e77c4f0881f588229f7b7ca094d4a1929829f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:11 -0500 Subject: [PATCH 81/90] New translations curating.mdx (Korean) --- pages/ko/curating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ko/curating.mdx b/pages/ko/curating.mdx index dcb329288947..456deec666f7 100644 --- a/pages/ko/curating.mdx +++ b/pages/ko/curating.mdx @@ -100,5 +100,5 @@ title: 큐레이팅 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> From 0f88f3812ff917d7ede619a66147b124486c32cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:13 -0500 Subject: [PATCH 82/90] New translations curating.mdx (Vietnamese) --- pages/vi/curating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/vi/curating.mdx b/pages/vi/curating.mdx index 32018f0aa360..1affd60eaf9d 100644 --- a/pages/vi/curating.mdx +++ b/pages/vi/curating.mdx @@ -100,5 +100,5 @@ Vẫn còn thắc mắc? Xem video hướng dẫn Curation của chúng tôi bê title="Trình phát video YouTube" frameBorder="0" allowFullScreen - > +> From 5a5c1c99aefba1c9ed9825b5d10397a43eb207f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:14 -0500 Subject: [PATCH 83/90] New translations explorer.mdx (Japanese) --- pages/ja/explorer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ja/explorer.mdx b/pages/ja/explorer.mdx index 5494043c66f5..95bdbb2f3bdc 100644 --- a/pages/ja/explorer.mdx +++ b/pages/ja/explorer.mdx @@ -11,7 +11,7 @@ title: エクスプローラー title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen - > +> ## サブグラフ From a7c9ec5c93097afd3145abf31a10404c2c963fcf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:15 -0500 Subject: [PATCH 84/90] New translations delegating.mdx (Spanish) --- pages/es/delegating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/es/delegating.mdx b/pages/es/delegating.mdx index 378a35378ae3..ec596e39f1ac 100644 --- a/pages/es/delegating.mdx +++ b/pages/es/delegating.mdx @@ -95,5 +95,5 @@ Esta guía proporciona una revisión completa de este documento, y cómo tener e title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen - > +> From 4f668a1f6634590c8866b051865aff55d666dac2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:18 -0500 Subject: [PATCH 85/90] New translations delegating.mdx (Arabic) --- pages/ar/delegating.mdx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pages/ar/delegating.mdx b/pages/ar/delegating.mdx index 19e582cab7ff..f13340ace765 100644 --- a/pages/ar/delegating.mdx +++ b/pages/ar/delegating.mdx @@ -32,7 +32,9 @@ title: المفوض(Delegator) إذا اخترت مفهرسا ليس جديرا بالثقة ، أو لا يقوم بعمل جيد ، فستحتاج إلى إلغاء التفويض ، مما يعني أنك ستفقد الكثير من الفرص لكسب المكافآت وعند قيامك بالتفويض مرة أخرى عند مفهرس آخر فحينها سيتم حرق 0.5% من GRT المفوضة. -
لاحظ 0.5٪ رسوم التفويض ، بالإضافة إلى فترة 28 يوما لإلغاء التفويض.
+
+ لاحظ 0.5٪ رسوم التفويض ، بالإضافة إلى فترة 28 يوما لإلغاء التفويض. +
### اختيار مفهرس جدير بالثقة مع عائد جيد للمفوضين @@ -90,5 +92,5 @@ title: المفوض(Delegator) title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen - > +> From 30fab37b66d35062b06e85ecc72ccaa4aba6978e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:21 -0500 Subject: [PATCH 86/90] New translations delegating.mdx (Korean) --- pages/ko/delegating.mdx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pages/ko/delegating.mdx b/pages/ko/delegating.mdx index 09d3ee53b7ee..8b9ca4863ca1 100644 --- a/pages/ko/delegating.mdx +++ b/pages/ko/delegating.mdx @@ -32,7 +32,9 @@ title: 위임하기 Indexing Reward Cut – Indexing Reward Cut은 인덱서가 스스로 가져갈 보상의 비율입니다. 즉, 100%로 설정된 경우 위임자에게 주어지는 인덱싱 보상이 0이 됩니다. 만약 UI에 80%로 표시되어 있다면, 이는 여러분은 위임자로서 20%를 받게 된다는 것을 의미합니다. 중요 참고 사항 - 네트워크 시작 부분의 인덱싱 보상이 보상의 대부분을 차지합니다. -
위임 UI에는 0.5%의 수수료 및 28일의 위임 해지 기간이 명시되어있습니다.
+
+ 위임 UI에는 0.5%의 수수료 및 28일의 위임 해지 기간이 명시되어있습니다. +
### 위임자들에 대한 공정한 보상 지급 규칙을 지닌 신뢰할 수 있는 인덱서 선택 @@ -91,5 +93,5 @@ This guide provides a full review of this document, and how to consider everythi title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen - > +> From b335dc4b79486dc15278b267a3ecd0a3ed2825c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:23 -0500 Subject: [PATCH 87/90] New translations delegating.mdx (Vietnamese) --- pages/vi/delegating.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/vi/delegating.mdx b/pages/vi/delegating.mdx index c7f73c64a544..aad7059eb09b 100644 --- a/pages/vi/delegating.mdx +++ b/pages/vi/delegating.mdx @@ -94,5 +94,5 @@ Hướng dẫn này cung cấp đánh giá đầy đủ về tài liệu này v title="YouTube video player" frameBorder="0" allowFullScreen - > +> From a7ca03f8ba09d1f99af61a214c095b0dd35bf26d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:24 -0500 Subject: [PATCH 88/90] New translations explorer.mdx (Spanish) --- pages/es/explorer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/es/explorer.mdx b/pages/es/explorer.mdx index 676a3ad54e39..6ede1f9592e3 100644 --- a/pages/es/explorer.mdx +++ b/pages/es/explorer.mdx @@ -11,7 +11,7 @@ Bienvenido al explorador de The Graph, o como nos gusta llamarlo, tu portal desc title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen - > +> ## Subgrafos From 50720237f545351983bf73bc65c2069c159777b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Rouleau?= Date: Thu, 3 Mar 2022 13:01:25 -0500 Subject: [PATCH 89/90] New translations explorer.mdx (Arabic) --- pages/ar/explorer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/ar/explorer.mdx b/pages/ar/explorer.mdx index 26b05bf307a6..652e914fe353 100644 --- a/pages/ar/explorer.mdx +++ b/pages/ar/explorer.mdx @@ -11,7 +11,7 @@ title: مستكشف title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen - > +> ## Subgraphs From 9fe96398a183d4ab6434c023fc2690b0b0f465c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benoi=CC=82t=20Rouleau?= Date: Thu, 3 Mar 2022 13:15:42 -0500 Subject: [PATCH 90/90] Run Prettier + fix build --- pages/ar/curating.mdx | 2 +- pages/ar/delegating.mdx | 6 +- pages/ar/developer/assemblyscript-api.mdx | 14 ++-- .../assemblyscript-migration-guide.mdx | 5 ++ pages/ar/developer/create-subgraph-hosted.mdx | 22 ++--- pages/ar/developer/graphql-api.mdx | 12 +-- pages/ar/developer/subgraph-debug-forking.mdx | 8 +- pages/ar/explorer.mdx | 2 +- .../ar/hosted-service/migrating-subgraph.mdx | 2 +- pages/ar/indexing.mdx | 24 +++--- pages/ar/studio/billing.mdx | 2 +- pages/ar/studio/deploy-subgraph-studio.mdx | 2 +- pages/ar/studio/subgraph-studio.mdx | 2 +- pages/ar/supported-networks/near.mdx | 12 +-- pages/es/curating.mdx | 2 +- pages/es/delegating.mdx | 2 +- pages/es/developer/assemblyscript-api.mdx | 14 ++-- .../assemblyscript-migration-guide.mdx | 5 ++ pages/es/developer/create-subgraph-hosted.mdx | 30 +++---- pages/es/developer/graphql-api.mdx | 12 +-- pages/es/developer/subgraph-debug-forking.mdx | 4 +- pages/es/explorer.mdx | 2 +- .../es/hosted-service/migrating-subgraph.mdx | 2 +- pages/es/indexing.mdx | 34 ++++---- pages/es/studio/billing.mdx | 2 +- pages/es/studio/subgraph-studio.mdx | 2 +- pages/ja/curating.mdx | 2 +- pages/ja/delegating.mdx | 4 +- pages/ja/developer/assemblyscript-api.mdx | 12 +-- .../assemblyscript-migration-guide.mdx | 5 ++ pages/ja/developer/create-subgraph-hosted.mdx | 34 ++++---- pages/ja/developer/graphql-api.mdx | 14 ++-- pages/ja/developer/subgraph-debug-forking.mdx | 36 ++++---- pages/ja/explorer.mdx | 2 +- .../ja/hosted-service/migrating-subgraph.mdx | 16 ++-- pages/ja/indexing.mdx | 34 ++++---- pages/ja/studio/billing.mdx | 2 +- pages/ja/studio/studio-faq.mdx | 6 +- pages/ja/studio/subgraph-studio.mdx | 4 +- pages/ko/curating.mdx | 2 +- pages/ko/delegating.mdx | 6 +- pages/ko/developer/assemblyscript-api.mdx | 12 +-- .../assemblyscript-migration-guide.mdx | 5 ++ pages/ko/developer/create-subgraph-hosted.mdx | 68 +++++++-------- pages/ko/developer/graphql-api.mdx | 12 +-- pages/ko/explorer.mdx | 2 +- .../ko/hosted-service/migrating-subgraph.mdx | 2 +- pages/ko/indexing.mdx | 42 +++++----- pages/ko/studio/billing.mdx | 2 +- pages/ko/studio/subgraph-studio.mdx | 2 +- pages/vi/curating.mdx | 2 +- pages/vi/delegating.mdx | 2 +- pages/vi/developer/assemblyscript-api.mdx | 14 ++-- .../assemblyscript-migration-guide.mdx | 5 ++ pages/vi/developer/create-subgraph-hosted.mdx | 22 ++--- pages/vi/developer/graphql-api.mdx | 12 +-- pages/vi/explorer.mdx | 2 +- .../vi/hosted-service/migrating-subgraph.mdx | 2 +- pages/vi/indexing.mdx | 34 ++++---- pages/vi/studio/billing.mdx | 2 +- pages/vi/studio/subgraph-studio.mdx | 2 +- pages/zh/curating.mdx | 2 +- pages/zh/delegating.mdx | 6 +- pages/zh/developer/assemblyscript-api.mdx | 82 +++++++++---------- .../assemblyscript-migration-guide.mdx | 5 ++ pages/zh/developer/create-subgraph-hosted.mdx | 64 +++++++-------- pages/zh/developer/graphql-api.mdx | 12 +-- pages/zh/developer/matchstick.mdx | 2 +- pages/zh/developer/subgraph-debug-forking.mdx | 16 ++-- pages/zh/explorer.mdx | 2 +- .../zh/hosted-service/migrating-subgraph.mdx | 14 ++-- .../hosted-service/what-is-hosted-service.mdx | 4 +- pages/zh/indexing.mdx | 40 ++++----- pages/zh/studio/billing.mdx | 2 +- pages/zh/studio/multisig.mdx | 4 +- pages/zh/studio/subgraph-studio.mdx | 6 +- pages/zh/supported-networks/near.mdx | 10 +-- 77 files changed, 473 insertions(+), 449 deletions(-) diff --git a/pages/ar/curating.mdx b/pages/ar/curating.mdx index 6e37a8776a6f..b13e20525f2f 100644 --- a/pages/ar/curating.mdx +++ b/pages/ar/curating.mdx @@ -100,5 +100,5 @@ title: (التنسيق) curating title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen -> + > diff --git a/pages/ar/delegating.mdx b/pages/ar/delegating.mdx index f13340ace765..19e582cab7ff 100644 --- a/pages/ar/delegating.mdx +++ b/pages/ar/delegating.mdx @@ -32,9 +32,7 @@ title: المفوض(Delegator) إذا اخترت مفهرسا ليس جديرا بالثقة ، أو لا يقوم بعمل جيد ، فستحتاج إلى إلغاء التفويض ، مما يعني أنك ستفقد الكثير من الفرص لكسب المكافآت وعند قيامك بالتفويض مرة أخرى عند مفهرس آخر فحينها سيتم حرق 0.5% من GRT المفوضة. -
- لاحظ 0.5٪ رسوم التفويض ، بالإضافة إلى فترة 28 يوما لإلغاء التفويض. -
+
لاحظ 0.5٪ رسوم التفويض ، بالإضافة إلى فترة 28 يوما لإلغاء التفويض.
### اختيار مفهرس جدير بالثقة مع عائد جيد للمفوضين @@ -92,5 +90,5 @@ title: المفوض(Delegator) title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen -> + > diff --git a/pages/ar/developer/assemblyscript-api.mdx b/pages/ar/developer/assemblyscript-api.mdx index c2d82023b87f..3e5aa0b700ca 100644 --- a/pages/ar/developer/assemblyscript-api.mdx +++ b/pages/ar/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install --save-dev @graphprotocol/graph-ts # NPM الـ `apiVersion` في الـ subgraph manifest تحدد إصدار الـ mapping API الذي يتم تشغيله بواسطة Graph Node للـ subgraph المحدد. الاصدار الحالي لـ mapping API هو 0.0.6. -| الاصدار | ملاحظات الإصدار | -|:-------:| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| 0.0.6 | تمت إضافة حقل `nonce` إلى كائن إجراء الـ Ethereum
تمت إضافة `baseFeePerGas` إلى كائن Ethereum Block | -| 0.0.5 | تمت ترقية AssemblyScript إلى الإصدار 0.19.10 (يرجى الاطلاع على [ `دليل الترحيل` ](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` أعيد تسميته إلى `ethereum.transaction.gasLimit` | -| 0.0.4 | تمت إضافة حقل `functionSignature` إلى كائن Ethereum SmartContractCall | -| 0.0.3 | تمت إضافةحقل `from` إلى كائن Ethereum Call
`etherem.call.address` تمت إعادة تسميته إلى `ethereum.call.to` | -| 0.0.2 | تمت إضافة حقل `input` إلى كائن إجراء Ethereum | +| الاصدار | ملاحظات الإصدار | +| :-: | --- | +| 0.0.6 | تمت إضافة حقل `nonce` إلى كائن إجراء الـ Ethereum
تمت إضافة `baseFeePerGas` إلى كائن Ethereum Block | +| 0.0.5 | تمت ترقية AssemblyScript إلى الإصدار 0.19.10 (يرجى الاطلاع على [ `دليل الترحيل` ](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` أعيد تسميته إلى `ethereum.transaction.gasLimit` | +| 0.0.4 | تمت إضافة حقل `functionSignature` إلى كائن Ethereum SmartContractCall | +| 0.0.3 | تمت إضافةحقل `from` إلى كائن Ethereum Call
`etherem.call.address` تمت إعادة تسميته إلى `ethereum.call.to` | +| 0.0.2 | تمت إضافة حقل `input` إلى كائن إجراء Ethereum | ### الأنواع المضمنة (Built-in) diff --git a/pages/ar/developer/assemblyscript-migration-guide.mdx b/pages/ar/developer/assemblyscript-migration-guide.mdx index 3e5ea9d0315d..d20ebc9559fd 100644 --- a/pages/ar/developer/assemblyscript-migration-guide.mdx +++ b/pages/ar/developer/assemblyscript-migration-guide.mdx @@ -127,8 +127,11 @@ let a = a + b ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` + ستحتاج إلى إعادة تسمية المتغيرات المكررة إذا كان لديك variable shadowing. + ### مقارانات Null + من خلال إجراء الترقية على ال Subgraph الخاص بك ، قد تحصل أحيانًا على أخطاء مثل هذه: ```typescript @@ -137,6 +140,7 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` + لحل المشكلة يمكنك ببساطة تغيير عبارة `if` إلى شيء مثل هذا: ```typescript @@ -284,6 +288,7 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` + لإصلاح هذه المشكلة ، يمكنك إنشاء متغير للوصول إلى الخاصية حتى يتمكن المترجم من القيام بعملية التحقق من الـ nullability: ```typescript diff --git a/pages/ar/developer/create-subgraph-hosted.mdx b/pages/ar/developer/create-subgraph-hosted.mdx index 85db0e41d388..2c4c64d46737 100644 --- a/pages/ar/developer/create-subgraph-hosted.mdx +++ b/pages/ar/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ type GravatarDeclined @entity { ندعم المقاييس التالية في GraphQL API الخاصة بنا: -| النوع | الوصف | -| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `Bytes` | مصفوفة Byte ، ممثلة كسلسلة سداسية عشرية. يشيع استخدامها في Ethereum hashes وعناوينه. | -| `ID` | يتم تخزينه كـ `string`. | -| `String` | لقيم `string`. لا يتم دعم اNull ويتم إزالتها تلقائيا. | -| `Boolean` | لقيم `boolean`. | -| `Int` | المواصفات الفنية لـ GraphQL تعرف `Int` بحجم 32 بايت. | -| `BigInt` | أعداد صحيحة كبيرة. يستخدم لأنواع Ethereum `uint32` ، `int64` ، `uint64` ، ... ، `uint256`. ملاحظة: كل شيء تحت `uint32` ، مثل `int32` أو `uint24` أو `int8` يتم تمثيله كـ `i32`. | -| `BigDecimal` | `BigDecimal` يتم تمثيل الكسور العشرية عالية الدقة على أنها signficand وأسس.. يتراوح نطاق الأس من −6143 إلى +6144. مقربة إلى 34 رقما. | +| النوع | الوصف | +| --- | --- | +| `Bytes` | مصفوفة Byte ، ممثلة كسلسلة سداسية عشرية. يشيع استخدامها في Ethereum hashes وعناوينه. | +| `ID` | يتم تخزينه كـ `string`. | +| `String` | لقيم `string`. لا يتم دعم اNull ويتم إزالتها تلقائيا. | +| `Boolean` | لقيم `boolean`. | +| `Int` | المواصفات الفنية لـ GraphQL تعرف `Int` بحجم 32 بايت. | +| `BigInt` | أعداد صحيحة كبيرة. يستخدم لأنواع Ethereum `uint32` ، `int64` ، `uint64` ، ... ، `uint256`. ملاحظة: كل شيء تحت `uint32` ، مثل `int32` أو `uint24` أو `int8` يتم تمثيله كـ `i32`. | +| `BigDecimal` | `BigDecimal` يتم تمثيل الكسور العشرية عالية الدقة على أنها signficand وأسس.. يتراوح نطاق الأس من −6143 إلى +6144. مقربة إلى 34 رقما. | #### Enums @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **ملاحظة:** مصدر البيانات الجديد سيعالج فقط الاستدعاءات والأحداث للكتلة التي تم إنشاؤها فيه وجميع الكتل التالية ، ولكنه لن يعالج البيانات التاريخية ، أي البيانات الموجودة في الكتل السابقة. -> +> > إذا كانت الكتل السابقة تحتوي على بيانات ذات صلة بمصدر البيانات الجديد ، فمن الأفضل فهرسة تلك البيانات من خلال قراءة الحالة الحالية للعقد وإنشاء كيانات تمثل تلك الحالة في وقت إنشاء مصدر البيانات الجديد. ### سياق (Context) مصدر البيانات @@ -684,7 +684,7 @@ dataSources: ``` > **ملاحظة:** يمكن البحث عن كتلة إنشاء العقد بسرعة على Etherscan: -> +> > 1. ابحث عن العقد بإدخال عنوانه في شريط البحث. > 2. انقر فوق hash إجراء الإنشاء في قسم `Contract Creator`. > 3. قم بتحميل صفحة تفاصيل الإجراء(transaction) حيث ستجد كتلة البدء لذلك العقد. diff --git a/pages/ar/developer/graphql-api.mdx b/pages/ar/developer/graphql-api.mdx index d495f3edad4f..bf6cfc5221cc 100644 --- a/pages/ar/developer/graphql-api.mdx +++ b/pages/ar/developer/graphql-api.mdx @@ -204,12 +204,12 @@ not_ends_with_ عوامل تشغيل البحث عن النص الكامل: -| رمز | عامل التشغيل | الوصف | -| ----------- | ------------ | --------------------------------------------------------------------------------------------------------------------------- | -| `&` | `And` | لدمج عبارات بحث متعددة في فلتر للكيانات التي تتضمن جميع العبارات المتوفرة | -| | | `Or` | الاستعلامات التي تحتوي على عبارات بحث متعددة مفصولة بواسطة عامل التشغيل or ستعيد جميع الكيانات المتطابقة من أي عبارة متوفرة | -| `<->` | `Follow by` | يحدد المسافة بين كلمتين. | -| `*:` | `Prefix` | يستخدم عبارة البحث prefix للعثور على الكلمات التي تتطابق بادئتها (مطلوب حرفان.) | +| رمز | عامل التشغيل | الوصف | +| --- | --- | --- | +| `&` | `And` | لدمج عبارات بحث متعددة في فلتر للكيانات التي تتضمن جميع العبارات المتوفرة | +| | | `Or` | الاستعلامات التي تحتوي على عبارات بحث متعددة مفصولة بواسطة عامل التشغيل or ستعيد جميع الكيانات المتطابقة من أي عبارة متوفرة | +| `<->` | `Follow by` | يحدد المسافة بين كلمتين. | +| `*:` | `Prefix` | يستخدم عبارة البحث prefix للعثور على الكلمات التي تتطابق بادئتها (مطلوب حرفان.) | #### أمثلة diff --git a/pages/ar/developer/subgraph-debug-forking.mdx b/pages/ar/developer/subgraph-debug-forking.mdx index 3d4a40e00987..b57926914ed5 100644 --- a/pages/ar/developer/subgraph-debug-forking.mdx +++ b/pages/ar/developer/subgraph-debug-forking.mdx @@ -16,7 +16,7 @@ title: تصحيح أخطاء الـ subgraph بسرعة وسهولة باستخ عندما تنشر subgraph إلى Graph node بعيدة للقيام بالفهرسة ويفشل عند الكتلة _ X _ ، فإن الخبر الجيد هو أن Graph node ستظل تقدم استعلامات GraphQL باستخدام مخزنها(store)، والذي تمت مزامنته للكتلة(block) _ X _. هذا عظيم! هذا يعني أنه يمكننا الاستفادة من هذا المخزن "المحدث" لإصلاح الأخطاء التي تظهر عند فهرسة الكتلة _ X _. -باختصار ، سنقوم _ بتفريع (fork) الـ subgraph الفاشل _ من Graph node بعيدة والتي تضمن فهرسة الـ subgraph للكتلة * X * وذلك من أجل توفير الـ subgraph المنشور محليًا والذي يتم تصحيحه عندالكتلة_X_ مع عرض محدث لحالة الفهرسة. +باختصار ، سنقوم _ بتفريع (fork) الـ subgraph الفاشل _ من Graph node بعيدة والتي تضمن فهرسة الـ subgraph للكتلة _ X _ وذلك من أجل توفير الـ subgraph المنشور محليًا والذي يتم تصحيحه عندالكتلة*X* مع عرض محدث لحالة الفهرسة. ## من فضلك ، أرني بعض الأكواد! @@ -71,14 +71,14 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { وأنا أجيب: -1. ` fork-base ` هو عنوان URL "الأساسي" ،فمثلا عند إلحاق _subgraph id_ ، يكون عنوان URL الناتج (`/`) هو GraphQL endpoint صالح لمخزن الـ subgraph. +1. `fork-base` هو عنوان URL "الأساسي" ،فمثلا عند إلحاق _subgraph id_ ، يكون عنوان URL الناتج (`/`) هو GraphQL endpoint صالح لمخزن الـ subgraph. 2. الـتفريع سهل ، فلا داعي للقلق: ```bash $ graph deploy --debug-fork --ipfs http://localhost:5001 --node http://localhost:8020 ``` -أيضًا ، لا تنس تعيين حقل ` dataSources.source.startBlock ` في subgraph manifest لرقم الكتلة(block) التي بها المشكلة، حتى تتمكن من تخطي فهرسة الكتل الغير ضرورية والاستفادة من التفريع! +أيضًا ، لا تنس تعيين حقل `dataSources.source.startBlock` في subgraph manifest لرقم الكتلة(block) التي بها المشكلة، حتى تتمكن من تخطي فهرسة الكتل الغير ضرورية والاستفادة من التفريع! لذلك ، هذا ما أفعله: @@ -92,7 +92,7 @@ $ cargo run -p graph-node --release -- \ --fork-base https://api.thegraph.com/subgraphs/id/ ``` -1. بعد فحص دقيق ، لاحظت أن هناك عدم تطابق في تمثيلات الـ ` id ` المستخدمة عند فهرسة ` Gravatar ` في المعالجين الخاصين بي. بينما ` handleNewGravatar ` يحول (`event.params.id.toHex()`) إلى سداسي ، `handleUpdatedGravatar` يستخدم int32 (`event.params.id.toI32()`) مما يجعل ` handleUpdatedGravatar ` قلقا من "Gravatar not found!". أنا أجعلهم كلاهما يحولان ` id ` إلى سداسي. +1. بعد فحص دقيق ، لاحظت أن هناك عدم تطابق في تمثيلات الـ `id` المستخدمة عند فهرسة `Gravatar` في المعالجين الخاصين بي. بينما `handleNewGravatar` يحول (`event.params.id.toHex()`) إلى سداسي ، `handleUpdatedGravatar` يستخدم int32 (`event.params.id.toI32()`) مما يجعل `handleUpdatedGravatar` قلقا من "Gravatar not found!". أنا أجعلهم كلاهما يحولان `id` إلى سداسي. 2. بعد إجراء التغييرات ، قمت بنشر الـ subgraph الخاص بي على Graph node المحلية **_وتفريع الـsubgraph الفاشل_** وضبط `dataSources.source.startBlock` إلى `6190343` في `subgraph.yaml`: ```bash diff --git a/pages/ar/explorer.mdx b/pages/ar/explorer.mdx index 652e914fe353..26b05bf307a6 100644 --- a/pages/ar/explorer.mdx +++ b/pages/ar/explorer.mdx @@ -11,7 +11,7 @@ title: مستكشف title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen -> + > ## Subgraphs diff --git a/pages/ar/hosted-service/migrating-subgraph.mdx b/pages/ar/hosted-service/migrating-subgraph.mdx index a5a3d60a6f56..ef5910a281be 100644 --- a/pages/ar/hosted-service/migrating-subgraph.mdx +++ b/pages/ar/hosted-service/migrating-subgraph.mdx @@ -154,7 +154,7 @@ _بينما تتم هذه الآلية حاليا على الشبكة ، ينا title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen -> + > - [عقود شبكة The Graph](https://github.com/graphprotocol/contracts) diff --git a/pages/ar/indexing.mdx b/pages/ar/indexing.mdx index 7800bc514766..044a6c5b00c9 100644 --- a/pages/ar/indexing.mdx +++ b/pages/ar/indexing.mdx @@ -115,7 +115,7 @@ import { Difficulty } from '@/components' - **كبيرة** - مُعدة لفهرسة جميع ال subgraphs المستخدمة حاليا وأيضا لخدمة طلبات حركة مرور البيانات ذات الصلة. | Setup | (CPUs) | (memory in GB) | (disk in TBs) | (CPUs) | (memory in GB) | -| ----- |:------:|:--------------:|:-------------:|:------:|:--------------:| +| ----- | :----: | :------------: | :-----------: | :----: | :------------: | | صغير | 4 | 8 | 1 | 4 | 16 | | قياسي | 8 | 30 | 1 | 12 | 48 | | متوسط | 16 | 64 | 2 | 32 | 64 | @@ -151,20 +151,20 @@ import { Difficulty } from '@/components' #### Graph Node -| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | -| ------ | ------------------------------------------------------- | ------------------------------------------------------------------- | ----------------- | -------------- | -| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | http-port-- | - | -| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | ws-port-- | - | -| 8020 | JSON-RPC
(for managing deployments) | / | admin-port-- | - | -| 8030 | Subgraph indexing status API | /graphql | index-node-port-- | - | -| 8040 | Prometheus metrics | /metrics | metrics-port-- | - | +| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | +| --- | --- | --- | --- | --- | +| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | http-port-- | - | +| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | ws-port-- | - | +| 8020 | JSON-RPC
(for managing deployments) | / | admin-port-- | - | +| 8030 | Subgraph indexing status API | /graphql | index-node-port-- | - | +| 8040 | Prometheus metrics | /metrics | metrics-port-- | - | #### خدمة المفهرس -| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | -| ------ | ------------------------------------------------------------ | --------------------------------------------------------------------------- | -------------- | ---------------------- | -| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | port-- | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus metrics | /metrics | metrics-port-- | - | +| المنفذ | الغرض | المسار | CLI Argument | متغيرات البيئة | +| --- | --- | --- | --- | --- | +| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | port-- | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus metrics | /metrics | metrics-port-- | - | #### وكيل المفهرس(Indexer Agent) diff --git a/pages/ar/studio/billing.mdx b/pages/ar/studio/billing.mdx index 8f7568bb8907..b41808395eb7 100644 --- a/pages/ar/studio/billing.mdx +++ b/pages/ar/studio/billing.mdx @@ -46,7 +46,7 @@ title: الفوترة على Subgraph Studio title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen -> + > ### مستخدمو Multisig diff --git a/pages/ar/studio/deploy-subgraph-studio.mdx b/pages/ar/studio/deploy-subgraph-studio.mdx index d89738b45b65..7ee7328b8c08 100644 --- a/pages/ar/studio/deploy-subgraph-studio.mdx +++ b/pages/ar/studio/deploy-subgraph-studio.mdx @@ -63,6 +63,6 @@ graph auth --studio graph deploy --studio ``` -بعد تشغيل هذا الأمر ، سيطلب الـ CLI أن تقوم بتسمية الإصدار ، ويمكنك تسميته كما تريد ، يمكنك استخدام تسميات مثل ` 0.1 ` و ` 0.2 ` أو استخدام الأحرف مثل ` uniswap-v2-0.1 `. ستكون هذه التسميات مرئية في Graph Explorer ويمكن استخدامها من قبل المنسقين (curators) لتقرير ما إذا كانوا يريدون الإشارة إلى هذا الإصدار أم لا ، لذا اختر بحكمة. +بعد تشغيل هذا الأمر ، سيطلب الـ CLI أن تقوم بتسمية الإصدار ، ويمكنك تسميته كما تريد ، يمكنك استخدام تسميات مثل `0.1` و `0.2` أو استخدام الأحرف مثل `uniswap-v2-0.1`. ستكون هذه التسميات مرئية في Graph Explorer ويمكن استخدامها من قبل المنسقين (curators) لتقرير ما إذا كانوا يريدون الإشارة إلى هذا الإصدار أم لا ، لذا اختر بحكمة. بمجرد النشر(deploy) ، يمكنك اختبار الـ subgraph الخاص بك في Subgraph Studio باستخدام playground، ونشر(deploy) إصدار آخر إذا لزم الأمر ، وتحديث البيانات الوصفية ، وعندما تكون جاهزًا ، قم بنشر(publish) الـ subgraph الخاص بك إلى Graph Explorer. diff --git a/pages/ar/studio/subgraph-studio.mdx b/pages/ar/studio/subgraph-studio.mdx index 08575d0a9653..6b3dbcebfbc4 100644 --- a/pages/ar/studio/subgraph-studio.mdx +++ b/pages/ar/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ title: كيفية استخدام Subgraph Studio title="مشغل فيديو يوتيوب" frameBorder="0" allowFullScreen -> + > تذكر ، أثناء تقدمك في تدفق النشر ، ستتمكن من الدفع(push) إما إلى mainnet أو Rinkeby ، وهي testnet التي ندعمها. إذا كنت مطور subgraph لأول مرة ، فنحن نقترح بشدة أن تبدأ بالنشر على Rinkeby ، وهو مجاني. سيسمح لك ذلك بمعرفة كيفية عمل الـ subgraph في The Graph Explorer وسيسمح لك باختبار عناصر التنسيق. diff --git a/pages/ar/supported-networks/near.mdx b/pages/ar/supported-networks/near.mdx index 17f14a271fc3..0f7bf71e1632 100644 --- a/pages/ar/supported-networks/near.mdx +++ b/pages/ar/supported-networks/near.mdx @@ -29,13 +29,13 @@ title: بناء Subgraphs على NEAR `graphprotocol/graph-ts@` هي مكتبة لأنواع خاصة بـ subgraph. -تطوير NEAR subgraph يتطلب `graph-cli` بإصدار أعلى من ` 0.23.0 ` و `graph-ts` بإصدار أعلى من ` 0.23.0 `. +تطوير NEAR subgraph يتطلب `graph-cli` بإصدار أعلى من `0.23.0` و `graph-ts` بإصدار أعلى من `0.23.0`. > بناء NEAR subgraph يشبه إلى حد كبير بناء subgraph يقوم بفهرسة الـ Ethereum. هناك ثلاثة جوانب لتعريف الـ subgraph: -**subgraph.yaml:** الـ subgraph manifest ، وتحديد مصادر البيانات ذات الأهمية ، وكيف يجب أن تتم معالجتها.علما أن NEAR هو ` نوع ` جديد لمصدر البيانات. +**subgraph.yaml:** الـ subgraph manifest ، وتحديد مصادر البيانات ذات الأهمية ، وكيف يجب أن تتم معالجتها.علما أن NEAR هو `نوع` جديد لمصدر البيانات. **schema.graphql:** مخطط يقوم بتعريف البيانات المخزنة لـ subgraph الخاص بك ، وكيفية الاستعلام عنها عبر GraphQL. وتتم تغطية متطلبات NEAR subgraphs بواسطة [ الوثائق الحالية ](/developer/create-subgraph-hosted#the-graphql-schema). @@ -73,8 +73,8 @@ dataSources: ``` - NEAR subgraphs يقدم `نوعا ` جديدا من مصدر بيانات (`near`) -- يجب أن يتوافق الـ `network` مع شبكة على Graph Node المضيفة. في الخدمة المستضافة ، الشبكة الرئيسية لـ NEAR هي ` near-mainnet ` ، وشبكة NEAR's testnet هي ` near-testnet ` -- مصادر بيانات NEAR تقدم حقلًا اختياريًا ` source.account ` ، وهو ID يمكن قراءته و يتوافق مع [ حساب NEAR ](https://docs.near.org/docs/concepts/account). ويمكن أن يكون ذلك حسابًا أو حسابًا فرعيًا. +- يجب أن يتوافق الـ `network` مع شبكة على Graph Node المضيفة. في الخدمة المستضافة ، الشبكة الرئيسية لـ NEAR هي `near-mainnet` ، وشبكة NEAR's testnet هي `near-testnet` +- مصادر بيانات NEAR تقدم حقلًا اختياريًا `source.account` ، وهو ID يمكن قراءته و يتوافق مع [ حساب NEAR ](https://docs.near.org/docs/concepts/account). ويمكن أن يكون ذلك حسابًا أو حسابًا فرعيًا. مصادر بيانات NEAR تدعم نوعين من المعالجات: @@ -154,11 +154,11 @@ class ReceiptWithOutcome { يتم تمرير هذه الأنواع لمعالجات الكتلة(block) & الاستلام(receipt): - معالجات الكتلة ستتلقى`Block` -- معالجات الاستلام ستتلقى` ReceiptWithOutcome ` +- معالجات الاستلام ستتلقى`ReceiptWithOutcome` وبخلاف ذلك ، فإن بقية [ AssemblyScript API ](/developer/assemblyscript-api) تكون متاحة لمطوري NEAR subgraph أثناء تنفيذ الـ mapping. -هذا يتضمن دالة تحليل JSON جديدة - يتم إرسال السجلات الموجودة على NEAR بشكل متكرر على هيئة JSONs. تتوفر دالة ` (...)json.fromString ` جديدة كجزء من [JSON API](/developer/assemblyscript-api#json-api) للسماح للمطورين لمعالجة هذه السجلات بسهولة. +هذا يتضمن دالة تحليل JSON جديدة - يتم إرسال السجلات الموجودة على NEAR بشكل متكرر على هيئة JSONs. تتوفر دالة `(...)json.fromString` جديدة كجزء من [JSON API](/developer/assemblyscript-api#json-api) للسماح للمطورين لمعالجة هذه السجلات بسهولة. ## نشر NEAR Subgraph diff --git a/pages/es/curating.mdx b/pages/es/curating.mdx index 425cb5608b6f..a3d986829e1d 100644 --- a/pages/es/curating.mdx +++ b/pages/es/curating.mdx @@ -100,5 +100,5 @@ Las participaciones de un curador no se pueden "comprar" o "vender" como otros t title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen -> + > diff --git a/pages/es/delegating.mdx b/pages/es/delegating.mdx index ec596e39f1ac..378a35378ae3 100644 --- a/pages/es/delegating.mdx +++ b/pages/es/delegating.mdx @@ -95,5 +95,5 @@ Esta guía proporciona una revisión completa de este documento, y cómo tener e title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen -> + > diff --git a/pages/es/developer/assemblyscript-api.mdx b/pages/es/developer/assemblyscript-api.mdx index a376a0f67029..5ae139ce8ed9 100644 --- a/pages/es/developer/assemblyscript-api.mdx +++ b/pages/es/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ La librería de `@graphprotocol/graph-ts` proporciona las siguientes APIs: La `apiVersion` en el manifiesto del subgrafo especifica la versión de la API correspondiente al mapeo que está siendo ejecutado en el Graph Node de un subgrafo en específico. La versión actual para la APÍ de mapeo es la 0.0.6. -| Version | Notas del lanzamiento | -|:-------:| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| 0.0.6 | Se agregó la casilla `nonce` a las Transacciones de Ethereum, se
añadió `baseFeePerGas` para los bloques de Ethereum | -| 0.0.5 | Se actualizó la versión del AssemblyScript a la v0.19.10 (esta incluye cambios importantes, recomendamos leer la [`guía de migración`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` actualizada a `ethereum.transaction.gasLimit` | -| 0.0.4 | Añadido la casilla de `functionSignature` para la función de Ethereum SmartContractCall | -| 0.0.3 | Añadida la casilla `from` para la función de Ethereum Call
`ethereum.call.address` actualizada a `ethereum.call.to` | -| 0.0.2 | Añadida la casilla de `input` para la función de Ethereum Transaction | +| Version | Notas del lanzamiento | +| :-: | --- | +| 0.0.6 | Se agregó la casilla `nonce` a las Transacciones de Ethereum, se
añadió `baseFeePerGas` para los bloques de Ethereum | +| 0.0.5 | Se actualizó la versión del AssemblyScript a la v0.19.10 (esta incluye cambios importantes, recomendamos leer la [`guía de migración`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` actualizada a `ethereum.transaction.gasLimit` | +| 0.0.4 | Añadido la casilla de `functionSignature` para la función de Ethereum SmartContractCall | +| 0.0.3 | Añadida la casilla `from` para la función de Ethereum Call
`ethereum.call.address` actualizada a `ethereum.call.to` | +| 0.0.2 | Añadida la casilla de `input` para la función de Ethereum Transaction | ### Built-in Types diff --git a/pages/es/developer/assemblyscript-migration-guide.mdx b/pages/es/developer/assemblyscript-migration-guide.mdx index 191d1afb6c4e..3385a907586b 100644 --- a/pages/es/developer/assemblyscript-migration-guide.mdx +++ b/pages/es/developer/assemblyscript-migration-guide.mdx @@ -127,8 +127,11 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` + Tendrás que cambiar el nombre de las variables duplicadas si tienes una variable shadowing. + ### Comparaciones Nulas + Al hacer la actualización en ut subgrafo, a veces pueden aparecer errores como estos: ```typescript @@ -137,6 +140,7 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` + Para solucionarlo puedes simplemente cambiar la declaracion `if` por algo así: ```typescript @@ -284,6 +288,7 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` + Para solucionar este problema, puedes crear una variable para ese acceso a la propiedad de manera que el compilador pueda hacer la magia de la comprobación de nulidad: ```typescript diff --git a/pages/es/developer/create-subgraph-hosted.mdx b/pages/es/developer/create-subgraph-hosted.mdx index 142238359ffb..d6d8a966bcc6 100644 --- a/pages/es/developer/create-subgraph-hosted.mdx +++ b/pages/es/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Cada entidad debe tener un campo `id`, que es de tipo `ID!` (string). El campo ` Admitimos los siguientes scalars en nuestra API GraphQL: -| Tipo | Descripción | -| ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `Bytes` | Byte array, representado como un string hexadecimal. Comúnmente utilizado para los hashes y direcciones de Ethereum. | -| `ID` | Almacenado como un `string`. | -| `String` | Scalar para valores `string`. Los caracteres null no se admiten y se eliminan automáticamente. | -| `Boolean` | Scalar para valores `boolean`. | -| `Int` | The GraphQL spec define `Int` para tener un tamano de 32 bytes. | -| `BigInt` | Números enteros grandes. Usados para los tipos `uint32`, `int64`, `uint64`, ..., `uint256` de Ethereum. Nota: Todo debajo de `uint32`, como `int32`, `uint24` o `int8` es representado como `i32`. | -| `BigDecimal` | `BigDecimal` Decimales de alta precisión representados como un signo y un exponente. El rango de exponentes va de -6143 a +6144. Redondeado a 34 dígitos significativos. | +| Tipo | Descripción | +| --- | --- | +| `Bytes` | Byte array, representado como un string hexadecimal. Comúnmente utilizado para los hashes y direcciones de Ethereum. | +| `ID` | Almacenado como un `string`. | +| `String` | Scalar para valores `string`. Los caracteres null no se admiten y se eliminan automáticamente. | +| `Boolean` | Scalar para valores `boolean`. | +| `Int` | The GraphQL spec define `Int` para tener un tamano de 32 bytes. | +| `BigInt` | Números enteros grandes. Usados para los tipos `uint32`, `int64`, `uint64`, ..., `uint256` de Ethereum. Nota: Todo debajo de `uint32`, como `int32`, `uint24` o `int8` es representado como `i32`. | +| `BigDecimal` | `BigDecimal` Decimales de alta precisión representados como un signo y un exponente. El rango de exponentes va de -6143 a +6144. Redondeado a 34 dígitos significativos. | #### Enums @@ -451,10 +451,10 @@ Diccionarios de idiomas admitidos: Algoritmos admitidos para ordenar los resultados: -| Algoritmos | Descripción | -| ------------------- | -------------------------------------------------------------------------------------------------- | -| rango | Usa la calidad de coincidencia (0-1) de la consulta de texto completo para ordenar los resultados. | -| rango de proximidad | Similar al rango, pero también incluye la proximidad de los matches. | +| Algoritmos | Descripción | +| --- | --- | +| rango | Usa la calidad de coincidencia (0-1) de la consulta de texto completo para ordenar los resultados. | +| rango de proximidad | Similar al rango, pero también incluye la proximidad de los matches. | ## Escribir mapeos @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **Nota:** Un nuevo origen de datos sólo procesará las llamadas y los eventos del bloque en el que fue creado y todos los bloques siguientes, pero no procesará los datos históricos, es decir, los datos que están contenidos en bloques anteriores. -> +> > Si los bloques anteriores contienen datos relevantes para la nueva fuente de datos, lo mejor es indexar esos datos leyendo el estado actual del contrato y creando entidades que representen ese estado en el momento de crear la nueva fuente de datos. ### Contexto de la fuente de datos @@ -684,7 +684,7 @@ dataSources: ``` > **Nota:** El bloque de creación del contrato se puede buscar rápidamente en Etherscan: -> +> > 1. Busca el contrato introduciendo su dirección en la barra de búsqueda. > 2. Haz clic en el hash de la transacción de creación en la sección `Contract Creator`. > 3. Carga la página de detalles de la transacción, donde encontrarás el bloque inicial de ese contrato. diff --git a/pages/es/developer/graphql-api.mdx b/pages/es/developer/graphql-api.mdx index fa335bef73d0..5c584bc56bd0 100644 --- a/pages/es/developer/graphql-api.mdx +++ b/pages/es/developer/graphql-api.mdx @@ -204,12 +204,12 @@ Las consultas de búsqueda de texto completo tienen un campo obligatorio, `text` Operadores de búsqueda de texto completo: -| Símbolo | Operador | Descripción | -| ----------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `&` | `And` | Para combinar varios términos de búsqueda en un filtro para entidades que incluyen todos los términos proporcionados | -| | | `Or` | Las consultas con varios términos de búsqueda separados por o el operador devolverá todas las entidades que coincidan con cualquiera de los términos proporcionados | -| `<->` | `Follow by` | Especifica la distancia entre dos palabras. | -| `:*` | `Prefix` | Utilice el término de búsqueda del prefijo para encontrar palabras cuyo prefijo coincida (se requieren 2 caracteres.) | +| Símbolo | Operador | Descripción | +| --- | --- | --- | +| `&` | `And` | Para combinar varios términos de búsqueda en un filtro para entidades que incluyen todos los términos proporcionados | +| | | `Or` | Las consultas con varios términos de búsqueda separados por o el operador devolverá todas las entidades que coincidan con cualquiera de los términos proporcionados | +| `<->` | `Follow by` | Especifica la distancia entre dos palabras. | +| `:*` | `Prefix` | Utilice el término de búsqueda del prefijo para encontrar palabras cuyo prefijo coincida (se requieren 2 caracteres.) | #### Ejemplos diff --git a/pages/es/developer/subgraph-debug-forking.mdx b/pages/es/developer/subgraph-debug-forking.mdx index 025911c2b6d4..955aed14b521 100644 --- a/pages/es/developer/subgraph-debug-forking.mdx +++ b/pages/es/developer/subgraph-debug-forking.mdx @@ -16,7 +16,7 @@ En el contexto de la depuración, **subgraph forking** te permite depurar tu sub Cuando implementas un subgrafo en un nodo Graph remoto para la indexación y falla en el bloque _X_, la buena noticia es que el nodo Graph seguirá atendiendo consultas de GraphQL usando su tienda, que está sincronizado para bloquear _X_. ¡Genial! Esto significa que podemos aprovechar esta tienda "actualizada" para corregir los errores que surgen al indexar el bloque _X_. -En pocas palabras, vamos a _bifurcar el subgrafo fallido_ desde un nodo de Graph remoto que garantiza que el subgrafo se indexe para bloquear *X* para proporcionar al subgrafo implementado localmente que se está depurando en el bloque _X_ una vista actualizada del estado de indexación. +En pocas palabras, vamos a _bifurcar el subgrafo fallido_ desde un nodo de Graph remoto que garantiza que el subgrafo se indexe para bloquear _X_ para proporcionar al subgrafo implementado localmente que se está depurando en el bloque _X_ una vista actualizada del estado de indexación. ## ¡Por favor, muéstrame algo de código! @@ -46,7 +46,7 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -Vaya, qué desafortunado, cuando implemento mi subgrafo de aspecto perfecto en el [HostedService](https://thegraph.com/hosted-service/), falla con el *"¡Gravatar no encontrado!"* error. +Vaya, qué desafortunado, cuando implemento mi subgrafo de aspecto perfecto en el [HostedService](https://thegraph.com/hosted-service/), falla con el _"¡Gravatar no encontrado!"_ error. La forma habitual de intentar una solución es: diff --git a/pages/es/explorer.mdx b/pages/es/explorer.mdx index 6ede1f9592e3..676a3ad54e39 100644 --- a/pages/es/explorer.mdx +++ b/pages/es/explorer.mdx @@ -11,7 +11,7 @@ Bienvenido al explorador de The Graph, o como nos gusta llamarlo, tu portal desc title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen -> + > ## Subgrafos diff --git a/pages/es/hosted-service/migrating-subgraph.mdx b/pages/es/hosted-service/migrating-subgraph.mdx index 84b0def9ad1b..94cccd8a7c1e 100644 --- a/pages/es/hosted-service/migrating-subgraph.mdx +++ b/pages/es/hosted-service/migrating-subgraph.mdx @@ -154,7 +154,7 @@ If you're still confused, fear not! Check out the following resources or watch o title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen -> + > - [The Graph Network Contracts](https://github.com/graphprotocol/contracts) diff --git a/pages/es/indexing.mdx b/pages/es/indexing.mdx index f7bf0dfa46ea..01cf9afbdfee 100644 --- a/pages/es/indexing.mdx +++ b/pages/es/indexing.mdx @@ -115,11 +115,11 @@ Los indexadores pueden diferenciarse aplicando técnicas avanzadas para tomar de - **Grande**: Preparado para indexar todos los subgrafos utilizados actualmente y atender solicitudes para el tráfico relacionado. | Configuración | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | -| ------------- |:--------------------------:|:-----------------------------------:|:---------------------------------:|:---------------------:|:------------------------------:| -| Pequeño | 4 | 8 | 1 | 4 | 16 | -| Estándar | 8 | 30 | 1 | 12 | 48 | -| Medio | 16 | 64 | 2 | 32 | 64 | -| Grande | 72 | 468 | 3,5 | 48 | 184 | +| --- | :-: | :-: | :-: | :-: | :-: | +| Pequeño | 4 | 8 | 1 | 4 | 16 | +| Estándar | 8 | 30 | 1 | 12 | 48 | +| Medio | 16 | 64 | 2 | 32 | 64 | +| Grande | 72 | 468 | 3,5 | 48 | 184 | ### ¿Cuáles son algunas de las precauciones de seguridad básicas que debe tomar un indexador? @@ -151,24 +151,24 @@ Nota: Para admitir el escalado ágil, se recomienda que las inquietudes de consu #### Graph Node -| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | -| ------ | -------------------------------------------------------------- | ---------------------------------------------------- | ----------------- | ------------------- | -| 8000 | Servidor HTTP GraphQL
(para consultas de subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(para suscripciones a subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(para administrar implementaciones) | / | --admin-port | - | -| 8030 | API de estado de indexación de subgrafos | /graphql | --index-node-port | - | -| 8040 | Métricas de Prometheus | /metrics | --metrics-port | - | +| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | +| --- | --- | --- | --- | --- | +| 8000 | Servidor HTTP GraphQL
(para consultas de subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(para suscripciones a subgrafos) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(para administrar implementaciones) | / | --admin-port | - | +| 8030 | API de estado de indexación de subgrafos | /graphql | --index-node-port | - | +| 8040 | Métricas de Prometheus | /metrics | --metrics-port | - | #### Servicio de Indexador -| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | -| ------ | --------------------------------------------------------------------- | ----------------------------------------------------------------------- | -------------- | ---------------------- | -| 7600 | Servidor HTTP GraphQL
(para consultas de subgrafo pagadas) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Métricas de Prometheus | /metrics | --metrics-port | - | +| Puerto | Objeto | Rutas | Argumento CLI | Variable de Entorno | +| --- | --- | --- | --- | --- | +| 7600 | Servidor HTTP GraphQL
(para consultas de subgrafo pagadas) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Métricas de Prometheus | /metrics | --metrics-port | - | #### Agente Indexador -| Puerto | Objeto | Rutas | Argumento CLI | Variable de
Entorno | +| Puerto | Objeto | Rutas | Argumento CLI | Variable de
Entorno | | ------ | ----------------------------- | ----- | ------------------------- | --------------------------------------- | | 8000 | API de gestión de indexadores | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | diff --git a/pages/es/studio/billing.mdx b/pages/es/studio/billing.mdx index 674243d209d4..60c6dd0390ae 100644 --- a/pages/es/studio/billing.mdx +++ b/pages/es/studio/billing.mdx @@ -46,7 +46,7 @@ Si quieres ver una demostración rápida de cómo funciona la facturación en Su title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen -> + > ### Usuarios Multisig diff --git a/pages/es/studio/subgraph-studio.mdx b/pages/es/studio/subgraph-studio.mdx index 28cfadea4edc..966b30ba2bac 100644 --- a/pages/es/studio/subgraph-studio.mdx +++ b/pages/es/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ You’ve made it this far - congrats! Publishing your subgraph means that an IPF title="Reproductor de video de YouTube" frameBorder="0" allowFullScreen -> + > Remember, while you’re going through your publishing flow, you’ll be able to push to either mainnet or Rinkeby, the testnet we support. If you’re a first time subgraph developer, we highly suggest you start with publishing to Rinkeby, which is free to do. This will allow you to see how the subgraph will work in The Graph Explorer and will allow you to test curation elements. diff --git a/pages/ja/curating.mdx b/pages/ja/curating.mdx index 06367abdcc50..03a6c67b0b57 100644 --- a/pages/ja/curating.mdx +++ b/pages/ja/curating.mdx @@ -100,5 +100,5 @@ The Graph の場合は、 [Bancor が実装しているボンディングカー title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > diff --git a/pages/ja/delegating.mdx b/pages/ja/delegating.mdx index 1b47a11008f2..0db2a637cd9e 100644 --- a/pages/ja/delegating.mdx +++ b/pages/ja/delegating.mdx @@ -84,7 +84,7 @@ title: デリゲーティング ## ネットワーク UI のビデオガイド -この式を使うと、デリゲーターに20%しか提供していないインデクサーが、デリゲーターに90%を提供しているインデクサーよりも、デリゲーターにさらに良い報酬を与えている可能性があることがわかります。 +この式を使うと、デリゲーターに 20%しか提供していないインデクサーが、デリゲーターに 90%を提供しているインデクサーよりも、デリゲーターにさらに良い報酬を与えている可能性があることがわかります。
+ >
diff --git a/pages/ja/developer/assemblyscript-api.mdx b/pages/ja/developer/assemblyscript-api.mdx index 4826602d3457..0069310090ce 100644 --- a/pages/ja/developer/assemblyscript-api.mdx +++ b/pages/ja/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install -save-dev @graphprotocol/graph-ts # NPM サブグラフマニフェストの`apiVersion` は、指定されたサブグラフに対してグラフノードが実行するマッピング API のバージョンを指定します。 現在のマッピング API のバージョンは 0.0.6 です。 -| バージョン | リリースノート | -|:-----:| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| 0.0.6 | Ethereum Transaction オブジェクトに`nonce`フィールドを追加 イーサリアムブロックオブジェクトに
Added `baseFeePerGas`を追加 | +| バージョン | リリースノート | +| :-: | --- | +| 0.0.6 | Ethereum Transaction オブジェクトに`nonce`フィールドを追加 イーサリアムブロックオブジェクトに
Added `baseFeePerGas`を追加 | | 0.0.5 | AssemblyScript がバージョン 0.19.10 にアップグレード(変更点がありますので[`Migration Guide`](/developer/assemblyscript-migration-guide))をご覧ください)。
`ethereum.transaction.gasUsed`の名前が`ethereum.transaction.gasLimit`に変更 | -| 0.0.4 | Ethereum SmartContractCall オブジェクトに`functionSignature`フィールドを追加 | -| 0.0.3 | Ethereum Call オブジェクトに`from`フィールドを追加
`etherem.call.address`の名前を `ethereum.call.to`に変更 | -| 0.0.2 | Ethereum Transaction オブジェクトに `input`フィールドを追加 | +| 0.0.4 | Ethereum SmartContractCall オブジェクトに`functionSignature`フィールドを追加 | +| 0.0.3 | Ethereum Call オブジェクトに`from`フィールドを追加
`etherem.call.address`の名前を `ethereum.call.to`に変更 | +| 0.0.2 | Ethereum Transaction オブジェクトに `input`フィールドを追加 | ### 組み込み型 diff --git a/pages/ja/developer/assemblyscript-migration-guide.mdx b/pages/ja/developer/assemblyscript-migration-guide.mdx index 8ab20ff7685d..885a760c0bd9 100644 --- a/pages/ja/developer/assemblyscript-migration-guide.mdx +++ b/pages/ja/developer/assemblyscript-migration-guide.mdx @@ -127,8 +127,11 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` + 変数シャドウイングを行っていた場合は、重複する変数の名前を変更する必要があります。 + ### Null 比較 + サブグラフのアップグレードを行うと、時々以下のようなエラーが発生することがあります。 ```typescript @@ -137,6 +140,7 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` + 解決するには、 `if` 文を以下のように変更するだけです。 ```typescript @@ -284,6 +288,7 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` + この問題を解決するには、そのプロパティアクセスのための変数を作成して、コンパイラが nullability check のマジックを行うようにします。 ```typescript diff --git a/pages/ja/developer/create-subgraph-hosted.mdx b/pages/ja/developer/create-subgraph-hosted.mdx index bc903e8b549e..deaf9bc18d11 100644 --- a/pages/ja/developer/create-subgraph-hosted.mdx +++ b/pages/ja/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Null value resolved for non-null field 'name' GraphQL API では、以下の Scalar をサポートしています: -| タイプ | 説明 | -| ------------ | --------------------------------------------------------------------------------------------------------------------------------- | -| `Bytes` | Byte 配列で、16 進数の文字列で表されます。Ethereum のハッシュやアドレスによく使われます。 | -| `ID` | `string`として格納されます。 | -| `String` | `string`値の Scalar であり、Null 文字はサポートされておらず、自動的に削除されます。 | -| `Boolean` | `boolean`値を表す Scalar。 | -| `Int` | Int GraphQL の仕様では、`Int`のサイズは 32 バイトと定義されています。 | -| `BigInt` | 大きな整数。Ethereum の`uint32`, `int64`, `uint64`, ..., `uint256` タイプに使用されます。注: `int32`, `uint24` `int8`など`uint32`以下のものは`i32`として表現されます。 | -| `BigDecimal` | `BigDecimal`は、高精度の 10 進数を記号と指数で表します。指数の範囲は -6143 ~ +6144 です。有効数字 34 桁にまとめられます。 | +| タイプ | 説明 | +| --- | --- | +| `Bytes` | Byte 配列で、16 進数の文字列で表されます。Ethereum のハッシュやアドレスによく使われます。 | +| `ID` | `string`として格納されます。 | +| `String` | `string`値の Scalar であり、Null 文字はサポートされておらず、自動的に削除されます。 | +| `Boolean` | `boolean`値を表す Scalar。 | +| `Int` | Int GraphQL の仕様では、`Int`のサイズは 32 バイトと定義されています。 | +| `BigInt` | 大きな整数。Ethereum の`uint32`, `int64`, `uint64`, ..., `uint256` タイプに使用されます。注: `int32`, `uint24` `int8`など`uint32`以下のものは`i32`として表現されます。 | +| `BigDecimal` | `BigDecimal`は、高精度の 10 進数を記号と指数で表します。指数の範囲は -6143 ~ +6144 です。有効数字 34 桁にまとめられます。 | #### Enums @@ -428,7 +428,7 @@ query { サポートされている言語の辞書: -| コード | 辞書 | +| コード | 辞書 | | ------ | --------- | | simple | General | | da | Danish | @@ -451,10 +451,10 @@ query { サポートされている結果の順序付けのアルゴリズム: -| アルゴリズム | 説明 | -| ------------- | ---------------------------------------- | -| rank | フルテキストクエリのマッチ品質 (0-1) を使用して結果を並べ替えます。 | -| proximityRank | proximityRank rank に似ていますが、マッチの近接性も含みます。 | +| アルゴリズム | 説明 | +| ------------- | ------------------------------------------------------------------- | +| rank | フルテキストクエリのマッチ品質 (0-1) を使用して結果を並べ替えます。 | +| proximityRank | proximityRank rank に似ていますが、マッチの近接性も含みます。 | ## マッピングの記述 @@ -628,7 +628,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **注: **新しいデータソースは、作成されたブロックとそれに続くすべてのブロックのコールとイベントのみを処理しますが、過去のデータ、つまり以前のブロックに含まれているデータは処理しません。 -> +> > 以前のブロックに新しいデータソースに関連するデータが含まれている場合は、コントラクトの現在の状態を読み取り、新しいデータソースが作成された時点でその状態を表すエンティティを作成することで、そのデータにインデックスを付けることが最善です。 ### データソースコンテクスト @@ -685,7 +685,7 @@ dataSources: ``` > **注: ** コントラクト作成ブロックは、Etherscan ですぐに調べることができます: -> +> > 1. 検索バーにアドレスを入力してコントラクトを検索します。 > 2. `Contract Creator` セクションの作成トランザクションハッシュをクリックします。 > 3. トランザクションの詳細ページを読み込んで、そのコントラクトの開始ブロックを見つけます。 @@ -817,7 +817,7 @@ eventHandlers: `specVersion` `0.0.4`以降、サブグラフ機能はマニフェストファイルのトップレベルにある`features`セクションで、以下の表のように`camelCase` の名前を使って明示的に宣言する必要があります: -| 特徴 | 名前 | +| 特徴 | 名前 | | --------------------------------------------------------- | ------------------------- | | [Non-fatal errors](#non-fatal-errors) | `nonFatalErrors` | | [Full-text Search](#defining-fulltext-search-fields) | `fullTextSearch` | diff --git a/pages/ja/developer/graphql-api.mdx b/pages/ja/developer/graphql-api.mdx index 57fa7d736641..4ff0a4034adb 100644 --- a/pages/ja/developer/graphql-api.mdx +++ b/pages/ja/developer/graphql-api.mdx @@ -204,12 +204,12 @@ _not_ends_with フルテキスト検索オペレーター: -| シンボル | オペレーター | 説明 | -| ----------- | ----------- | --------------------------------------------------------- | -| `&` | `And` | 複数の検索語を組み合わせて、指定したすべての検索語を含むエンティティをフィルタリングします。 | -| | | `Or` | 複数の検索語をオペレーターで区切って検索すると、指定した語のいずれかにマッチするすべてのエンティティが返されます。 | -| `<->` | `Follow by` | 2 つの単語の間の距離を指定します。 | -| `:*` | `Prefix` | プレフィックス検索語を使って、プレフィックスが一致する単語を検索します(2 文字必要) | +| シンボル | オペレーター | 説明 | +| --- | --- | --- | +| `&` | `And` | 複数の検索語を組み合わせて、指定したすべての検索語を含むエンティティをフィルタリングします。 | +| | | `Or` | 複数の検索語をオペレーターで区切って検索すると、指定した語のいずれかにマッチするすべてのエンティティが返されます。 | +| `<->` | `Follow by` | 2 つの単語の間の距離を指定します。 | +| `:*` | `Prefix` | プレフィックス検索語を使って、プレフィックスが一致する単語を検索します(2 文字必要) | #### 例 @@ -266,6 +266,6 @@ GraphQL スキーマは一般に、`クエリ`、`サブスクリプション` ### エンティティ -スキーマに`@entity`ディレクティブが含まれるすべてのGraphQLタイプはエンティティとして扱われ、`ID`フィールドが必要です。 +スキーマに`@entity`ディレクティブが含まれるすべての GraphQL タイプはエンティティとして扱われ、`ID`フィールドが必要です。 > **注:**現在、スキーマ内のすべてのタイプに`@entity` ディレクティブが必要です。将来的には、`@entity` ディレクティブを持たないタイプをバリューオブジェクトとして扱う予定ですが、これはまだサポートされていません。 diff --git a/pages/ja/developer/subgraph-debug-forking.mdx b/pages/ja/developer/subgraph-debug-forking.mdx index 24697f21ea21..87ff2a877cad 100644 --- a/pages/ja/developer/subgraph-debug-forking.mdx +++ b/pages/ja/developer/subgraph-debug-forking.mdx @@ -4,23 +4,23 @@ title: フォークを使った迅速で簡単なサブグラフのデバッギ > 注:この`graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) または、この[docker tag ](https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore) 以降でのみ利用可能で、マイナーリリース(例:0.26.0)ではまだリリースされていません。 -大量のデータを処理する多くのシステムと同様に、The GraphのIndexers(グラフノード)は、サブグラフとターゲットブロックチェーンの同期にかなりの時間がかかる場合があります。デバッグを目的とした素早い変更と、インデックス作成に必要な長い待ち時間の不一致は非常に逆効果であり、私たちはそれを十分に認識しています。そこで、[LimeChain](https://limechain.tech/)が開発した**subgraph forking**を導入し、今回はこの機能を使ってサブグラフのデバッグを大幅に高速化する方法を紹介します。 +大量のデータを処理する多くのシステムと同様に、The Graph の Indexers(グラフノード)は、サブグラフとターゲットブロックチェーンの同期にかなりの時間がかかる場合があります。デバッグを目的とした素早い変更と、インデックス作成に必要な長い待ち時間の不一致は非常に逆効果であり、私たちはそれを十分に認識しています。そこで、[LimeChain](https://limechain.tech/)が開発した**subgraph forking**を導入し、今回はこの機能を使ってサブグラフのデバッグを大幅に高速化する方法を紹介します。 ## さて、それは何でしょうか? -**サブグラフのフォーク**とは、_他_のサブグラフのストア(通常はリモート) からエンティティをフェッチするプロセスです。 +**サブグラフのフォーク**とは、*他*のサブグラフのストア(通常はリモート) からエンティティをフェッチするプロセスです。 -デバッグの文脈では、**サブグラフのフォーク**により、ブロック_X_への同期を待つことなく、ブロック_X_で失敗したサブグラフのデバッグを行うことができます。 +デバッグの文脈では、**サブグラフのフォーク**により、ブロック*X*への同期を待つことなく、ブロック*X*で失敗したサブグラフのデバッグを行うことができます。 ## その方法は? -インデックス作成のためにリモートのGraphノードにサブグラフをデプロイし、ブロック_X_で失敗した場合でも、ブロック_X_と同期しているストアを使用して GraphQL クエリを提供することができます。つまり、ブロック _X_ のインデックス作成時に発生するバグを修正するために、この最新のストアを利用できるのです。 +インデックス作成のためにリモートの Graph ノードにサブグラフをデプロイし、ブロック*X*で失敗した場合でも、ブロック*X*と同期しているストアを使用して GraphQL クエリを提供することができます。つまり、ブロック _X_ のインデックス作成時に発生するバグを修正するために、この最新のストアを利用できるのです。 -簡単に言うと、ブロック_X_でデバッグされているローカルにデプロイされたサブグラフにインデックス状態の最新のビューを提供するために、ブロック_X_までインデックスされたサブグラフを持つことが保証されているリモートGraphノードから _失敗したサブグラフをフォーク_しようとしているのです。 +簡単に言うと、ブロック*X*でデバッグされているローカルにデプロイされたサブグラフにインデックス状態の最新のビューを提供するために、ブロック*X*までインデックスされたサブグラフを持つことが保証されているリモート Graph ノードから *失敗したサブグラフをフォーク*しようとしているのです。 ## コードを見てみましょう -サブグラフのデバッグに集中するために、物事をシンプルにして、Ethereum Gravityスマートコントラクトのサブグラフのインデックス作成の[例](https://github.com/graphprotocol/example-subgraph)に沿って実行しましょう。 +サブグラフのデバッグに集中するために、物事をシンプルにして、Ethereum Gravity スマートコントラクトのサブグラフのインデックス作成の[例](https://github.com/graphprotocol/example-subgraph)に沿って実行しましょう。 以下は、`Gravatar`のインデックスを作成するために定義されたハンドラで、バグが全くありません。 @@ -46,32 +46,32 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -この場合、残念なことに、この完璧に見えるサブグラフを[HostedService](https://thegraph.com/hosted-service/) にデプロイすると、_"Gravatar not found!"_というエラーで失敗してしまいます。 +この場合、残念なことに、この完璧に見えるサブグラフを[HostedService](https://thegraph.com/hosted-service/) にデプロイすると、*"Gravatar not found!"*というエラーで失敗してしまいます。 通常の試すであろう修正方法: 1. マッピングソースを変更して問題の解決を試す(解決されないことは分かっていても) -2. サブグラフを[HostedService](https://thegraph.com/hosted-service/)(または別のリモートGraphノード)に再デプロイする +2. サブグラフを[HostedService](https://thegraph.com/hosted-service/)(または別のリモート Graph ノード)に再デプロイする 3. 同期を待つ -4. 再び問題が発生した場合は、1に戻る +4. 再び問題が発生した場合は、1 に戻る -このように、通常のデバッグ処理とほぼ同じですが、1つだけ、処理を恐ろしく遅くするステップがあります:_3. 同期を待つ_ +このように、通常のデバッグ処理とほぼ同じですが、1 つだけ、処理を恐ろしく遅くするステップがあります:_3. 同期を待つ_ **サブグラフのフォーク**を利用することで、このステップを実質的に省略することができます。その方法は次の通りです: 0. **_適切なフォークベース_**セットを持つローカルのグラフ・ノードをスピンアップする 1. マッピングのソースを変更し、問題を解決する -2. ローカルGraphノードにデプロイし、**_失敗したサブグラフをフォーク_**して、**_問題のブロックから開始_**する -3. もし再度、壊れる場合1に戻る +2. ローカル Graph ノードにデプロイし、**_失敗したサブグラフをフォーク_**して、**_問題のブロックから開始_**する +3. もし再度、壊れる場合 1 に戻る -さて、ここで2つの疑問が生じます: +さて、ここで 2 つの疑問が生じます: 1. フォークベースとは? 2. 誰がフォークするのか? 回答: -1. `fork-base`は「ベース」URLで、_subgraph id_が追加されたときのURL (`/`) はサブグラフのストアに対する有効な GraphQL endpoint であることを示します。 +1. `fork-base`は「ベース」URL で、*subgraph id*が追加されたときの URL (`/`) はサブグラフのストアに対する有効な GraphQL endpoint であることを示します。 2. フォーキングは簡単であり煩雑な手間はありません ```bash @@ -92,13 +92,13 @@ $ cargo run -p graph-node --release -- \ --fork-base https://api.thegraph.com/subgraphs/id/ ``` -1. よく調べてみると、2つのハンドラで `Gravatar` をインデックスする際に使用される `id` 表現にミスマッチがあることに気づきました。`handleNewGravatar` はそれを hex (`event.params.id.toHex()`) に変換しますが、`handleUpdatedGravatar` は int32 (`event.params.id.toI32()`) を使用するので `handleUpdatedGravatar` は "Gravatar not found!" でパニックになってしまうのです。両方とも`id`を16進数に変換するようにしています。 -2. 変更後、ローカルのGraphノードにサブグラフをデプロイし、**_失敗したサブグラフのフォーク_**と `subgraph.yaml` で `dataSources.source.startBlock` を `6190343` にセットしてください。 +1. よく調べてみると、2 つのハンドラで `Gravatar` をインデックスする際に使用される `id` 表現にミスマッチがあることに気づきました。`handleNewGravatar` はそれを hex (`event.params.id.toHex()`) に変換しますが、`handleUpdatedGravatar` は int32 (`event.params.id.toI32()`) を使用するので `handleUpdatedGravatar` は "Gravatar not found!" でパニックになってしまうのです。両方とも`id`を 16 進数に変換するようにしています。 +2. 変更後、ローカルの Graph ノードにサブグラフをデプロイし、**_失敗したサブグラフのフォーク_**と `subgraph.yaml` で `dataSources.source.startBlock` を `6190343` にセットしてください。 ```bash $ graph deploy gravity --debug-fork QmNp169tKvomnH3cPXTfGg4ZEhAHA6kEq5oy1XDqAxqHmW --ipfs http://localhost:5001 --node http://localhost:8020 ``` -3. ローカルのGraphノードが出力するログを調べてみると、すべてうまくいっていることがわかります。 -4. バグのないサブグラフをリモートのGraphノードにデプロイすることができました。 +3. ローカルの Graph ノードが出力するログを調べてみると、すべてうまくいっていることがわかります。 +4. バグのないサブグラフをリモートの Graph ノードにデプロイすることができました。 5. 完了です。 diff --git a/pages/ja/explorer.mdx b/pages/ja/explorer.mdx index 95bdbb2f3bdc..5494043c66f5 100644 --- a/pages/ja/explorer.mdx +++ b/pages/ja/explorer.mdx @@ -11,7 +11,7 @@ title: エクスプローラー title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen -> + > ## サブグラフ diff --git a/pages/ja/hosted-service/migrating-subgraph.mdx b/pages/ja/hosted-service/migrating-subgraph.mdx index 53cd30301eed..a56de01c6e53 100644 --- a/pages/ja/hosted-service/migrating-subgraph.mdx +++ b/pages/ja/hosted-service/migrating-subgraph.mdx @@ -90,7 +90,7 @@ graph deploy --studio ### サブグラフの安定版の維持 -アップグレードには、旧バージョンのサブグラフから新バージョンのサブグラフへのGRTの移行が必要です。つまり、アップグレードのたびに、新しいボンディングカーブが作成されます(ボンディングカーブについての詳細は[こちら](/curating#bonding-curve-101)) +アップグレードには、旧バージョンのサブグラフから新バージョンのサブグラフへの GRT の移行が必要です。つまり、アップグレードのたびに、新しいボンディングカーブが作成されます(ボンディングカーブについての詳細は[こちら](/curating#bonding-curve-101)) サブグラフに多くの変更を加えている場合、継続的にアップグレードしてアップグレード費用を負担するのは得策ではありません。サブグラフの安定した一貫性のあるバージョンを維持することは、コストの観点からだけでなく、インデクサーが自信を持って同期時間を設定できるようにするためにも重要です。アップグレードを計画する際には、インデクサーの同期時間に影響が出ないように、インデクサにフラグを立てる必要があります。Discord の[#Indexers channel](https://discord.gg/8tgJ7rKW)チャンネルを利用して、サブグラフのバージョンアップをインデクサーに知らせることができます。 @@ -98,7 +98,7 @@ graph deploy --studio - ENS を設定する: https://app.ens.domains/ - ENS 名を[こちら](https://thegraph.com/explorer/settings?view=display-name)の設定に追加します。 -- 所有者は料金の半分の1250GRTをバーンすることができます。アップグレードの前に、この資金をウォレットに用意しておかなければなりません。この操作は、アップグレードと同じトランザクションで行われます。 +- 所有者は料金の半分の 1250GRT をバーンすることができます。アップグレードの前に、この資金をウォレットに用意しておかなければなりません。この操作は、アップグレードと同じトランザクションで行われます。 _このメカニズムは現在ネットワーク上で稼動していますが、現在コミュニティでは、サブグラフ開発者のアップグレードコストを削減する方法について議論しています。_ @@ -118,8 +118,8 @@ _このメカニズムは現在ネットワーク上で稼動していますが 1. サブグラフの開発に ENS 名を活用する -- ENSのセットアップ:[https://app.ens.domains/](https://app.ens.domains/) -- ENSネームの追加方法は name to your settings [こちら](https://thegraph.com/explorer/settings?view=display-name). +- ENS のセットアップ:[https://app.ens.domains/](https://app.ens.domains/) +- ENS ネームの追加方法は name to your settings [こちら](https://thegraph.com/explorer/settings?view=display-name). 2. プロフィールが充実しているほど、サブグラフがインデックスやキュレーションされる可能性が高くなります。 @@ -154,10 +154,10 @@ The Graph Network が真の意味で分散化されるためには、プロト title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen -> + > -- [The Graph Networkのコントラクト](https://github.com/graphprotocol/contracts) -- [キュレーションコントラクト](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - GNSが包括する基本的なコントラクト +- [The Graph Network のコントラクト](https://github.com/graphprotocol/contracts) +- [キュレーションコントラクト](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - GNS が包括する基本的なコントラクト - アドレス - `0x8fe00a685bcb3b2cc296ff6ffeab10aca4ce1538` -- [Subgraph Studioドキュメント](/studio/subgraph-studio) +- [Subgraph Studio ドキュメント](/studio/subgraph-studio) diff --git a/pages/ja/indexing.mdx b/pages/ja/indexing.mdx index f8a0d760efae..ad80d2257638 100644 --- a/pages/ja/indexing.mdx +++ b/pages/ja/indexing.mdx @@ -114,12 +114,12 @@ Use Etherscan to call `getRewards()`: - **Medium** - 100 個のサブグラフと 1 秒あたり 200 ~ 500 のリクエストをサポートするプロダクションインデクサー - **Large** - 現在使用されているすべてのサブグラフのインデックスを作成し、関連するトラフィックのリクエストに対応します -| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | -| -------- |:--------------------------:|:-----------------------------------:|:---------------------------------:|:---------------------:|:------------------------------:| -| Small | 4 | 8 | 1 | 4 | 16 | -| Standard | 8 | 30 | 1 | 12 | 48 | -| Medium | 16 | 64 | 2 | 32 | 64 | -| Large | 72 | 468 | 3.5 | 48 | 184 | +| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | +| --- | :-: | :-: | :-: | :-: | :-: | +| Small | 4 | 8 | 1 | 4 | 16 | +| Standard | 8 | 30 | 1 | 12 | 48 | +| Medium | 16 | 64 | 2 | 32 | 64 | +| Large | 72 | 468 | 3.5 | 48 | 184 | ### インデクサーが取るべきセキュリティ対策は? @@ -151,20 +151,20 @@ Use Etherscan to call `getRewards()`: #### グラフノード -| Port | Purpose | Routes | CLI Argument | Environment Variable | -| ---- | ------------------------------------------------------- | ------------------------------------------------------------------- | ----------------- | -------------------- | -| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(for managing deployments) | / | --admin-port | - | -| 8030 | Subgraph indexing status API | /graphql | --index-node-port | - | -| 8040 | Prometheus metrics | /metrics | --metrics-port | - | +| Port | Purpose | Routes | CLI Argument | Environment Variable | +| --- | --- | --- | --- | --- | +| 8000 | GraphQL HTTP server
(for subgraph queries) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(for subgraph subscriptions) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(for managing deployments) | / | --admin-port | - | +| 8030 | Subgraph indexing status API | /graphql | --index-node-port | - | +| 8040 | Prometheus metrics | /metrics | --metrics-port | - | #### Indexer Service -| Port | Purpose | Routes | CLI Argument | Environment Variable | -| ---- | ------------------------------------------------------------ | --------------------------------------------------------------------------- | -------------- | ---------------------- | -| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus metrics | /metrics | --metrics-port | - | +| Port | Purpose | Routes | CLI Argument | Environment Variable | +| --- | --- | --- | --- | --- | +| 7600 | GraphQL HTTP server
(for paid subgraph queries) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus metrics | /metrics | --metrics-port | - | #### Indexer Agent diff --git a/pages/ja/studio/billing.mdx b/pages/ja/studio/billing.mdx index a2250d788953..5eac4d88a13d 100644 --- a/pages/ja/studio/billing.mdx +++ b/pages/ja/studio/billing.mdx @@ -46,7 +46,7 @@ Subgraph Studio 上での課金機能のデモについては、以下のビデ title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen -> + > ### マルチシグユーザー diff --git a/pages/ja/studio/studio-faq.mdx b/pages/ja/studio/studio-faq.mdx index b939e8f8b1ee..7612dddff07b 100644 --- a/pages/ja/studio/studio-faq.mdx +++ b/pages/ja/studio/studio-faq.mdx @@ -20,8 +20,8 @@ API キーを作成後、「セキュリティ」セクションで、特定の API キーを作成すると、自分でサブグラフを構築した場合でも、ネットワークに公開されているすべてのサブグラフにクエリを実行できることを覚えておいてください。新しい API キーを介したこれらのクエリは、ネットワーク上の他のクエリと同様に支払われます。 -### 5. 使用したいサブグラフのクエリURLを見つける方法は? +### 5. 使用したいサブグラフのクエリ URL を見つける方法は? -各サブグラフのクエリ URL は、Graph Explorerの「Subgraph Details」で確認できます。「Query」をクリックすると、興味のあるサブグラフのクエリ URL が表示されます。ここで``というプレースホルダーを、Subgraph Studioで利用したい API キーに置き換えることができます。 +各サブグラフのクエリ URL は、Graph Explorer の「Subgraph Details」で確認できます。「Query」をクリックすると、興味のあるサブグラフのクエリ URL が表示されます。ここで``というプレースホルダーを、Subgraph Studio で利用したい API キーに置き換えることができます。 -APIキーを作成すると、自分でサブグラフを構築した場合でも、ネットワークに公開されているすべてのサブグラフにクエリを実行できることを覚えておいてください。新しい API キーを介したこれらのクエリは、ネットワーク上の他のクエリと同様に支払われます。 +API キーを作成すると、自分でサブグラフを構築した場合でも、ネットワークに公開されているすべてのサブグラフにクエリを実行できることを覚えておいてください。新しい API キーを介したこれらのクエリは、ネットワーク上の他のクエリと同様に支払われます。 diff --git a/pages/ja/studio/subgraph-studio.mdx b/pages/ja/studio/subgraph-studio.mdx index ade83087fe23..8058d1acc22e 100644 --- a/pages/ja/studio/subgraph-studio.mdx +++ b/pages/ja/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ The Graph Network の機能やネットワークは順次追加されていき title="YouTube ビデオプレイヤー" frameBorder="0" allowFullScreen -> + > 公開する際には、メインネットまたはテストネットである Rinkeby のどちらかに公開することができます。初めてサブグラフを開発される方は、まず Rinkeby への公開から始めることをお勧めします。これにより、サブグラフが The Graph Explorer でどのように動作するかを確認することができ、キュレーション要素をテストすることができます。 @@ -110,7 +110,7 @@ Dapp 開発者、サブグラフ開発者に関わらず、API キーを管理 - API キーの現在の使用状況を統計で表示: - クエリの数 - 使用した GRT の量 -2. **Manage Security Settings**では、APIキーの管理レベルに応じて、セキュリティ設定を選択することができます。このセクションでは、以下のことができます: +2. **Manage Security Settings**では、API キーの管理レベルに応じて、セキュリティ設定を選択することができます。このセクションでは、以下のことができます: - API キーの使用を許可されたドメイン名の表示と管理 - API キーでクエリ可能なサブグラフの割り当て diff --git a/pages/ko/curating.mdx b/pages/ko/curating.mdx index 456deec666f7..dcb329288947 100644 --- a/pages/ko/curating.mdx +++ b/pages/ko/curating.mdx @@ -100,5 +100,5 @@ title: 큐레이팅 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > diff --git a/pages/ko/delegating.mdx b/pages/ko/delegating.mdx index 8b9ca4863ca1..09d3ee53b7ee 100644 --- a/pages/ko/delegating.mdx +++ b/pages/ko/delegating.mdx @@ -32,9 +32,7 @@ title: 위임하기 Indexing Reward Cut – Indexing Reward Cut은 인덱서가 스스로 가져갈 보상의 비율입니다. 즉, 100%로 설정된 경우 위임자에게 주어지는 인덱싱 보상이 0이 됩니다. 만약 UI에 80%로 표시되어 있다면, 이는 여러분은 위임자로서 20%를 받게 된다는 것을 의미합니다. 중요 참고 사항 - 네트워크 시작 부분의 인덱싱 보상이 보상의 대부분을 차지합니다. -
- 위임 UI에는 0.5%의 수수료 및 28일의 위임 해지 기간이 명시되어있습니다. -
+
위임 UI에는 0.5%의 수수료 및 28일의 위임 해지 기간이 명시되어있습니다.
### 위임자들에 대한 공정한 보상 지급 규칙을 지닌 신뢰할 수 있는 인덱서 선택 @@ -93,5 +91,5 @@ This guide provides a full review of this document, and how to consider everythi title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > diff --git a/pages/ko/developer/assemblyscript-api.mdx b/pages/ko/developer/assemblyscript-api.mdx index c5eec178398a..1f5ce7dc1ca1 100644 --- a/pages/ko/developer/assemblyscript-api.mdx +++ b/pages/ko/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install --save-dev @graphprotocol/graph-ts # NPM 서브그래프 매니페스트의 `apiVersion`은 주어진 서브그래프에 대해 그래프 노드가 실행하는 매핑 API 버전을 지정합니다. 현재 맵핑 API 버전은 0.0.6 입니다. -| 버전 | 릴리스 노트 | -|:-----:| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| 0.0.6 | 이더리움 트랜잭션 개체에 `nonce` 필드를 추가했습니다.
`baseFeePerGas`가 이더리움 블록 개체에 추가되었습니다. | +| 버전 | 릴리스 노트 | +| :-: | --- | +| 0.0.6 | 이더리움 트랜잭션 개체에 `nonce` 필드를 추가했습니다.
`baseFeePerGas`가 이더리움 블록 개체에 추가되었습니다. | | 0.0.5 | AssemblyScript를 버전 0.19.10으로 업그레이드했습니다(변경 내용 깨짐 포함. [`Migration Guide`](/developer/assemblyscript-migration-guide) 참조)
`ethereum.transaction.gasUsed`의 이름이 `ethereum.transaction.gasLimit`로 변경되었습니다. | -| 0.0.4 | Ethereum SmartContractCall 개체에 `functionSignature` 필드를 추가했습니다. | -| 0.0.3 | Ethereum Call 개체에 `from` 필드를 추가했습니다.
`etherem.call.address`의 이름이 `ethereum.call.to`로 변경되었습니다. | -| 0.0.2 | Ethereum Transaction 개체에 `input` 필드를 추가했습니다. | +| 0.0.4 | Ethereum SmartContractCall 개체에 `functionSignature` 필드를 추가했습니다. | +| 0.0.3 | Ethereum Call 개체에 `from` 필드를 추가했습니다.
`etherem.call.address`의 이름이 `ethereum.call.to`로 변경되었습니다. | +| 0.0.2 | Ethereum Transaction 개체에 `input` 필드를 추가했습니다. | ### 기본 제공 유형 diff --git a/pages/ko/developer/assemblyscript-migration-guide.mdx b/pages/ko/developer/assemblyscript-migration-guide.mdx index 1c66f3c58257..ad2fb218a699 100644 --- a/pages/ko/developer/assemblyscript-migration-guide.mdx +++ b/pages/ko/developer/assemblyscript-migration-guide.mdx @@ -127,8 +127,11 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` + Variable shadowing이 있는 경우 중복 변수의 이름을 바꿔야 합니다. + ### Null Comparisons + 서브그래프에서 업그레이드를 수행하면 때때로 다음과 같은 오류가 발생할 수 있습니다: ```typescript @@ -137,6 +140,7 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` + 이를 해결하기 위해 여러분들은 `if` 구문을 다음과 같이 간단히 변경할 수 있습니다: ```typescript @@ -284,6 +288,7 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` + 이 문제를 해결하려면 컴파일러에서 nullability 검사를 수행할 수 있도록 해당 속성 액세스에 대한 변수를 생성할 수 있습니다: ```typescript diff --git a/pages/ko/developer/create-subgraph-hosted.mdx b/pages/ko/developer/create-subgraph-hosted.mdx index 515579710f4e..3d0d11498e6c 100644 --- a/pages/ko/developer/create-subgraph-hosted.mdx +++ b/pages/ko/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Null value resolved for non-null field 'name' GraphQL API에서는 다음과 같은 스칼라들을 지원합니다: -| 유형 | 설명 | -| ------------ | -------------------------------------------------------------------------------------------------------------------------------------------------- | -| `Bytes` | 16진수 문자열로 표시되는 바이트 배열입니다. 이더리움 해시 및 주소에 일반적으로 사용됩니다. | -| `ID` | `string`으로 저장됩니다. | -| `String` | `string` 값을 위한 스칼라. Null 문자는 지원되지 않으며 자동으로 제거됩니다. | -| `Boolean` | `boolean` 값을 위한 스칼라 | -| `Int` | GraphQL 규격은 `Int`의 크기를 32바이트로 정의합니다. | -| `BigInt` | 큰 정수. 이더리움의 `uint32`, `int64`, `uint64`, ..., `uint256` 유형에 사용됩니다. 참고: , such as `int32`, `uint24` 또는 `int8`과 같은 `uint32` 아래의 모든 항목은 `i32`로 표시됩니다. | -| `BigDecimal` | 정수부와 지수로 표현되는 `BigDecimal` 고정밀 소수. 지수 범위는 -6143 ~ +6144입니다. 34자리 유효 숫자로 반올림합니다. | +| 유형 | 설명 | +| --- | --- | +| `Bytes` | 16진수 문자열로 표시되는 바이트 배열입니다. 이더리움 해시 및 주소에 일반적으로 사용됩니다. | +| `ID` | `string`으로 저장됩니다. | +| `String` | `string` 값을 위한 스칼라. Null 문자는 지원되지 않으며 자동으로 제거됩니다. | +| `Boolean` | `boolean` 값을 위한 스칼라 | +| `Int` | GraphQL 규격은 `Int`의 크기를 32바이트로 정의합니다. | +| `BigInt` | 큰 정수. 이더리움의 `uint32`, `int64`, `uint64`, ..., `uint256` 유형에 사용됩니다. 참고: , such as `int32`, `uint24` 또는 `int8`과 같은 `uint32` 아래의 모든 항목은 `i32`로 표시됩니다. | +| `BigDecimal` | 정수부와 지수로 표현되는 `BigDecimal` 고정밀 소수. 지수 범위는 -6143 ~ +6144입니다. 34자리 유효 숫자로 반올림합니다. | #### 열거형(Enums) @@ -428,33 +428,33 @@ query { 지원되는 언어 사전: -| 코드 | 사전(Dictionary) | -| ------ | -------------- | -| simple | General | -| da | Danish | -| nl | Dutch | -| en | English | -| fi | Finnish | -| fr | French | -| de | German | -| hu | Hungarian | -| it | Italian | -| no | Norwegian | -| pt | Portugese | -| ro | Romanian | -| ru | Russian | -| es | Spanish | -| sv | Swedish | -| tr | Turkish | +| 코드 | 사전(Dictionary) | +| ------ | ---------------- | +| simple | General | +| da | Danish | +| nl | Dutch | +| en | English | +| fi | Finnish | +| fr | French | +| de | German | +| hu | Hungarian | +| it | Italian | +| no | Norwegian | +| pt | Portugese | +| ro | Romanian | +| ru | Russian | +| es | Spanish | +| sv | Swedish | +| tr | Turkish | ### 순위 알고리즘 결과 정렬을 위해 지원되는 알고리즘: -| 알고리즘 | 설명 | -| ------------- | ---------------------------------------------- | +| 알고리즘 | 설명 | +| ------------- | ------------------------------------------------------------------- | | rank | 전체 텍스트 쿼리의 match quality(0-1)를 사용하여 결과를 정렬합니다. | -| proximityRank | 순위와 유사하지만 matches의 근접성도 포함합니다. | +| proximityRank | 순위와 유사하지만 matches의 근접성도 포함합니다. | ## 매핑 작성 @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **참고:**: 새 데이터 소스는 자신이 생성된 블록과 이후의 모든 블록에 대한 호출 및 이벤트만 처리하지만 과거 데이터, 즉 이전 블록에 포함된 데이터는 처리하지 않습니다. -> +> > 만약 이전 블록에 새 데이터 원본과 관련된 데이터가 포함된 경우 컨트랙트의 현재 상태를 읽고 새 데이터 원본이 생성될 때 해당 상태를 나타내는 엔터티를 만들어 해당 데이터를 인덱싱하는 것이 가장 좋습니다. ### 데이터 소스 컨텍스트 @@ -684,7 +684,7 @@ dataSources: ``` > **참고:**: Etherscan에서 컨트랙트 생성 블록을 빠르게 조회할 수 있습니다. -> +> > 1. 검색 창에 주소를 입력하여 컨트랙트를 검색합니다. > 2. `Contract Creator` 섹션에서 creation transaction hash를 클릭합니다. > 3. 해당 컨트랙트의 start block을 찾을 거래 세부 정보 페이지를 로드합니다. @@ -743,7 +743,7 @@ export function handleCreateGravatar(call: CreateGravatarCall): void { } ``` -`handleCreateGravatar` 함수는 `@graphprotocol/graph-ts``에서 제공하는 ethereum.Call`의 하위 클래스인 새 `CreateGravatarCall`을 취하며, 여기에는 호출의 유형이 지정된 입력 및 출력이 포함됩니다. `graph codegen`을 실행할 때 CreateGravatarCall 유형이 생성됩니다. +`handleCreateGravatar` 함수는 ` @graphprotocol/graph-ts``에서 제공하는 ethereum.Call `의 하위 클래스인 새 `CreateGravatarCall`을 취하며, 여기에는 호출의 유형이 지정된 입력 및 출력이 포함됩니다. `graph codegen`을 실행할 때 CreateGravatarCall 유형이 생성됩니다. ## 블록 핸들러 @@ -816,7 +816,7 @@ eventHandlers: `specVersion` `0.0.4`부터 서브그래프 기능은 매니페스트 파일의 최상위 레벨에 있는 `features` 섹션에 아래 표에 나열된 대로 그들의 `camelCase` 이름을 사용하여 명백하게 명시되어야 합니다. -| 기능 | 이름 | +| 기능 | 이름 | | --------------------------------------------------------- | ------------------------- | | [Non-fatal errors](#non-fatal-errors) | `nonFatalErrors` | | [Full-text Search](#defining-fulltext-search-fields) | `fullTextSearch` | diff --git a/pages/ko/developer/graphql-api.mdx b/pages/ko/developer/graphql-api.mdx index 41086bbb8627..65c0da07b871 100644 --- a/pages/ko/developer/graphql-api.mdx +++ b/pages/ko/developer/graphql-api.mdx @@ -204,12 +204,12 @@ _not_ends_with 전체 텍스트 검색 연산자: -| 심볼 | 연산자 | 설명 | -| ----------- | ----------- | ------------------------------------------------------------------------ | -| `&` | `And` | 제공된 모든 용어를 포함하는 엔터티에 대한 필터로, 여러 검색어를 결합하기 위해 사용합니다. | -| | | `Or` | the 혹은 오퍼레이터에 의해 구분된 다중 검색어들과 함께 쿼리는 제공된 어떠한 용어들로부터 일치하는 모든 엔티티들을 반환합니다. | -| `<->` | `Follow by` | 두 단어 사이의 거리를 지정합니다. | -| `:*` | `Prefix` | 접두사 검색어를 사용하여 접두사가 일치하는 단어를 찾습니다(2글자 필요). | +| 심볼 | 연산자 | 설명 | +| --- | --- | --- | +| `&` | `And` | 제공된 모든 용어를 포함하는 엔터티에 대한 필터로, 여러 검색어를 결합하기 위해 사용합니다. | +| | | `Or` | the 혹은 오퍼레이터에 의해 구분된 다중 검색어들과 함께 쿼리는 제공된 어떠한 용어들로부터 일치하는 모든 엔티티들을 반환합니다. | +| `<->` | `Follow by` | 두 단어 사이의 거리를 지정합니다. | +| `:*` | `Prefix` | 접두사 검색어를 사용하여 접두사가 일치하는 단어를 찾습니다(2글자 필요). | #### 예시 diff --git a/pages/ko/explorer.mdx b/pages/ko/explorer.mdx index 02a0697dc6bf..b7b9d9f43930 100644 --- a/pages/ko/explorer.mdx +++ b/pages/ko/explorer.mdx @@ -11,7 +11,7 @@ title: 탐색기 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > ## 서브그래프 diff --git a/pages/ko/hosted-service/migrating-subgraph.mdx b/pages/ko/hosted-service/migrating-subgraph.mdx index 7ed6a4b8312f..6755533bcf0f 100644 --- a/pages/ko/hosted-service/migrating-subgraph.mdx +++ b/pages/ko/hosted-service/migrating-subgraph.mdx @@ -154,7 +154,7 @@ If you're still confused, fear not! Check out the following resources or watch o title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > - [The Graph Network Contracts](https://github.com/graphprotocol/contracts) diff --git a/pages/ko/indexing.mdx b/pages/ko/indexing.mdx index 7764f52318f7..f04d20aa1da5 100644 --- a/pages/ko/indexing.mdx +++ b/pages/ko/indexing.mdx @@ -114,12 +114,12 @@ query indexerAllocations { - **Medium** - 100개의 Subgraph 및 초당 200 - 500개의 요청을 서포트 할 수 있는 프로덕션 인덱서입니다. - **Large** - 현재 사용되는 모든 서브그래프들 및 관련 트레픽 요청의 처리에 대한 요건을 충족합니다. -| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | -| -------- |:--------------------------:|:-----------------------------------:|:---------------------------------:|:---------------------:|:------------------------------:| -| Small | 4 | 8 | 1 | 4 | 16 | -| Standard | 8 | 30 | 1 | 12 | 48 | -| Medium | 16 | 64 | 2 | 32 | 64 | -| Large | 72 | 468 | 3.5 | 48 | 184 | +| Setup | Postgres
(CPUs) | Postgres
(memory in GBs) | Postgres
(disk in TBs) | VMs
(CPUs) | VMs
(memory in GBs) | +| --- | :-: | :-: | :-: | :-: | :-: | +| Small | 4 | 8 | 1 | 4 | 16 | +| Standard | 8 | 30 | 1 | 12 | 48 | +| Medium | 16 | 64 | 2 | 32 | 64 | +| Large | 72 | 468 | 3.5 | 48 | 184 | ### 인덱서가 취해야 할 기본적인 보안 예방 조치는 무엇인가요? @@ -151,26 +151,26 @@ query indexerAllocations { #### 그래프 노드 -| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | -| ---- | ------------------------------------------ | ---------------------------------------------------- | ----------------- | ----- | -| 8000 | GraphQL HTTP server
(서브그래프 쿼리용) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(서브그래프 구독용) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(배포 관리용) | / | --admin-port | - | -| 8030 | 서브그래프 인덱싱 상태 API | /graphql | --index-node-port | - | -| 8040 | Prometheus metrics | /metrics | --metrics-port | - | +| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | +| --- | --- | --- | --- | --- | +| 8000 | GraphQL HTTP server
(서브그래프 쿼리용) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(서브그래프 구독용) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(배포 관리용) | / | --admin-port | - | +| 8030 | 서브그래프 인덱싱 상태 API | /graphql | --index-node-port | - | +| 8040 | Prometheus metrics | /metrics | --metrics-port | - | #### 인덱서 서비스 -| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | -| ---- | ----------------------------------------------- | ----------------------------------------------------------------------- | -------------- | ---------------------- | -| 7600 | GraphQL HTTP server
(유료 서브그래프 쿼리용) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus metrics | /metrics | --metrics-port | - | +| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | +| --- | --- | --- | --- | --- | +| 7600 | GraphQL HTTP server
(유료 서브그래프 쿼리용) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus metrics | /metrics | --metrics-port | - | #### 인덱서 에이전트 -| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | -| ---- | ---------- | -- | ------------------------- | --------------------------------------- | -| 8000 | 인덱서 관리 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | +| 포트 | 목적 | 경로 | CLI 인수 | 환경 변수 | +| ---- | --------------- | ---- | ------------------------- | --------------------------------------- | +| 8000 | 인덱서 관리 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | ### Google Cloud상의 Terraform을 사용한 서버 인프라 구축 @@ -600,7 +600,7 @@ default => 0.1 * $SYSTEM_LOAD; 비용 모델 예시: -| 쿼리 | 가격 | +| 쿼리 | 가격 | | ---------------------------------------------------------------------------- | ------- | | { pairs(skip: 5000) { id } } | 0.5 GRT | | { tokens { symbol } } | 0.1 GRT | diff --git a/pages/ko/studio/billing.mdx b/pages/ko/studio/billing.mdx index 66d3ddb46b68..0d4433e3f939 100644 --- a/pages/ko/studio/billing.mdx +++ b/pages/ko/studio/billing.mdx @@ -46,7 +46,7 @@ Subgraph Studio에서 청구가 작동하는 방식에 대한 빠른 이해를 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > ### Multisig Users diff --git a/pages/ko/studio/subgraph-studio.mdx b/pages/ko/studio/subgraph-studio.mdx index a8ada10bb731..a4e7755055c1 100644 --- a/pages/ko/studio/subgraph-studio.mdx +++ b/pages/ko/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ The Graph 네트워크는 아직 호스팅 서비스에서 사용할 수 있는 title="YouTubeビデオプレーヤー" frameBorder="0" allowFullScreen -> + > 퍼블리싱 플로우를 진행하는 동안 메인넷이나 우리가 지원하는 테스트넷인 Rinkeby로 푸시할 수 있음을 기억하시기 바랍니다. 서브그래프 개발자가 처음이라면 무료인 Rinkeby에 퍼블리싱하는 것으로 시작하는 것이 좋습니다. 이를 통해 그래프 탐색기에서 서브그래프가 어떻게 작동하는지 확인하고 큐레이션 요소를 테스트할 수 있습니다. diff --git a/pages/vi/curating.mdx b/pages/vi/curating.mdx index 1affd60eaf9d..32018f0aa360 100644 --- a/pages/vi/curating.mdx +++ b/pages/vi/curating.mdx @@ -100,5 +100,5 @@ Vẫn còn thắc mắc? Xem video hướng dẫn Curation của chúng tôi bê title="Trình phát video YouTube" frameBorder="0" allowFullScreen -> + > diff --git a/pages/vi/delegating.mdx b/pages/vi/delegating.mdx index aad7059eb09b..c7f73c64a544 100644 --- a/pages/vi/delegating.mdx +++ b/pages/vi/delegating.mdx @@ -94,5 +94,5 @@ Hướng dẫn này cung cấp đánh giá đầy đủ về tài liệu này v title="YouTube video player" frameBorder="0" allowFullScreen -> + > diff --git a/pages/vi/developer/assemblyscript-api.mdx b/pages/vi/developer/assemblyscript-api.mdx index 35ba6cba5f0c..458efa587c17 100644 --- a/pages/vi/developer/assemblyscript-api.mdx +++ b/pages/vi/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ Thư viện `@graphprotocol/graph-ts` cung cấp các API sau: `apiVersion` trong tệp kê khai subgraph chỉ định phiên bản API ánh xạ được chạy bởi Graph Node cho một subgraph nhất định. Phiên bản API ánh xạ hiện tại là 0.0.6. -| Phiên bản | Ghi chú phát hành | -|:---------:| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| 0.0.6 | Đã thêm trường `nonce` đến đối tượng Giao dịch Ethereum
Đã thêm `baseFeePerGas`đến đối tượng Ethereum Block | -| 0.0.5 | AssemblyScript đã nâng cấp lên phiên bản 0.19.10 (điều này bao gồm các thay đổi vi phạm, vui lòng xem [`Hướng dẫn Di chuyển`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` đổi tên thành `ethereum.transaction.gasLimit` | -| 0.0.4 | Đã thêm trường `functionSignature` vào đối tượng Ethereum SmartContractCall | -| 0.0.3 | Đã thêm trường `from` vào đối tượng Ethereum Call
`etherem.call.address` đổi tên thành `ethereum.call.to` | -| 0.0.2 | Đã thêm trường `input` vào đối tượng Ethereum Transaction | +| Phiên bản | Ghi chú phát hành | +| :-: | --- | +| 0.0.6 | Đã thêm trường `nonce` đến đối tượng Giao dịch Ethereum
Đã thêm `baseFeePerGas`đến đối tượng Ethereum Block | +| 0.0.5 | AssemblyScript đã nâng cấp lên phiên bản 0.19.10 (điều này bao gồm các thay đổi vi phạm, vui lòng xem [`Hướng dẫn Di chuyển`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` đổi tên thành `ethereum.transaction.gasLimit` | +| 0.0.4 | Đã thêm trường `functionSignature` vào đối tượng Ethereum SmartContractCall | +| 0.0.3 | Đã thêm trường `from` vào đối tượng Ethereum Call
`etherem.call.address` đổi tên thành `ethereum.call.to` | +| 0.0.2 | Đã thêm trường `input` vào đối tượng Ethereum Transaction | ### Các loại cài sẵn diff --git a/pages/vi/developer/assemblyscript-migration-guide.mdx b/pages/vi/developer/assemblyscript-migration-guide.mdx index 4358b17bc540..7af2e4782a29 100644 --- a/pages/vi/developer/assemblyscript-migration-guide.mdx +++ b/pages/vi/developer/assemblyscript-migration-guide.mdx @@ -127,8 +127,11 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` + Bạn sẽ cần đổi tên các biến trùng lặp của mình nếu bạn có che biến. + ### So sánh Null + Bằng cách thực hiện nâng cấp trên subgraph của bạn, đôi khi bạn có thể gặp các lỗi như sau: ```typescript @@ -137,6 +140,7 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` + Để giải quyết, bạn có thể chỉ cần thay đổi câu lệnh `if` thành một cái gì đó như sau: ```typescript @@ -284,6 +288,7 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` + Để khắc phục sự cố này, bạn có thể tạo một biến cho quyền truy cập thuộc tính đó để trình biên dịch có thể thực hiện phép thuật kiểm tra tính nullability: ```typescript diff --git a/pages/vi/developer/create-subgraph-hosted.mdx b/pages/vi/developer/create-subgraph-hosted.mdx index af0ecc490f9f..748de8d62a00 100644 --- a/pages/vi/developer/create-subgraph-hosted.mdx +++ b/pages/vi/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Mỗi thực thể phải có một trường `id`, thuộc loại `ID!` (string Chúng tôi hỗ trợ các đại lượng vô hướng sau trong API GraphQL của chúng tôi: -| Loại | Miêu tả | -| ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `Bytes` | Mảng byte, được biểu diễn dưới dạng chuỗi thập lục phân. Thường được sử dụng cho các mã băm và địa chỉ Ethereum. | -| `ID` | Được lưu trữ dưới dạng `string`. | -| `String` | Vô hướng cho các giá trị `string`. Các ký tự rỗng không được hỗ trợ và tự động bị xóa. | -| `Boolean` | Vô hướng cho các giá trị `boolean`. | -| `Int` | Thông số GraphQL xác định `Int` có kích thước 32 byte. | -| `BigInt` | Số nguyên lớn. Được sử dụng cho các loại `uint32`, `int64`, `uint64`, ..., `uint256` của Ethereum. Lưu ý: mọi thứ dưới `uint32`, như là `int32`, `uint24` or `int8` được đại diện như là `i32`. | -| `BigDecimal` | `BigDecimal` Các số thập phân có độ chính xác cao được biểu diễn dưới dạng dấu hiệu và số mũ. Phạm vi số mũ là từ −6143 đến +6144. Được làm tròn đến 34 chữ số có nghĩa. | +| Loại | Miêu tả | +| --- | --- | +| `Bytes` | Mảng byte, được biểu diễn dưới dạng chuỗi thập lục phân. Thường được sử dụng cho các mã băm và địa chỉ Ethereum. | +| `ID` | Được lưu trữ dưới dạng `string`. | +| `String` | Vô hướng cho các giá trị `string`. Các ký tự rỗng không được hỗ trợ và tự động bị xóa. | +| `Boolean` | Vô hướng cho các giá trị `boolean`. | +| `Int` | Thông số GraphQL xác định `Int` có kích thước 32 byte. | +| `BigInt` | Số nguyên lớn. Được sử dụng cho các loại `uint32`, `int64`, `uint64`, ..., `uint256` của Ethereum. Lưu ý: mọi thứ dưới `uint32`, như là `int32`, `uint24` or `int8` được đại diện như là `i32`. | +| `BigDecimal` | `BigDecimal` Các số thập phân có độ chính xác cao được biểu diễn dưới dạng dấu hiệu và số mũ. Phạm vi số mũ là từ −6143 đến +6144. Được làm tròn đến 34 chữ số có nghĩa. | #### Enums @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **Lưu ý:** Nguồn dữ liệu mới sẽ chỉ xử lý các lệnh gọi và sự kiện cho khối mà nó được tạo và tất cả các khối tiếp theo, nhưng sẽ không xử lý dữ liệu lịch sử, tức là dữ liệu được chứa trong các khối trước đó. -> +> > Nếu các khối trước đó chứa dữ liệu có liên quan đến nguồn dữ liệu mới, tốt nhất là lập chỉ mục dữ liệu đó bằng cách đọc trạng thái hiện tại của hợp đồng và tạo các thực thể đại diện cho trạng thái đó tại thời điểm nguồn dữ liệu mới được tạo. ### Bối cảnh Nguồn Dữ liệu @@ -684,7 +684,7 @@ dataSources: ``` > **Lưu ý:** Khối tạo hợp đồng có thể được nhanh chóng tra cứu trên Etherscan: -> +> > 1. Tìm kiếm hợp đồng bằng cách nhập địa chỉ của nó vào thanh tìm kiếm. > 2. Nhấp vào băm giao dịch tạo trong phần `Contract Creator`. > 3. Tải trang chi tiết giao dịch nơi bạn sẽ tìm thấy khối bắt đầu cho hợp đồng đó. diff --git a/pages/vi/developer/graphql-api.mdx b/pages/vi/developer/graphql-api.mdx index f2ab7b6eb8c3..729409defd91 100644 --- a/pages/vi/developer/graphql-api.mdx +++ b/pages/vi/developer/graphql-api.mdx @@ -204,12 +204,12 @@ Các truy vấn tìm kiếm toàn văn bản có một trường bắt buộc, ` Toán tử tìm kiếm toàn văn bản: -| Biểu tượng | Toán tử | Miêu tả | -| ----------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `&` | `And` | Để kết hợp nhiều cụm từ tìm kiếm thành một bộ lọc cho các thực thể bao gồm tất cả các cụm từ được cung cấp | -| | | `Or` | Các truy vấn có nhiều cụm từ tìm kiếm được phân tách bằng toán tử hoặc sẽ trả về tất cả các thực thể có kết quả khớp với bất kỳ cụm từ nào được cung cấp | -| `<->` | `Follow by` | Chỉ định khoảng cách giữa hai từ. | -| `:*` | `Prefix` | Sử dụng cụm từ tìm kiếm tiền tố để tìm các từ có tiền tố khớp với nhau (yêu cầu 2 ký tự.) | +| Biểu tượng | Toán tử | Miêu tả | +| --- | --- | --- | +| `&` | `And` | Để kết hợp nhiều cụm từ tìm kiếm thành một bộ lọc cho các thực thể bao gồm tất cả các cụm từ được cung cấp | +| | | `Or` | Các truy vấn có nhiều cụm từ tìm kiếm được phân tách bằng toán tử hoặc sẽ trả về tất cả các thực thể có kết quả khớp với bất kỳ cụm từ nào được cung cấp | +| `<->` | `Follow by` | Chỉ định khoảng cách giữa hai từ. | +| `:*` | `Prefix` | Sử dụng cụm từ tìm kiếm tiền tố để tìm các từ có tiền tố khớp với nhau (yêu cầu 2 ký tự.) | #### Các ví dụ diff --git a/pages/vi/explorer.mdx b/pages/vi/explorer.mdx index 1bb93f9bc45c..5c5573c0abdf 100644 --- a/pages/vi/explorer.mdx +++ b/pages/vi/explorer.mdx @@ -11,7 +11,7 @@ Chào mừng bạn đến với Graph Explorer, hay như chúng tôi thường g title="Trình phát video YouTube" frameBorder="0" allowFullScreen -> + > ## Subgraphs diff --git a/pages/vi/hosted-service/migrating-subgraph.mdx b/pages/vi/hosted-service/migrating-subgraph.mdx index 4843eccaa273..1bcde4a57054 100644 --- a/pages/vi/hosted-service/migrating-subgraph.mdx +++ b/pages/vi/hosted-service/migrating-subgraph.mdx @@ -154,7 +154,7 @@ If you're still confused, fear not! Check out the following resources or watch o title="Trình phát video YouTube" frameBorder="0" allowFullScreen -> + > - [The Graph Network Contracts](https://github.com/graphprotocol/contracts) diff --git a/pages/vi/indexing.mdx b/pages/vi/indexing.mdx index 5e578fa971f9..3c2108b02fcf 100644 --- a/pages/vi/indexing.mdx +++ b/pages/vi/indexing.mdx @@ -114,12 +114,12 @@ Indexer có thể tự phân biệt bản thân bằng cách áp dụng các k - **Trung bình** - Công cụ indexing production hỗ trợ 100 đồ subgraph và 200-500 yêu cầu mỗi giây. - **Lớn** - Được chuẩn bị để index tất cả các subgraph hiện đang được sử dụng và phục vụ các yêu cầu cho lưu lượng truy cập liên quan. -| Cài đặt | Postgres
(CPUs) | Postgres
(bộ nhớ tính bằng GB) | Postgres
(đĩa tính bằng TB) | VMs
(CPUs) | VMs
(bộ nhớ tính bằng GB) | -| ----------- |:--------------------------:|:-----------------------------------------:|:--------------------------------------:|:---------------------:|:------------------------------------:| -| Nhỏ | 4 | 8 | 1 | 4 | 16 | -| Tiêu chuẩn | 8 | 30 | 1 | 12 | 48 | -| Trung bình | 16 | 64 | 2 | 32 | 64 | -| Lớn | 72 | 468 | 3.5 | 48 | 184 | +| Cài đặt | Postgres
(CPUs) | Postgres
(bộ nhớ tính bằng GB) | Postgres
(đĩa tính bằng TB) | VMs
(CPUs) | VMs
(bộ nhớ tính bằng GB) | +| --- | :-: | :-: | :-: | :-: | :-: | +| Nhỏ | 4 | 8 | 1 | 4 | 16 | +| Tiêu chuẩn | 8 | 30 | 1 | 12 | 48 | +| Trung bình | 16 | 64 | 2 | 32 | 64 | +| Lớn | 72 | 468 | 3.5 | 48 | 184 | ### Một số biện pháp phòng ngừa bảo mật cơ bản mà indexer nên thực hiện là gì? @@ -151,20 +151,20 @@ Lưu ý: Để hỗ trợ mở rộng quy mô nhanh, bạn nên tách các mối #### Graph Node -| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | -| ---- | ----------------------------------------------------------- | ---------------------------------------------------- | ----------------- | --------------- | -| 8000 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(cho các đăng ký subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(để quản lý triển khai) | / | --admin-port | - | -| 8030 | API trạng thái lập chỉ mục Subgraph | /graphql | --index-node-port | - | -| 8040 | Số liệu Prometheus | /metrics | --metrics-port | - | +| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | +| --- | --- | --- | --- | --- | +| 8000 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(cho các đăng ký subgraph) | /subgraphs/id/...
/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(để quản lý triển khai) | / | --admin-port | - | +| 8030 | API trạng thái lập chỉ mục Subgraph | /graphql | --index-node-port | - | +| 8040 | Số liệu Prometheus | /metrics | --metrics-port | - | #### Dịch vụ Indexer -| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | -| ---- | ---------------------------------------------------------------------- | ----------------------------------------------------------------------- | -------------- | ---------------------- | -| 7600 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph có trả phí) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Số liệu Prometheus | /metrics | --metrics-port | - | +| Cổng | Mục đích | Tuyến | Đối số CLI | Biến môi trường | +| --- | --- | --- | --- | --- | +| 7600 | Máy chủ GraphQL HTTP
(cho các truy vấn subgraph có trả phí) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Số liệu Prometheus | /metrics | --metrics-port | - | #### Đại lý Indexer diff --git a/pages/vi/studio/billing.mdx b/pages/vi/studio/billing.mdx index d42fb8c4b92a..8e98e0996567 100644 --- a/pages/vi/studio/billing.mdx +++ b/pages/vi/studio/billing.mdx @@ -46,7 +46,7 @@ For a quick demo of how billing works on the Subgraph Studio, check out the vide title="Trình phát video YouTube" frameBorder="0" allowFullScreen -> + > ### Multisig Users diff --git a/pages/vi/studio/subgraph-studio.mdx b/pages/vi/studio/subgraph-studio.mdx index 570e8cac851f..bf4f8e412b3f 100644 --- a/pages/vi/studio/subgraph-studio.mdx +++ b/pages/vi/studio/subgraph-studio.mdx @@ -73,7 +73,7 @@ You’ve made it this far - congrats! Publishing your subgraph means that an IPF title="Trình phát video YouTube" frameBorder="0" allowFullScreen -> + > Remember, while you’re going through your publishing flow, you’ll be able to push to either mainnet or Rinkeby, the testnet we support. If you’re a first time subgraph developer, we highly suggest you start with publishing to Rinkeby, which is free to do. This will allow you to see how the subgraph will work in The Graph Explorer and will allow you to test curation elements. diff --git a/pages/zh/curating.mdx b/pages/zh/curating.mdx index f53632ba91b8..774fac8c90ee 100644 --- a/pages/zh/curating.mdx +++ b/pages/zh/curating.mdx @@ -100,5 +100,5 @@ Remember that curation is risky. 请做好你的工作,确保你在你信任 title="YouTube video player" frameBorder="0" allowFullScreen -> + > diff --git a/pages/zh/delegating.mdx b/pages/zh/delegating.mdx index e40bb06c8497..016ee2b659eb 100644 --- a/pages/zh/delegating.mdx +++ b/pages/zh/delegating.mdx @@ -32,9 +32,7 @@ title: 委托人 索引奖励分成- 索引奖励分成是指索引人将为自己保留的那部分奖励。 这意味着,如果它被设置为 100%,作为一个委托人,你将获得 0 个索引奖励。 如果你在 UI 中看到 80%,这意味着作为委托人,你将获得 20%。 一个重要的说明 -在网络的初期,索引奖励将占奖励的大部分比重。 -
- 请注意委托用户界面中的0.5%费用,以及28天的解约期。 -
+
请注意委托用户界面中的0.5%费用,以及28天的解约期。
### 选择一个为委托人提供公平的奖励分配的值得信赖的索引人 @@ -92,5 +90,5 @@ title: 委托人 title="YouTube video player" frameBorder="0" allowFullScreen -> + > diff --git a/pages/zh/developer/assemblyscript-api.mdx b/pages/zh/developer/assemblyscript-api.mdx index 0cab89ed08d6..c10acf58a788 100644 --- a/pages/zh/developer/assemblyscript-api.mdx +++ b/pages/zh/developer/assemblyscript-api.mdx @@ -43,13 +43,13 @@ npm install --save-dev @graphprotocol/graph-ts # NPM 子图清单中的 `apiVersion` 指定了由 Graph 节点为给定子图运行的映射 API 版本。 当前的映射 API 版本是 0.0.6。 -| 版本 | Release 说明 | -|:-----:| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| 0.0.6 | 向 Ethereum Transaction 对象添加 `nonce` 字段
向 Ethereum Block 对象添加 `baseFeePerGas` | +| 版本 | Release 说明 | +| :-: | --- | +| 0.0.6 | 向 Ethereum Transaction 对象添加 `nonce` 字段
向 Ethereum Block 对象添加 `baseFeePerGas` | | 0.0.5 | AssemblyScript 升级到版本 0.19.10(这包括重大更改,参阅 [`迁移指南`](/developer/assemblyscript-migration-guide))
`ethereum.transaction.gasUsed` 重命名为 `ethereum.transaction.gasLimit` | -| 0.0.4 | 向 Ethereum SmartContractCall 对象添加 `functionSignature` 字段 | -| 0.0.3 | 将 `from` 字段添加到 Ethereum Call 对象
`etherem.call.address` 重命名为 `ethereum.call.to` | -| 0.0.2 | 向 Ethereum Transaction 对象添加 `input` 字段 | +| 0.0.4 | 向 Ethereum SmartContractCall 对象添加 `functionSignature` 字段 | +| 0.0.3 | 将 `from` 字段添加到 Ethereum Call 对象
`etherem.call.address` 重命名为 `ethereum.call.to` | +| 0.0.2 | 向 Ethereum Transaction 对象添加 `input` 字段 | ### 内置类型 @@ -650,43 +650,43 @@ if (value.kind == JSONValueKind.BOOL) { ### 类型转换参考 -| 源 | 目标 | 转换函数 | -| -------------------- | -------------------- | --------------------------- | -| Address | Bytes | none | -| Address | ID | s.toHexString() | -| Address | String | s.toHexString() | -| BigDecimal | String | s.toString() | -| BigInt | BigDecimal | s.toBigDecimal() | +| 源 | 目标 | 转换函数 | +| -------------------- | -------------------- | ---------------------------- | +| Address | Bytes | none | +| Address | ID | s.toHexString() | +| Address | String | s.toHexString() | +| BigDecimal | String | s.toString() | +| BigInt | BigDecimal | s.toBigDecimal() | | BigInt | String (hexadecimal) | s.toHexString() 或 s.toHex() | -| BigInt | String (unicode) | s.toString() | -| BigInt | i32 | s.toI32() | -| Boolean | Boolean | none | -| Bytes (signed) | BigInt | BigInt.fromSignedBytes(s) | -| Bytes (unsigned) | BigInt | BigInt.fromUnsignedBytes(s) | +| BigInt | String (unicode) | s.toString() | +| BigInt | i32 | s.toI32() | +| Boolean | Boolean | none | +| Bytes (signed) | BigInt | BigInt.fromSignedBytes(s) | +| Bytes (unsigned) | BigInt | BigInt.fromUnsignedBytes(s) | | Bytes | String (hexadecimal) | s.toHexString() 或 s.toHex() | -| Bytes | String (unicode) | s.toString() | -| Bytes | String (base58) | s.toBase58() | -| Bytes | i32 | s.toI32() | -| Bytes | u32 | s.toU32() | -| Bytes | JSON | json.fromBytes(s) | -| int8 | i32 | none | -| int32 | i32 | none | -| int32 | BigInt | Bigint.fromI32(s) | -| uint24 | i32 | none | -| int64 - int256 | BigInt | none | -| uint32 - uint256 | BigInt | none | -| JSON | boolean | s.toBool() | -| JSON | i64 | s.toI64() | -| JSON | u64 | s.toU64() | -| JSON | f64 | s.toF64() | -| JSON | BigInt | s.toBigInt() | -| JSON | string | s.toString() | -| JSON | Array | s.toArray() | -| JSON | Object | s.toObject() | -| String | Address | Address.fromString(s) | -| String | BigDecimal | BigDecimal.fromString(s) | -| String (hexadecimal) | Bytes | ByteArray.fromHexString(s) | -| String (UTF-8) | Bytes | ByteArray.fromUTF8(s) | +| Bytes | String (unicode) | s.toString() | +| Bytes | String (base58) | s.toBase58() | +| Bytes | i32 | s.toI32() | +| Bytes | u32 | s.toU32() | +| Bytes | JSON | json.fromBytes(s) | +| int8 | i32 | none | +| int32 | i32 | none | +| int32 | BigInt | Bigint.fromI32(s) | +| uint24 | i32 | none | +| int64 - int256 | BigInt | none | +| uint32 - uint256 | BigInt | none | +| JSON | boolean | s.toBool() | +| JSON | i64 | s.toI64() | +| JSON | u64 | s.toU64() | +| JSON | f64 | s.toF64() | +| JSON | BigInt | s.toBigInt() | +| JSON | string | s.toString() | +| JSON | Array | s.toArray() | +| JSON | Object | s.toObject() | +| String | Address | Address.fromString(s) | +| String | BigDecimal | BigDecimal.fromString(s) | +| String (hexadecimal) | Bytes | ByteArray.fromHexString(s) | +| String (UTF-8) | Bytes | ByteArray.fromUTF8(s) | ### 数据源元数据 diff --git a/pages/zh/developer/assemblyscript-migration-guide.mdx b/pages/zh/developer/assemblyscript-migration-guide.mdx index ca5013b93cb6..bc8f6609ecba 100644 --- a/pages/zh/developer/assemblyscript-migration-guide.mdx +++ b/pages/zh/developer/assemblyscript-migration-guide.mdx @@ -127,8 +127,11 @@ ERROR TS2451: Cannot redeclare block-scoped variable 'a' ~~~~~~~~~~~~~ in assembly/index.ts(4,3) ``` + 如果您有变量遮蔽的情况,则需要重命名重名变量。 + ### 空值比较 + 对子图进行升级后,有时您可能会遇到如下错误: ```typescript @@ -137,6 +140,7 @@ ERROR TS2322: Type '~lib/@graphprotocol/graph-ts/common/numbers/BigInt | null' i ~~~~ in src/mappings/file.ts(41,21) ``` + 要解决此问题,您只需将 `if` 语句更改为如下所示代码: ```typescript @@ -284,6 +288,7 @@ ERROR TS2322: Type '~lib/string/String | null' is not assignable to type '~lib/s let somethingOrElse: string = container.data ? container.data : "else"; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` + 要解决此问题,您可以为该属性访问创建一个变量,以便编译器可以执行可空性检查: ```typescript diff --git a/pages/zh/developer/create-subgraph-hosted.mdx b/pages/zh/developer/create-subgraph-hosted.mdx index abb0402ca45f..5c396c577abf 100644 --- a/pages/zh/developer/create-subgraph-hosted.mdx +++ b/pages/zh/developer/create-subgraph-hosted.mdx @@ -218,15 +218,15 @@ Null value resolved for non-null field 'name' 我们在 GraphQL API 中支持以下标量: -| 类型 | 描述 | -| ------------ | -------------------------------------------------------------------------------------------------------------- | -| `Bytes` | 字节数组,表示为十六进制字符串。 通常用于以太坊哈希和地址。 | -| `ID` | 存储为`string`。 | -| `String` | `string` 值的标量。 不支持空字符,并会自动进行删除。 | -| `Boolean` | `boolean` 值的标量。 | -| `Int` | GraphQL 规范将 `Int` 定义为 32 字节的大小。 | -| `BigInt` | 大整数。 用于以太坊的 `uint32`、`int64`、`uint64`、...、`uint256` 类型。 注意:`uint32`以下的所有类型,例如`int32`、`uint24`或`int8`都表示为`i32`。 | -| `BigDecimal` | `BigDecimal` 表示为有效数字和指数的高精度小数。 指数范围是 -6143 到 +6144。 四舍五入到 34 位有效数字。 | +| 类型 | 描述 | +| --- | --- | +| `Bytes` | 字节数组,表示为十六进制字符串。 通常用于以太坊哈希和地址。 | +| `ID` | 存储为`string`。 | +| `String` | `string` 值的标量。 不支持空字符,并会自动进行删除。 | +| `Boolean` | `boolean` 值的标量。 | +| `Int` | GraphQL 规范将 `Int` 定义为 32 字节的大小。 | +| `BigInt` | 大整数。 用于以太坊的 `uint32`、`int64`、`uint64`、...、`uint256` 类型。 注意:`uint32`以下的所有类型,例如`int32`、`uint24`或`int8`都表示为`i32`。 | +| `BigDecimal` | `BigDecimal` 表示为有效数字和指数的高精度小数。 指数范围是 -6143 到 +6144。 四舍五入到 34 位有效数字。 | #### 枚举类型 @@ -428,33 +428,33 @@ query { 支持的语言词典: -| 代码 | 词典 | -| ------ | ----- | -| simple | 通用 | -| da | 丹麦语 | -| nl | 荷兰语 | -| en | 英语 | -| fi | 芬兰语 | -| fr | 法语 | -| de | 德语 | -| hu | 匈牙利语 | -| it | 意大利语 | -| no | 挪威语 | -| pt | 葡萄牙语 | +| 代码 | 词典 | +| ------ | ---------- | +| simple | 通用 | +| da | 丹麦语 | +| nl | 荷兰语 | +| en | 英语 | +| fi | 芬兰语 | +| fr | 法语 | +| de | 德语 | +| hu | 匈牙利语 | +| it | 意大利语 | +| no | 挪威语 | +| pt | 葡萄牙语 | | ro | 罗马尼亚语 | -| ru | 俄语 | -| es | 西班牙语 | -| sv | 瑞典语 | -| tr | 土耳其语 | +| ru | 俄语 | +| es | 西班牙语 | +| sv | 瑞典语 | +| tr | 土耳其语 | ### 排序算法 支持的排序结果算法: -| 算法 | 描述 | -| ------------- | -------------------------- | +| 算法 | 描述 | +| ------------- | --------------------------------------------- | | rank | 使用全文查询的匹配质量 (0-1) 对结果进行排序。 | -| proximityRank | 与 rank 类似,但也包括匹配的接近程度。 | +| proximityRank | 与 rank 类似,但也包括匹配的接近程度。 | ## 编写映射 @@ -627,7 +627,7 @@ export function handleNewExchange(event: NewExchange): void { ``` > **注意:** 新的数据源只会处理创建它的区块和所有后续区块的调用和事件,而不会处理历史数据,也就是包含在先前区块中的数据。 -> +> > 如果先前的区块包含与新数据源相关的数据,最好通过读取合约的当前状态,并在创建新数据源时创建表示该状态的实体来索引该数据。 ### 数据源上下文 @@ -684,7 +684,7 @@ dataSources: ``` > **注意:** 合约创建区块可以在 Etherscan 上快速查找: -> +> > 1. 通过在搜索栏中输入合约地址来搜索合约。 > 2. 单击 `Contract Creator` 部分中的创建交易哈希。 > 3. 加载交易详情页面,您将在其中找到该合约的起始区块。 @@ -816,7 +816,7 @@ eventHandlers: 从 `specVersion` `0.0.4` 开始,子图特征必须使用它们的 `camelCase` 名称,在清单文件顶层的 `features` 部分中显式声明,如下表所列: -| 特征 | 名称 | +| 特征 | 名称 | | --------------------------------------------------------- | ------------------------- | | [Non-fatal errors](#non-fatal-errors) | `nonFatalErrors` | | [Full-text Search](#defining-fulltext-search-fields) | `fullTextSearch` | diff --git a/pages/zh/developer/graphql-api.mdx b/pages/zh/developer/graphql-api.mdx index fde0e4a8d94a..127ee11c9003 100644 --- a/pages/zh/developer/graphql-api.mdx +++ b/pages/zh/developer/graphql-api.mdx @@ -204,12 +204,12 @@ _not_ends_with 全文搜索运算符: -| 符号 | 运算符 | 描述 | -| ----------- | ----------- | ------------------------------------- | -| `&` | `And` | 用于将多个搜索词组合到包含所有提供词条的实体的过滤器中 | -| | | `Or` | 由 or 运算符分隔的多个搜索词的查询,将返回与任何提供的词匹配的所有实体 | -| `<->` | `Follow by` | 指定两个单词之间的距离。 | -| `:*` | `Prefix` | 使用前缀搜索词查找前缀匹配的单词(需要 2 个字符) | +| 符号 | 运算符 | 描述 | +| ------ | ----------- | ---------------------------------------------------------------------- | +| `&` | `And` | 用于将多个搜索词组合到包含所有提供词条的实体的过滤器中 | +| | | `Or` | 由 or 运算符分隔的多个搜索词的查询,将返回与任何提供的词匹配的所有实体 | +| `<->` | `Follow by` | 指定两个单词之间的距离。 | +| `:*` | `Prefix` | 使用前缀搜索词查找前缀匹配的单词(需要 2 个字符) | #### 例子 diff --git a/pages/zh/developer/matchstick.mdx b/pages/zh/developer/matchstick.mdx index d3d0e1a213c7..b290daf76568 100644 --- a/pages/zh/developer/matchstick.mdx +++ b/pages/zh/developer/matchstick.mdx @@ -135,7 +135,7 @@ Mapping terminated before handling trigger: oneshot canceled ### 用某种状态给商店补充 -用户能够用一组已知的实体来给商店注入水。下面是一个用Gravatar实体初始化商店的例子。 +用户能够用一组已知的实体来给商店注入水。下面是一个用 Gravatar 实体初始化商店的例子。 ```typescript let gravatar = new Gravatar('entryId') diff --git a/pages/zh/developer/subgraph-debug-forking.mdx b/pages/zh/developer/subgraph-debug-forking.mdx index 1fda56d4b3f5..fab2c82eeab5 100644 --- a/pages/zh/developer/subgraph-debug-forking.mdx +++ b/pages/zh/developer/subgraph-debug-forking.mdx @@ -2,13 +2,13 @@ title: 使用分叉快速轻松地调试子图 --- -> 注意:这只能从这个 `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) 或这个 < a href="https://hub.docker.com/layers/graphprotocol/graph-node/f4e6992/images/sha256-51ad494a2ecc387bef2359d863b596ad5bd44436808964cf221e60365a7c00c8?context=explore">docker tag之后,还没有发布 在次要版本中(例如:0.26.0) +> 注意:这只能从这个 `graph-node` [commit](https://github.com/graphprotocol/graph-node/commit/f4e6992d7949b18f990045c8babdcd205a060ef6) 或这个 docker tag之后,还没有发布 在次要版本中(例如:0.26.0) 与许多处理大量数据的系统一样,The Graph 的索引器(Graph 节点)可能需要相当长的时间才能将您的子图与目标区块链同步。 以调试为目的的快速更改与索引所需的长时间等待之间的差异非常适得其反,我们很清楚这一点。 这就是我们在本文中介绍 [LimeChain](https://limechain.tech/) 开发的 **subgraph forking** 的原因 我将向您展示如何使用此功能来显着加快子图调试! ## 好的,那是什么? -**子图分叉** 是从_另一个_ 子图的存储(通常是远程存储)中延迟获取实体的过程。 +**子图分叉** 是从*另一个* 子图的存储(通常是远程存储)中延迟获取实体的过程。 在调试的上下文中,**subgraph forking** 允许您在块 _X_ 处调试失败的子图,而无需等待 同步以阻止 _X_。 @@ -16,7 +16,7 @@ title: 使用分叉快速轻松地调试子图 当您将子图部署到远程 Graph 节点以进行索引并且它在块 _X_ 处失败时,好消息是 Graph 节点仍将使用其存储服务 GraphQL 查询, 同步到阻止 _X_。 那太棒了! 这意味着我们可以利用这个“最新”存储来修复索引块 _X_ 时出现的错误。 -简而言之,我们将从远程 Graph 节点 _fork 失败的子图_,该节点保证将子图索引到块 *X* 以便为在块 _X_ 处调试的本地部署的子图提供索引状态的最新视图。 +简而言之,我们将从远程 Graph 节点 _fork 失败的子图_,该节点保证将子图索引到块 _X_ 以便为在块 _X_ 处调试的本地部署的子图提供索引状态的最新视图。 ## 请给我看一些代码! @@ -46,7 +46,7 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { } ``` -糟糕,多么不幸,当我将完美的子图部署到 [HostedService](https://thegraph.com/hosted-service/) 时,它会因 *“未找到 Gravatar!”* 错误。 +糟糕,多么不幸,当我将完美的子图部署到 [HostedService](https://thegraph.com/hosted-service/) 时,它会因 _“未找到 Gravatar!”_ 错误。 尝试修复的常用方法是: @@ -66,8 +66,8 @@ export function handleUpdatedGravatar(event: UpdatedGravatar): void { 现在,您可能有 2 个问题: -1. fork-base是什么??? 2 -2. 向谁Forking?! +1. fork-base 是什么??? 2 +2. 向谁 Forking?! 我回答: @@ -82,7 +82,7 @@ $ graph deploy --debug-fork --ipfs http://localhos 所以,这就是我所做的: -0. 我启动了一个本地Graph节点([这里是如何做到的](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) 将 `fork-base` 选项设置为:`https://api.thegraph.com/subgraphs/id/`,因为我将分叉一个子图,我部署的那个有问题的 之前,来自 [HostedService](https://thegraph.com/hosted-service/)。 +0. 我启动了一个本地 Graph 节点([这里是如何做到的](https://github.com/graphprotocol/graph-node#running-a-local-graph-node)) 将 `fork-base` 选项设置为:`https://api.thegraph.com/subgraphs/id/`,因为我将分叉一个子图,我部署的那个有问题的 之前,来自 [HostedService](https://thegraph.com/hosted-service/)。 ``` $ cargo run -p graph-node --release -- \ @@ -93,7 +93,7 @@ $ cargo run -p graph-node --release -- \ ``` 1. 经过仔细检查,我注意到在我的两个处理程序中索引 `Gravatar` 时使用的 `id` 表示不匹配。 `handleNewGravatar` 将其转换为十六进制 (`event.params.id.toHex()`),而 `handleUpdatedGravatar` 使用 int32 (`event. params.id.toI32()`) 会导致 `handleUpdatedGravatar` 出现“未找到 Gravatar!”的恐慌。 我让它们都将 `id` 转换为十六进制。 -2. 进行更改后,我将子图部署到本地 Graph 节点,**_分叉失败的子图_**并设置 < `subgraph.yaml` 中的 code>dataSources.source.startBlock
到 `6190343`: +2. 进行更改后,我将子图部署到本地 Graph 节点,**_分叉失败的子图_**并设置 `subgraph.yaml` 中的 `dataSources.source.startBlock` 到 `6190343`: ```bash $ graph deploy gravity --debug-fork QmNp169tKvomnH3cPXTfGg4ZEhAHA6kEq5oy1XDqAxqHmW --ipfs http://localhost:5001 --node http://localhost:8020 diff --git a/pages/zh/explorer.mdx b/pages/zh/explorer.mdx index 85698d600f9e..af72c5557ff9 100644 --- a/pages/zh/explorer.mdx +++ b/pages/zh/explorer.mdx @@ -11,7 +11,7 @@ title: 浏览器 title="YouTube video player" frameBorder="0" allowFullScreen -> + > ## 子图 diff --git a/pages/zh/hosted-service/migrating-subgraph.mdx b/pages/zh/hosted-service/migrating-subgraph.mdx index 8cb1284f63c2..3c785d5d30a3 100644 --- a/pages/zh/hosted-service/migrating-subgraph.mdx +++ b/pages/zh/hosted-service/migrating-subgraph.mdx @@ -16,7 +16,7 @@ title: 将现有子图迁移到Graph网络 - 使用 [全文搜索字段](https://thegraph.com/docs/en/developer/create-subgraph-hosted/#defining-fulltext-search-fields)。 - 以太坊主网以外的索引链。 -### 将现有子图迁移到Graph网络 +### 将现有子图迁移到 Graph 网络 1. 获取已安装的最新版本的 graph-cli: @@ -114,7 +114,7 @@ _虽然这种机制目前在网络上运行,但社区目前正在讨论降低 确保选中**Update Subgraph Details in Explorer**,然后点击**保存**。 如果选中此项,将生成一个链上事务,更新资源管理器中的子图详细信息,而无需发布具有新部署的新版本。 -## 将子图部署到Graph网络的最佳实践 +## 将子图部署到 Graph 网络的最佳实践 1. 利用 ENS 名称进行子图开发: @@ -123,11 +123,11 @@ _虽然这种机制目前在网络上运行,但社区目前正在讨论降低 2. 您的个人资料填写得越多,您的子图被索引和管理的机会就越大。 -## 弃用Graph网络上的子图 +## 弃用 Graph 网络上的子图 按照[此处](/developer/deprecating-a-subgraph)的步骤弃用您的子图并将其从 The Graph Network 中删除。 -## 在Graph网络上查询子图 + 计费 +## 在 Graph 网络上查询子图 + 计费 托管服务的设置允许开发人员不受任何限制地部署他们的子图。 @@ -137,7 +137,7 @@ _虽然这种机制目前在网络上运行,但社区目前正在讨论降低 虽然这不是产品 UI 中的实时功能,但您可以通过将每月愿意支付的金额除以预期查询量来设置每次查询的最大预算。 -虽然您可以决定查询预算,但不能保证索引人愿意以该价格提供查询服务。 如果网关可以将您与愿意以或低于您愿意支付的价格提供查询的索引人相匹配,您将支付预算的增量/差异**和< /strong> 他们的价格。 因此,较低的查询价格会减少可供您使用的索引人池,这可能会影响您获得的服务质量。 收取高额查询费用是有益的,因为这可能会吸引您的子图的管理和知名索引人。

+虽然您可以决定查询预算,但不能保证索引人愿意以该价格提供查询服务。 如果网关可以将您与愿意以或低于您愿意支付的价格提供查询的索引人相匹配,您将支付预算的增量/差异\*\*和 他们的价格。 因此,较低的查询价格会减少可供您使用的索引人池,这可能会影响您获得的服务质量。 收取高额查询费用是有益的,因为这可能会吸引您的子图的管理和知名索引人 请记住,这是一个充满活力且不断增长的市场,但您如何与之互动是您的控制。 协议或网关中没有指定最高或最低价格。 例如,您可以查看网络上一些 dapps 支付的价格(每周),如下所示。 请参阅最后一列,它显示了 GRT 中的查询费用。 例如,[Pickle Finance](https://www.pickle.finance/) 每秒有 8 个请求,支付 2.4 GRT 一周。 @@ -154,10 +154,10 @@ _虽然这种机制目前在网络上运行,但社区目前正在讨论降低 title="YouTube video player" frameBorder="0" allowFullScreen -> + > -- [The Graph网络合约](https://github.com/graphprotocol/contracts) +- [The Graph 网络合约](https://github.com/graphprotocol/contracts) - [Curation Contract](https://github.com/graphprotocol/contracts/blob/dev/contracts/curation/Curation.sol) - GNS 包裹的底层合约 - 地址 - `0x8fe00a685bcb3b2cc296ff6ffeab10aca4ce1538` - [子图工作室文档](/studio/subgraph-studio) diff --git a/pages/zh/hosted-service/what-is-hosted-service.mdx b/pages/zh/hosted-service/what-is-hosted-service.mdx index b14311e2c767..2d17f123d992 100644 --- a/pages/zh/hosted-service/what-is-hosted-service.mdx +++ b/pages/zh/hosted-service/what-is-hosted-service.mdx @@ -8,7 +8,7 @@ title: 什么是托管服务? ## 创建子图 -首先按照[此处](/developer/define-subgraph-hosted)的说明安装Graph CLI。 通过传入 `graph init --product hosting service` 创建子图 +首先按照[此处](/developer/define-subgraph-hosted)的说明安装 Graph CLI。 通过传入 `graph init --product hosting service` 创建子图 ### 基于现有合约 @@ -30,7 +30,7 @@ graph init \ --abi \ ``` -`` 在这种情况下是您的 github 用户或组织名称, ``是您的子图的名称,并且`` Graph初始化将放置示例子图清单的目录的可选名称。 ``是您现有合约的地址。 `` 是合约所在的以太坊网络的名称。``是合约 ABI 文件的本地路径。**Both --network 和 --abi 都是可选的。** +`` 在这种情况下是您的 github 用户或组织名称, ``是您的子图的名称,并且`` Graph 初始化将放置示例子图清单的目录的可选名称。 ``是您现有合约的地址。 `` 是合约所在的以太坊网络的名称。``是合约 ABI 文件的本地路径。**Both --network 和 --abi 都是可选的。** ### 基于子图示例 diff --git a/pages/zh/indexing.mdx b/pages/zh/indexing.mdx index 7dafdbe96174..1a08e70528e3 100644 --- a/pages/zh/indexing.mdx +++ b/pages/zh/indexing.mdx @@ -115,11 +115,11 @@ query indexerAllocations { - **大型** -准备对当前使用的所有子图进行索引,并为相关流量的请求提供服务 | 类型 | (CPU 数量) | (内存 GB) | (硬盘 TB) | (CPU 数量) | (内存 GB) | -| -- |:--------:|:-------:|:-------:|:--------:|:-------:| -| 小型 | 4 | 8 | 1 | 4 | 16 | -| 标准 | 8 | 30 | 1 | 12 | 48 | -| 中型 | 16 | 64 | 2 | 32 | 64 | -| 大型 | 72 | 468 | 3.5 | 48 | 184 | +| ---- | :--------: | :-------: | :-------: | :--------: | :-------: | +| 小型 | 4 | 8 | 1 | 4 | 16 | +| 标准 | 8 | 30 | 1 | 12 | 48 | +| 中型 | 16 | 64 | 2 | 32 | 64 | +| 大型 | 72 | 468 | 3.5 | 48 | 184 | ### 索引人应该采取哪些基本的安全防范措施? @@ -151,26 +151,26 @@ query indexerAllocations { #### Graph 节点 -| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | -| ---- | ------------------------------------ | ------------------------------------------------------------------- | ----------------- | ----- | -| 8000 | GraphQL HTTP 服务
(用于子图查询) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | -| 8001 | GraphQL WS
(用于子图订阅) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | -| 8020 | JSON-RPC
(用于管理部署) | / | --admin-port | - | -| 8030 | 子图索引状态 API | /graphql | --index-node-port | - | -| 8040 | Prometheus 指标 | /metrics | --metrics-port | - | +| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | +| --- | --- | --- | --- | --- | +| 8000 | GraphQL HTTP 服务
(用于子图查询) | /subgraphs/id/...

/subgraphs/name/.../... | --http-port | - | +| 8001 | GraphQL WS
(用于子图订阅) | /subgraphs/id/...

/subgraphs/name/.../... | --ws-port | - | +| 8020 | JSON-RPC
(用于管理部署) | / | --admin-port | - | +| 8030 | 子图索引状态 API | /graphql | --index-node-port | - | +| 8040 | Prometheus 指标 | /metrics | --metrics-port | - | #### 索引人服务 -| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | -| ---- | -------------------------------------- | --------------------------------------------------------------------------- | -------------- | ---------------------- | -| 7600 | GraphQL HTTP 服务
(用于付费子图查询) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | -| 7300 | Prometheus 指标 | /metrics | --metrics-port | - | +| 端口 | 用途 | 路径 | CLI 参数 | 环境 变量 | +| --- | --- | --- | --- | --- | +| 7600 | GraphQL HTTP 服务
(用于付费子图查询) | /subgraphs/id/...
/status
/channel-messages-inbox | --port | `INDEXER_SERVICE_PORT` | +| 7300 | Prometheus 指标 | /metrics | --metrics-port | - | #### 索引人代理 -| 端口 | 用途 | 路径 | CLI 参数 | 环境
变量 | -| ---- | --------- | -- | ------------------------- | --------------------------------------- | -| 8000 | 索引人管理 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | +| 端口 | 用途 | 路径 | CLI 参数 | 环境
变量 | +| ---- | -------------- | ---- | ------------------------- | --------------------------------------- | +| 8000 | 索引人管理 API | / | --indexer-management-port | `INDEXER_AGENT_INDEXER_MANAGEMENT_PORT` | ### Google Cloud 上使用 Terraform 建立基础架构 @@ -600,7 +600,7 @@ default => 0.1 * $SYSTEM_LOAD; 成本模型示例: -| 询问 | 价格 | +| 询问 | 价格 | | ---------------------------------------------------------------------------- | ------- | | { pairs(skip: 5000) { id } } | 0.5 GRT | | { tokens { symbol } } | 0.1 GRT | diff --git a/pages/zh/studio/billing.mdx b/pages/zh/studio/billing.mdx index f83b46196159..cd0a7ff142e0 100644 --- a/pages/zh/studio/billing.mdx +++ b/pages/zh/studio/billing.mdx @@ -46,7 +46,7 @@ title: 子图工作室的计费 title="YouTube video player" frameBorder="0" allowFullScreen -> + > ### 多重签名用户 diff --git a/pages/zh/studio/multisig.mdx b/pages/zh/studio/multisig.mdx index 4a83b29f579b..59d19d092813 100644 --- a/pages/zh/studio/multisig.mdx +++ b/pages/zh/studio/multisig.mdx @@ -32,7 +32,7 @@ graph deploy --studio #### 发布新子图 -有几种方法可以使用多重签名钱包发布子图。 在这里,我们将描述使用 Etherscan 在 [GNS 合约](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825)中调用[ publishNewSubgraph 函数
](https://github.com/graphprotocol/contracts/blob/dev/contracts/discovery/GNS.sol#L231)。 +有几种方法可以使用多重签名钱包发布子图。 在这里,我们将描述使用 Etherscan 在 [GNS 合约](https://etherscan.io/address/0xaDcA0dd4729c8BA3aCf3E99F3A9f471EF37b6825)中调用[ publishNewSubgraph 函数](https://github.com/graphprotocol/contracts/blob/dev/contracts/discovery/GNS.sol#L231)。 在我们使用该函数之前,我们需要为其生成输入参数。 在 Subgraph Studio 中访问此[页面](https://thegraph.com/studio/multisig)并提供以下内容: @@ -42,7 +42,7 @@ graph deploy --studio 点击“获取参数”后,我们将为您生成所有合约参数! -应该有4个参数: +应该有 4 个参数: - `graphAccount`:这是您的多重签名帐户地址 - `subgraphDeploymentID`:该子图的部署 ID 的十六进制哈希 diff --git a/pages/zh/studio/subgraph-studio.mdx b/pages/zh/studio/subgraph-studio.mdx index 159e66c3684b..d480d4e0f808 100644 --- a/pages/zh/studio/subgraph-studio.mdx +++ b/pages/zh/studio/subgraph-studio.mdx @@ -2,7 +2,7 @@ title: 如何使用子图工作室 --- -欢迎使用您的新启动板👩🏽‍🚀 +欢迎使用您的新启动板 👩🏽‍🚀 Subgraph Studio 是您构建和创建子图、添加元数据并将其发布到新的分散式资源管理器的地方(更多关于[这里](/explorer))。 @@ -40,7 +40,7 @@ Subgraph Studio 是您构建和创建子图、添加元数据并将其发布到 - 类别 - 网站 -## 子图与The Graph网络的兼容性 +## 子图与 The Graph 网络的兼容性 The Graph 网络还不能支持所有的数据源和 托管服务上可用的功能。 为了被网络上的索引器支持,子图必须: @@ -73,7 +73,7 @@ The Graph 网络还不能支持所有的数据源和 托管服务上可用的功 title="YouTube video player" frameBorder="0" allowFullScreen -> + > 请记住,在您完成发布流程时,您将能够推送到我们支持的测试网主网或 Rinkeby。 如果您是第一次开发子图,我们强烈建议您从发布到 Rinkeby 开始,这是免费的。 这将允许您查看子图在 The Graph Explorer 中的工作方式,并允许您测试管理元素。 diff --git a/pages/zh/supported-networks/near.mdx b/pages/zh/supported-networks/near.mdx index 8f192167f8b2..719a2dab720b 100644 --- a/pages/zh/supported-networks/near.mdx +++ b/pages/zh/supported-networks/near.mdx @@ -188,7 +188,7 @@ $ graph deploy --node --ipfs https://api.thegraph.com/ipfs/ # u graph deploy --node https://api.thegraph.com/deploy/ --ipfs https://api.thegraph.com/ipfs/ --access-token ``` -#### 本地Graph节点(基于默认配置): +#### 本地 Graph 节点(基于默认配置): ``` graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 @@ -204,13 +204,13 @@ graph deploy --node http://localhost:8020/ --ipfs http://localhost:5001 } ``` -### 使用本地Graph节点索引 NEAR +### 使用本地 Graph 节点索引 NEAR 运行索引 NEAR 的 Graph Node 有以下操作要求: - 带有 Firehose 工具的 NEAR 索引人框架 - NEAR Firehose 组件 -- 配置了 Firehose 端点的Graph节点 +- 配置了 Firehose 端点的 Graph 节点 我们将很快提供有关运行上述组件的更多信息。 @@ -222,9 +222,9 @@ NEAR 子图的 GraphQL 端点由架构定义确定,具有现有的 API 接口 以下是一些示例子图供参考: -[NEAR块](https://github.com/graphprotocol/example-subgraph/tree/near-blocks-example) +[NEAR 块](https://github.com/graphprotocol/example-subgraph/tree/near-blocks-example) -[NEAR收据](https://github.com/graphprotocol/example-subgraph/tree/near-receipts-example) +[NEAR 收据](https://github.com/graphprotocol/example-subgraph/tree/near-receipts-example) ## 常见问题