ניהול מילון המונחים הארגוני

במאמר הזה נסביר איך ליצור ולנהל מילוני מונחים עסקיים ב-Knowledge Catalog (לשעבר Dataplex Universal Catalog). כדאי להשתמש במילון מונחים עסקי כדי ליצור אוצר מילים סטנדרטי לנכסי הנתונים שלכם. כך תוכלו לצמצם את אי הבהירות ולשפר את איתור הנתונים והניהול שלהם בכל הארגון.

תרחישי שימוש במילון המונחים הארגוני של Knowledge Catalog

יצירת שפה משותפת לנתונים באמצעות מילון המונחים הארגוני ב-Knowledge Catalog מאפשרת לכם להשיג את הדברים הבאים:

  • הגדירו היררכיה ברורה של קטגוריות ומונחים עסקיים.
  • לקשר בין מושגים באמצעות מילים נרדפות ולהציג את הקשרים בין מונחים.
  • חיפוש משאבי נתונים על סמך מושגים עסקיים, ולא רק על סמך שמות טכניים.

מילון המונחים הארגוני ב-Knowledge Catalog עוזר לייעל את גילוי הנתונים ולצמצם את אי הבהירות, וכך לשפר את השליטה, להפיק ניתוחים מדויקים יותר ולקבל תובנות מהר יותר.

רכיבים של מילון המונחים הארגוני

בקטע הזה מתוארים הרכיבים העיקריים שבהם אפשר להשתמש כדי ליצור מילון מונחים עסקי.

מילון מונחים

למילון מונחים יש את המאפיינים הבאים:

  • סקירה כללית. מתאר את המטרה והתוכן של מילון המונחים הארגוני. אפשר להוסיף תמונות, קישורים וטבלאות. אין תמיכה בעיצוב HTML, אבל אפשר לכלול קוד HTML בפורמט של קוד או להוסיף קישור לדף HTML. אפשר גם להשתמש באפשרויות עיצוב של Rich Text, כמו הדגשה, הטיה, קו תחתון, רשימות עם תבליטים, פסקאות, כותרות ובלוקים של קוד. הגודל המקסימלי שנתמך הוא 120 KB.

  • תיאור. תיאור המילון. הטקסט בשדה הזה עובר אינדוקס לצורך חיפוש. הגודל המקסימלי שנתמך הוא 1KB.

  • אזור. מציינים את האזור שבו נמצא המילון.

קטגוריה

קטגוריה מאפשרת לארגן ולבנות קטגוריות ומונחים שונים. הקטגוריות מוגדרות במילון המונחים הארגוני. אפשר להציב קטגוריות בתוך קטגוריות עד שלוש רמות.

לקטגוריה יש את המאפיינים של מילון מונחים, וגם את המאפיינים הבאים:

  • אנשי קשר. מציין את האדם שאחראי על התחזוקה של הקטגוריה. המאפיין הזה הוא תיאורי ולא משפיע על ההרשאות של הקטגוריה.
  • הורה. מציין קשר גומלין שמשמש לקביעת הקטגוריה הראשית של הקטגוריה הנוכחית. אפשר להציב עד שלוש קטגוריות בתוך קטגוריות.

האזור של קטגוריה זהה לאזור של המילון שמכיל אותה.

מונח

מונח (קיצור של "מונח במילון מונחים") מתאר מושג שמשמש בענף מסוים של העסק בחברה שלכם. לדוגמה, מחלקת השיווק של חברה יכולה ליצור מונח שמתאר את העלות לקליק. המונחים מוגדרים במילון המונחים הארגוני, ישירות במילון או בכל קטגוריה שמופיעה בו.

למונח יש את המאפיינים של קטגוריה, וגם את המאפיינים הבאים:

  • מילים נרדפות. מציין קישורים בין מונחים עם אותה משמעות. מונחים נרדפים
  • מונחים קשורים. מציין קישורים בין מונחים שקשורים זה לזה מבחינה מושגית, אבל יש להם משמעויות שונות. תנאים קשורים
  • ערכים קשורים. מציין קישורים בין מונחים לבין נכסי נתונים, או בין מונחים לבין עמודות בתוך נכסי נתונים.
  • כללים לגבי איכות הנתונים. מציין את דרישות איכות הנתונים של המונח. מידע נוסף על שימוש חוזר בכללים לאיכות הנתונים
  • אנשי קשר. מציין את האדם שאחראי לתחזוקת המונח. המונחים לא מקבלים בירושה את אנשי הקשר שמוגדרים בקטגוריות.

האזור של מונח זהה לאזור של המילון שכולל אותו.

מילים נרדפות

מילה נרדפת היא קשר שמציין שתי מילים שונות שוות ערך. כדאי להשתמש במילים נרדפות כששני מונחים עם אותה משמעות מוגדרים על ידי צוותים שונים במילונים שונים. לדוגמה, אפשר ליצור מילה נרדפת כדי לקשר בין המונחים 'רווח' ו'הכנסות'.

מונח קשור הוא קשר שמציין ששני מונחים משויכים זה לזה, אבל יש להם משמעויות שונות. לדוגמה, אפשר ליצור מונח קשור כדי לקשר בין המונחים 'הכנסה' ו'רווח'.

מגבלות

התפקידים הנדרשים

כדי לקבל את ההרשאות שדרושות ליצירה ולניהול של מילוני מונחים, צריך לבקש מהאדמין להקצות לכם את תפקידי ה-IAM הבאים בפרויקט:

  • אדמינים של נתונים מקבלים גישה מלאה למילוני מונחים, לקטגוריות, למונחים, למילים נרדפות ולמונחים קשורים, ויכולים להגדיר מדיניות IAM: אדמין של Dataplex Catalog (roles/dataplex.catalogAdmin)
  • למנהלי נתונים או לבעלי נתונים, גישה ליצירה, לעריכה או למחיקה של מילוני מונחים, קטגוריות, מונחים, קישורים בין מונחים, קישורים בין מונחים לבין נכסי נתונים ולחיפוש: Dataplex Catalog Editor (roles/dataplex.catalogEditor)
  • למנתחי נתונים או לצרכני נתונים, אפשר לקבל גישת קריאה בלבד למילוני מונחים, לקטגוריות, למונחים, לקישורים בין מונחים ובין מונחים לנכסי נתונים, ולחיפוש: Dataplex Catalog Viewer (roles/dataplex.catalogViewer)

להסבר על מתן תפקידים, ראו איך מנהלים את הגישה ברמת הפרויקט, התיקייה והארגון.

התפקידים המוגדרים מראש האלה כוללים את ההרשאות שנדרשות ליצירה ולניהול של מילוני מונחים. כדי לראות בדיוק אילו הרשאות נדרשות, אפשר להרחיב את הקטע ההרשאות הנדרשות:

ההרשאות הנדרשות

כדי ליצור ולנהל מילוני מונחים, צריך את ההרשאות הבאות:

  • יצירה, קריאה, עדכון ומחיקה של מילון מונחים עסקי, קטגוריה ומונחים בפרויקט:
    • dataplex.glossaries.list
    • dataplex.glossaries.create
    • dataplex.glossaries.get
    • dataplex.glossaries.update
    • dataplex.glossaries.delete
    • dataplex.glossaryCategories.create
    • dataplex.glossaryCategories.list
    • dataplex.glossaryCategories.get
    • dataplex.glossaryCategories.update
    • dataplex.glossaryCategories.delete
    • dataplex.glossaryTerms.create
    • dataplex.glossaryTerms.list
    • dataplex.glossaryTerms.get
    • dataplex.glossaryTerms.update
    • dataplex.glossaryTerms.delete
  • כדי ליצור, לחפש ולמחוק קישורים בין מונחים נרדפים בפרויקט:
    • ‫dataplex.entryLinks.create בקבוצת הרשומות של Knowledge Catalog בפרויקט שבו מופיע אחד ממונחי המילון. הקישור נוצר בקבוצת הרשומות שעבורה ניתנה ההרשאה.
    • dataplex.entryGroups.useSynonymEntryLink on the Knowledge Catalog entry group in the project in which either of the glossary terms is present. הקישור נוצר בקבוצת הרשומות שעבורה ניתנה ההרשאה.
    • ‫dataplex.glossaryTerms.use במילוני המונחים שצריך לשייך אליהם את המונחים.
    • ‫dataplex.glossaryTerms.get על המונח שאתם מחפשים את הקישורים למילים הנרדפות שלו. אם אין לכם הרשאה מסוג dataplex.glossaryTerms.get למונחים מסוימים, הם יוסתרו בתשובה של Knowledge Catalog.
    • dataplex.entryLinks.delete on the Knowledge Catalog entry group in the project in which the link is present.
  • יצירה, חיפוש ומחיקה של קישורים קשורים בין מונחים בפרויקט:
    • ‫dataplex.entryLinks.create בקבוצת הרשומות של Knowledge Catalog בפרויקט שבו מופיע אחד ממונחי המילון. הקישור נוצר בקבוצת הרשומות שעבורה ניתנה ההרשאה.
    • dataplex.entryGroups.useRelatedEntryLink בקבוצת הרשומות של Knowledge Catalog בפרויקט שבו מופיע אחד ממונחי המילון. הקישור נוצר בקבוצת הרשומות שעבורה ניתנה ההרשאה.
    • ‫dataplex.entries.link בקבוצת הרשומות של Knowledge Catalog בפרויקטים שבהם יש רשומות שמתאימות למונחים במילון.
    • dataplex.glossaryTerms.get על המונח שאתם מחפשים את הקישורים שקשורים אליו. אם אין לכם הרשאה מסוג dataplex.glossaryTerms.get למונחים מסוימים, מערכת Knowledge Catalog תצנזר את המונחים האלה בתשובה.
    • dataplex.entryLinks.delete on the Knowledge Catalog entry group in the project in which the link is present.
  • ליצור, לחפש ולמחוק קישורים בין מונחים לבין נכסי נתונים או עמודות בפרויקט:
    • ‫dataplex.entryLinks.create on the system entry group corresponding to data assets or columns in the project. הקישור נוצר בפרויקט שבו ניתנה ההרשאה.
    • dataplex.entryGroups.useDefinitionEntryLink on the system entry group corresponding to data assets or columns in the project. הקישור נוצר בפרויקט שניתנה לו הרשאה.
    • ‫dataplex.entries.link בקבוצת הרשומות של המערכת שמתאימה לנכסי נתונים או לעמודות בפרויקט. הקישור נוצר בפרויקט שבו ניתנה ההרשאה.
    • dataplex.glossaryTerms.use on the glossary whose term needs to be associated.
    • הרשאת קריאה במערכת המקור (לדוגמה, bigquery.tables.get או dataplex.glossaryTerms.get) של הרשומה שאתם מחפשים את הקישורים שלה. אם אין לכם הרשאת קריאה במערכת המקור של נכסי הנתונים, הם יוסתרו בתשובה של Knowledge Catalog.
    • dataplex.entryLinks.delete on the system entry group in which the link is present.

