GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation retrieves information about batched background migrations from the GitLab API. It is useful for administrators who want to monitor or manage background migration tasks in their GitLab instance. For example, an admin can use this node to fetch the status and details of ongoing or completed batched background migrations to ensure database migrations are progressing as expected.

Use Case Examples

  1. An admin uses this node to get a list of all batched background migrations running on the main database.
  2. A DevOps engineer queries the node to check migration statuses on different databases like 'ci' or 'geo' for troubleshooting.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the API request (boolean). Defaults to false.
Authentication The authentication method used for the API request, defaulting to GitLab API key authentication.
baseUrl The base URL of the GitLab instance to which the API request is sent. Defaults to https://gitlab.com.
Method The HTTP method used for the API request. Defaults to GET.
Query Parameters Optional query parameters for the API request, including 'database' to specify which database's migrations to retrieve. Defaults to empty string, with possible values like 'main', 'ci', 'sec', 'embedding', 'geo'.

Output

JSON

  • id - Unique identifier of the batched background migration.
  • job_class_name - The class name of the migration job.
  • table_name - The database table affected by the migration.
  • column_name - The column in the table affected by the migration.
  • interval - The interval at which the migration batches run.
  • batch_size - The size of each batch in the migration.
  • sub_batch_size - The size of sub-batches within each batch.
  • max_batch_size - The maximum allowed batch size.
  • min_value - The minimum value for the migration range.
  • max_value - The maximum value for the migration range.
  • status - Current status of the migration (e.g., active, paused).
  • migration_class_name - The class name of the migration.
  • migration_arguments - Arguments passed to the migration.
  • migration_job_arguments - Arguments passed to the migration job.
  • paused - Boolean indicating if the migration is paused.
  • total_tuple_count - Total number of tuples to migrate.
  • total_batch_count - Total number of batches to process.
  • batched_migration_job_id - Identifier for the batched migration job.
  • batched_migration_job_status - Status of the batched migration job.
  • batched_migration_job_class_name - Class name of the batched migration job.
  • batched_migration_job_arguments - Arguments for the batched migration job.
  • batched_migration_job_table_name - Table name related to the batched migration job.
  • batched_migration_job_column_name - Column name related to the batched migration job.
  • batched_migration_job_interval - Interval for the batched migration job.
  • batched_migration_job_batch_size - Batch size for the batched migration job.
  • batched_migration_job_sub_batch_size - Sub-batch size for the batched migration job.
  • batched_migration_job_max_batch_size - Maximum batch size for the batched migration job.
  • batched_migration_job_min_value - Minimum value for the batched migration job.
  • batched_migration_job_max_value - Maximum value for the batched migration job.

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the GitLab API key credential is correctly configured and has sufficient permissions to access admin batched background migrations.
  • Verify the baseUrl is correct and accessible from the n8n instance.
  • If skipping authentication, confirm the GitLab instance allows unauthenticated access to this endpoint, otherwise the request will fail.
  • Check that the query parameter 'database' is valid and supported by the GitLab instance to avoid errors.

Links

Discussion