יכול להיות שתקבלו את ההרשאות האלה באמצעות תפקידים בהתאמה אישית או תפקידים מוגדרים מראש אחרים.

מידע נוסף זמין במאמר תפקידי IAM ב-Knowledge Catalog.

יצירה וניהול של מילוני מונחים עסקיים

בקטעים הבאים מוסבר איך ליצור, לראות, לערוך ולמחוק מילון מונחים עסקי.

יצירת מילון המונחים הארגוני

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. לוחצים על יצירת מילון המונחים הארגוני.

  3. בדף יצירת מילון מונחים ארגוני, מציינים שם ומיקום למילון המונחים הארגוני. אחרי שיוצרים את המילון, אי אפשר לשנות את המיקום שלו.

  4. לוחצים על יצירה. המונחון נוצר בפרויקט הנוכחי.

  5. אופציונלי: מוסיפים תיאור קצר בשדה תיאור (עד 1,024 תווים) או תיאור ארוך בשדה סקירה כללית (עד 120KB).

C#‎

C#

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי C#ההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog C# API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

using Google.Api.Gax.ResourceNames;
using Google.Cloud.Dataplex.V1;
using Google.LongRunning;

public sealed partial class GeneratedBusinessGlossaryServiceClientSnippets
{
    /// <summary>Snippet for CreateGlossary</summary>
    /// <remarks>
    /// This snippet has been automatically generated and should be regarded as a code template only.
    /// It will require modifications to work:
    /// - It may require correct/in-range values for request initialization.
    /// - It may require specifying regional endpoints when creating the service client as shown in
    ///   https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint.
    /// </remarks>
    public void CreateGlossaryRequestObject()
    {
        // Create client
        BusinessGlossaryServiceClient businessGlossaryServiceClient = BusinessGlossaryServiceClient.Create();
        // Initialize request argument(s)
        CreateGlossaryRequest request = new CreateGlossaryRequest
        {
            ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
            GlossaryId = "",
            Glossary = new Glossary(),
            ValidateOnly = false,
        };
        // Make the request
        Operation<Glossary, OperationMetadata> response = businessGlossaryServiceClient.CreateGlossary(request);

        // Poll until the returned long-running operation is complete
        Operation<Glossary, OperationMetadata> completedResponse = response.PollUntilCompleted();
        // Retrieve the operation result
        Glossary result = completedResponse.Result;

        // Or get the name of the operation
        string operationName = response.Name;
        // This name can be stored, then the long-running operation retrieved later by name
        Operation<Glossary, OperationMetadata> retrievedResponse = businessGlossaryServiceClient.PollOnceCreateGlossary(operationName);
        // Check if the retrieved long-running operation has completed
        if (retrievedResponse.IsCompleted)
        {
            // If it has completed, then access the result
            Glossary retrievedResult = retrievedResponse.Result;
        }
    }
}

המשך

Go

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Goההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Go API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.


//go:build examples

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	dataplexpb "cloud.google.com/go/dataplex/apiv1/dataplexpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := dataplex.NewBusinessGlossaryClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateGlossaryRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/dataplex/apiv1/dataplexpb#CreateGlossaryRequest.
	}
	op, err := c.CreateGlossary(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

Java

Java

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Javaההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Java API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient;
import com.google.cloud.dataplex.v1.CreateGlossaryRequest;
import com.google.cloud.dataplex.v1.Glossary;
import com.google.cloud.dataplex.v1.LocationName;

public class SyncCreateGlossary {

  public static void main(String[] args) throws Exception {
    syncCreateGlossary();
  }

  public static void syncCreateGlossary() throws Exception {
    // This snippet has been automatically generated and should be regarded as a code template only.
    // It will require modifications to work:
    // - It may require correct/in-range values for request initialization.
    // - It may require specifying regional endpoints when creating the service client as shown in
    // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
        BusinessGlossaryServiceClient.create()) {
      CreateGlossaryRequest request =
          CreateGlossaryRequest.newBuilder()
              .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
              .setGlossaryId("glossaryId1849967577")
              .setGlossary(Glossary.newBuilder().build())
              .setValidateOnly(true)
              .build();
      Glossary response = businessGlossaryServiceClient.createGlossaryAsync(request).get();
    }
  }
}

Node.js

Node.js

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Node.jsההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Node.js API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

/**
 * This snippet has been automatically generated and should be regarded as a code template only.
 * It will require modifications to work.
 * It may require correct/in-range values for request initialization.
 * TODO(developer): Uncomment these variables before running the sample.
 */
/**
 *  Required. The parent resource where this Glossary will be created.
 *  Format: projects/{project_id_or_number}/locations/{location_id}
 *  where `location_id` refers to a Google Cloud region.
 */
// const parent = 'abc123'
/**
 *  Required. Glossary ID: Glossary identifier.
 */
// const glossaryId = 'abc123'
/**
 *  Required. The Glossary to create.
 */
// const glossary = {}
/**
 *  Optional. Validates the request without actually creating the Glossary.
 *  Default: false.
 */
// const validateOnly = true

// Imports the Dataplex library
const {BusinessGlossaryServiceClient} = require('@google-cloud/dataplex').v1;

// Instantiates a client
const dataplexClient = new BusinessGlossaryServiceClient();

async function callCreateGlossary() {
  // Construct request
  const request = {
    parent,
    glossaryId,
    glossary,
  };

  // Run request
  const [operation] = await dataplexClient.createGlossary(request);
  const [response] = await operation.promise();
  console.log(response);
}

callCreateGlossary();

Python

Python

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Pythonההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Python API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import dataplex_v1


def sample_create_glossary():
    # Create a client
    client = dataplex_v1.BusinessGlossaryServiceClient()

    # Initialize request argument(s)
    request = dataplex_v1.CreateGlossaryRequest(
        parent="parent_value",
        glossary_id="glossary_id_value",
    )

    # Make the request
    operation = client.create_glossary(request=request)

    print("Waiting for operation to complete...")

    response = operation.result()

    # Handle the response
    print(response)

Ruby

Ruby

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Rubyההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Ruby API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

require "google/cloud/dataplex/v1"

##
# Snippet for the create_glossary call in the BusinessGlossaryService service
#
# This snippet has been automatically generated and should be regarded as a code
# template only. It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
# client as shown in https://cloud.google.com/ruby/docs/reference.
#
# This is an auto-generated example demonstrating basic usage of
# Google::Cloud::Dataplex::V1::BusinessGlossaryService::Client#create_glossary.
#
def create_glossary
  # Create a client object. The client can be reused for multiple calls.
  client = Google::Cloud::Dataplex::V1::BusinessGlossaryService::Client.new

  # Create a request. To set request fields, pass in keyword arguments.
  request = Google::Cloud::Dataplex::V1::CreateGlossaryRequest.new

  # Call the create_glossary method.
  result = client.create_glossary request

  # The returned object is of type Gapic::Operation. You can use it to
  # check the status of an operation, cancel it, or wait for results.
  # Here is how to wait for a response.
  result.wait_until_done! timeout: 60
  if result.response?
    p result.response
  else
    puts "No response received."
  end
end

REST

כשיוצרים מילון מונחים, Knowledge Catalog יוצר רשומה שמייצגת את מילון המונחים.

  1. יוצרים את מילון המונחים.

    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries?glossary_id=GLOSSARY_ID --data @- << EOF
    {
    "displayName": "DISPLAY_NAME",
    "description": "DESCRIPTION"
    }
    EOF

    מחליפים את מה שכתוב בשדות הבאים:

    • PROJECT_ID: מזהה הפרויקט שבו רוצים ליצור את המילון
    • LOCATION_ID: המזהה של המיקום שבו רוצים ליצור את המילון
    • GLOSSARY_ID: המזהה של המילון
    • DISPLAY_NAME: השם המוצג של המילון
    • DESCRIPTION: תיאור המילון, עד 1,024 תווים
  2. אופציונלי: מוסיפים סקירה כללית למילון המונחים.

    1. מחפשים את הערך במילון המונחים:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID
      \
      \&view=ALL

      מחליפים את PROJECT_NUMBER במספר הפרויקט שבו נוצר המילון.

    2. כדי להוסיף סקירה כללית למילון המונחים:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID\
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/overview \
      --data @- << EOF
      {
      "aspects": {
         "dataplex-types.global.overview": {
            "aspect_type": "projects/dataplex-types/locations/global/aspectTypes/overview",
            "data": {
            "content": "OVERVIEW",
            "links": []
            },
         }
      }
      }
      EOF

      מחליפים את OVERVIEW בטקסט רגיל או ב-HTML כדי לתאר את הקטגוריה או המונח במילון המונחים.

צפייה במילוני המונחים הזמינים

המסוף

  • נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

    בחלונית המונחונים שלי מוצגים כל המונחונים של הארגון שיש לכם הרשאה לצפות בהם, יחד עם התיאורים שלהם וחותמות הזמן של השינוי האחרון.

C#‎

C#

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי C#ההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog C# API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

using Google.Api.Gax;
using Google.Api.Gax.ResourceNames;
using Google.Cloud.Dataplex.V1;
using System;

public sealed partial class GeneratedBusinessGlossaryServiceClientSnippets
{
    /// <summary>Snippet for ListGlossaries</summary>
    /// <remarks>
    /// This snippet has been automatically generated and should be regarded as a code template only.
    /// It will require modifications to work:
    /// - It may require correct/in-range values for request initialization.
    /// - It may require specifying regional endpoints when creating the service client as shown in
    ///   https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint.
    /// </remarks>
    public void ListGlossariesRequestObject()
    {
        // Create client
        BusinessGlossaryServiceClient businessGlossaryServiceClient = BusinessGlossaryServiceClient.Create();
        // Initialize request argument(s)
        ListGlossariesRequest request = new ListGlossariesRequest
        {
            ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
            Filter = "",
            OrderBy = "",
        };
        // Make the request
        PagedEnumerable<ListGlossariesResponse, Glossary> response = businessGlossaryServiceClient.ListGlossaries(request);

        // Iterate over all response items, lazily performing RPCs as required
        foreach (Glossary item in response)
        {
            // Do something with each item
            Console.WriteLine(item);
        }

        // Or iterate over pages (of server-defined size), performing one RPC per page
        foreach (ListGlossariesResponse page in response.AsRawResponses())
        {
            // Do something with each page of items
            Console.WriteLine("A page of results:");
            foreach (Glossary item in page)
            {
                // Do something with each item
                Console.WriteLine(item);
            }
        }

        // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
        int pageSize = 10;
        Page<Glossary> singlePage = response.ReadPage(pageSize);
        // Do something with the page of items
        Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
        foreach (Glossary item in singlePage)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
        // Store the pageToken, for when the next page is required.
        string nextPageToken = singlePage.NextPageToken;
    }
}

המשך

Go

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Goההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Go API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.


//go:build examples

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	dataplexpb "cloud.google.com/go/dataplex/apiv1/dataplexpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := dataplex.NewBusinessGlossaryClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListGlossariesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/dataplex/apiv1/dataplexpb#ListGlossariesRequest.
	}
	it := c.ListGlossaries(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*dataplexpb.ListGlossariesResponse)
	}
}

Java

Java

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Javaההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Java API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient;
import com.google.cloud.dataplex.v1.Glossary;
import com.google.cloud.dataplex.v1.ListGlossariesRequest;
import com.google.cloud.dataplex.v1.LocationName;

public class SyncListGlossaries {

  public static void main(String[] args) throws Exception {
    syncListGlossaries();
  }

  public static void syncListGlossaries() throws Exception {
    // This snippet has been automatically generated and should be regarded as a code template only.
    // It will require modifications to work:
    // - It may require correct/in-range values for request initialization.
    // - It may require specifying regional endpoints when creating the service client as shown in
    // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
        BusinessGlossaryServiceClient.create()) {
      ListGlossariesRequest request =
          ListGlossariesRequest.newBuilder()
              .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
              .setPageSize(883849137)
              .setPageToken("pageToken873572522")
              .setFilter("filter-1274492040")
              .setOrderBy("orderBy-1207110587")
              .build();
      for (Glossary element : businessGlossaryServiceClient.listGlossaries(request).iterateAll()) {
        // doThingsWith(element);
      }
    }
  }
}

Node.js

Node.js

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Node.jsההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Node.js API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

/**
 * This snippet has been automatically generated and should be regarded as a code template only.
 * It will require modifications to work.
 * It may require correct/in-range values for request initialization.
 * TODO(developer): Uncomment these variables before running the sample.
 */
/**
 *  Required. The parent, which has this collection of GlossaryTerms.
 *  Format:
 *  projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
 *  where `location_id` refers to a Google Cloud region.
 */
// const parent = 'abc123'
/**
 *  Optional. The maximum number of GlossaryTerms to return. The service may
 *  return fewer than this value. If unspecified, at most 50 GlossaryTerms will
 *  be returned. The maximum value is 1000; values above 1000 will be coerced
 *  to 1000.
 */
// const pageSize = 1234
/**
 *  Optional. A page token, received from a previous `ListGlossaryTerms` call.
 *  Provide this to retrieve the subsequent page.
 *  When paginating, all other parameters provided to `ListGlossaryTerms` must
 *  match the call that provided the page token.
 */
// const pageToken = 'abc123'
/**
 *  Optional. Filter expression that filters GlossaryTerms listed in the
 *  response. Filters are supported on the following fields:
 *    - immediate_parent
 *  Examples of using a filter are:
 *    -
 *    `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
 *    -
 *    `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
 *  This will only return the GlossaryTerms that are directly nested under the
 *  specified parent.
 */
// const filter = 'abc123'
/**
 *  Optional. Order by expression that orders GlossaryTerms listed in the
 *  response. Order by fields are: `name` or `create_time` for the result. If
 *  not specified, the ordering is undefined.
 */
// const orderBy = 'abc123'

// Imports the Dataplex library
const {BusinessGlossaryServiceClient} = require('@google-cloud/dataplex').v1;

// Instantiates a client
const dataplexClient = new BusinessGlossaryServiceClient();

async function callListGlossaryTerms() {
  // Construct request
  const request = {
    parent,
  };

  // Run request
  const iterable = dataplexClient.listGlossaryTermsAsync(request);
  for await (const response of iterable) {
      console.log(response);
  }
}

callListGlossaryTerms();

Python

Python

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Pythonההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Python API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import dataplex_v1


def sample_list_glossaries():
    # Create a client
    client = dataplex_v1.BusinessGlossaryServiceClient()

    # Initialize request argument(s)
    request = dataplex_v1.ListGlossariesRequest(
        parent="parent_value",
    )

    # Make the request
    page_result = client.list_glossaries(request=request)

    # Handle the response
    for response in page_result:
        print(response)

Ruby

Ruby

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Rubyההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Ruby API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

require "google/cloud/dataplex/v1"

##
# Snippet for the list_glossaries call in the BusinessGlossaryService service
#
# This snippet has been automatically generated and should be regarded as a code
# template only. It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
# client as shown in https://cloud.google.com/ruby/docs/reference.
#
# This is an auto-generated example demonstrating basic usage of
# Google::Cloud::Dataplex::V1::BusinessGlossaryService::Client#list_glossaries.
#
def list_glossaries
  # Create a client object. The client can be reused for multiple calls.
  client = Google::Cloud::Dataplex::V1::BusinessGlossaryService::Client.new

  # Create a request. To set request fields, pass in keyword arguments.
  request = Google::Cloud::Dataplex::V1::ListGlossariesRequest.new

  # Call the list_glossaries method.
  result = client.list_glossaries request

  # The returned object is of type Gapic::PagedEnumerable. You can iterate
  # over elements, and API calls will be issued to fetch pages as needed.
  result.each do |item|
    # Each element is of type ::Google::Cloud::Dataplex::V1::Glossary.
    p item
  end
end

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries

עריכת מילון מונחים

אפשר לערוך את השם והתיאור של מילון מונחים.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. לוחצים על המילון שרוצים לערוך.

  3. לוחצים על עריכה לצד השם, התיאור או הסקירה הכללית, ואז מבצעים את השינוי.

  4. לוחצים על Save.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID?update_mask=displayName,description --data @- << EOF
{
"displayName": "DISPLAY_NAME",
"description": "DESCRIPTION"
}
EOF

מחיקת מילון מונחים

כדי למחוק מילון מונחים, קודם צריך למחוק את כל הקטגוריות והמונחים במילון המונחים.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. לוחצים על המילון שרוצים למחוק.

  3. לוחצים על מחיקה ומאשרים כשמוצגת בקשה.

C#‎

C#

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי C#ההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog C# API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

using Google.Cloud.Dataplex.V1;
using Google.LongRunning;
using Google.Protobuf.WellKnownTypes;

public sealed partial class GeneratedBusinessGlossaryServiceClientSnippets
{
    /// <summary>Snippet for DeleteGlossary</summary>
    /// <remarks>
    /// This snippet has been automatically generated and should be regarded as a code template only.
    /// It will require modifications to work:
    /// - It may require correct/in-range values for request initialization.
    /// - It may require specifying regional endpoints when creating the service client as shown in
    ///   https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint.
    /// </remarks>
    public void DeleteGlossaryRequestObject()
    {
        // Create client
        BusinessGlossaryServiceClient businessGlossaryServiceClient = BusinessGlossaryServiceClient.Create();
        // Initialize request argument(s)
        DeleteGlossaryRequest request = new DeleteGlossaryRequest
        {
            GlossaryName = GlossaryName.FromProjectLocationGlossary("[PROJECT]", "[LOCATION]", "[GLOSSARY]"),
            Etag = "",
        };
        // Make the request
        Operation<Empty, OperationMetadata> response = businessGlossaryServiceClient.DeleteGlossary(request);

        // Poll until the returned long-running operation is complete
        Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
        // Retrieve the operation result
        Empty result = completedResponse.Result;

        // Or get the name of the operation
        string operationName = response.Name;
        // This name can be stored, then the long-running operation retrieved later by name
        Operation<Empty, OperationMetadata> retrievedResponse = businessGlossaryServiceClient.PollOnceDeleteGlossary(operationName);
        // Check if the retrieved long-running operation has completed
        if (retrievedResponse.IsCompleted)
        {
            // If it has completed, then access the result
            Empty retrievedResult = retrievedResponse.Result;
        }
    }
}

המשך

Go

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Goההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Go API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.


//go:build examples

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	dataplexpb "cloud.google.com/go/dataplex/apiv1/dataplexpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := dataplex.NewBusinessGlossaryClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteGlossaryRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/dataplex/apiv1/dataplexpb#DeleteGlossaryRequest.
	}
	op, err := c.DeleteGlossary(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

Java

Java

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Javaההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Java API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient;
import com.google.cloud.dataplex.v1.DeleteGlossaryRequest;
import com.google.cloud.dataplex.v1.GlossaryName;
import com.google.protobuf.Empty;

public class SyncDeleteGlossary {

  public static void main(String[] args) throws Exception {
    syncDeleteGlossary();
  }

  public static void syncDeleteGlossary() throws Exception {
    // This snippet has been automatically generated and should be regarded as a code template only.
    // It will require modifications to work:
    // - It may require correct/in-range values for request initialization.
    // - It may require specifying regional endpoints when creating the service client as shown in
    // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
        BusinessGlossaryServiceClient.create()) {
      DeleteGlossaryRequest request =
          DeleteGlossaryRequest.newBuilder()
              .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
              .setEtag("etag3123477")
              .build();
      businessGlossaryServiceClient.deleteGlossaryAsync(request).get();
    }
  }
}

Node.js

Node.js

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Node.jsההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Node.js API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

/**
 * This snippet has been automatically generated and should be regarded as a code template only.
 * It will require modifications to work.
 * It may require correct/in-range values for request initialization.
 * TODO(developer): Uncomment these variables before running the sample.
 */
/**
 *  Required. The name of the Glossary to delete.
 *  Format:
 *  projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
 */
// const name = 'abc123'
/**
 *  Optional. The etag of the Glossary.
 *  If this is provided, it must match the server's etag.
 *  If the etag is provided and does not match the server-computed etag,
 *  the request must fail with a ABORTED error code.
 */
// const etag = 'abc123'

// Imports the Dataplex library
const {BusinessGlossaryServiceClient} = require('@google-cloud/dataplex').v1;

// Instantiates a client
const dataplexClient = new BusinessGlossaryServiceClient();

async function callDeleteGlossary() {
  // Construct request
  const request = {
    name,
  };

  // Run request
  const [operation] = await dataplexClient.deleteGlossary(request);
  const [response] = await operation.promise();
  console.log(response);
}

callDeleteGlossary();

Python

Python

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Pythonההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Python API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import dataplex_v1


def sample_delete_glossary():
    # Create a client
    client = dataplex_v1.BusinessGlossaryServiceClient()

    # Initialize request argument(s)
    request = dataplex_v1.DeleteGlossaryRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_glossary(request=request)

    print("Waiting for operation to complete...")

    response = operation.result()

    # Handle the response
    print(response)

Ruby

Ruby

לפני שמנסים את הדוגמה הזו, צריך לפעול לפי Rubyההוראות להגדרה במאמר מדריך למתחילים לעבודה עם Knowledge Catalog באמצעות ספריות לקוח. מידע נוסף מופיע במאמרי העזרה של Knowledge Catalog Ruby API.

כדי לבצע אימות לקטלוג הידע, צריך להגדיר את Application Default Credentials. מידע נוסף זמין במאמר הגדרת אימות לסביבת פיתוח מקומית.

require "google/cloud/dataplex/v1"

##
# Snippet for the delete_glossary call in the BusinessGlossaryService service
#
# This snippet has been automatically generated and should be regarded as a code
# template only. It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
# client as shown in https://cloud.google.com/ruby/docs/reference.
#
# This is an auto-generated example demonstrating basic usage of
# Google::Cloud::Dataplex::V1::BusinessGlossaryService::Client#delete_glossary.
#
def delete_glossary
  # Create a client object. The client can be reused for multiple calls.
  client = Google::Cloud::Dataplex::V1::BusinessGlossaryService::Client.new

  # Create a request. To set request fields, pass in keyword arguments.
  request = Google::Cloud::Dataplex::V1::DeleteGlossaryRequest.new

  # Call the delete_glossary method.
  result = client.delete_glossary request

  # The returned object is of type Gapic::Operation. You can use it to
  # check the status of an operation, cancel it, or wait for results.
  # Here is how to wait for a response.
  result.wait_until_done! timeout: 60
  if result.response?
    p result.response
  else
    puts "No response received."
  end
end

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X DELETE https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID

יצירה וניהול של קטגוריות

בסעיפים הבאים מוסבר איך ליצור, לראות, לעדכן ולמחוק קטגוריות.

יצירת קטגוריה במילון מונחים

במילון המונחים הארגוני יכולות להיות עד 200 קטגוריות.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. בוחרים את המילון שבו רוצים ליצור קטגוריה, ואז לוחצים על יצירת קטגוריה.

  3. מזינים שם לקטגוריה.

  4. לוחצים על יצירה.

  5. אופציונלי: מוסיפים תיאור קצר בשדה תיאור (עד 1,024 תווים) או תיאור ארוך בשדה סקירה כללית (עד 120KB).

REST

כשיוצרים קטגוריה, נוצר רשומה ב-Knowledge Catalog שמייצגת את הקטגוריה.

  1. יוצרים את הקטגוריה.

    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories?category_id=CATEGORY_ID --data @- << EOF
    {
    "displayName": "CATEGORY_DISPLAY_NAME",
    "description": "CATEGORY_DESCRIPTION",
    "parent": "projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID"
    }
    EOF

    מחליפים את מה שכתוב בשדות הבאים:

    • CATEGORY_ID: מזהה הקטגוריה
    • CATEGORY_DISPLAY_NAME: השם המוצג של הקטגוריה
    • CATEGORY_DESCRIPTION: תיאור הקטגוריה
  2. אופציונלי: מוסיפים סקירה כללית לקטגוריה.

    1. מחפשים את הערך של הקטגוריה:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID
      \
      \&view=ALL
    2. מוסיפים סקירה כללית לקטגוריה:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID\
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/overview
      \
      --data @- << EOF
      {
      "aspects": {
      "dataplex-types.global.overview": {
         "aspect_type":"projects/dataplex-types/locations/global/aspectTypes/overview
      ",
         "data": {
         "content": "OVERVIEW",
         "links": []
         },
      }
      }
      }
      EOF

      מחליפים את OVERVIEW בטקסט רגיל או ב-HTML כדי לתאר את הקטגוריה או המונח במילון המונחים.

  3. אופציונלי: הוספת אנשי קשר

    1. מחפשים את הערך של הקטגוריה:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID
      \
      \&view=ALL
    2. מעדכנים את הרשומה של הקטגוריה עם אנשי הקשר:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID\
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/contacts \
      --data @- << EOF
      {
      "aspects": {
      "dataplex-types.global.contacts": {
         "aspect_type": "projects/dataplex-types/locations/global/aspectTypes/contacts",
         "data": {
         "identities": [
            {
               "role": "steward",
               "name": "CONTACT_NAME",
               "id": "CONTACT_EMAIL"
            }
         ]
         },
      }
      }
      }
      EOF

יצירת קטגוריה משנה

מילון המונחים הארגוני יכול לכלול עד שלוש רמות של קטגוריות מקוננות, לא כולל רמת השורש של מילון המונחים.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון שבו רוצים ליצור קטגוריה.

  3. בוחרים את קטגוריית האב שבה רוצים ליצור עוד קטגוריה ולוחצים על יצירת קטגוריה.

  4. מזינים שם לקטגוריה.

  5. לוחצים על יצירה.

  6. אופציונלי: מוסיפים תיאור קצר בשדה תיאור (עד 1,024 תווים) או תיאור ארוך בשדה סקירה כללית (עד 120KB).

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories?category_id=CATEGORY_ID --data @- << EOF
{
  "displayName": "CATEGORY_DISPLAY_NAME",
  "description": "CATEGORY_DESCRIPTION",
  "parent": "projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/PARENT_CATEGORY_ID"
}
EOF

מחליפים את PARENT_CATEGORY_ID במזהה של קטגוריית האב.

הצגת הקטגוריות ששייכות למילון מונחים

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. כדי לראות את הקטגוריות במילון מונחים, מרחיבים את מילון המונחים.

  3. כדי לראות את הקטגוריות המשנה בקטגוריה, מרחיבים את הקטגוריה.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories

עריכת קטגוריה

אפשר לערוך את השם, התיאור ואנשי הקשר של קטגוריה. בקטגוריות מקוננות, אפשר גם לערוך את קטגוריית ההורה.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולוחצים על הקטגוריה שרוצים לערוך.

  3. לוחצים על עריכה ליד השם, התיאור או הסקירה הכללית, ואז מבצעים את השינוי.

  4. לוחצים על Save.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID?update_mask=displayName,description --data @- << EOF
{
"displayName": "CATEGORY_DISPLAY_NAME",
"description": "DESCRIPTION"
}
EOF

מחיקת קטגוריה

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולוקחים על הקטגוריה שרוצים למחוק.

  3. לוחצים על מחיקה ומאשרים כשמוצגת בקשה.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X DELETE https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID

יצירה וניהול של מונחים

בקטעים הבאים מוסבר איך ליצור, לראות, לגשת, לערוך ולמחוק תנאים.

יצירת מונח במילון המונחים הארגוני

מילון המונחים הארגוני יכול להכיל עד 5,000 מונחים.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. כדי ליצור מונח ברמת המילון, בוחרים את המילון שבו רוצים ליצור מונח ולוחצים על יצירת מונח.

  3. מזינים שם למונח.

  4. לוחצים על יצירה.

  5. אופציונלי: מוסיפים תיאור קצר בשדה תיאור (עד 1,024 תווים) או תיאור ארוך בשדה סקירה כללית (עד 120KB).

  6. אופציונלי: כדי להוסיף אנשי קשר, לוחצים על עריכה ומזינים רשימה של כתובות אימייל של נאמני מידע, בעלי מידע או בעלי דומיין מידע. לאחר מכן לוחצים על שמירה.

REST

כשיוצרים מונח, מתפרסם ב-Knowledge Catalog ערך שמייצג את המונח.

  1. יוצרים את המונח.

    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms?term_id=TERM_ID --data @- << EOF
    {
    "displayName": "TERM_DISPLAY_NAME",
    "description": "TERM_DESCRIPTION",
    "parent": "projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID"
    }
    EOF

    מחליפים את מה שכתוב בשדות הבאים:

    • TERM_ID: המזהה של התנאי שאתם יוצרים
    • TERM_DISPLAY_NAME: השם המוצג של המונח שאתם יוצרים
    • TERM_DESCRIPTION: התיאור של המונח שיוצרים
  2. אופציונלי: מוסיפים סקירה כללית למונח.

    1. מחפשים את הערך של המונח:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      \
      \&view=ALL
    2. הוספת סקירה כללית למונח:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      \
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/overview
      \
      --data @- << EOF
      {
      "aspects": {
      "dataplex-types.global.overview": {
         "aspect_type":"projects/dataplex-types/locations/global/aspectTypes/overview
      ",
         "data": {
         "content": "OVERVIEW",
         "links": []
         },
      }
      }
      }
      EOF

      מחליפים את OVERVIEW בטקסט רגיל או ב-HTML כדי לתאר את הקטגוריה או המונח במילון המונחים.

  3. אופציונלי: מוסיפים אנשי קשר.

    1. מחפשים את הערך של המונח:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      \
      \&view=ALL
    2. מעדכנים את הערך של המונח עם אנשי הקשר:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/contacts \
      --data @- << EOF
      {
      "aspects": {
      "dataplex-types.global.contacts": {
         "aspect_type": "projects/dataplex-types/locations/global/aspectTypes/contacts",
         "data": {
         "identities": [
            {
               "role": "steward",
               "name": "CONTACT_NAME",
               "id": "CONTACT_EMAIL"
            }
         ]
         },
      }
      }
      }
      EOF

יצירת מונח בקטגוריה

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. כדי ליצור מונח בקטגוריה, בוחרים את הקטגוריה שבה רוצים ליצור מונח ולוחצים על הוספת מונח.

  3. מזינים שם למונח.

  4. לוחצים על יצירה.

  5. אופציונלי: מוסיפים תיאור קצר בשדה תיאור (עד 1,024 תווים) או תיאור ארוך בשדה סקירה כללית (עד 120KB).

  6. אופציונלי: כדי להוסיף אנשי קשר, לוחצים על עריכה ומזינים רשימה של כתובות אימייל של נאמני מידע, בעלי מידע או בעלי דומיין מידע. לאחר מכן לוחצים על שמירה.

REST

כשיוצרים מונח, מתפרסם ב-Knowledge Catalog ערך שמייצג את המונח.

  1. יוצרים מונח.

    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms?term_id=TERM_ID --data @- << EOF
    {
    "displayName": "TERM_DISPLAY_NAME",
    "description": "TERM_DESCRIPTION",
    "parent": "projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/PARENT_CATEGORY_ID"
    }
    EOF

    מחליפים את מה שכתוב בשדות הבאים:

    • TERM_ID: המזהה של התנאי שאתם יוצרים
    • TERM_DISPLAY_NAME: השם המוצג של המונח שאתם יוצרים
    • TERM_DESCRIPTION: התיאור של המונח שיוצרים
  2. אופציונלי: מוסיפים סקירה כללית למונח.

    1. מחפשים את הערך של המונח:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      \
      \&view=ALL
    2. הוספת סקירה כללית למונח:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      \
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/overview
      \
      --data @- << EOF
      {
      "aspects": {
      "dataplex-types.global.overview": {
         "aspect_type":"projects/dataplex-types/locations/global/aspectTypes/overview
      ",
         "data": {
         "content": "OVERVIEW",
         "links": []
         },
      }
      }
      }
      EOF

      מחליפים את OVERVIEW בטקסט רגיל או ב-HTML כדי לתאר את הקטגוריה או המונח במילון המונחים.

  3. אופציונלי: מוסיפים אנשי קשר.

    1. מחפשים את הערך של המונח:

      gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID
      :lookupEntry\
      ?entry=projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      \
      \&view=ALL
    2. מעדכנים את הערך של המונח עם אנשי הקשר:

      gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID
      ?update_mask=aspects\
      \&deleteMissingAspects=false\
      \&aspect_keys=projects/dataplex-types/locations/global/aspectTypes/contacts \
      --data @- << EOF
      {
      "aspects": {
      "dataplex-types.global.contacts": {
         "aspect_type": "projects/dataplex-types/locations/global/aspectTypes/contacts",
         "data": {
         "identities": [
            {
               "role": "steward",
               "name": "CONTACT_NAME",
               "id": "CONTACT_EMAIL"
            }
         ]
         },
      }
      }
      }
      EOF

הוספת היבט למונח

אפשר להוסיף היבטים למונחים כדי לספק הקשר נוסף או מטא-נתונים.

המסוף

  1. נכנסים לדף Glossaries ב-Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולוחצים על המונח שרוצים להוסיף לו היבט.

  3. בקטע Aspects (היבטים), לוחצים על Add (הוספה).

  4. מחפשים את ההיבט, מספקים פרטים לגביו ולוחצים על שמירה.

REST

מונחים במילון הם ערכים. כדי לצרף היבט, צריך לתקן את משאב הרשומה. קבוצת הערכים למילונים היא @dataplex.

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID?update_mask=aspects\&aspect_keys=ASPECT_PROJECT_ID.ASPECT_LOCATION_ID.ASPECT_TYPE_ID --data @- << EOF
{
 "aspects": {
   "ASPECT_PROJECT_ID.ASPECT_LOCATION_ID.ASPECT_TYPE_ID": {
     "aspect_type": "projects/ASPECT_PROJECT_ID/locations/ASPECT_LOCATION_ID/aspectTypes/ASPECT_TYPE_ID",
     "data": {
       "sensitivity": "HIGH",
       "data_owner": "achalg@google.com"
     }
   }
 }
}
EOF

מחליפים את מה שכתוב בשדות הבאים:

  • PROJECT_NUMBER: מספר הפרויקט שמכיל את המונח במילון המונחים.
  • LOCATION_ID: המיקום של המונח במילון המונחים.
  • GLOSSARY_ID: המזהה של המילון שמכיל את המונח.
  • TERM_ID: המזהה של המונח שאליו רוצים לצרף את ההיבט.
  • ASPECT_PROJECT_ID: מזהה הפרויקט שמכיל את סוג ההיבט.
  • ASPECT_LOCATION_ID: המיקום של סוג ההיבט.
  • ASPECT_TYPE_ID: המזהה של סוג ההיבט.

הצגת המונחים במילון מונחים או בקטגוריה

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. כדי לראות את המונחים במילון מונחים, מרחיבים את מילון המונחים. כדי לראות את המונחים בקטגוריה במילון המונחים הזה, מרחיבים את הקטגוריה. כדי לראות את התנאים בקטגוריה משנית, מרחיבים את הקטגוריה המשנית.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms

הצגת הפרטים של מונח

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. כדי לראות את רשימת המונחים במילון מונחים, מרחיבים את מילון המונחים.

  3. לוחצים על מונח. בדף פרטי המונח מוצגים שם המונח, תיאור, מונחים קשורים, מילים נרדפות וערכים קשורים.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID

עריכת מונח

אפשר לערוך את השם, התיאור, הסקירה הכללית, אנשי הקשר וההורה של מונח.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

הוספת היבט למונח

אפשר להוסיף היבטים למונחים כדי לספק הקשר נוסף או מטא-נתונים.

המסוף

  1. נכנסים לדף Glossaries ב-Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולוחצים על המונח שרוצים להוסיף לו היבט.

  3. בקטע Aspects (היבטים), לוחצים על Add (הוספה).

  4. מחפשים את ההיבט, מספקים פרטים לגביו ולוחצים על שמירה.

REST

מונחים במילון הם ערכים. כדי לצרף היבט, צריך לתקן את משאב הרשומה. קבוצת הערכים למילונים היא @dataplex.

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID?update_mask=aspects\&aspect_keys=ASPECT_PROJECT_ID.ASPECT_LOCATION_ID.ASPECT_TYPE_ID --data @- << EOF
{
 "aspects": {
   "ASPECT_PROJECT_ID.ASPECT_LOCATION_ID.ASPECT_TYPE_ID": {
     "aspect_type": "projects/ASPECT_PROJECT_ID/locations/ASPECT_LOCATION_ID/aspectTypes/ASPECT_TYPE_ID",
     "data": {
       "sensitivity": "HIGH",
       "data_owner": "achalg@google.com"
     }
   }
 }
}
EOF

מחליפים את מה שכתוב בשדות הבאים:

  • PROJECT_NUMBER: מספר הפרויקט שמכיל את המונח במילון המונחים.
  • LOCATION_ID: המיקום של המונח במילון המונחים.
  • GLOSSARY_ID: המזהה של המילון שמכיל את המונח.
  • TERM_ID: המזהה של המונח שאליו רוצים לצרף את ההיבט.
  • ASPECT_PROJECT_ID: מזהה הפרויקט שמכיל את סוג ההיבט.
  • ASPECT_LOCATION_ID: המיקום של סוג ההיבט.
  • ASPECT_TYPE_ID: המזהה של סוג ההיבט. מעבר אל Glossaries
  1. מרחיבים את המילון ולוחצים על המונח שרוצים לערוך.

  2. לוחצים על Edit.

  3. עורכים את השדות הרצויים ולוחצים על שמירה.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X PATCH https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID?update_mask=displayName,description --data @- << EOF
{
  "displayName": "TERM_DISPLAY_NAME",
  "description": "TERM_DESCRIPTION"
}
EOF

מחיקת מונח

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולוחצים על המונח שרוצים למחוק.

  3. לוחצים על מחיקה ומאשרים כשמוצגת בקשה.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X DELETE https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM_ID

אפשר להוסיף קשרים בין מונחים על ידי קישור שלהם כמילים נרדפות או כמונחים קשורים.

הקשרים בין המונחים הם דו-כיווניים. לדוגמה, כשמקשרים את profit כמילה נרדפת של earnings, ‏ earnings הופכת גם היא למילה נרדפת של profit.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולחצים על המונח שרוצים ליצור ממנו קישורים.

  3. לוחצים על עריכה לצד מונחים נרדפים.

  4. מחפשים את המונחים שרוצים לקשר אליהם ובוחרים אותם.

    המונח מקושר באופן מיידי כשבוחרים אותו.

  5. לוחצים על Close.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/TERM1_PROJECT_ID/locations/TERM1_LOCATION_ID/entryGroups/@dataplex/entryLinks?entry_link_id=ENTRY_LINK_ID -d "$(cat<<EOF
{
  "entry_link_type": "projects/dataplex-types/locations/global/entryLinkTypes/synonym",
"entry_references": [{
     "name": "projects/TERM1_PROJECT_NUMBER/locations/TERM1_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM1_PROJECT_NUMBER/locations/TERM1_LOCATION_ID/glossaries/TERM1_GLOSSARY_ID/terms/TERM1_ID",
     "type": "UNSPECIFIED"
  }, {
     "name": "projects/TERM2_PROJECT_NUMBER/locations/TERM2_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM2_PROJECT_NUMBER/locations/TERM2_LOCATION_ID/glossaries/TERM2_GLOSSARY_ID/terms/TERM2_ID",
     "type": "UNSPECIFIED"
  }
  ]

}
EOF
)"

מחליפים את מה שכתוב בשדות הבאים:

  • TERM1_PROJECT_NUMBER: מספר הפרויקט של התקופה הראשונה שמקשרים.
  • TERM1_LOCATION_ID: מזהה המיקום של המילון שמכיל את המונח הראשון.
  • TERM1_GLOSSARY_ID: המזהה של המילון שמכיל את המונח הראשון.
  • TERM1_ID: המזהה של התקופה הראשונה.
  • TERM2_PROJECT_NUMBER: מספר הפרויקט של המונח השני שרוצים לקשר אליו בתור מונח נרדף. אם שני התנאים נמצאים באותו פרויקט, הערך הזה זהה למספר הפרויקט של התנאי הראשון.
  • TERM2_LOCATION_ID: מזהה המיקום של המילון שמכיל את המונח השני. אם שני המונחים נמצאים באותו מיקום, הערך הזה זהה למזהה המיקום של המונח הראשון.
  • TERM2_GLOSSARY_ID: המזהה של המילון שמכיל את המונח השני. אם שני המונחים מופיעים באותו מילון מונחים, הערך הזה זהה למזהה מילון המונחים של המונח הראשון.
  • TERM2_ID: המזהה של התקופה השנייה.
  • ENTRY_LINK_ID: מזהה של הקישור בין שני המונחים. כל מונח מיוצג כרשומה ב-Knowledge Catalog. קישור הערך הוא הקשר בין מונחים נרדפים.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולחצים על המונח שרוצים ליצור ממנו קישורים.

  3. לוחצים על עריכה לצד מונחים קשורים.

  4. מחפשים את המונחים שרוצים לקשר אליהם ובוחרים אותם.

    המונח מקושר באופן מיידי כשבוחרים אותו.

  5. לוחצים על Close.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/TERM1_PROJECT_ID/locations/TERM1_LOCATION_ID/entryGroups/@dataplex/entryLinks?entry_link_id=ENTRY_LINK_ID -d "$(cat<<EOF
{
  "entry_link_type": "projects/dataplex-types/locations/global/entryLinkTypes/related",
"entry_references": [{
     "name": "projects/TERM1_PROJECT_NUMBER/locations/TERM1_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM1_PROJECT_NUMBER/locations/TERM1_LOCATION_ID/glossaries/TERM1_GLOSSARY_ID/terms/TERM1_ID",
     "type": "UNSPECIFIED"
  }, {
     "name": "projects/TERM2_PROJECT_NUMBER/locations/TERM2_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM2_PROJECT_NUMBER/locations/TERM2_LOCATION_ID/glossaries/TERM2_GLOSSARY_ID/terms/TERM2_ID",
     "type": "UNSPECIFIED"
  }
  ]

}
EOF
)"

מחליפים את מה שכתוב בשדות הבאים:

  • TERM1_PROJECT_NUMBER: מספר הפרויקט של התקופה הראשונה שמקשרים.
  • TERM1_LOCATION_ID: מזהה המיקום של המילון שמכיל את המונח הראשון.
  • TERM1_GLOSSARY_ID: המזהה של המילון שמכיל את המונח הראשון.
  • TERM1_ID: המזהה של התקופה הראשונה.
  • TERM2_PROJECT_NUMBER: מספר הפרויקט של התקופה השנייה שרוצים לקשר אליה כאל תקופה קשורה. אם שני המונחים נמצאים באותו פרויקט, הערך הזה זהה למספר הפרויקט של המונח הראשון.
  • TERM2_LOCATION_ID: מזהה המיקום של המילון שמכיל את המונח השני. אם שני המונחים נמצאים באותו מיקום, הערך הזה זהה למזהה המיקום של המונח הראשון.
  • TERM2_GLOSSARY_ID: המזהה של המילון שמכיל את המונח השני. אם שני המונחים מופיעים באותו מילון מונחים, הערך הזה זהה למזהה מילון המונחים של המונח הראשון.
  • TERM2_ID: המזהה של התקופה השנייה.
  • ENTRY_LINK_ID: מזהה של הקישור בין שני המונחים. כל מונח מיוצג כרשומה ב-Knowledge Catalog. קישור הערך הוא הקשר בין מונחים קשורים.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/TERM_PROJECT_ID/locations/SYNONYM_LINKS_LOCATION_ID:lookupEntryLinks?entry=projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/glossaries/TERM_GLOSSARY_ID/terms/TERM_ID&entry_link_types=projects/dataplex-types/locations/global/entryLinkTypes/synonym&page_size=10

מחליפים את מה שכתוב בשדות הבאים:

  • TERM_PROJECT_ID: מזהה הפרויקט של המונח שאתם מחפשים את הקישורים למילים הנרדפות שלו.
  • TERM_PROJECT_NUMBER: מספר הפרויקט של המונח שאת הקישורים למילים הנרדפות שלו מחפשים.
  • SYNONYM_LINKS_LOCATION_ID: מזהה המיקום שבו מחפשים את הקישורים למילים נרדפות.
  • TERM_LOCATION_ID: מזהה המיקום של המונח.
  • TERM_GLOSSARY_ID: המזהה של המילון שמכיל את המונח.
  • TERM_ID: המזהה של המונח.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/TERM_PROJECT_ID/locations/RELATED_LINKS_LOCATION_ID:lookupEntryLinks?entry=projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/glossaries/TERM_GLOSSARY_ID/terms/TERM_ID&entry_link_types=projects/dataplex-types/locations/global/entryLinkTypes/related&page_size=10

מחליפים את מה שכתוב בשדות הבאים:

  • TERM_PROJECT_ID: מזהה הפרויקט של המונח שאתם מחפשים את הקישורים שקשורים אליו.
  • TERM_PROJECT_NUMBER: מספר הפרויקט של המונח שאת הקישורים הרלוונטיים שלו אתם מחפשים.
  • RELATED_LINKS_LOCATION_ID: מזהה המיקום שבו מחפשים את הקישורים הרלוונטיים.
  • TERM_LOCATION_ID: מזהה המיקום של המונח.
  • TERM_GLOSSARY_ID: המזהה של המילון שמכיל את המונח.
  • TERM_ID: המזהה של המונח.

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. מרחיבים את המילון ולחצים על המונח שרוצים להסיר ממנו מילים נרדפות או מונחים קשורים.

  3. כדי למחוק קישורים בין מונחים קשורים, לוחצים על עריכה לצד מונחים קשורים. מוחקים את המונחים שקשורים למונח המרכזי ולוחצים על סגירה.

  4. כדי למחוק קישורים בין מילים נרדפות, לוחצים על עריכה לצד מילים נרדפות. מוחקים את המילים הנרדפות ולוחצים על סגירה.

REST

  1. מחפשים את הקישורים לרשומות כדי למצוא את מזהה הקישור לרשומה של הקישור שרוצים למחוק. מידע נוסף זמין במאמרים חיפוש קישורים למילים נרדפות למונח או חיפוש קישורים קשורים למונח.

  2. כדי למחוק את הקישור, שולחים את הבקשה הבאה DELETE:

    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl -X DELETE https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entryLinks/ENTRY_LINK_ID

אפשר לצרף תנאים לנכסי נתונים או לעמודות של נכסי נתונים. לדוגמה, אפשר לצרף תנאים למערכי נתונים ב-BigQuery ולטבלאות ב-Iceberg REST Catalog.

המסוף

  1. נכנסים לדף Search של Knowledge Catalog במסוף Google Cloud .

    מעבר אל חיפוש

  2. מחפשים את נכס הנתונים (כמו מערך נתונים, קובץ או טבלה) שרוצים לקשר אליו את המונח, ואז לוחצים עליו.

  3. בדף של נכס הנתונים, מבצעים אחת מהפעולות הבאות:

    • כדי לקשר מונחים לנכס, בכרטיסייה פרטים, בקטע מונחי מילון מונחים, לוחצים על הוספה. מחפשים את התנאים ובוחרים אותם, ואז לוחצים על סגירה.
    • אם לנכס יש סכימה, אפשר לקשר מונחים לעמודה. בכרטיסייה סכימה, בוחרים עמודה לקישור המונחים ולוחצים על הוספת מונח עסקי. מחפשים את התנאים ובוחרים אותם, ואז לוחצים על סגירה.

Python

from google.cloud import dataplex_v1

def attach_term_to_asset(
    project_id: str,
    location: str,
    entry_group_id: str,
    entry_link_id: str,
    source_entry_name: str,
    target_term_name: str,
) -> dataplex_v1.EntryLink:
    """Creates an entry link attaching a glossary term to a data asset."""
    client = dataplex_v1.CatalogServiceClient()
    parent_group = (
        f"projects/{project_id}/locations/{location}/"
        f"entryGroups/{entry_group_id}"
    )

    entry_link = dataplex_v1.EntryLink(
        entry_link_type=(
            "projects/dataplex-types/locations/global/"
            "entryLinkTypes/definition"
        ),
        entry_references=[
            dataplex_v1.EntryLink.EntryReference(
                name=source_entry_name, type_="SOURCE"
            ),
            dataplex_v1.EntryLink.EntryReference(
                name=target_term_name, type_="TARGET"
            ),
        ],
    )

    return client.create_entry_link(
        parent=parent_group,
        entry_link_id=entry_link_id,
        entry_link=entry_link,
    )

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/ENTRY_LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entryLinks?entry_link_id=ENTRY_LINK_ID -d "$(cat<<EOF
{
  "entry_link_type": "projects/dataplex-types/locations/global/entryLinkTypes/definition",
  "entry_references": [{
     "name": "projects/PROJECT_NUMBER/locations/ENTRY_LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entries/ENTRY_ID",
     "type": "SOURCE"
  }, {
     "name": "projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/glossaries/TERM_GLOSSARY_ID/terms/TERM_ID",
     "type": "TARGET"
  }
  ]
}
EOF
)"

מחליפים את מה שכתוב בשדות הבאים:

  • PROJECT_NUMBER: מספר הפרויקט של נכס הנתונים שמקשרים אליו
  • ENTRY_LOCATION_ID: מזהה המיקום של נכס הנתונים שמקשרים אליו
  • ENTRY_GROUP_ID: קבוצת הרשומות של נכס הנתונים שמקושר אליה
  • ENTRY_LINK_ID: מזהה לקישור בין המונח לבין הרשומה ב-Knowledge Catalog שמייצגת את נכס הנתונים.
  • TERM_PROJECT_NUMBER: מספר הפרויקט של התקופה שמקשרים.

צירוף מונחים לעמודה בסכימת רשומות

המסוף

  1. נכנסים לדף Search של Knowledge Catalog במסוף Google Cloud .

    מעבר אל חיפוש

  2. מחפשים את נכס הנתונים (כמו מערך נתונים, קובץ או טבלה) שיש לו סכימה עם עמודה שרוצים לקשר אליה מונח. לוחצים על נכס הנתונים.

  3. בדף של נכס הנתונים, מבצעים אחת מהפעולות הבאות:

    • כדי לקשר מונחים לעמודה בנכס הנתונים, בכרטיסייה סכימה, בוחרים את העמודות שרוצים לצרף אליהן את המונח.
    • לוחצים על הוספת מונח עסקי. מחפשים את המונח שרוצים לצרף ולוחצים עליו כדי לצרף אותו.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_NUMBER/locations/ENTRY_LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entryLinks?entry_link_id=ENTRY_LINK_ID -d "$(cat<<EOF
{
 "entry_link_type": "projects/dataplex-types/locations/global/entryLinkTypes/definition",
 "entry_references": [
   {
     "name": "projects/PROJECT_NUMBER/locations/ENTRY_LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entries/ENTRY_ID",
     "path": "Schema.COLUMN_NAME",
     "type": "SOURCE"
   },
   {
     "name": "projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/glossaries/TERM_GLOSSARY_ID/terms/TERM_ID",
     "type": "TARGET"
   }
 ]
}
EOF
)"

מחליפים את מה שכתוב בשדות הבאים:

  • PROJECT_NUMBER: מספר הפרויקט של נכס הנתונים שמקושר
  • ENTRY_LOCATION_ID: מזהה המיקום של נכס הנתונים שמקשרים אליו
  • ENTRY_GROUP_ID: קבוצת הרשומות של נכס הנתונים שמקושר אליה
  • ENTRY_LINK_ID: מזהה לקישור בין המונח לבין הרשומה ב-Knowledge Catalog שמייצגת את נכס הנתונים
  • TERM_PROJECT_NUMBER: מספר הפרויקט של התקופה שמקשרים
  • COLUMN_NAME: העמודה שאליה רוצים לצרף את המונח

צירוף מונח לכמה נכסי נתונים או עמודות

אפשר לצרף מונח מילון מונחים יחיד לכמה נכסי נתונים או עמודות בו-זמנית. אפשר לבחור עד 20 מקורות או עמודות בפעולה אחת.

המסוף

כדי לצרף מונח לכמה משאבים:

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. ברשימה מילוני מונחים, מרחיבים את מילון המונחים שמכיל את המונח שרוצים לקשר.

  3. לוחצים על המונח.

  4. בקטע Related entries (ערכים קשורים), לוחצים על Add (הוספה).

  5. בתיבת הדו-שיח Attach related entries (צירוף רשומות קשורות), מבצעים את הפעולות הבאות:

    1. מאתרים את המשאבים או העמודות שרוצים לקשר. כדי לצמצם את תוצאות החיפוש, משתמשים במסנן כדי לחפש לפי שם משאב, סוג משאב או שם עמודה.

      לדוגמה, כדי למצוא עמודה בשם sample-column בטבלה ב-BigQuery בשם sample-table בפרויקט עם המזהה sample-project, משתמשים בשאילתה הבאה:

      project id:sample-project
      Resource Name:sample-table
      Column Name:sample-column
      

      אפשר להזין מחרוזות חלקיות כדי למצוא נכסים תואמים.

    2. בוחרים את נכסי הנתונים והעמודות שרוצים לצרף.

    3. כדי לבדוק את הבחירות לפני ההוספה, לוחצים על המתג הצגת המשאבים שנבחרו.

    4. לוחצים על הוספה.

  6. כדי לוודא שהמשאבים והעמודות שצורפו חדשים, עוברים לקטע רשומות קשורות בדף הפרטים של המונח.

חיפוש נכסי נתונים שמקושרים למונח

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/TERM_PROJECT_ID/locations/DEFINITION_LINKS_LOCATION_ID:lookupEntryLinks?entry=projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/entryGroups/@dataplex/entries/projects/TERM_PROJECT_NUMBER/locations/TERM_LOCATION_ID/glossaries/TERM_GLOSSARY_ID/terms/TERM_ID&entry_link_types=projects/dataplex-types/locations/global/entryLinkTypes/definition&entry_mode=TARGET&page_size=10

מחליפים את מה שכתוב בשדות הבאים:

  • TERM_PROJECT_ID: מזהה הפרויקט של המונח שאתם מחפשים את ההגדרה שלו.
  • TERM_PROJECT_NUMBER: מספר הפרויקט של המונח שאתם מחפשים את הקישורים להגדרה שלו.
  • DEFINITION_LINKS_LOCATION_ID: מזהה המיקום שבו מחפשים את קישורי ההגדרה.
  • TERM_LOCATION_ID: מזהה המיקום של המונח.
  • TERM_GLOSSARY_ID: המזהה של המילון שמכיל את המונח.
  • TERM_ID: המזהה של המונח.

חיפוש מונחים שמקושרים לנכס נתונים

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/DEFINITION_LINKS_LOCATION_ID:lookupEntryLinks?entry=projects/PROJECT_NUMBER/locations/ENTRY_LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entries/ENTRY_ID&entry_link_types=projects/dataplex-types/locations/global/entryLinkTypes/definition&entry_mode=SOURCE&page_size=10

מחליפים את מה שכתוב בשדות הבאים:

  • PROJECT_ID: מזהה הפרויקט של נכס הנתונים שאתם מחפשים את ההגדרות שלו.
  • PROJECT_NUMBER: מספר הפרויקט של נכס הנתונים שאתם מחפשים את הקישורים להגדרה שלו.
  • DEFINITION_LINKS_LOCATION_ID: מזהה המיקום שבו מחפשים את קישורי ההגדרה.
  • ENTRY_LOCATION_ID: מזהה המיקום של נכס המידע.
  • ENTRY_GROUP_ID: המזהה של קבוצת הרשומות של נכס הנתונים.
  • ENTRY_ID: המזהה של נכס הנתונים.

המסוף

  1. נכנסים לדף Search של Knowledge Catalog במסוף Google Cloud .

    מעבר אל חיפוש

  2. מחפשים את נכס הנתונים (למשל מערך נתונים, קובץ או טבלה) שרוצים להסיר ממנו את התנאים, ולוחצים עליו.

  3. בדף של נכס הנתונים, מבצעים אחת מהפעולות הבאות:

    • כדי להסיר מונח מנכס, בכרטיסייה פרטים, בקטע מונחי מילון מונחים, לוחצים על המונח. ואז לוחצים על .
    • כדי להסיר מונח מעמודה, בכרטיסייה סכימה, לוחצים על לצד המונח.

REST

alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'

gcurl -X DELETE https://dataplex.googleapis.com/v1/projects/ENTRY_PROJECT_ID/locations/ENTRY_LOCATION_ID/entryGroups/ENTRY_GROUP_ID/entryLinks/ENTRY_LINK_ID

חיפוש מילוני מונחים, מונחים ונכסי נתונים מקושרים

המסוף

כדי לנווט בתוכן של מילון המונחים העסקי, משתמשים בעץ של מילון המונחים והמונחים בדף Glossaries (מילוני מונחים).

  1. נכנסים לדף Glossaries ב-Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. בדף מילוני מונחים, משתמשים בסרגל הסינון כדי למצוא קטגוריות. המסננים הבאים זמינים:

    • Name: מחזירה את המילונים, הקטגוריות והמונחים שהשם שלהם מכיל את הטקסט שאתם מספקים.
    • Parent: מחזירה את המונחים שהשם או התיאור של מילון המונחים ברמת ההורה שלהם תואמים לטקסט שסיפקתם. לדוגמה, הפונקציה parent:Finance מחזירה את המונחים שמקושרים למונחון האב ששמו או התיאור שלו מכילים את הביטוי Finance.
    • מילה נרדפת: מחזירה את רשימת המונחים עם מילה נרדפת שהשם או המזהה שלהם מכילים את הטקסט שסיפקתם. לדוגמה, הפונקציה synonym:Profit מחזירה את התנאים שיש להם מונח נרדף שהשם או המזהה שלו מכילים את הביטוי profit.
    • Contact: מחזירה את המונחים שבהם מנהל הנתונים מופיע כאיש קשר. לדוגמה, contact:alex@example.com מחזירה את הרשומות שמקושרות למונחים עם בעלי הרשאה לניהול נתונים שתואמים ל-alex@example.com.

REST

כדי למצוא מילונים, מונחים ונכסי נתונים מקושרים באמצעות API בארכיטקטורת REST, צריך להירשם לגרסת Preview.

חיפוש נכסי נתונים שמקושרים למונחים

המסוף

  1. נכנסים לדף Glossaries של Knowledge Catalog במסוף Google Cloud .

    מעבר אל Glossaries

  2. בדף מילונים, משתמשים בסרגל הסינון כדי להזין שאילתת חיפוש של טקסט חופשי. הפונקציה מחזירה רשימה של התאמות תואמות במילון המונחים, בקטגוריה ובשמות המונחים.

  3. לוחצים על מונח תואם.

  4. בדף פרטי המונח אפשר לראות את המונחים המקושרים (מילים נרדפות ומונחים קשורים) ואת הרשומות המקושרות (נכסי נתונים) למונח הזה.

  5. כדי לראות את הפרטים של רשומה ב-Knowledge Catalog, לוחצים על הרשומה.

REST

כדי למצוא מילונים, מונחים ונכסי נתונים מקושרים באמצעות API בארכיטקטורת REST, צריך להירשם לגרסת Preview.

ייבוא מילונים וקישורים בין מונחים או בין מונחים לנכסי נתונים

כדי לייבא מילונים וקישורים מכלי קטלוג אחר או לעדכן את המילונים ב-Knowledge Catalog, אפשר לייבא בכמות גדולה מילונים, קטגוריות, מונחים, קישורים בין מונחים, קישורים בין מונחים לבין נכסי נתונים או עמודות באמצעות ה-API בארכיטקטורת REST.

  1. יוצרים את מילון המונחים של היעד.

    REST

    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl -X POST https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/glossaries?glossary_id=GLOSSARY_ID -d "$(cat<<EOF
    
    {
     "displayName": "DISPLAY_NAME",
     "description": "DESCRIPTION"
    }
    EOF
    )"

    מחליפים את מה שכתוב בשדות הבאים:

    • PROJECT_ID: מזהה הפרויקט שבו יוצרים את המילון
    • LOCATION_ID: המיקום שבו רוצים ליצור את המילון
    • GLOSSARY_ID: מזהה המילון
    • DISPLAY_NAME: השם המוצג של המילון
    • DESCRIPTION: תיאור המילון
  2. כדי לייבא קטגוריות, מונחים וקישורים בין מונחים לבין נכסי נתונים במילון המונחים שנוצר, מעלים קבצים לכל אחד מהפריטים האלה לקטגוריה של Cloud Storage. הקבצים האלה הם בפורמט הבא:

    • דוגמה לפורמט של מונחים וקטגוריות במילון מונחים

       {"entry":{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID","entryType":"projects/dataplex-types/locations/global/entryTypes/glossary-category","aspects":{"dataplex-types.global.glossary-category-aspect":{"data":{}},"dataplex-types.global.overview":{"data":{"content":"CONTENT"}},"dataplex-types.global.contacts":{"data":{"identities":[{role: "steward", name: "CONTACT_DISPLAY_NAME", id: "CONTACT_EMAIL"}]}}},"parentEntry":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID","entrySource":{"resource":"projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID","displayName":"CATEGORY_NAME","description":"CATEGORY_DESCRIPTION","ancestors":[{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID","type":"projects/dataplex-types/locations/global/entryTypes/glossary"}]}}}
       {"entry":{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM1_ID","entryType":"projects/dataplex-types/locations/global/entryTypes/glossary-term","aspects":{"dataplex-types.global.glossary-term-aspect":{"data":{}},"dataplex-types.global.overview":{"data":{"content":"TERM1_CONTENT"}},"dataplex-types.global.contacts":{"data":{"identities":[{role: "steward", name: "CONTACT_DISPLAY_NAME", id: "CONTACT_EMAIL"}]}}},"parentEntry":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID","entrySource":{"resource":"projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM1_ID","displayName":"TERM1_DISPLAY_NAME","description":"TERM1_DESCRIPTION","ancestors":[{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID","type":"projects/dataplex-types/locations/global/entryTypes/glossary"},{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID","type":"projects/dataplex-types/locations/global/entryTypes/glossary-category"}]}}}
       {"entry":{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM2_ID","entryType":"projects/dataplex-types/locations/global/entryTypes/glossary-term","aspects":{"dataplex-types.global.glossary-term-aspect":{"data":{}},"dataplex-types.global.overview":{"data":{"content":"TERM1_CONTENT"}},"dataplex-types.global.contacts":{"data":{"identities":[{role: "steward", name: "CONTACT_DISPLAY_NAME", id: "CONTACT_EMAIL"}]}}},"parentEntry":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID","entrySource":{"resource":"projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/terms/TERM2_ID","displayName":"TERM2_DISPLAY_NAME","description":"TERM2_DESCRIPTION","ancestors":[{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID","type":"projects/dataplex-types/locations/global/entryTypes/glossary"},{"name":"projects/PROJECT_NUMBER/locations/LOCATION_ID/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/LOCATION_ID/glossaries/GLOSSARY_ID/categories/CATEGORY_ID","type":"projects/dataplex-types/locations/global/entryTypes/glossary-category"}]}}}
       
    • דוגמה לפורמט של קישורים בין מונחים

       {"entryLink":{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entryLinks/el-import-0606e3f2-8206-4f3a-aba9-32c6196f6048","entryLinkType":"projects/dataplex-types/locations/global/entryLinkTypes/synonym","entryReferences":[{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/global/glossaries/import-glossary/terms/term-1"},{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/global/glossaries/import-glossary/terms/term-2"}]}}
       {"entryLink":{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entryLinks/el-import-2f7408e3-af3d-405d-81bb-861cf9ec5146","entryLinkType":"projects/dataplex-types/locations/global/entryLinkTypes/related","entryReferences":[{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/global/glossaries/import-glossary/terms/term-1"},{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/global/glossaries/import-glossary/terms/term-2"}]}}
       
    • פורמט לדוגמה של קישורים בין מונחים לנכסי נתונים

       projects/PROJECT_NUMBER/locations/us-central1/entryGroups/entry-group-1/entries/entry-1 and term projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/global/glossaries/import-glossary/terms/term-1
       {"entryLink":{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entryLinks/el-import-0606e3f2-8206-4f3a-aba9-32c6196f6048","entryLinkType":"projects/dataplex-types/locations/global/entryLinkTypes/definition","entryReferences":[{"name":"projects/PROJECT_NUMBER/locations/global/entryGroups/@dataplex/entries/projects/PROJECT_NUMBER/locations/global/glossaries/import-glossary/terms/term-1"},{"name":"projects/PROJECT_NUMBER/locations/us-central1/entryGroups/entry-group-1/entries/entry-1"}]}}
       
    # Set GCURL alias
    alias gcurl='curl -H "Authorization: Bearer $(gcloud auth print-access-token)" -H "Content-Type: application/json"'
    
    gcurl https://DATAPLEX_API/metadataJobs?metadata_job_id=JOB_ID -d "$(cat<<EOF
    {
      "type":"IMPORT",
      "import_spec":{
         "log_level":"DEBUG",
         "source_storage_uri":"gs://STORAGE_BUCKET/",
         "entry_sync_mode":"FULL",
         "aspect_sync_mode":"INCREMENTAL",
         "scope":{
            "glossaries": "GLOSSARY_NAME"
         }
      }
    }
    EOF
    )"

    מחליפים את DATAPLEX_API בנקודת הקצה של Dataplex API בפורמט dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID.

  3. אופציונלי: קבלת הסטטוס של הפעולה.

    gcurl https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/operations/operation-OPERATION_ID

    מחליפים את OPERATION_ID במזהה הפעולה.

  4. אופציונלי: קבלת הסטטוס של משימת המטא-נתונים.

    gcurl -X GET https://dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID/metadataJobs/JOB_ID
  5. ייבוא קישורים בין מונחים כמילים נרדפות או כמונחים קשורים.

    gcurl https://DATAPLEX_API/metadataJobs?metadata_job_id=JOB_ID -d "$(cat<<EOF
    {
      "type":"IMPORT",
      "import_spec":{
         "log_level":"DEBUG",
         "source_storage_uri":"gs://STORAGE_BUCKET/",
         "entry_sync_mode":"FULL",
         "aspect_sync_mode":"INCREMENTAL",
         "scope":{
            "entry_groups":[  "projects/PROJECT_ID/locations/LOCATION_ID/entryGroups/@dataplex"
            ],
            "entry_link_types":[
               "projects/dataplex-types/locations/global/entryLinkTypes/synonym",
               "projects/dataplex-types/locations/global/entryLinkTypes/related"
            ],
            "referenced_entry_scopes":[
               "PROJECT_IDS"
            ]
         }
      }
    }
    EOF
    )"

    מחליפים את DATAPLEX_API ב-dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID.

  6. ייבוא קישורים בין מונחים לבין נכסי נתונים או עמודות.

    כדי ליצור קישור בין מונחים במילון המונחים לבין נכסי נתונים, מריצים את עבודת הייבוא לכל קבוצת רשומות שהרשומה של נכס הנתונים שייכת לה. כל הקישורים להגדרות נוצרים בקבוצת ההגדרות הזו.

    gcurl https://DATAPLEX_API/metadataJobs?metadata_job_id=JOB_ID -d "$(cat<<EOF
    {
    "type":"IMPORT",
    "import_spec":{
      "log_level":"DEBUG",
      "source_storage_uri":"gs://STORAGE_BUCKET/",
      "entry_sync_mode":"FULL",
      "aspect_sync_mode":"INCREMENTAL",
      "scope":{
         "entry_groups":[  "projects/PROJECT_ID/locations/ENTRY_GROUP_LOCATION_ID/entryGroups/@dataplex"
         ],
         "entry_link_types":[
            "projects/dataplex-types/locations/global/entryLinkTypes/definition"
         ],
         "referenced_entry_scopes":[
            "PROJECT_IDS"
         ]
      }
    }
    }
    EOF
    )"

    מחליפים את DATAPLEX_API ב-dataplex.googleapis.com/v1/projects/PROJECT_ID/locations/LOCATION_ID.

תמחור

החל מיולי 2026, תהיה עלות על השימוש במילון המונחים הארגוני של Knowledge Catalog, כמו עלות האחסון של מטא-נתונים. מידע על התמחור של אחסון המטא-נתונים ב-Knowledge Catalog

המאמרים הבאים