From 3898b63f87dcd9d8fa74ad85d73dd6198151f168 Mon Sep 17 00:00:00 2001 From: OCI DEX Release Bot Automation Date: Tue, 6 Aug 2024 06:11:51 +0000 Subject: [PATCH] Releasing version 2.131.0 Co-authored-by: Harsh Kumar --- CHANGELOG.rst | 31 + docs/api/bds.rst | 11 + ....models.BatchingBasedOdhPatchingConfig.rst | 11 + ...eResourcePrincipalConfigurationDetails.rst | 11 + ...ds.models.DomainBasedOdhPatchingConfig.rst | 11 + ....bds.models.DomainBasedPatchingConfigs.rst | 11 + ....models.DowntimeBasedOdhPatchingConfig.rst | 11 + ...s.ForceRefreshResourcePrincipalDetails.rst | 11 + .../oci.bds.models.OdhPatchingConfig.rst | 11 + ...eResourcePrincipalConfigurationDetails.rst | 11 + ....models.ResourcePrincipalConfiguration.rst | 11 + ....ResourcePrincipalConfigurationSummary.rst | 11 + ...eResourcePrincipalConfigurationDetails.rst | 11 + docs/api/devops.rst | 91 + ....devops.models.ApprovalActivitySummary.rst | 11 + .../models/oci.devops.models.ApprovalRule.rst | 11 + ...i.devops.models.ApprovalRuleCollection.rst | 11 + ...i.devops.models.ApprovalRuleMergeCheck.rst | 11 + .../oci.devops.models.BuildMergeCheck.rst | 11 + .../oci.devops.models.BuildRunSnapshot.rst | 11 + ...vops.models.BuildRunSnapshotCollection.rst | 11 + ....devops.models.BuildRunSnapshotSummary.rst | 11 + ...i.devops.models.CommentActivitySummary.rst | 11 + ...ci.devops.models.CommitActivitySummary.rst | 11 + ...models.CommitAnalyticsAuthorCollection.rst | 11 + ...ps.models.CommitAnalyticsAuthorSummary.rst | 11 + .../oci.devops.models.ConflictMergeCheck.rst | 11 + ....models.CreateOrUpdateGitBranchDetails.rst | 11 + ...ops.models.CreateOrUpdateGitRefDetails.rst | 11 + ...ops.models.CreateOrUpdateGitTagDetails.rst | 11 + ...s.CreateOrUpdateProtectedBranchDetails.rst | 11 + ...models.CreatePullRequestCommentDetails.rst | 11 + ...devops.models.CreatePullRequestDetails.rst | 11 + ...ci.devops.models.CreateReviewerDetails.rst | 11 + .../oci.devops.models.DeleteGitRefDetails.rst | 11 + ...ps.models.DeleteProtectedBranchDetails.rst | 11 + ....models.ExecuteMergePullRequestDetails.rst | 11 + ...devops.models.ForkSyncStatusCollection.rst | 11 + ...ci.devops.models.ForkSyncStatusSummary.rst | 11 + ....models.GenericArtifactLocationDetails.rst | 11 + .../oci.devops.models.GenericArtifacts.rst | 11 + .../models/oci.devops.models.MergeCheck.rst | 11 + ...oci.devops.models.MergeCheckCollection.rst | 11 + .../models/oci.devops.models.MergeChecks.rst | 11 + ....devops.models.MergePullRequestDetails.rst | 11 + .../oci.devops.models.MergeSettings.rst | 11 + ...tStorageGenericArtifactLocationDetails.rst | 11 + ...i.devops.models.PatchInsertInstruction.rst | 11 + .../oci.devops.models.PatchInstruction.rst | 11 + ...ci.devops.models.PatchMergeInstruction.rst | 11 + ...oci.devops.models.PatchMoveInstruction.rst | 11 + ...devops.models.PatchProhibitInstruction.rst | 11 + ....devops.models.PatchPullRequestDetails.rst | 11 + ...i.devops.models.PatchRemoveInstruction.rst | 11 + ....devops.models.PatchReplaceInstruction.rst | 11 + ....devops.models.PatchRequireInstruction.rst | 11 + .../oci.devops.models.PrincipalDetails.rst | 11 + ...s.models.ProjectNotificationPreference.rst | 11 + ...evops.models.ProjectRepositorySettings.rst | 11 + .../oci.devops.models.ProtectedBranch.rst | 11 + ...evops.models.ProtectedBranchCollection.rst | 11 + ...i.devops.models.ProtectedBranchSummary.rst | 11 + .../models/oci.devops.models.PullRequest.rst | 11 + ...s.models.PullRequestActivityCollection.rst | 11 + ...vops.models.PullRequestActivitySummary.rst | 11 + ...ci.devops.models.PullRequestAttachment.rst | 11 + ...models.PullRequestAttachmentCollection.rst | 11 + ...ps.models.PullRequestAttachmentSummary.rst | 11 + ...ops.models.PullRequestAuthorCollection.rst | 11 + ...devops.models.PullRequestAuthorSummary.rst | 11 + ...models.PullRequestChangeSummaryMetrics.rst | 11 + ...ci.devops.models.PullRequestCollection.rst | 11 + .../oci.devops.models.PullRequestComment.rst | 11 + ...ps.models.PullRequestCommentCollection.rst | 11 + ...odels.PullRequestCommentLikeCollection.rst | 11 + ...evops.models.PullRequestCommentSummary.rst | 11 + ...models.PullRequestFileChangeCollection.rst | 11 + ...ps.models.PullRequestFileChangeSummary.rst | 11 + ...ls.PullRequestLifecycleActivitySummary.rst | 11 + ...dels.PullRequestNotificationPreference.rst | 11 + .../oci.devops.models.PullRequestSummary.rst | 11 + ...vops.models.RepositoryAnalyticsDetails.rst | 11 + ...ops.models.RepositoryMetricAggregation.rst | 11 + ....devops.models.RepositoryMetricSummary.rst | 11 + ...odels.RepositoryNotificationPreference.rst | 11 + .../oci.devops.models.RepositorySettings.rst | 11 + ...devops.models.ReviewPullRequestDetails.rst | 11 + .../models/oci.devops.models.Reviewer.rst | 11 + ....devops.models.ReviewerActivitySummary.rst | 11 + .../models/oci.devops.models.StageOutput.rst | 11 + ...arizeProjectRepositoryAnalyticsDetails.rst | 11 + ...ls.SummarizeRepositoryAnalyticsDetails.rst | 11 + ...ci.devops.models.SyncRepositoryDetails.rst | 11 + .../oci.devops.models.TestReportOutput.rst | 11 + ...evops.models.UpdateApprovalRuleDetails.rst | 11 + ...ls.UpdateApprovalRuleDetailsCollection.rst | 11 + ...teProjectNotificationPreferenceDetails.rst | 11 + ...UpdateProjectRepositorySettingsDetails.rst | 11 + ...models.UpdatePullRequestCommentDetails.rst | 11 + ...devops.models.UpdatePullRequestDetails.rst | 11 + ...llRequestNotificationPreferenceDetails.rst | 11 + ...epositoryNotificationPreferenceDetails.rst | 11 + ...models.UpdateRepositorySettingsDetails.rst | 11 + ...ci.devops.models.UpdateReviewerDetails.rst | 11 + ...models.ValidateMergePullRequestDetails.rst | 11 + docs/api/jms.rst | 12 + ...ci.jms.models.AgentInstallerCollection.rst | 11 + .../oci.jms.models.AgentInstallerSummary.rst | 11 + .../oci.jms.models.CreateJmsPluginDetails.rst | 11 + ...oyedApplicationMigrationAnalysesTarget.rst | 11 + ...els.DeployedApplicationWorkItemDetails.rst | 11 + ...rateAgentInstallerConfigurationDetails.rst | 11 + ...dels.GenerateLoadPipelineScriptDetails.rst | 11 + .../jms/models/oci.jms.models.JmsPlugin.rst | 11 + .../oci.jms.models.JmsPluginCollection.rst | 11 + .../oci.jms.models.JmsPluginSummary.rst | 11 + ...yedApplicationMigrationAnalysesDetails.rst | 11 + .../oci.jms.models.UpdateJmsPluginDetails.rst | 11 + docs/api/psql.rst | 3 + .../oci.psql.models.ShapeMemoryOptions.rst | 11 + .../oci.psql.models.ShapeOcpuOptions.rst | 11 + .../oci.psql.models.UpdateNetworkDetails.rst | 11 + src/oci/bds/bds_client.py | 762 +- .../bds/bds_client_composite_operations.py | 177 + src/oci/bds/models/__init__.py | 22 + .../models/auto_scale_policy_metric_rule.py | 14 +- .../batching_based_odh_patching_config.py | 113 + .../models/batching_based_patching_configs.py | 4 +- ...esource_principal_configuration_details.py | 134 + .../domain_based_odh_patching_config.py | 82 + .../models/domain_based_patching_configs.py | 113 + .../downtime_based_odh_patching_config.py | 51 + .../models/downtime_based_patching_configs.py | 2 +- ...orce_refresh_resource_principal_details.py | 72 + src/oci/bds/models/install_patch_details.py | 31 +- src/oci/bds/models/node.py | 31 + src/oci/bds/models/odh_patching_config.py | 117 + src/oci/bds/models/patching_configs.py | 16 +- ...esource_principal_configuration_details.py | 72 + .../resource_principal_configuration.py | 352 + ...esource_principal_configuration_summary.py | 289 + ...esource_principal_configuration_details.py | 103 + src/oci/bds/models/work_request.py | 22 +- src/oci/devops/devops_client.py | 11154 ++++++++++++---- .../devops_client_composite_operations.py | 443 + src/oci/devops/models/__init__.py | 182 + .../models/approval_activity_summary.py | 127 + src/oci/devops/models/approval_rule.py | 165 + .../devops/models/approval_rule_collection.py | 72 + .../models/approval_rule_merge_check.py | 270 + src/oci/devops/models/build_merge_check.py | 144 + src/oci/devops/models/build_run_snapshot.py | 329 + .../models/build_run_snapshot_collection.py | 72 + .../models/build_run_snapshot_summary.py | 297 + .../devops/models/comment_activity_summary.py | 110 + .../devops/models/commit_activity_summary.py | 141 + .../commit_analytics_author_collection.py | 72 + .../models/commit_analytics_author_summary.py | 103 + src/oci/devops/models/conflict_merge_check.py | 99 + .../create_or_update_git_branch_details.py | 89 + .../create_or_update_git_ref_details.py | 140 + .../create_or_update_git_tag_details.py | 89 + ...eate_or_update_protected_branch_details.py | 122 + .../create_pull_request_comment_details.py | 227 + .../models/create_pull_request_details.py | 328 + .../models/create_repository_details.py | 33 + .../devops/models/create_reviewer_details.py | 72 + .../devops/models/delete_git_ref_details.py | 72 + .../models/delete_protected_branch_details.py | 72 + .../devops/models/deploy_artifact_source.py | 10 +- .../models/devops_code_repository_filter.py | 14 +- ...evops_code_repository_filter_attributes.py | 31 + .../execute_merge_pull_request_details.py | 196 + .../models/fork_sync_status_collection.py | 72 + .../devops/models/fork_sync_status_summary.py | 154 + .../generic_artifact_location_details.py | 101 + src/oci/devops/models/generic_artifacts.py | 116 + .../models/generic_deploy_artifact_source.py | 2 +- .../helm_command_spec_artifact_source.py | 2 +- .../helm_repository_deploy_artifact_source.py | 2 +- .../models/inline_deploy_artifact_source.py | 2 +- src/oci/devops/models/merge_check.py | 117 + .../devops/models/merge_check_collection.py | 145 + src/oci/devops/models/merge_checks.py | 88 + .../models/merge_pull_request_details.py | 109 + src/oci/devops/models/merge_settings.py | 139 + .../devops/models/mirror_repository_config.py | 4 +- ...orage_generic_artifact_location_details.py | 175 + .../models/ocir_deploy_artifact_source.py | 2 +- .../devops/models/patch_insert_instruction.py | 171 + src/oci/devops/models/patch_instruction.py | 184 + .../devops/models/patch_merge_instruction.py | 97 + .../devops/models/patch_move_instruction.py | 147 + .../models/patch_prohibit_instruction.py | 100 + .../models/patch_pull_request_details.py | 72 + .../devops/models/patch_remove_instruction.py | 59 + .../models/patch_replace_instruction.py | 92 + .../models/patch_require_instruction.py | 99 + src/oci/devops/models/principal_details.py | 209 + .../models/project_notification_preference.py | 154 + .../models/project_repository_settings.py | 95 + src/oci/devops/models/protected_branch.py | 189 + .../models/protected_branch_collection.py | 72 + .../devops/models/protected_branch_summary.py | 224 + src/oci/devops/models/pull_request.py | 814 ++ .../pull_request_activity_collection.py | 72 + .../models/pull_request_activity_summary.py | 253 + .../devops/models/pull_request_attachment.py | 196 + .../pull_request_attachment_collection.py | 72 + .../models/pull_request_attachment_summary.py | 196 + .../models/pull_request_author_collection.py | 72 + .../models/pull_request_author_summary.py | 68 + .../pull_request_change_summary_metrics.py | 134 + .../devops/models/pull_request_collection.py | 72 + src/oci/devops/models/pull_request_comment.py | 581 + .../models/pull_request_comment_collection.py | 72 + .../pull_request_comment_like_collection.py | 103 + .../models/pull_request_comment_summary.py | 533 + .../pull_request_file_change_collection.py | 72 + .../pull_request_file_change_summary.py | 456 + ...pull_request_lifecycle_activity_summary.py | 135 + .../pull_request_notification_preference.py | 154 + src/oci/devops/models/pull_request_summary.py | 669 + src/oci/devops/models/repository.py | 53 +- .../models/repository_analytics_details.py | 318 + .../models/repository_metric_aggregation.py | 72 + .../models/repository_metric_summary.py | 281 + .../repository_notification_preference.py | 158 + src/oci/devops/models/repository_settings.py | 122 + src/oci/devops/models/repository_summary.py | 33 + .../models/review_pull_request_details.py | 88 + src/oci/devops/models/reviewer.py | 256 + .../models/reviewer_activity_summary.py | 141 + src/oci/devops/models/stage_output.py | 140 + ...ze_project_repository_analytics_details.py | 318 + .../summarize_repository_analytics_details.py | 318 + .../devops/models/sync_repository_details.py | 103 + src/oci/devops/models/test_report_output.py | 89 + .../models/update_approval_rule_details.py | 165 + ...update_approval_rule_details_collection.py | 72 + ...project_notification_preference_details.py | 72 + ...ate_project_repository_settings_details.py | 95 + .../update_pull_request_comment_details.py | 72 + .../models/update_pull_request_details.py | 235 + ...request_notification_preference_details.py | 72 + .../models/update_repository_details.py | 2 + ...ository_notification_preference_details.py | 72 + .../update_repository_settings_details.py | 122 + .../devops/models/update_reviewer_details.py | 72 + .../validate_merge_pull_request_details.py | 51 + src/oci/devops/models/work_request.py | 34 +- src/oci/devops/models/work_request_summary.py | 34 +- src/oci/em_warehouse/em_warehouse_client.py | 26 +- src/oci/jms/java_management_service_client.py | 1518 ++- ...ent_service_client_composite_operations.py | 194 + src/oci/jms/models/__init__.py | 24 + .../jms/models/agent_installer_collection.py | 72 + src/oci/jms/models/agent_installer_summary.py | 411 + .../application_installation_usage_summary.py | 62 + src/oci/jms/models/application_usage.py | 39 +- .../models/application_work_item_details.py | 2 +- src/oci/jms/models/basic_work_item_details.py | 2 +- .../jms/models/create_jms_plugin_details.py | 220 + src/oci/jms/models/crypto_analysis_result.py | 62 + .../models/crypto_analysis_result_summary.py | 62 + ..._application_installation_usage_summary.py | 33 +- ...d_application_migration_analyses_target.py | 197 + .../jms/models/deployed_application_usage.py | 31 + .../deployed_application_work_item_details.py | 183 + src/oci/jms/models/export_setting.py | 6 +- .../jms/models/fleet_agent_configuration.py | 62 + ...e_agent_installer_configuration_details.py | 111 + .../generate_load_pipeline_script_details.py | 165 + src/oci/jms/models/installation_site.py | 10 +- src/oci/jms/models/java_artifact.py | 4 +- src/oci/jms/models/java_family.py | 39 +- src/oci/jms/models/java_family_summary.py | 39 +- .../models/java_migration_analysis_target.py | 37 +- .../jms/models/java_server_instance_usage.py | 31 + src/oci/jms/models/jms_plugin.py | 698 + src/oci/jms/models/jms_plugin_collection.py | 72 + src/oci/jms/models/jms_plugin_summary.py | 698 + src/oci/jms/models/lcm_work_item_details.py | 2 +- src/oci/jms/models/library_usage.py | 66 +- src/oci/jms/models/managed_instance_usage.py | 41 +- src/oci/jms/models/operating_system.py | 4 +- .../performance_tuning_analysis_result.py | 8 +- ...formance_tuning_analysis_result_summary.py | 8 +- ..._application_migration_analyses_details.py | 73 + .../models/update_export_setting_details.py | 6 +- ...pdate_fleet_agent_configuration_details.py | 62 + .../jms/models/update_jms_plugin_details.py | 150 + src/oci/jms/models/work_item_details.py | 14 +- src/oci/jms/models/work_item_summary.py | 10 +- .../java_download_client.py | 10 +- .../generate_artifact_download_url_details.py | 35 + .../create_custom_software_source_details.py | 41 + ...ersioned_custom_software_source_details.py | 41 + .../models/custom_software_source.py | 41 + .../update_custom_software_source_details.py | 45 +- .../versioned_custom_software_source.py | 41 + .../software_source_client.py | 2 +- src/oci/psql/models/__init__.py | 6 + src/oci/psql/models/backup.py | 4 +- src/oci/psql/models/backup_summary.py | 4 +- src/oci/psql/models/configuration.py | 148 +- src/oci/psql/models/configuration_summary.py | 77 +- .../models/create_configuration_details.py | 81 +- .../psql/models/create_db_system_details.py | 2 +- src/oci/psql/models/default_configuration.py | 105 +- .../models/default_configuration_summary.py | 81 +- .../psql/models/management_policy_details.py | 12 +- src/oci/psql/models/shape_memory_options.py | 196 + src/oci/psql/models/shape_ocpu_options.py | 103 + src/oci/psql/models/shape_summary.py | 89 +- .../psql/models/update_db_system_details.py | 122 + src/oci/psql/models/update_network_details.py | 76 + src/oci/psql/postgresql_client.py | 4 +- src/oci/regions_definitions.py | 3 + src/oci/version.py | 2 +- 320 files changed, 34818 insertions(+), 2974 deletions(-) create mode 100644 docs/api/bds/models/oci.bds.models.BatchingBasedOdhPatchingConfig.rst create mode 100644 docs/api/bds/models/oci.bds.models.CreateResourcePrincipalConfigurationDetails.rst create mode 100644 docs/api/bds/models/oci.bds.models.DomainBasedOdhPatchingConfig.rst create mode 100644 docs/api/bds/models/oci.bds.models.DomainBasedPatchingConfigs.rst create mode 100644 docs/api/bds/models/oci.bds.models.DowntimeBasedOdhPatchingConfig.rst create mode 100644 docs/api/bds/models/oci.bds.models.ForceRefreshResourcePrincipalDetails.rst create mode 100644 docs/api/bds/models/oci.bds.models.OdhPatchingConfig.rst create mode 100644 docs/api/bds/models/oci.bds.models.RemoveResourcePrincipalConfigurationDetails.rst create mode 100644 docs/api/bds/models/oci.bds.models.ResourcePrincipalConfiguration.rst create mode 100644 docs/api/bds/models/oci.bds.models.ResourcePrincipalConfigurationSummary.rst create mode 100644 docs/api/bds/models/oci.bds.models.UpdateResourcePrincipalConfigurationDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.ApprovalActivitySummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.ApprovalRule.rst create mode 100644 docs/api/devops/models/oci.devops.models.ApprovalRuleCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.ApprovalRuleMergeCheck.rst create mode 100644 docs/api/devops/models/oci.devops.models.BuildMergeCheck.rst create mode 100644 docs/api/devops/models/oci.devops.models.BuildRunSnapshot.rst create mode 100644 docs/api/devops/models/oci.devops.models.BuildRunSnapshotCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.BuildRunSnapshotSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.CommentActivitySummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.CommitActivitySummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.ConflictMergeCheck.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreateOrUpdateGitBranchDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreateOrUpdateGitRefDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreateOrUpdateGitTagDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreateOrUpdateProtectedBranchDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreatePullRequestCommentDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreatePullRequestDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.CreateReviewerDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.DeleteGitRefDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.DeleteProtectedBranchDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.ExecuteMergePullRequestDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.ForkSyncStatusCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.ForkSyncStatusSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.GenericArtifactLocationDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.GenericArtifacts.rst create mode 100644 docs/api/devops/models/oci.devops.models.MergeCheck.rst create mode 100644 docs/api/devops/models/oci.devops.models.MergeCheckCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.MergeChecks.rst create mode 100644 docs/api/devops/models/oci.devops.models.MergePullRequestDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.MergeSettings.rst create mode 100644 docs/api/devops/models/oci.devops.models.ObjectStorageGenericArtifactLocationDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchInsertInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchMergeInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchMoveInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchProhibitInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchPullRequestDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchRemoveInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchReplaceInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PatchRequireInstruction.rst create mode 100644 docs/api/devops/models/oci.devops.models.PrincipalDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.ProjectNotificationPreference.rst create mode 100644 docs/api/devops/models/oci.devops.models.ProjectRepositorySettings.rst create mode 100644 docs/api/devops/models/oci.devops.models.ProtectedBranch.rst create mode 100644 docs/api/devops/models/oci.devops.models.ProtectedBranchCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.ProtectedBranchSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequest.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestActivityCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestActivitySummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestAttachment.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestAttachmentCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestAttachmentSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestAuthorCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestAuthorSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestChangeSummaryMetrics.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestComment.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestCommentCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestCommentLikeCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestCommentSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestFileChangeCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestFileChangeSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestLifecycleActivitySummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestNotificationPreference.rst create mode 100644 docs/api/devops/models/oci.devops.models.PullRequestSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.RepositoryAnalyticsDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.RepositoryMetricAggregation.rst create mode 100644 docs/api/devops/models/oci.devops.models.RepositoryMetricSummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.RepositoryNotificationPreference.rst create mode 100644 docs/api/devops/models/oci.devops.models.RepositorySettings.rst create mode 100644 docs/api/devops/models/oci.devops.models.ReviewPullRequestDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.Reviewer.rst create mode 100644 docs/api/devops/models/oci.devops.models.ReviewerActivitySummary.rst create mode 100644 docs/api/devops/models/oci.devops.models.StageOutput.rst create mode 100644 docs/api/devops/models/oci.devops.models.SummarizeProjectRepositoryAnalyticsDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.SummarizeRepositoryAnalyticsDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.SyncRepositoryDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.TestReportOutput.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetailsCollection.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateProjectNotificationPreferenceDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateProjectRepositorySettingsDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdatePullRequestCommentDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdatePullRequestDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdatePullRequestNotificationPreferenceDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateRepositoryNotificationPreferenceDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateRepositorySettingsDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.UpdateReviewerDetails.rst create mode 100644 docs/api/devops/models/oci.devops.models.ValidateMergePullRequestDetails.rst create mode 100644 docs/api/jms/models/oci.jms.models.AgentInstallerCollection.rst create mode 100644 docs/api/jms/models/oci.jms.models.AgentInstallerSummary.rst create mode 100644 docs/api/jms/models/oci.jms.models.CreateJmsPluginDetails.rst create mode 100644 docs/api/jms/models/oci.jms.models.DeployedApplicationMigrationAnalysesTarget.rst create mode 100644 docs/api/jms/models/oci.jms.models.DeployedApplicationWorkItemDetails.rst create mode 100644 docs/api/jms/models/oci.jms.models.GenerateAgentInstallerConfigurationDetails.rst create mode 100644 docs/api/jms/models/oci.jms.models.GenerateLoadPipelineScriptDetails.rst create mode 100644 docs/api/jms/models/oci.jms.models.JmsPlugin.rst create mode 100644 docs/api/jms/models/oci.jms.models.JmsPluginCollection.rst create mode 100644 docs/api/jms/models/oci.jms.models.JmsPluginSummary.rst create mode 100644 docs/api/jms/models/oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails.rst create mode 100644 docs/api/jms/models/oci.jms.models.UpdateJmsPluginDetails.rst create mode 100644 docs/api/psql/models/oci.psql.models.ShapeMemoryOptions.rst create mode 100644 docs/api/psql/models/oci.psql.models.ShapeOcpuOptions.rst create mode 100644 docs/api/psql/models/oci.psql.models.UpdateNetworkDetails.rst create mode 100644 src/oci/bds/models/batching_based_odh_patching_config.py create mode 100644 src/oci/bds/models/create_resource_principal_configuration_details.py create mode 100644 src/oci/bds/models/domain_based_odh_patching_config.py create mode 100644 src/oci/bds/models/domain_based_patching_configs.py create mode 100644 src/oci/bds/models/downtime_based_odh_patching_config.py create mode 100644 src/oci/bds/models/force_refresh_resource_principal_details.py create mode 100644 src/oci/bds/models/odh_patching_config.py create mode 100644 src/oci/bds/models/remove_resource_principal_configuration_details.py create mode 100644 src/oci/bds/models/resource_principal_configuration.py create mode 100644 src/oci/bds/models/resource_principal_configuration_summary.py create mode 100644 src/oci/bds/models/update_resource_principal_configuration_details.py create mode 100644 src/oci/devops/models/approval_activity_summary.py create mode 100644 src/oci/devops/models/approval_rule.py create mode 100644 src/oci/devops/models/approval_rule_collection.py create mode 100644 src/oci/devops/models/approval_rule_merge_check.py create mode 100644 src/oci/devops/models/build_merge_check.py create mode 100644 src/oci/devops/models/build_run_snapshot.py create mode 100644 src/oci/devops/models/build_run_snapshot_collection.py create mode 100644 src/oci/devops/models/build_run_snapshot_summary.py create mode 100644 src/oci/devops/models/comment_activity_summary.py create mode 100644 src/oci/devops/models/commit_activity_summary.py create mode 100644 src/oci/devops/models/commit_analytics_author_collection.py create mode 100644 src/oci/devops/models/commit_analytics_author_summary.py create mode 100644 src/oci/devops/models/conflict_merge_check.py create mode 100644 src/oci/devops/models/create_or_update_git_branch_details.py create mode 100644 src/oci/devops/models/create_or_update_git_ref_details.py create mode 100644 src/oci/devops/models/create_or_update_git_tag_details.py create mode 100644 src/oci/devops/models/create_or_update_protected_branch_details.py create mode 100644 src/oci/devops/models/create_pull_request_comment_details.py create mode 100644 src/oci/devops/models/create_pull_request_details.py create mode 100644 src/oci/devops/models/create_reviewer_details.py create mode 100644 src/oci/devops/models/delete_git_ref_details.py create mode 100644 src/oci/devops/models/delete_protected_branch_details.py create mode 100644 src/oci/devops/models/execute_merge_pull_request_details.py create mode 100644 src/oci/devops/models/fork_sync_status_collection.py create mode 100644 src/oci/devops/models/fork_sync_status_summary.py create mode 100644 src/oci/devops/models/generic_artifact_location_details.py create mode 100644 src/oci/devops/models/generic_artifacts.py create mode 100644 src/oci/devops/models/merge_check.py create mode 100644 src/oci/devops/models/merge_check_collection.py create mode 100644 src/oci/devops/models/merge_checks.py create mode 100644 src/oci/devops/models/merge_pull_request_details.py create mode 100644 src/oci/devops/models/merge_settings.py create mode 100644 src/oci/devops/models/object_storage_generic_artifact_location_details.py create mode 100644 src/oci/devops/models/patch_insert_instruction.py create mode 100644 src/oci/devops/models/patch_instruction.py create mode 100644 src/oci/devops/models/patch_merge_instruction.py create mode 100644 src/oci/devops/models/patch_move_instruction.py create mode 100644 src/oci/devops/models/patch_prohibit_instruction.py create mode 100644 src/oci/devops/models/patch_pull_request_details.py create mode 100644 src/oci/devops/models/patch_remove_instruction.py create mode 100644 src/oci/devops/models/patch_replace_instruction.py create mode 100644 src/oci/devops/models/patch_require_instruction.py create mode 100644 src/oci/devops/models/principal_details.py create mode 100644 src/oci/devops/models/project_notification_preference.py create mode 100644 src/oci/devops/models/project_repository_settings.py create mode 100644 src/oci/devops/models/protected_branch.py create mode 100644 src/oci/devops/models/protected_branch_collection.py create mode 100644 src/oci/devops/models/protected_branch_summary.py create mode 100644 src/oci/devops/models/pull_request.py create mode 100644 src/oci/devops/models/pull_request_activity_collection.py create mode 100644 src/oci/devops/models/pull_request_activity_summary.py create mode 100644 src/oci/devops/models/pull_request_attachment.py create mode 100644 src/oci/devops/models/pull_request_attachment_collection.py create mode 100644 src/oci/devops/models/pull_request_attachment_summary.py create mode 100644 src/oci/devops/models/pull_request_author_collection.py create mode 100644 src/oci/devops/models/pull_request_author_summary.py create mode 100644 src/oci/devops/models/pull_request_change_summary_metrics.py create mode 100644 src/oci/devops/models/pull_request_collection.py create mode 100644 src/oci/devops/models/pull_request_comment.py create mode 100644 src/oci/devops/models/pull_request_comment_collection.py create mode 100644 src/oci/devops/models/pull_request_comment_like_collection.py create mode 100644 src/oci/devops/models/pull_request_comment_summary.py create mode 100644 src/oci/devops/models/pull_request_file_change_collection.py create mode 100644 src/oci/devops/models/pull_request_file_change_summary.py create mode 100644 src/oci/devops/models/pull_request_lifecycle_activity_summary.py create mode 100644 src/oci/devops/models/pull_request_notification_preference.py create mode 100644 src/oci/devops/models/pull_request_summary.py create mode 100644 src/oci/devops/models/repository_analytics_details.py create mode 100644 src/oci/devops/models/repository_metric_aggregation.py create mode 100644 src/oci/devops/models/repository_metric_summary.py create mode 100644 src/oci/devops/models/repository_notification_preference.py create mode 100644 src/oci/devops/models/repository_settings.py create mode 100644 src/oci/devops/models/review_pull_request_details.py create mode 100644 src/oci/devops/models/reviewer.py create mode 100644 src/oci/devops/models/reviewer_activity_summary.py create mode 100644 src/oci/devops/models/stage_output.py create mode 100644 src/oci/devops/models/summarize_project_repository_analytics_details.py create mode 100644 src/oci/devops/models/summarize_repository_analytics_details.py create mode 100644 src/oci/devops/models/sync_repository_details.py create mode 100644 src/oci/devops/models/test_report_output.py create mode 100644 src/oci/devops/models/update_approval_rule_details.py create mode 100644 src/oci/devops/models/update_approval_rule_details_collection.py create mode 100644 src/oci/devops/models/update_project_notification_preference_details.py create mode 100644 src/oci/devops/models/update_project_repository_settings_details.py create mode 100644 src/oci/devops/models/update_pull_request_comment_details.py create mode 100644 src/oci/devops/models/update_pull_request_details.py create mode 100644 src/oci/devops/models/update_pull_request_notification_preference_details.py create mode 100644 src/oci/devops/models/update_repository_notification_preference_details.py create mode 100644 src/oci/devops/models/update_repository_settings_details.py create mode 100644 src/oci/devops/models/update_reviewer_details.py create mode 100644 src/oci/devops/models/validate_merge_pull_request_details.py create mode 100644 src/oci/jms/models/agent_installer_collection.py create mode 100644 src/oci/jms/models/agent_installer_summary.py create mode 100644 src/oci/jms/models/create_jms_plugin_details.py create mode 100644 src/oci/jms/models/deployed_application_migration_analyses_target.py create mode 100644 src/oci/jms/models/deployed_application_work_item_details.py create mode 100644 src/oci/jms/models/generate_agent_installer_configuration_details.py create mode 100644 src/oci/jms/models/generate_load_pipeline_script_details.py create mode 100644 src/oci/jms/models/jms_plugin.py create mode 100644 src/oci/jms/models/jms_plugin_collection.py create mode 100644 src/oci/jms/models/jms_plugin_summary.py create mode 100644 src/oci/jms/models/request_deployed_application_migration_analyses_details.py create mode 100644 src/oci/jms/models/update_jms_plugin_details.py create mode 100644 src/oci/psql/models/shape_memory_options.py create mode 100644 src/oci/psql/models/shape_ocpu_options.py create mode 100644 src/oci/psql/models/update_network_details.py diff --git a/CHANGELOG.rst b/CHANGELOG.rst index f5b49214e..e0ede7d9d 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -3,6 +3,37 @@ Change Log All notable changes to this project will be documented in this file. The format is based on `Keep a Changelog `_. +==================== +2.131.0 - 09/16/2023 +==================== + +Added +----- +* Support for calling Oracle Cloud Infrastructure services in the me-riyadh-1 region +* Support for vertically scaling a Database system in the PostgreSQL service +* Support for flex shapes in the PostgreSQL service +* Support for new fork repository feature in the Source Code Management service +* Support for Developer Charts in the Source Code Management service +* Support for pull requests and merge in Source Code Management service +* Support for limiting custom and versioned custom software source content to the latest package versions in the OS Management service +* Support for Open Data Hub (ODH) patching in a staged manner in the Big Data service +* Support for Autoscale Memory Utilization in the Big Data service +* Support for Resource Principal configuration feature in the Big Data service +* Support for a new optional parameter compartment ID in the Java Management service +* Support for Agent Installer in the Java Management service +* Support for Java migration analysis request of deployed applications in the Java Management service +* Support for JmsPlugin in the Java Management service +* Support for improved cryptographic analysis result listing in the Java Management service +* Support for improved fleet agent configuration setting in the Java Management service +* Support for improved Java migration analysis result listing in the Java Management service +* Support for improved library usage summary in the Java Management service +* Support for improved performance tuning analysis result listing in the Java Management service +* Support for improved work request listing in the Java Management service + +Breaking +-------- +* Parameter `credentials` is now required for model `CreateDbSystemDetails` in the PostgreSQL service + ==================== 2.130.0 - 2024-07-30 ==================== diff --git a/docs/api/bds.rst b/docs/api/bds.rst index 84dcbeb66..f3415884f 100644 --- a/docs/api/bds.rst +++ b/docs/api/bds.rst @@ -38,6 +38,7 @@ Bds oci.bds.models.AutoScalingConfiguration oci.bds.models.AutoScalingConfigurationSummary oci.bds.models.BackupNodeDetails + oci.bds.models.BatchingBasedOdhPatchingConfig oci.bds.models.BatchingBasedPatchingConfigs oci.bds.models.BdsApiKey oci.bds.models.BdsApiKeySummary @@ -58,13 +59,18 @@ Bds oci.bds.models.CreateNodeBackupConfigurationDetails oci.bds.models.CreateNodeDetails oci.bds.models.CreateNodeReplaceConfigurationDetails + oci.bds.models.CreateResourcePrincipalConfigurationDetails oci.bds.models.DayBasedHorizontalScalingScheduleDetails oci.bds.models.DayBasedVerticalScalingScheduleDetails oci.bds.models.DefaultError oci.bds.models.DisableCertificateDetails + oci.bds.models.DomainBasedOdhPatchingConfig + oci.bds.models.DomainBasedPatchingConfigs + oci.bds.models.DowntimeBasedOdhPatchingConfig oci.bds.models.DowntimeBasedPatchingConfigs oci.bds.models.EnableCertificateDetails oci.bds.models.ExecuteBootstrapScriptDetails + oci.bds.models.ForceRefreshResourcePrincipalDetails oci.bds.models.HorizontalScalingScheduleDetails oci.bds.models.HostCertDetails oci.bds.models.HostSpecificCertificateDetails @@ -89,6 +95,7 @@ Bds oci.bds.models.NodeReplaceConfiguration oci.bds.models.NodeReplaceConfigurationSummary oci.bds.models.NodeTypeLevelDetails + oci.bds.models.OdhPatchingConfig oci.bds.models.OsPatchDetails oci.bds.models.OsPatchPackageSummary oci.bds.models.OsPatchSummary @@ -100,8 +107,11 @@ Bds oci.bds.models.RemoveKafkaDetails oci.bds.models.RemoveNodeDetails oci.bds.models.RemoveNodeReplaceConfigurationDetails + oci.bds.models.RemoveResourcePrincipalConfigurationDetails oci.bds.models.RenewCertificateDetails oci.bds.models.ReplaceNodeDetails + oci.bds.models.ResourcePrincipalConfiguration + oci.bds.models.ResourcePrincipalConfigurationSummary oci.bds.models.RestartNodeDetails oci.bds.models.ScheduleBasedHorizontalScalingPolicyDetails oci.bds.models.ScheduleBasedVerticalScalingPolicyDetails @@ -120,6 +130,7 @@ Bds oci.bds.models.UpdateMetricBasedVerticalScalingPolicyDetails oci.bds.models.UpdateNodeBackupConfigurationDetails oci.bds.models.UpdateNodeReplaceConfigurationDetails + oci.bds.models.UpdateResourcePrincipalConfigurationDetails oci.bds.models.UpdateScheduleBasedHorizontalScalingPolicyDetails oci.bds.models.UpdateScheduleBasedVerticalScalingPolicyDetails oci.bds.models.VerticalScalingScheduleDetails diff --git a/docs/api/bds/models/oci.bds.models.BatchingBasedOdhPatchingConfig.rst b/docs/api/bds/models/oci.bds.models.BatchingBasedOdhPatchingConfig.rst new file mode 100644 index 000000000..fac749c07 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.BatchingBasedOdhPatchingConfig.rst @@ -0,0 +1,11 @@ +BatchingBasedOdhPatchingConfig +============================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: BatchingBasedOdhPatchingConfig + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.CreateResourcePrincipalConfigurationDetails.rst b/docs/api/bds/models/oci.bds.models.CreateResourcePrincipalConfigurationDetails.rst new file mode 100644 index 000000000..448294eb9 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.CreateResourcePrincipalConfigurationDetails.rst @@ -0,0 +1,11 @@ +CreateResourcePrincipalConfigurationDetails +=========================================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: CreateResourcePrincipalConfigurationDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.DomainBasedOdhPatchingConfig.rst b/docs/api/bds/models/oci.bds.models.DomainBasedOdhPatchingConfig.rst new file mode 100644 index 000000000..c4a214892 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.DomainBasedOdhPatchingConfig.rst @@ -0,0 +1,11 @@ +DomainBasedOdhPatchingConfig +============================ + +.. currentmodule:: oci.bds.models + +.. autoclass:: DomainBasedOdhPatchingConfig + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.DomainBasedPatchingConfigs.rst b/docs/api/bds/models/oci.bds.models.DomainBasedPatchingConfigs.rst new file mode 100644 index 000000000..6bbc2807f --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.DomainBasedPatchingConfigs.rst @@ -0,0 +1,11 @@ +DomainBasedPatchingConfigs +========================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: DomainBasedPatchingConfigs + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.DowntimeBasedOdhPatchingConfig.rst b/docs/api/bds/models/oci.bds.models.DowntimeBasedOdhPatchingConfig.rst new file mode 100644 index 000000000..e59285ed3 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.DowntimeBasedOdhPatchingConfig.rst @@ -0,0 +1,11 @@ +DowntimeBasedOdhPatchingConfig +============================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: DowntimeBasedOdhPatchingConfig + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.ForceRefreshResourcePrincipalDetails.rst b/docs/api/bds/models/oci.bds.models.ForceRefreshResourcePrincipalDetails.rst new file mode 100644 index 000000000..85489e3cf --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.ForceRefreshResourcePrincipalDetails.rst @@ -0,0 +1,11 @@ +ForceRefreshResourcePrincipalDetails +==================================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: ForceRefreshResourcePrincipalDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.OdhPatchingConfig.rst b/docs/api/bds/models/oci.bds.models.OdhPatchingConfig.rst new file mode 100644 index 000000000..f7f3c2de8 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.OdhPatchingConfig.rst @@ -0,0 +1,11 @@ +OdhPatchingConfig +================= + +.. currentmodule:: oci.bds.models + +.. autoclass:: OdhPatchingConfig + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.RemoveResourcePrincipalConfigurationDetails.rst b/docs/api/bds/models/oci.bds.models.RemoveResourcePrincipalConfigurationDetails.rst new file mode 100644 index 000000000..95415109b --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.RemoveResourcePrincipalConfigurationDetails.rst @@ -0,0 +1,11 @@ +RemoveResourcePrincipalConfigurationDetails +=========================================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: RemoveResourcePrincipalConfigurationDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.ResourcePrincipalConfiguration.rst b/docs/api/bds/models/oci.bds.models.ResourcePrincipalConfiguration.rst new file mode 100644 index 000000000..5b526d6e0 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.ResourcePrincipalConfiguration.rst @@ -0,0 +1,11 @@ +ResourcePrincipalConfiguration +============================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: ResourcePrincipalConfiguration + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.ResourcePrincipalConfigurationSummary.rst b/docs/api/bds/models/oci.bds.models.ResourcePrincipalConfigurationSummary.rst new file mode 100644 index 000000000..3d7b7132d --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.ResourcePrincipalConfigurationSummary.rst @@ -0,0 +1,11 @@ +ResourcePrincipalConfigurationSummary +===================================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: ResourcePrincipalConfigurationSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/bds/models/oci.bds.models.UpdateResourcePrincipalConfigurationDetails.rst b/docs/api/bds/models/oci.bds.models.UpdateResourcePrincipalConfigurationDetails.rst new file mode 100644 index 000000000..e794dddf2 --- /dev/null +++ b/docs/api/bds/models/oci.bds.models.UpdateResourcePrincipalConfigurationDetails.rst @@ -0,0 +1,11 @@ +UpdateResourcePrincipalConfigurationDetails +=========================================== + +.. currentmodule:: oci.bds.models + +.. autoclass:: UpdateResourcePrincipalConfigurationDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops.rst b/docs/api/devops.rst index b0a32070a..746adf163 100644 --- a/docs/api/devops.rst +++ b/docs/api/devops.rst @@ -22,7 +22,11 @@ Devops oci.devops.models.AbsoluteWaitCriteriaSummary oci.devops.models.ActualBuildRunnerShapeConfig oci.devops.models.ApprovalAction + oci.devops.models.ApprovalActivitySummary oci.devops.models.ApprovalPolicy + oci.devops.models.ApprovalRule + oci.devops.models.ApprovalRuleCollection + oci.devops.models.ApprovalRuleMergeCheck oci.devops.models.ApproveDeploymentDetails oci.devops.models.AutomatedDeployStageRollbackPolicy oci.devops.models.BackendSetIpCollection @@ -45,6 +49,7 @@ Devops oci.devops.models.BitbucketServerTrigger oci.devops.models.BitbucketServerTriggerCreateResult oci.devops.models.BitbucketServerTriggerSummary + oci.devops.models.BuildMergeCheck oci.devops.models.BuildOutputs oci.devops.models.BuildPipeline oci.devops.models.BuildPipelineCollection @@ -62,6 +67,9 @@ Devops oci.devops.models.BuildRunArgumentCollection oci.devops.models.BuildRunProgress oci.devops.models.BuildRunProgressSummary + oci.devops.models.BuildRunSnapshot + oci.devops.models.BuildRunSnapshotCollection + oci.devops.models.BuildRunSnapshotSummary oci.devops.models.BuildRunSource oci.devops.models.BuildRunSummary oci.devops.models.BuildRunSummaryCollection @@ -76,6 +84,10 @@ Devops oci.devops.models.CancelBuildRunDetails oci.devops.models.CancelDeploymentDetails oci.devops.models.ChangeProjectCompartmentDetails + oci.devops.models.CommentActivitySummary + oci.devops.models.CommitActivitySummary + oci.devops.models.CommitAnalyticsAuthorCollection + oci.devops.models.CommitAnalyticsAuthorSummary oci.devops.models.CommitInfo oci.devops.models.ComputeInstanceGroupBlueGreenDeployStage oci.devops.models.ComputeInstanceGroupBlueGreenDeployStageExecutionProgress @@ -107,6 +119,7 @@ Devops oci.devops.models.ComputeInstanceGroupRolloutPolicy oci.devops.models.ComputeInstanceGroupSelector oci.devops.models.ComputeInstanceGroupSelectorCollection + oci.devops.models.ConflictMergeCheck oci.devops.models.Connection oci.devops.models.ConnectionCollection oci.devops.models.ConnectionSummary @@ -160,8 +173,15 @@ Devops oci.devops.models.CreateOkeClusterDeployEnvironmentDetails oci.devops.models.CreateOkeDeployStageDetails oci.devops.models.CreateOkeHelmChartDeployStageDetails + oci.devops.models.CreateOrUpdateGitBranchDetails + oci.devops.models.CreateOrUpdateGitRefDetails + oci.devops.models.CreateOrUpdateGitTagDetails + oci.devops.models.CreateOrUpdateProtectedBranchDetails oci.devops.models.CreateProjectDetails + oci.devops.models.CreatePullRequestCommentDetails + oci.devops.models.CreatePullRequestDetails oci.devops.models.CreateRepositoryDetails + oci.devops.models.CreateReviewerDetails oci.devops.models.CreateShellDeployStageDetails oci.devops.models.CreateSingleDeployStageDeploymentDetails oci.devops.models.CreateSingleDeployStageRedeploymentDetails @@ -174,6 +194,8 @@ Devops oci.devops.models.CreateWaitStageDetails oci.devops.models.CustomBuildRunnerShapeConfig oci.devops.models.DefaultBuildRunnerShapeConfig + oci.devops.models.DeleteGitRefDetails + oci.devops.models.DeleteProtectedBranchDetails oci.devops.models.DeliverArtifact oci.devops.models.DeliverArtifactCollection oci.devops.models.DeliverArtifactStage @@ -237,17 +259,22 @@ Devops oci.devops.models.DiffResponseEntry oci.devops.models.DiffSection oci.devops.models.DiffSummary + oci.devops.models.ExecuteMergePullRequestDetails oci.devops.models.ExportedVariable oci.devops.models.ExportedVariableCollection oci.devops.models.FileDiffResponse oci.devops.models.FileFilter oci.devops.models.FileLineDetails oci.devops.models.Filter + oci.devops.models.ForkSyncStatusCollection + oci.devops.models.ForkSyncStatusSummary oci.devops.models.FunctionDeployEnvironment oci.devops.models.FunctionDeployEnvironmentSummary oci.devops.models.FunctionDeployStage oci.devops.models.FunctionDeployStageExecutionProgress oci.devops.models.FunctionDeployStageSummary + oci.devops.models.GenericArtifactLocationDetails + oci.devops.models.GenericArtifacts oci.devops.models.GenericDeliveredArtifact oci.devops.models.GenericDeployArtifactSource oci.devops.models.GithubAccessTokenConnection @@ -298,6 +325,11 @@ Devops oci.devops.models.ManualApprovalDeployStageExecutionProgress oci.devops.models.ManualApprovalDeployStageSummary oci.devops.models.ManualBuildRunSource + oci.devops.models.MergeCheck + oci.devops.models.MergeCheckCollection + oci.devops.models.MergeChecks + oci.devops.models.MergePullRequestDetails + oci.devops.models.MergeSettings oci.devops.models.MirrorRepositoryConfig oci.devops.models.NetworkChannel oci.devops.models.NginxBlueGreenStrategy @@ -305,6 +337,7 @@ Devops oci.devops.models.NoDeployStageRollbackPolicy oci.devops.models.NoneVerificationKeySource oci.devops.models.NotificationConfig + oci.devops.models.ObjectStorageGenericArtifactLocationDetails oci.devops.models.OcirDeployArtifactSource oci.devops.models.OkeBlueGreenDeployStage oci.devops.models.OkeBlueGreenDeployStageExecutionProgress @@ -331,14 +364,49 @@ Devops oci.devops.models.OkeHelmChartDeployStage oci.devops.models.OkeHelmChartDeployStageSummary oci.devops.models.OkeHelmChartDeploymentStageExecutionProgress + oci.devops.models.PatchInsertInstruction + oci.devops.models.PatchInstruction + oci.devops.models.PatchMergeInstruction + oci.devops.models.PatchMoveInstruction + oci.devops.models.PatchProhibitInstruction + oci.devops.models.PatchPullRequestDetails + oci.devops.models.PatchRemoveInstruction + oci.devops.models.PatchReplaceInstruction + oci.devops.models.PatchRequireInstruction + oci.devops.models.PrincipalDetails oci.devops.models.PrivateEndpointChannel oci.devops.models.Project oci.devops.models.ProjectCollection + oci.devops.models.ProjectNotificationPreference + oci.devops.models.ProjectRepositorySettings oci.devops.models.ProjectSummary + oci.devops.models.ProtectedBranch + oci.devops.models.ProtectedBranchCollection + oci.devops.models.ProtectedBranchSummary + oci.devops.models.PullRequest + oci.devops.models.PullRequestActivityCollection + oci.devops.models.PullRequestActivitySummary + oci.devops.models.PullRequestAttachment + oci.devops.models.PullRequestAttachmentCollection + oci.devops.models.PullRequestAttachmentSummary + oci.devops.models.PullRequestAuthorCollection + oci.devops.models.PullRequestAuthorSummary + oci.devops.models.PullRequestChangeSummaryMetrics + oci.devops.models.PullRequestCollection + oci.devops.models.PullRequestComment + oci.devops.models.PullRequestCommentCollection + oci.devops.models.PullRequestCommentLikeCollection + oci.devops.models.PullRequestCommentSummary + oci.devops.models.PullRequestFileChangeCollection + oci.devops.models.PullRequestFileChangeSummary + oci.devops.models.PullRequestLifecycleActivitySummary + oci.devops.models.PullRequestNotificationPreference + oci.devops.models.PullRequestSummary oci.devops.models.PutRepositoryBranchDetails oci.devops.models.PutRepositoryRefDetails oci.devops.models.PutRepositoryTagDetails oci.devops.models.Repository + oci.devops.models.RepositoryAnalyticsDetails oci.devops.models.RepositoryAuthorCollection oci.devops.models.RepositoryAuthorSummary oci.devops.models.RepositoryBranch @@ -348,18 +416,25 @@ Devops oci.devops.models.RepositoryCommitCollection oci.devops.models.RepositoryCommitSummary oci.devops.models.RepositoryFileLines + oci.devops.models.RepositoryMetricAggregation + oci.devops.models.RepositoryMetricSummary oci.devops.models.RepositoryMirrorRecord oci.devops.models.RepositoryMirrorRecordCollection oci.devops.models.RepositoryMirrorRecordSummary + oci.devops.models.RepositoryNotificationPreference oci.devops.models.RepositoryObject oci.devops.models.RepositoryPathCollection oci.devops.models.RepositoryPathSummary oci.devops.models.RepositoryRef oci.devops.models.RepositoryRefCollection oci.devops.models.RepositoryRefSummary + oci.devops.models.RepositorySettings oci.devops.models.RepositorySummary oci.devops.models.RepositoryTag oci.devops.models.RepositoryTagSummary + oci.devops.models.ReviewPullRequestDetails + oci.devops.models.Reviewer + oci.devops.models.ReviewerActivitySummary oci.devops.models.ServiceVnicChannel oci.devops.models.ShapeConfig oci.devops.models.ShellDeployStage @@ -369,6 +444,11 @@ Devops oci.devops.models.SingleDeployStageDeploymentSummary oci.devops.models.SingleDeployStageRedeployment oci.devops.models.SingleDeployStageRedeploymentSummary + oci.devops.models.StageOutput + oci.devops.models.SummarizeProjectRepositoryAnalyticsDetails + oci.devops.models.SummarizeRepositoryAnalyticsDetails + oci.devops.models.SyncRepositoryDetails + oci.devops.models.TestReportOutput oci.devops.models.TlsVerifyConfig oci.devops.models.Trigger oci.devops.models.TriggerAction @@ -382,6 +462,8 @@ Devops oci.devops.models.TriggerSchedule oci.devops.models.TriggerSummary oci.devops.models.UpdateAbsoluteWaitCriteriaDetails + oci.devops.models.UpdateApprovalRuleDetails + oci.devops.models.UpdateApprovalRuleDetailsCollection oci.devops.models.UpdateBitbucketCloudAppPasswordConnectionDetails oci.devops.models.UpdateBitbucketCloudTriggerDetails oci.devops.models.UpdateBitbucketServerAccessTokenConnectionDetails @@ -427,7 +509,15 @@ Devops oci.devops.models.UpdateOkeDeployStageDetails oci.devops.models.UpdateOkeHelmChartDeployStageDetails oci.devops.models.UpdateProjectDetails + oci.devops.models.UpdateProjectNotificationPreferenceDetails + oci.devops.models.UpdateProjectRepositorySettingsDetails + oci.devops.models.UpdatePullRequestCommentDetails + oci.devops.models.UpdatePullRequestDetails + oci.devops.models.UpdatePullRequestNotificationPreferenceDetails oci.devops.models.UpdateRepositoryDetails + oci.devops.models.UpdateRepositoryNotificationPreferenceDetails + oci.devops.models.UpdateRepositorySettingsDetails + oci.devops.models.UpdateReviewerDetails oci.devops.models.UpdateShellDeployStageDetails oci.devops.models.UpdateSingleDeployStageDeploymentDetails oci.devops.models.UpdateSingleDeployStageRedeploymentDetails @@ -438,6 +528,7 @@ Devops oci.devops.models.UpdateWaitCriteriaDetails oci.devops.models.UpdateWaitDeployStageDetails oci.devops.models.UpdateWaitStageDetails + oci.devops.models.ValidateMergePullRequestDetails oci.devops.models.VaultSecretVerificationKeySource oci.devops.models.VbsAccessTokenConnection oci.devops.models.VbsAccessTokenConnectionSummary diff --git a/docs/api/devops/models/oci.devops.models.ApprovalActivitySummary.rst b/docs/api/devops/models/oci.devops.models.ApprovalActivitySummary.rst new file mode 100644 index 000000000..866859ea9 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ApprovalActivitySummary.rst @@ -0,0 +1,11 @@ +ApprovalActivitySummary +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: ApprovalActivitySummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ApprovalRule.rst b/docs/api/devops/models/oci.devops.models.ApprovalRule.rst new file mode 100644 index 000000000..721e2e7c4 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ApprovalRule.rst @@ -0,0 +1,11 @@ +ApprovalRule +============ + +.. currentmodule:: oci.devops.models + +.. autoclass:: ApprovalRule + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ApprovalRuleCollection.rst b/docs/api/devops/models/oci.devops.models.ApprovalRuleCollection.rst new file mode 100644 index 000000000..b420c77c9 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ApprovalRuleCollection.rst @@ -0,0 +1,11 @@ +ApprovalRuleCollection +====================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ApprovalRuleCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ApprovalRuleMergeCheck.rst b/docs/api/devops/models/oci.devops.models.ApprovalRuleMergeCheck.rst new file mode 100644 index 000000000..23ea85736 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ApprovalRuleMergeCheck.rst @@ -0,0 +1,11 @@ +ApprovalRuleMergeCheck +====================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ApprovalRuleMergeCheck + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.BuildMergeCheck.rst b/docs/api/devops/models/oci.devops.models.BuildMergeCheck.rst new file mode 100644 index 000000000..832c66ead --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.BuildMergeCheck.rst @@ -0,0 +1,11 @@ +BuildMergeCheck +=============== + +.. currentmodule:: oci.devops.models + +.. autoclass:: BuildMergeCheck + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.BuildRunSnapshot.rst b/docs/api/devops/models/oci.devops.models.BuildRunSnapshot.rst new file mode 100644 index 000000000..ecc159714 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.BuildRunSnapshot.rst @@ -0,0 +1,11 @@ +BuildRunSnapshot +================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: BuildRunSnapshot + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.BuildRunSnapshotCollection.rst b/docs/api/devops/models/oci.devops.models.BuildRunSnapshotCollection.rst new file mode 100644 index 000000000..7c80f2a19 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.BuildRunSnapshotCollection.rst @@ -0,0 +1,11 @@ +BuildRunSnapshotCollection +========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: BuildRunSnapshotCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.BuildRunSnapshotSummary.rst b/docs/api/devops/models/oci.devops.models.BuildRunSnapshotSummary.rst new file mode 100644 index 000000000..3321c58c4 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.BuildRunSnapshotSummary.rst @@ -0,0 +1,11 @@ +BuildRunSnapshotSummary +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: BuildRunSnapshotSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CommentActivitySummary.rst b/docs/api/devops/models/oci.devops.models.CommentActivitySummary.rst new file mode 100644 index 000000000..8d671ab75 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CommentActivitySummary.rst @@ -0,0 +1,11 @@ +CommentActivitySummary +====================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CommentActivitySummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CommitActivitySummary.rst b/docs/api/devops/models/oci.devops.models.CommitActivitySummary.rst new file mode 100644 index 000000000..1c95b5d53 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CommitActivitySummary.rst @@ -0,0 +1,11 @@ +CommitActivitySummary +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CommitActivitySummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorCollection.rst b/docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorCollection.rst new file mode 100644 index 000000000..5c63359fe --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorCollection.rst @@ -0,0 +1,11 @@ +CommitAnalyticsAuthorCollection +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CommitAnalyticsAuthorCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorSummary.rst b/docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorSummary.rst new file mode 100644 index 000000000..4ddb1a10e --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CommitAnalyticsAuthorSummary.rst @@ -0,0 +1,11 @@ +CommitAnalyticsAuthorSummary +============================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: CommitAnalyticsAuthorSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ConflictMergeCheck.rst b/docs/api/devops/models/oci.devops.models.ConflictMergeCheck.rst new file mode 100644 index 000000000..a4a478043 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ConflictMergeCheck.rst @@ -0,0 +1,11 @@ +ConflictMergeCheck +================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ConflictMergeCheck + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitBranchDetails.rst b/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitBranchDetails.rst new file mode 100644 index 000000000..21c204992 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitBranchDetails.rst @@ -0,0 +1,11 @@ +CreateOrUpdateGitBranchDetails +============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreateOrUpdateGitBranchDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitRefDetails.rst b/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitRefDetails.rst new file mode 100644 index 000000000..358072bf1 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitRefDetails.rst @@ -0,0 +1,11 @@ +CreateOrUpdateGitRefDetails +=========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreateOrUpdateGitRefDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitTagDetails.rst b/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitTagDetails.rst new file mode 100644 index 000000000..7c25024d2 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreateOrUpdateGitTagDetails.rst @@ -0,0 +1,11 @@ +CreateOrUpdateGitTagDetails +=========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreateOrUpdateGitTagDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreateOrUpdateProtectedBranchDetails.rst b/docs/api/devops/models/oci.devops.models.CreateOrUpdateProtectedBranchDetails.rst new file mode 100644 index 000000000..34419ba8e --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreateOrUpdateProtectedBranchDetails.rst @@ -0,0 +1,11 @@ +CreateOrUpdateProtectedBranchDetails +==================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreateOrUpdateProtectedBranchDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreatePullRequestCommentDetails.rst b/docs/api/devops/models/oci.devops.models.CreatePullRequestCommentDetails.rst new file mode 100644 index 000000000..702915b57 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreatePullRequestCommentDetails.rst @@ -0,0 +1,11 @@ +CreatePullRequestCommentDetails +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreatePullRequestCommentDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreatePullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.CreatePullRequestDetails.rst new file mode 100644 index 000000000..feb1f10e0 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreatePullRequestDetails.rst @@ -0,0 +1,11 @@ +CreatePullRequestDetails +======================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreatePullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.CreateReviewerDetails.rst b/docs/api/devops/models/oci.devops.models.CreateReviewerDetails.rst new file mode 100644 index 000000000..ec51349cb --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.CreateReviewerDetails.rst @@ -0,0 +1,11 @@ +CreateReviewerDetails +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: CreateReviewerDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.DeleteGitRefDetails.rst b/docs/api/devops/models/oci.devops.models.DeleteGitRefDetails.rst new file mode 100644 index 000000000..9270f671d --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.DeleteGitRefDetails.rst @@ -0,0 +1,11 @@ +DeleteGitRefDetails +=================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: DeleteGitRefDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.DeleteProtectedBranchDetails.rst b/docs/api/devops/models/oci.devops.models.DeleteProtectedBranchDetails.rst new file mode 100644 index 000000000..f23ee4afe --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.DeleteProtectedBranchDetails.rst @@ -0,0 +1,11 @@ +DeleteProtectedBranchDetails +============================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: DeleteProtectedBranchDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ExecuteMergePullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.ExecuteMergePullRequestDetails.rst new file mode 100644 index 000000000..2e0f33a0f --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ExecuteMergePullRequestDetails.rst @@ -0,0 +1,11 @@ +ExecuteMergePullRequestDetails +============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ExecuteMergePullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ForkSyncStatusCollection.rst b/docs/api/devops/models/oci.devops.models.ForkSyncStatusCollection.rst new file mode 100644 index 000000000..2e851dec2 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ForkSyncStatusCollection.rst @@ -0,0 +1,11 @@ +ForkSyncStatusCollection +======================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ForkSyncStatusCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ForkSyncStatusSummary.rst b/docs/api/devops/models/oci.devops.models.ForkSyncStatusSummary.rst new file mode 100644 index 000000000..ef60acf28 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ForkSyncStatusSummary.rst @@ -0,0 +1,11 @@ +ForkSyncStatusSummary +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ForkSyncStatusSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.GenericArtifactLocationDetails.rst b/docs/api/devops/models/oci.devops.models.GenericArtifactLocationDetails.rst new file mode 100644 index 000000000..5e6e011ac --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.GenericArtifactLocationDetails.rst @@ -0,0 +1,11 @@ +GenericArtifactLocationDetails +============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: GenericArtifactLocationDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.GenericArtifacts.rst b/docs/api/devops/models/oci.devops.models.GenericArtifacts.rst new file mode 100644 index 000000000..7f7e5c3ee --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.GenericArtifacts.rst @@ -0,0 +1,11 @@ +GenericArtifacts +================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: GenericArtifacts + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.MergeCheck.rst b/docs/api/devops/models/oci.devops.models.MergeCheck.rst new file mode 100644 index 000000000..550d19e05 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.MergeCheck.rst @@ -0,0 +1,11 @@ +MergeCheck +========== + +.. currentmodule:: oci.devops.models + +.. autoclass:: MergeCheck + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.MergeCheckCollection.rst b/docs/api/devops/models/oci.devops.models.MergeCheckCollection.rst new file mode 100644 index 000000000..ddf9eea35 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.MergeCheckCollection.rst @@ -0,0 +1,11 @@ +MergeCheckCollection +==================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: MergeCheckCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.MergeChecks.rst b/docs/api/devops/models/oci.devops.models.MergeChecks.rst new file mode 100644 index 000000000..3aedcefb4 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.MergeChecks.rst @@ -0,0 +1,11 @@ +MergeChecks +=========== + +.. currentmodule:: oci.devops.models + +.. autoclass:: MergeChecks + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.MergePullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.MergePullRequestDetails.rst new file mode 100644 index 000000000..56760bb29 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.MergePullRequestDetails.rst @@ -0,0 +1,11 @@ +MergePullRequestDetails +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: MergePullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.MergeSettings.rst b/docs/api/devops/models/oci.devops.models.MergeSettings.rst new file mode 100644 index 000000000..e3913067b --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.MergeSettings.rst @@ -0,0 +1,11 @@ +MergeSettings +============= + +.. currentmodule:: oci.devops.models + +.. autoclass:: MergeSettings + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ObjectStorageGenericArtifactLocationDetails.rst b/docs/api/devops/models/oci.devops.models.ObjectStorageGenericArtifactLocationDetails.rst new file mode 100644 index 000000000..94e04f7d6 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ObjectStorageGenericArtifactLocationDetails.rst @@ -0,0 +1,11 @@ +ObjectStorageGenericArtifactLocationDetails +=========================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ObjectStorageGenericArtifactLocationDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchInsertInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchInsertInstruction.rst new file mode 100644 index 000000000..261d23845 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchInsertInstruction.rst @@ -0,0 +1,11 @@ +PatchInsertInstruction +====================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchInsertInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchInstruction.rst new file mode 100644 index 000000000..2bad7874a --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchInstruction.rst @@ -0,0 +1,11 @@ +PatchInstruction +================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchMergeInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchMergeInstruction.rst new file mode 100644 index 000000000..19f1ddd6f --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchMergeInstruction.rst @@ -0,0 +1,11 @@ +PatchMergeInstruction +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchMergeInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchMoveInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchMoveInstruction.rst new file mode 100644 index 000000000..9dd5e337e --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchMoveInstruction.rst @@ -0,0 +1,11 @@ +PatchMoveInstruction +==================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchMoveInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchProhibitInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchProhibitInstruction.rst new file mode 100644 index 000000000..412f99d11 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchProhibitInstruction.rst @@ -0,0 +1,11 @@ +PatchProhibitInstruction +======================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchProhibitInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchPullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.PatchPullRequestDetails.rst new file mode 100644 index 000000000..66a8811d4 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchPullRequestDetails.rst @@ -0,0 +1,11 @@ +PatchPullRequestDetails +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchPullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchRemoveInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchRemoveInstruction.rst new file mode 100644 index 000000000..547918f1d --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchRemoveInstruction.rst @@ -0,0 +1,11 @@ +PatchRemoveInstruction +====================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchRemoveInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchReplaceInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchReplaceInstruction.rst new file mode 100644 index 000000000..8c163239a --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchReplaceInstruction.rst @@ -0,0 +1,11 @@ +PatchReplaceInstruction +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchReplaceInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PatchRequireInstruction.rst b/docs/api/devops/models/oci.devops.models.PatchRequireInstruction.rst new file mode 100644 index 000000000..9b15aac3f --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PatchRequireInstruction.rst @@ -0,0 +1,11 @@ +PatchRequireInstruction +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: PatchRequireInstruction + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PrincipalDetails.rst b/docs/api/devops/models/oci.devops.models.PrincipalDetails.rst new file mode 100644 index 000000000..aa4d579ac --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PrincipalDetails.rst @@ -0,0 +1,11 @@ +PrincipalDetails +================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: PrincipalDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ProjectNotificationPreference.rst b/docs/api/devops/models/oci.devops.models.ProjectNotificationPreference.rst new file mode 100644 index 000000000..122a04167 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ProjectNotificationPreference.rst @@ -0,0 +1,11 @@ +ProjectNotificationPreference +============================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: ProjectNotificationPreference + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ProjectRepositorySettings.rst b/docs/api/devops/models/oci.devops.models.ProjectRepositorySettings.rst new file mode 100644 index 000000000..38c7019e1 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ProjectRepositorySettings.rst @@ -0,0 +1,11 @@ +ProjectRepositorySettings +========================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: ProjectRepositorySettings + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ProtectedBranch.rst b/docs/api/devops/models/oci.devops.models.ProtectedBranch.rst new file mode 100644 index 000000000..e0ff1b643 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ProtectedBranch.rst @@ -0,0 +1,11 @@ +ProtectedBranch +=============== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ProtectedBranch + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ProtectedBranchCollection.rst b/docs/api/devops/models/oci.devops.models.ProtectedBranchCollection.rst new file mode 100644 index 000000000..a6592ea9d --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ProtectedBranchCollection.rst @@ -0,0 +1,11 @@ +ProtectedBranchCollection +========================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: ProtectedBranchCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ProtectedBranchSummary.rst b/docs/api/devops/models/oci.devops.models.ProtectedBranchSummary.rst new file mode 100644 index 000000000..8c1f9b580 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ProtectedBranchSummary.rst @@ -0,0 +1,11 @@ +ProtectedBranchSummary +====================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ProtectedBranchSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequest.rst b/docs/api/devops/models/oci.devops.models.PullRequest.rst new file mode 100644 index 000000000..553b0920c --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequest.rst @@ -0,0 +1,11 @@ +PullRequest +=========== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequest + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestActivityCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestActivityCollection.rst new file mode 100644 index 000000000..567f7eb27 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestActivityCollection.rst @@ -0,0 +1,11 @@ +PullRequestActivityCollection +============================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestActivityCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestActivitySummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestActivitySummary.rst new file mode 100644 index 000000000..b0d794e7e --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestActivitySummary.rst @@ -0,0 +1,11 @@ +PullRequestActivitySummary +========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestActivitySummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestAttachment.rst b/docs/api/devops/models/oci.devops.models.PullRequestAttachment.rst new file mode 100644 index 000000000..84360499b --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestAttachment.rst @@ -0,0 +1,11 @@ +PullRequestAttachment +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestAttachment + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestAttachmentCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestAttachmentCollection.rst new file mode 100644 index 000000000..2235406ec --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestAttachmentCollection.rst @@ -0,0 +1,11 @@ +PullRequestAttachmentCollection +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestAttachmentCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestAttachmentSummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestAttachmentSummary.rst new file mode 100644 index 000000000..61035afb1 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestAttachmentSummary.rst @@ -0,0 +1,11 @@ +PullRequestAttachmentSummary +============================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestAttachmentSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestAuthorCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestAuthorCollection.rst new file mode 100644 index 000000000..95c35c3bb --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestAuthorCollection.rst @@ -0,0 +1,11 @@ +PullRequestAuthorCollection +=========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestAuthorCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestAuthorSummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestAuthorSummary.rst new file mode 100644 index 000000000..b960c730a --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestAuthorSummary.rst @@ -0,0 +1,11 @@ +PullRequestAuthorSummary +======================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestAuthorSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestChangeSummaryMetrics.rst b/docs/api/devops/models/oci.devops.models.PullRequestChangeSummaryMetrics.rst new file mode 100644 index 000000000..e334c9efb --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestChangeSummaryMetrics.rst @@ -0,0 +1,11 @@ +PullRequestChangeSummaryMetrics +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestChangeSummaryMetrics + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestCollection.rst new file mode 100644 index 000000000..0c68af1b6 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestCollection.rst @@ -0,0 +1,11 @@ +PullRequestCollection +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestComment.rst b/docs/api/devops/models/oci.devops.models.PullRequestComment.rst new file mode 100644 index 000000000..23a17cf99 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestComment.rst @@ -0,0 +1,11 @@ +PullRequestComment +================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestComment + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestCommentCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestCommentCollection.rst new file mode 100644 index 000000000..69cb4a9bc --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestCommentCollection.rst @@ -0,0 +1,11 @@ +PullRequestCommentCollection +============================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestCommentCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestCommentLikeCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestCommentLikeCollection.rst new file mode 100644 index 000000000..870c34843 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestCommentLikeCollection.rst @@ -0,0 +1,11 @@ +PullRequestCommentLikeCollection +================================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestCommentLikeCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestCommentSummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestCommentSummary.rst new file mode 100644 index 000000000..f573a22d4 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestCommentSummary.rst @@ -0,0 +1,11 @@ +PullRequestCommentSummary +========================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestCommentSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestFileChangeCollection.rst b/docs/api/devops/models/oci.devops.models.PullRequestFileChangeCollection.rst new file mode 100644 index 000000000..bec3376fc --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestFileChangeCollection.rst @@ -0,0 +1,11 @@ +PullRequestFileChangeCollection +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestFileChangeCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestFileChangeSummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestFileChangeSummary.rst new file mode 100644 index 000000000..6c4e162a5 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestFileChangeSummary.rst @@ -0,0 +1,11 @@ +PullRequestFileChangeSummary +============================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestFileChangeSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestLifecycleActivitySummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestLifecycleActivitySummary.rst new file mode 100644 index 000000000..a33a3d824 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestLifecycleActivitySummary.rst @@ -0,0 +1,11 @@ +PullRequestLifecycleActivitySummary +=================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestLifecycleActivitySummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestNotificationPreference.rst b/docs/api/devops/models/oci.devops.models.PullRequestNotificationPreference.rst new file mode 100644 index 000000000..48254fabd --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestNotificationPreference.rst @@ -0,0 +1,11 @@ +PullRequestNotificationPreference +================================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestNotificationPreference + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.PullRequestSummary.rst b/docs/api/devops/models/oci.devops.models.PullRequestSummary.rst new file mode 100644 index 000000000..a16d99174 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.PullRequestSummary.rst @@ -0,0 +1,11 @@ +PullRequestSummary +================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: PullRequestSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.RepositoryAnalyticsDetails.rst b/docs/api/devops/models/oci.devops.models.RepositoryAnalyticsDetails.rst new file mode 100644 index 000000000..cd9a75c18 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.RepositoryAnalyticsDetails.rst @@ -0,0 +1,11 @@ +RepositoryAnalyticsDetails +========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: RepositoryAnalyticsDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.RepositoryMetricAggregation.rst b/docs/api/devops/models/oci.devops.models.RepositoryMetricAggregation.rst new file mode 100644 index 000000000..11a65879a --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.RepositoryMetricAggregation.rst @@ -0,0 +1,11 @@ +RepositoryMetricAggregation +=========================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: RepositoryMetricAggregation + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.RepositoryMetricSummary.rst b/docs/api/devops/models/oci.devops.models.RepositoryMetricSummary.rst new file mode 100644 index 000000000..a664f3089 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.RepositoryMetricSummary.rst @@ -0,0 +1,11 @@ +RepositoryMetricSummary +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: RepositoryMetricSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.RepositoryNotificationPreference.rst b/docs/api/devops/models/oci.devops.models.RepositoryNotificationPreference.rst new file mode 100644 index 000000000..0f3098a5f --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.RepositoryNotificationPreference.rst @@ -0,0 +1,11 @@ +RepositoryNotificationPreference +================================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: RepositoryNotificationPreference + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.RepositorySettings.rst b/docs/api/devops/models/oci.devops.models.RepositorySettings.rst new file mode 100644 index 000000000..f127b7b0c --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.RepositorySettings.rst @@ -0,0 +1,11 @@ +RepositorySettings +================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: RepositorySettings + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ReviewPullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.ReviewPullRequestDetails.rst new file mode 100644 index 000000000..bf6b988cc --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ReviewPullRequestDetails.rst @@ -0,0 +1,11 @@ +ReviewPullRequestDetails +======================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ReviewPullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.Reviewer.rst b/docs/api/devops/models/oci.devops.models.Reviewer.rst new file mode 100644 index 000000000..a687434ea --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.Reviewer.rst @@ -0,0 +1,11 @@ +Reviewer +======== + +.. currentmodule:: oci.devops.models + +.. autoclass:: Reviewer + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ReviewerActivitySummary.rst b/docs/api/devops/models/oci.devops.models.ReviewerActivitySummary.rst new file mode 100644 index 000000000..ae2667454 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ReviewerActivitySummary.rst @@ -0,0 +1,11 @@ +ReviewerActivitySummary +======================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: ReviewerActivitySummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.StageOutput.rst b/docs/api/devops/models/oci.devops.models.StageOutput.rst new file mode 100644 index 000000000..5c0778807 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.StageOutput.rst @@ -0,0 +1,11 @@ +StageOutput +=========== + +.. currentmodule:: oci.devops.models + +.. autoclass:: StageOutput + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.SummarizeProjectRepositoryAnalyticsDetails.rst b/docs/api/devops/models/oci.devops.models.SummarizeProjectRepositoryAnalyticsDetails.rst new file mode 100644 index 000000000..52d4babd2 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.SummarizeProjectRepositoryAnalyticsDetails.rst @@ -0,0 +1,11 @@ +SummarizeProjectRepositoryAnalyticsDetails +========================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: SummarizeProjectRepositoryAnalyticsDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.SummarizeRepositoryAnalyticsDetails.rst b/docs/api/devops/models/oci.devops.models.SummarizeRepositoryAnalyticsDetails.rst new file mode 100644 index 000000000..cc4971f62 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.SummarizeRepositoryAnalyticsDetails.rst @@ -0,0 +1,11 @@ +SummarizeRepositoryAnalyticsDetails +=================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: SummarizeRepositoryAnalyticsDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.SyncRepositoryDetails.rst b/docs/api/devops/models/oci.devops.models.SyncRepositoryDetails.rst new file mode 100644 index 000000000..5121a920f --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.SyncRepositoryDetails.rst @@ -0,0 +1,11 @@ +SyncRepositoryDetails +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: SyncRepositoryDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.TestReportOutput.rst b/docs/api/devops/models/oci.devops.models.TestReportOutput.rst new file mode 100644 index 000000000..2d21f5f25 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.TestReportOutput.rst @@ -0,0 +1,11 @@ +TestReportOutput +================ + +.. currentmodule:: oci.devops.models + +.. autoclass:: TestReportOutput + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetails.rst b/docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetails.rst new file mode 100644 index 000000000..88717c27e --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetails.rst @@ -0,0 +1,11 @@ +UpdateApprovalRuleDetails +========================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateApprovalRuleDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetailsCollection.rst b/docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetailsCollection.rst new file mode 100644 index 000000000..e16188e33 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateApprovalRuleDetailsCollection.rst @@ -0,0 +1,11 @@ +UpdateApprovalRuleDetailsCollection +=================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateApprovalRuleDetailsCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateProjectNotificationPreferenceDetails.rst b/docs/api/devops/models/oci.devops.models.UpdateProjectNotificationPreferenceDetails.rst new file mode 100644 index 000000000..b83075767 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateProjectNotificationPreferenceDetails.rst @@ -0,0 +1,11 @@ +UpdateProjectNotificationPreferenceDetails +========================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateProjectNotificationPreferenceDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateProjectRepositorySettingsDetails.rst b/docs/api/devops/models/oci.devops.models.UpdateProjectRepositorySettingsDetails.rst new file mode 100644 index 000000000..8e9949fb7 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateProjectRepositorySettingsDetails.rst @@ -0,0 +1,11 @@ +UpdateProjectRepositorySettingsDetails +====================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateProjectRepositorySettingsDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdatePullRequestCommentDetails.rst b/docs/api/devops/models/oci.devops.models.UpdatePullRequestCommentDetails.rst new file mode 100644 index 000000000..b0062ae68 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdatePullRequestCommentDetails.rst @@ -0,0 +1,11 @@ +UpdatePullRequestCommentDetails +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdatePullRequestCommentDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdatePullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.UpdatePullRequestDetails.rst new file mode 100644 index 000000000..520ba8624 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdatePullRequestDetails.rst @@ -0,0 +1,11 @@ +UpdatePullRequestDetails +======================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdatePullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdatePullRequestNotificationPreferenceDetails.rst b/docs/api/devops/models/oci.devops.models.UpdatePullRequestNotificationPreferenceDetails.rst new file mode 100644 index 000000000..dbe83ac2a --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdatePullRequestNotificationPreferenceDetails.rst @@ -0,0 +1,11 @@ +UpdatePullRequestNotificationPreferenceDetails +============================================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdatePullRequestNotificationPreferenceDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateRepositoryNotificationPreferenceDetails.rst b/docs/api/devops/models/oci.devops.models.UpdateRepositoryNotificationPreferenceDetails.rst new file mode 100644 index 000000000..585dd30ae --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateRepositoryNotificationPreferenceDetails.rst @@ -0,0 +1,11 @@ +UpdateRepositoryNotificationPreferenceDetails +============================================= + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateRepositoryNotificationPreferenceDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateRepositorySettingsDetails.rst b/docs/api/devops/models/oci.devops.models.UpdateRepositorySettingsDetails.rst new file mode 100644 index 000000000..b681b114d --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateRepositorySettingsDetails.rst @@ -0,0 +1,11 @@ +UpdateRepositorySettingsDetails +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateRepositorySettingsDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.UpdateReviewerDetails.rst b/docs/api/devops/models/oci.devops.models.UpdateReviewerDetails.rst new file mode 100644 index 000000000..5844f6f20 --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.UpdateReviewerDetails.rst @@ -0,0 +1,11 @@ +UpdateReviewerDetails +===================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: UpdateReviewerDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/devops/models/oci.devops.models.ValidateMergePullRequestDetails.rst b/docs/api/devops/models/oci.devops.models.ValidateMergePullRequestDetails.rst new file mode 100644 index 000000000..26549a23e --- /dev/null +++ b/docs/api/devops/models/oci.devops.models.ValidateMergePullRequestDetails.rst @@ -0,0 +1,11 @@ +ValidateMergePullRequestDetails +=============================== + +.. currentmodule:: oci.devops.models + +.. autoclass:: ValidateMergePullRequestDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms.rst b/docs/api/jms.rst index 30a77e568..579652434 100644 --- a/docs/api/jms.rst +++ b/docs/api/jms.rst @@ -21,6 +21,8 @@ Jms oci.jms.models.AddFleetInstallationSitesDetails oci.jms.models.AdvancedUsageTracking oci.jms.models.Agent + oci.jms.models.AgentInstallerCollection + oci.jms.models.AgentInstallerSummary oci.jms.models.AnnouncementCollection oci.jms.models.AnnouncementSummary oci.jms.models.ApplicationInstallationUsageSummary @@ -37,6 +39,7 @@ Jms oci.jms.models.CreateBlocklistDetails oci.jms.models.CreateDrsFileDetails oci.jms.models.CreateFleetDetails + oci.jms.models.CreateJmsPluginDetails oci.jms.models.CryptoAnalysisResult oci.jms.models.CryptoAnalysisResultCollection oci.jms.models.CryptoAnalysisResultSummary @@ -44,8 +47,10 @@ Jms oci.jms.models.CustomLog oci.jms.models.DeployedApplicationInstallationUsageSummary oci.jms.models.DeployedApplicationInstallationUsageSummaryCollection + oci.jms.models.DeployedApplicationMigrationAnalysesTarget oci.jms.models.DeployedApplicationUsage oci.jms.models.DeployedApplicationUsageCollection + oci.jms.models.DeployedApplicationWorkItemDetails oci.jms.models.DisableDrsDetails oci.jms.models.DrsFile oci.jms.models.DrsFileCollection @@ -64,6 +69,8 @@ Jms oci.jms.models.FleetDiagnosisSummary oci.jms.models.FleetSummary oci.jms.models.GenerateAgentDeployScriptDetails + oci.jms.models.GenerateAgentInstallerConfigurationDetails + oci.jms.models.GenerateLoadPipelineScriptDetails oci.jms.models.InstallationSite oci.jms.models.InstallationSiteCollection oci.jms.models.InstallationSiteSummary @@ -89,6 +96,9 @@ Jms oci.jms.models.JavaServerUsageCollection oci.jms.models.JfrAttachmentTarget oci.jms.models.JfrRecording + oci.jms.models.JmsPlugin + oci.jms.models.JmsPluginCollection + oci.jms.models.JmsPluginSummary oci.jms.models.JreUsage oci.jms.models.JreUsageCollection oci.jms.models.KeySizeAlgorithm @@ -113,6 +123,7 @@ Jms oci.jms.models.Proxies oci.jms.models.RemoveFleetInstallationSitesDetails oci.jms.models.RequestCryptoAnalysesDetails + oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails oci.jms.models.RequestJavaMigrationAnalysesDetails oci.jms.models.RequestJfrRecordingsDetails oci.jms.models.RequestPerformanceTuningAnalysesDetails @@ -125,6 +136,7 @@ Jms oci.jms.models.UpdateFleetAdvancedFeatureConfigurationDetails oci.jms.models.UpdateFleetAgentConfigurationDetails oci.jms.models.UpdateFleetDetails + oci.jms.models.UpdateJmsPluginDetails oci.jms.models.WorkItemCollection oci.jms.models.WorkItemDetails oci.jms.models.WorkItemSummary diff --git a/docs/api/jms/models/oci.jms.models.AgentInstallerCollection.rst b/docs/api/jms/models/oci.jms.models.AgentInstallerCollection.rst new file mode 100644 index 000000000..4899028f7 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.AgentInstallerCollection.rst @@ -0,0 +1,11 @@ +AgentInstallerCollection +======================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: AgentInstallerCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.AgentInstallerSummary.rst b/docs/api/jms/models/oci.jms.models.AgentInstallerSummary.rst new file mode 100644 index 000000000..873be1247 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.AgentInstallerSummary.rst @@ -0,0 +1,11 @@ +AgentInstallerSummary +===================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: AgentInstallerSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.CreateJmsPluginDetails.rst b/docs/api/jms/models/oci.jms.models.CreateJmsPluginDetails.rst new file mode 100644 index 000000000..64af33601 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.CreateJmsPluginDetails.rst @@ -0,0 +1,11 @@ +CreateJmsPluginDetails +====================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: CreateJmsPluginDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.DeployedApplicationMigrationAnalysesTarget.rst b/docs/api/jms/models/oci.jms.models.DeployedApplicationMigrationAnalysesTarget.rst new file mode 100644 index 000000000..aee68b25c --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.DeployedApplicationMigrationAnalysesTarget.rst @@ -0,0 +1,11 @@ +DeployedApplicationMigrationAnalysesTarget +========================================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: DeployedApplicationMigrationAnalysesTarget + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.DeployedApplicationWorkItemDetails.rst b/docs/api/jms/models/oci.jms.models.DeployedApplicationWorkItemDetails.rst new file mode 100644 index 000000000..fba092a05 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.DeployedApplicationWorkItemDetails.rst @@ -0,0 +1,11 @@ +DeployedApplicationWorkItemDetails +================================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: DeployedApplicationWorkItemDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.GenerateAgentInstallerConfigurationDetails.rst b/docs/api/jms/models/oci.jms.models.GenerateAgentInstallerConfigurationDetails.rst new file mode 100644 index 000000000..cdcf75157 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.GenerateAgentInstallerConfigurationDetails.rst @@ -0,0 +1,11 @@ +GenerateAgentInstallerConfigurationDetails +========================================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: GenerateAgentInstallerConfigurationDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.GenerateLoadPipelineScriptDetails.rst b/docs/api/jms/models/oci.jms.models.GenerateLoadPipelineScriptDetails.rst new file mode 100644 index 000000000..90af57f9c --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.GenerateLoadPipelineScriptDetails.rst @@ -0,0 +1,11 @@ +GenerateLoadPipelineScriptDetails +================================= + +.. currentmodule:: oci.jms.models + +.. autoclass:: GenerateLoadPipelineScriptDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.JmsPlugin.rst b/docs/api/jms/models/oci.jms.models.JmsPlugin.rst new file mode 100644 index 000000000..52ee0e495 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.JmsPlugin.rst @@ -0,0 +1,11 @@ +JmsPlugin +========= + +.. currentmodule:: oci.jms.models + +.. autoclass:: JmsPlugin + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.JmsPluginCollection.rst b/docs/api/jms/models/oci.jms.models.JmsPluginCollection.rst new file mode 100644 index 000000000..48b06d5c7 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.JmsPluginCollection.rst @@ -0,0 +1,11 @@ +JmsPluginCollection +=================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: JmsPluginCollection + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.JmsPluginSummary.rst b/docs/api/jms/models/oci.jms.models.JmsPluginSummary.rst new file mode 100644 index 000000000..56eb09ac4 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.JmsPluginSummary.rst @@ -0,0 +1,11 @@ +JmsPluginSummary +================ + +.. currentmodule:: oci.jms.models + +.. autoclass:: JmsPluginSummary + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails.rst b/docs/api/jms/models/oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails.rst new file mode 100644 index 000000000..8113c8038 --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails.rst @@ -0,0 +1,11 @@ +RequestDeployedApplicationMigrationAnalysesDetails +================================================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: RequestDeployedApplicationMigrationAnalysesDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/jms/models/oci.jms.models.UpdateJmsPluginDetails.rst b/docs/api/jms/models/oci.jms.models.UpdateJmsPluginDetails.rst new file mode 100644 index 000000000..61c0f8f8f --- /dev/null +++ b/docs/api/jms/models/oci.jms.models.UpdateJmsPluginDetails.rst @@ -0,0 +1,11 @@ +UpdateJmsPluginDetails +====================== + +.. currentmodule:: oci.jms.models + +.. autoclass:: UpdateJmsPluginDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/psql.rst b/docs/api/psql.rst index 6e620bc88..4ee2e8961 100644 --- a/docs/api/psql.rst +++ b/docs/api/psql.rst @@ -76,6 +76,8 @@ Psql oci.psql.models.RestartDbInstanceInDbSystemDetails oci.psql.models.RestoreDbSystemDetails oci.psql.models.ShapeCollection + oci.psql.models.ShapeMemoryOptions + oci.psql.models.ShapeOcpuOptions oci.psql.models.ShapeSummary oci.psql.models.SourceDetails oci.psql.models.StorageDetails @@ -84,6 +86,7 @@ Psql oci.psql.models.UpdateDbConfigParams oci.psql.models.UpdateDbSystemDbInstanceDetails oci.psql.models.UpdateDbSystemDetails + oci.psql.models.UpdateNetworkDetails oci.psql.models.UpdateStorageDetailsParams oci.psql.models.VaultSecretPasswordDetails oci.psql.models.WeeklyBackupPolicy diff --git a/docs/api/psql/models/oci.psql.models.ShapeMemoryOptions.rst b/docs/api/psql/models/oci.psql.models.ShapeMemoryOptions.rst new file mode 100644 index 000000000..0e8c0a3ed --- /dev/null +++ b/docs/api/psql/models/oci.psql.models.ShapeMemoryOptions.rst @@ -0,0 +1,11 @@ +ShapeMemoryOptions +================== + +.. currentmodule:: oci.psql.models + +.. autoclass:: ShapeMemoryOptions + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/psql/models/oci.psql.models.ShapeOcpuOptions.rst b/docs/api/psql/models/oci.psql.models.ShapeOcpuOptions.rst new file mode 100644 index 000000000..f8302a862 --- /dev/null +++ b/docs/api/psql/models/oci.psql.models.ShapeOcpuOptions.rst @@ -0,0 +1,11 @@ +ShapeOcpuOptions +================ + +.. currentmodule:: oci.psql.models + +.. autoclass:: ShapeOcpuOptions + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/docs/api/psql/models/oci.psql.models.UpdateNetworkDetails.rst b/docs/api/psql/models/oci.psql.models.UpdateNetworkDetails.rst new file mode 100644 index 000000000..d3e71508f --- /dev/null +++ b/docs/api/psql/models/oci.psql.models.UpdateNetworkDetails.rst @@ -0,0 +1,11 @@ +UpdateNetworkDetails +==================== + +.. currentmodule:: oci.psql.models + +.. autoclass:: UpdateNetworkDetails + :show-inheritance: + :special-members: __init__ + :members: + :undoc-members: + :inherited-members: \ No newline at end of file diff --git a/src/oci/bds/bds_client.py b/src/oci/bds/bds_client.py index 611856466..a0b417b51 100644 --- a/src/oci/bds/bds_client.py +++ b/src/oci/bds/bds_client.py @@ -2068,6 +2068,115 @@ def create_node_replace_configuration(self, bds_instance_id, create_node_replace api_reference_link=api_reference_link, required_arguments=required_arguments) + def create_resource_principal_configuration(self, bds_instance_id, create_resource_principal_configuration_details, **kwargs): + """ + Create a resource principal session token configuration. + + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param oci.bds.models.CreateResourcePrincipalConfigurationDetails create_resource_principal_configuration_details: (required) + Details of creating resource principal session token for the bds cluster. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or + server error, without risk of executing that same action again. Retry tokens expire after 24 + hours but can be invalidated before then due to conflicting operations. For example, if a resource + has been deleted and purged from the system, then a retry of the original creation request + might be rejected. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation will not retry by default, users can also use the convenient :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` provided by the SDK to enable retries for it. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use create_resource_principal_configuration API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['bdsInstanceId'] + resource_path = "/bdsInstances/{bdsInstanceId}/resourcePrincipalConfigurations" + method = "POST" + operation_name = "create_resource_principal_configuration" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/CreateResourcePrincipalConfiguration" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "opc_retry_token" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"create_resource_principal_configuration got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "bdsInstanceId": bds_instance_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=create_resource_principal_configuration_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=create_resource_principal_configuration_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def delete_bds_api_key(self, bds_instance_id, api_key_id, **kwargs): """ Deletes the user's API key represented by the provided ID. @@ -2953,6 +3062,128 @@ def execute_bootstrap_script(self, bds_instance_id, execute_bootstrap_script_det api_reference_link=api_reference_link, required_arguments=required_arguments) + def force_refresh_resource_principal(self, bds_instance_id, resource_principal_configuration_id, force_refresh_resource_principal_details, **kwargs): + """ + Force Refresh Resource Principal for the cluster. + + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param oci.bds.models.ForceRefreshResourcePrincipalDetails force_refresh_resource_principal_details: (required) + Details of refreshing resource principal session token + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call + for a resource, set the `if-match` parameter to the value of the + etag from a previous GET or POST response for that resource. + The resource will be updated or deleted only if the etag you + provide matches the resource's current etag value. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or + server error, without risk of executing that same action again. Retry tokens expire after 24 + hours but can be invalidated before then due to conflicting operations. For example, if a resource + has been deleted and purged from the system, then a retry of the original creation request + might be rejected. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation will not retry by default, users can also use the convenient :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` provided by the SDK to enable retries for it. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use force_refresh_resource_principal API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['bdsInstanceId', 'resourcePrincipalConfigurationId'] + resource_path = "/bdsInstances/{bdsInstanceId}/resourcePrincipalConfigurations/{resourcePrincipalConfigurationId}/actions/forceRefreshResourcePrincipal" + method = "POST" + operation_name = "force_refresh_resource_principal" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/ForceRefreshResourcePrincipal" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "if_match", + "opc_retry_token" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"force_refresh_resource_principal got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "bdsInstanceId": bds_instance_id, + "resourcePrincipalConfigurationId": resource_principal_configuration_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing), + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=force_refresh_resource_principal_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=force_refresh_resource_principal_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def get_auto_scaling_configuration(self, bds_instance_id, auto_scaling_configuration_id, **kwargs): """ Returns details of the autoscale configuration identified by the given ID. @@ -3774,6 +4005,106 @@ def get_os_patch_details(self, bds_instance_id, os_patch_version, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) + def get_resource_principal_configuration(self, bds_instance_id, resource_principal_configuration_id, **kwargs): + """ + Returns details of the resourcePrincipalConfiguration identified by the given ID. + + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation will not retry by default, users can also use the convenient :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` provided by the SDK to enable retries for it. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.bds.models.ResourcePrincipalConfiguration` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_resource_principal_configuration API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['bdsInstanceId', 'resourcePrincipalConfigurationId'] + resource_path = "/bdsInstances/{bdsInstanceId}/resourcePrincipalConfigurations/{resourcePrincipalConfigurationId}" + method = "GET" + operation_name = "get_resource_principal_configuration" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/GetResourcePrincipalConfiguration" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_resource_principal_configuration got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "bdsInstanceId": bds_instance_id, + "resourcePrincipalConfigurationId": resource_principal_configuration_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="ResourcePrincipalConfiguration", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="ResourcePrincipalConfiguration", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def get_work_request(self, work_request_id, **kwargs): """ Returns the status of the work request identified by the given ID. @@ -5583,18 +5914,148 @@ def list_patches(self, bds_instance_id, **kwargs): List all the available patches for this cluster. - :param str bds_instance_id: (required) - The OCID of the cluster. + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param int limit: (optional) + The maximum number of items to return. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation will not retry by default, users can also use the convenient :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` provided by the SDK to enable retries for it. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.bds.models.PatchSummary` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_patches API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['bdsInstanceId'] + resource_path = "/bdsInstances/{bdsInstanceId}/patches" + method = "GET" + operation_name = "list_patches" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/ListPatches" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "page", + "limit" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_patches got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "bdsInstanceId": bds_instance_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "page": kwargs.get("page", missing), + "limit": kwargs.get("limit", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="list[PatchSummary]", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="list[PatchSummary]", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_resource_principal_configurations(self, bds_instance_id, **kwargs): + """ + Returns information about the ResourcePrincipalConfiguration. + + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param int limit: (optional) + The maximum number of items to return. + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. If no value is specified timeCreated is default. + + Allowed values are: "timeCreated", "displayName" + + :param str sort_order: (optional) + The sort order to use, either 'asc' or 'desc'. + + Allowed values are: "ASC", "DESC" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param str lifecycle_state: (optional) + The state of the ResourcePrincipalConfiguration. + + Allowed values are: "CREATING", "ACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED" :param str opc_request_id: (optional) The client request ID for tracing. - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - - :param int limit: (optional) - The maximum number of items to return. - :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -5607,31 +6068,35 @@ def list_patches(self, bds_instance_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.bds.models.PatchSummary` + :return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.bds.models.ResourcePrincipalConfigurationSummary` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_patches API. + Click `here `__ to see an example of how to use list_resource_principal_configurations API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['bdsInstanceId'] - resource_path = "/bdsInstances/{bdsInstanceId}/patches" + resource_path = "/bdsInstances/{bdsInstanceId}/resourcePrincipalConfigurations" method = "GET" - operation_name = "list_patches" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/ListPatches" + operation_name = "list_resource_principal_configurations" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/ListResourcePrincipalConfigurations" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "opc_request_id", "page", - "limit" + "limit", + "sort_by", + "sort_order", + "display_name", + "lifecycle_state", + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_patches got unknown kwargs: {extra_kwargs!r}") + f"list_resource_principal_configurations got unknown kwargs: {extra_kwargs!r}") path_params = { "bdsInstanceId": bds_instance_id @@ -5643,9 +6108,34 @@ def list_patches(self, bds_instance_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "ACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + query_params = { "page": kwargs.get("page", missing), - "limit": kwargs.get("limit", missing) + "limit": kwargs.get("limit", missing), + "sortBy": kwargs.get("sort_by", missing), + "sortOrder": kwargs.get("sort_order", missing), + "displayName": kwargs.get("display_name", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -5672,7 +6162,7 @@ def list_patches(self, bds_instance_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="list[PatchSummary]", + response_type="list[ResourcePrincipalConfigurationSummary]", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5684,7 +6174,7 @@ def list_patches(self, bds_instance_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="list[PatchSummary]", + response_type="list[ResourcePrincipalConfigurationSummary]", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6692,6 +7182,118 @@ def remove_node_replace_configuration(self, bds_instance_id, node_replace_config api_reference_link=api_reference_link, required_arguments=required_arguments) + def remove_resource_principal_configuration(self, bds_instance_id, resource_principal_configuration_id, remove_resource_principal_configuration_details, **kwargs): + """ + Delete the resource principal configuration for the cluster. + + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param oci.bds.models.RemoveResourcePrincipalConfigurationDetails remove_resource_principal_configuration_details: (required) + Details of removing a resource principal for the bds cluster. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call + for a resource, set the `if-match` parameter to the value of the + etag from a previous GET or POST response for that resource. + The resource will be updated or deleted only if the etag you + provide matches the resource's current etag value. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation will not retry by default, users can also use the convenient :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` provided by the SDK to enable retries for it. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use remove_resource_principal_configuration API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['bdsInstanceId', 'resourcePrincipalConfigurationId'] + resource_path = "/bdsInstances/{bdsInstanceId}/resourcePrincipalConfigurations/{resourcePrincipalConfigurationId}/actions/remove" + method = "POST" + operation_name = "remove_resource_principal_configuration" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/ResourcePrincipalConfiguration/RemoveResourcePrincipalConfiguration" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "if_match" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"remove_resource_principal_configuration got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "bdsInstanceId": bds_instance_id, + "resourcePrincipalConfigurationId": resource_principal_configuration_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing), + "if-match": kwargs.get("if_match", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=remove_resource_principal_configuration_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=remove_resource_principal_configuration_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def renew_certificate(self, bds_instance_id, renew_certificate_details, **kwargs): """ Renewing TLS/SSL for various ODH services running on the BDS cluster. @@ -8062,3 +8664,125 @@ def update_node_replace_configuration(self, bds_instance_id, node_replace_config operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) + + def update_resource_principal_configuration(self, bds_instance_id, resource_principal_configuration_id, update_resource_principal_configuration_details, **kwargs): + """ + Updates fields on resourcePrincipalConfiguration, including the name, the lifeSpanInHours of the token. + + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param oci.bds.models.UpdateResourcePrincipalConfigurationDetails update_resource_principal_configuration_details: (required) + Details for updating the resourcePrincipalConfiguration. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call + for a resource, set the `if-match` parameter to the value of the + etag from a previous GET or POST response for that resource. + The resource will be updated or deleted only if the etag you + provide matches the resource's current etag value. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or + server error, without risk of executing that same action again. Retry tokens expire after 24 + hours but can be invalidated before then due to conflicting operations. For example, if a resource + has been deleted and purged from the system, then a retry of the original creation request + might be rejected. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation will not retry by default, users can also use the convenient :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` provided by the SDK to enable retries for it. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use update_resource_principal_configuration API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['bdsInstanceId', 'resourcePrincipalConfigurationId'] + resource_path = "/bdsInstances/{bdsInstanceId}/resourcePrincipalConfigurations/{resourcePrincipalConfigurationId}" + method = "PUT" + operation_name = "update_resource_principal_configuration" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/bigdata/20190531/BdsInstance/UpdateResourcePrincipalConfiguration" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "if_match", + "opc_retry_token" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"update_resource_principal_configuration got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "bdsInstanceId": bds_instance_id, + "resourcePrincipalConfigurationId": resource_principal_configuration_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing), + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=update_resource_principal_configuration_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=update_resource_principal_configuration_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) diff --git a/src/oci/bds/bds_client_composite_operations.py b/src/oci/bds/bds_client_composite_operations.py index 3fb2cf38f..3d19d0ec8 100644 --- a/src/oci/bds/bds_client_composite_operations.py +++ b/src/oci/bds/bds_client_composite_operations.py @@ -697,6 +697,48 @@ def create_node_replace_configuration_and_wait_for_state(self, bds_instance_id, except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def create_resource_principal_configuration_and_wait_for_state(self, bds_instance_id, create_resource_principal_configuration_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.bds.BdsClient.create_resource_principal_configuration` and waits for the :py:class:`~oci.bds.models.WorkRequest` + to enter the given state(s). + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param oci.bds.models.CreateResourcePrincipalConfigurationDetails create_resource_principal_configuration_details: (required) + Details of creating resource principal session token for the bds cluster. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.bds.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.bds.BdsClient.create_resource_principal_configuration` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.create_resource_principal_configuration(bds_instance_id, create_resource_principal_configuration_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_bds_api_key_and_wait_for_state(self, bds_instance_id, api_key_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.bds.BdsClient.delete_bds_api_key` and waits for the :py:class:`~oci.bds.models.WorkRequest` @@ -1070,6 +1112,51 @@ def execute_bootstrap_script_and_wait_for_state(self, bds_instance_id, execute_b except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def force_refresh_resource_principal_and_wait_for_state(self, bds_instance_id, resource_principal_configuration_id, force_refresh_resource_principal_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.bds.BdsClient.force_refresh_resource_principal` and waits for the :py:class:`~oci.bds.models.WorkRequest` + to enter the given state(s). + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param oci.bds.models.ForceRefreshResourcePrincipalDetails force_refresh_resource_principal_details: (required) + Details of refreshing resource principal session token + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.bds.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.bds.BdsClient.force_refresh_resource_principal` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.force_refresh_resource_principal(bds_instance_id, resource_principal_configuration_id, force_refresh_resource_principal_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def install_os_patch_and_wait_for_state(self, bds_instance_id, install_os_patch_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.bds.BdsClient.install_os_patch` and waits for the :py:class:`~oci.bds.models.WorkRequest` @@ -1370,6 +1457,51 @@ def remove_node_replace_configuration_and_wait_for_state(self, bds_instance_id, except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def remove_resource_principal_configuration_and_wait_for_state(self, bds_instance_id, resource_principal_configuration_id, remove_resource_principal_configuration_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.bds.BdsClient.remove_resource_principal_configuration` and waits for the :py:class:`~oci.bds.models.WorkRequest` + to enter the given state(s). + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param oci.bds.models.RemoveResourcePrincipalConfigurationDetails remove_resource_principal_configuration_details: (required) + Details of removing a resource principal for the bds cluster. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.bds.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.bds.BdsClient.remove_resource_principal_configuration` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.remove_resource_principal_configuration(bds_instance_id, resource_principal_configuration_id, remove_resource_principal_configuration_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def renew_certificate_and_wait_for_state(self, bds_instance_id, renew_certificate_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.bds.BdsClient.renew_certificate` and waits for the :py:class:`~oci.bds.models.WorkRequest` @@ -1891,3 +2023,48 @@ def update_node_replace_configuration_and_wait_for_state(self, bds_instance_id, return result_to_return except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + + def update_resource_principal_configuration_and_wait_for_state(self, bds_instance_id, resource_principal_configuration_id, update_resource_principal_configuration_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.bds.BdsClient.update_resource_principal_configuration` and waits for the :py:class:`~oci.bds.models.WorkRequest` + to enter the given state(s). + + :param str bds_instance_id: (required) + The OCID of the cluster. + + :param str resource_principal_configuration_id: (required) + Unique Oracle-assigned identifier of the ResourcePrincipalConfiguration. + + :param oci.bds.models.UpdateResourcePrincipalConfigurationDetails update_resource_principal_configuration_details: (required) + Details for updating the resourcePrincipalConfiguration. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.bds.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.bds.BdsClient.update_resource_principal_configuration` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.update_resource_principal_configuration(bds_instance_id, resource_principal_configuration_id, update_resource_principal_configuration_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) diff --git a/src/oci/bds/models/__init__.py b/src/oci/bds/models/__init__.py index 4774baf89..2c2e03e2e 100644 --- a/src/oci/bds/models/__init__.py +++ b/src/oci/bds/models/__init__.py @@ -26,6 +26,7 @@ from .auto_scaling_configuration import AutoScalingConfiguration from .auto_scaling_configuration_summary import AutoScalingConfigurationSummary from .backup_node_details import BackupNodeDetails +from .batching_based_odh_patching_config import BatchingBasedOdhPatchingConfig from .batching_based_patching_configs import BatchingBasedPatchingConfigs from .bds_api_key import BdsApiKey from .bds_api_key_summary import BdsApiKeySummary @@ -46,13 +47,18 @@ from .create_node_backup_configuration_details import CreateNodeBackupConfigurationDetails from .create_node_details import CreateNodeDetails from .create_node_replace_configuration_details import CreateNodeReplaceConfigurationDetails +from .create_resource_principal_configuration_details import CreateResourcePrincipalConfigurationDetails from .day_based_horizontal_scaling_schedule_details import DayBasedHorizontalScalingScheduleDetails from .day_based_vertical_scaling_schedule_details import DayBasedVerticalScalingScheduleDetails from .default_error import DefaultError from .disable_certificate_details import DisableCertificateDetails +from .domain_based_odh_patching_config import DomainBasedOdhPatchingConfig +from .domain_based_patching_configs import DomainBasedPatchingConfigs +from .downtime_based_odh_patching_config import DowntimeBasedOdhPatchingConfig from .downtime_based_patching_configs import DowntimeBasedPatchingConfigs from .enable_certificate_details import EnableCertificateDetails from .execute_bootstrap_script_details import ExecuteBootstrapScriptDetails +from .force_refresh_resource_principal_details import ForceRefreshResourcePrincipalDetails from .horizontal_scaling_schedule_details import HorizontalScalingScheduleDetails from .host_cert_details import HostCertDetails from .host_specific_certificate_details import HostSpecificCertificateDetails @@ -77,6 +83,7 @@ from .node_replace_configuration import NodeReplaceConfiguration from .node_replace_configuration_summary import NodeReplaceConfigurationSummary from .node_type_level_details import NodeTypeLevelDetails +from .odh_patching_config import OdhPatchingConfig from .os_patch_details import OsPatchDetails from .os_patch_package_summary import OsPatchPackageSummary from .os_patch_summary import OsPatchSummary @@ -88,8 +95,11 @@ from .remove_kafka_details import RemoveKafkaDetails from .remove_node_details import RemoveNodeDetails from .remove_node_replace_configuration_details import RemoveNodeReplaceConfigurationDetails +from .remove_resource_principal_configuration_details import RemoveResourcePrincipalConfigurationDetails from .renew_certificate_details import RenewCertificateDetails from .replace_node_details import ReplaceNodeDetails +from .resource_principal_configuration import ResourcePrincipalConfiguration +from .resource_principal_configuration_summary import ResourcePrincipalConfigurationSummary from .restart_node_details import RestartNodeDetails from .schedule_based_horizontal_scaling_policy_details import ScheduleBasedHorizontalScalingPolicyDetails from .schedule_based_vertical_scaling_policy_details import ScheduleBasedVerticalScalingPolicyDetails @@ -108,6 +118,7 @@ from .update_metric_based_vertical_scaling_policy_details import UpdateMetricBasedVerticalScalingPolicyDetails from .update_node_backup_configuration_details import UpdateNodeBackupConfigurationDetails from .update_node_replace_configuration_details import UpdateNodeReplaceConfigurationDetails +from .update_resource_principal_configuration_details import UpdateResourcePrincipalConfigurationDetails from .update_schedule_based_horizontal_scaling_policy_details import UpdateScheduleBasedHorizontalScalingPolicyDetails from .update_schedule_based_vertical_scaling_policy_details import UpdateScheduleBasedVerticalScalingPolicyDetails from .vertical_scaling_schedule_details import VerticalScalingScheduleDetails @@ -139,6 +150,7 @@ "AutoScalingConfiguration": AutoScalingConfiguration, "AutoScalingConfigurationSummary": AutoScalingConfigurationSummary, "BackupNodeDetails": BackupNodeDetails, + "BatchingBasedOdhPatchingConfig": BatchingBasedOdhPatchingConfig, "BatchingBasedPatchingConfigs": BatchingBasedPatchingConfigs, "BdsApiKey": BdsApiKey, "BdsApiKeySummary": BdsApiKeySummary, @@ -159,13 +171,18 @@ "CreateNodeBackupConfigurationDetails": CreateNodeBackupConfigurationDetails, "CreateNodeDetails": CreateNodeDetails, "CreateNodeReplaceConfigurationDetails": CreateNodeReplaceConfigurationDetails, + "CreateResourcePrincipalConfigurationDetails": CreateResourcePrincipalConfigurationDetails, "DayBasedHorizontalScalingScheduleDetails": DayBasedHorizontalScalingScheduleDetails, "DayBasedVerticalScalingScheduleDetails": DayBasedVerticalScalingScheduleDetails, "DefaultError": DefaultError, "DisableCertificateDetails": DisableCertificateDetails, + "DomainBasedOdhPatchingConfig": DomainBasedOdhPatchingConfig, + "DomainBasedPatchingConfigs": DomainBasedPatchingConfigs, + "DowntimeBasedOdhPatchingConfig": DowntimeBasedOdhPatchingConfig, "DowntimeBasedPatchingConfigs": DowntimeBasedPatchingConfigs, "EnableCertificateDetails": EnableCertificateDetails, "ExecuteBootstrapScriptDetails": ExecuteBootstrapScriptDetails, + "ForceRefreshResourcePrincipalDetails": ForceRefreshResourcePrincipalDetails, "HorizontalScalingScheduleDetails": HorizontalScalingScheduleDetails, "HostCertDetails": HostCertDetails, "HostSpecificCertificateDetails": HostSpecificCertificateDetails, @@ -190,6 +207,7 @@ "NodeReplaceConfiguration": NodeReplaceConfiguration, "NodeReplaceConfigurationSummary": NodeReplaceConfigurationSummary, "NodeTypeLevelDetails": NodeTypeLevelDetails, + "OdhPatchingConfig": OdhPatchingConfig, "OsPatchDetails": OsPatchDetails, "OsPatchPackageSummary": OsPatchPackageSummary, "OsPatchSummary": OsPatchSummary, @@ -201,8 +219,11 @@ "RemoveKafkaDetails": RemoveKafkaDetails, "RemoveNodeDetails": RemoveNodeDetails, "RemoveNodeReplaceConfigurationDetails": RemoveNodeReplaceConfigurationDetails, + "RemoveResourcePrincipalConfigurationDetails": RemoveResourcePrincipalConfigurationDetails, "RenewCertificateDetails": RenewCertificateDetails, "ReplaceNodeDetails": ReplaceNodeDetails, + "ResourcePrincipalConfiguration": ResourcePrincipalConfiguration, + "ResourcePrincipalConfigurationSummary": ResourcePrincipalConfigurationSummary, "RestartNodeDetails": RestartNodeDetails, "ScheduleBasedHorizontalScalingPolicyDetails": ScheduleBasedHorizontalScalingPolicyDetails, "ScheduleBasedVerticalScalingPolicyDetails": ScheduleBasedVerticalScalingPolicyDetails, @@ -221,6 +242,7 @@ "UpdateMetricBasedVerticalScalingPolicyDetails": UpdateMetricBasedVerticalScalingPolicyDetails, "UpdateNodeBackupConfigurationDetails": UpdateNodeBackupConfigurationDetails, "UpdateNodeReplaceConfigurationDetails": UpdateNodeReplaceConfigurationDetails, + "UpdateResourcePrincipalConfigurationDetails": UpdateResourcePrincipalConfigurationDetails, "UpdateScheduleBasedHorizontalScalingPolicyDetails": UpdateScheduleBasedHorizontalScalingPolicyDetails, "UpdateScheduleBasedVerticalScalingPolicyDetails": UpdateScheduleBasedVerticalScalingPolicyDetails, "VerticalScalingScheduleDetails": VerticalScalingScheduleDetails, diff --git a/src/oci/bds/models/auto_scale_policy_metric_rule.py b/src/oci/bds/models/auto_scale_policy_metric_rule.py index 159a37a95..a84cdb18a 100644 --- a/src/oci/bds/models/auto_scale_policy_metric_rule.py +++ b/src/oci/bds/models/auto_scale_policy_metric_rule.py @@ -19,6 +19,10 @@ class AutoScalePolicyMetricRule(object): #: This constant has a value of "CPU_UTILIZATION" METRIC_TYPE_CPU_UTILIZATION = "CPU_UTILIZATION" + #: A constant which can be used with the metric_type property of a AutoScalePolicyMetricRule. + #: This constant has a value of "MEMORY_UTILIZATION" + METRIC_TYPE_MEMORY_UTILIZATION = "MEMORY_UTILIZATION" + def __init__(self, **kwargs): """ Initializes a new AutoScalePolicyMetricRule object with values from keyword arguments. @@ -26,7 +30,7 @@ def __init__(self, **kwargs): :param metric_type: The value to assign to the metric_type property of this AutoScalePolicyMetricRule. - Allowed values for this property are: "CPU_UTILIZATION", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CPU_UTILIZATION", "MEMORY_UTILIZATION", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type metric_type: str @@ -52,9 +56,9 @@ def __init__(self, **kwargs): def metric_type(self): """ **[Required]** Gets the metric_type of this AutoScalePolicyMetricRule. - Allowed value is CPU_UTILIZATION. + Allowed values are CPU_UTILIZATION and MEMORY_UTILIZATION. - Allowed values for this property are: "CPU_UTILIZATION", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CPU_UTILIZATION", "MEMORY_UTILIZATION", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -67,13 +71,13 @@ def metric_type(self): def metric_type(self, metric_type): """ Sets the metric_type of this AutoScalePolicyMetricRule. - Allowed value is CPU_UTILIZATION. + Allowed values are CPU_UTILIZATION and MEMORY_UTILIZATION. :param metric_type: The metric_type of this AutoScalePolicyMetricRule. :type: str """ - allowed_values = ["CPU_UTILIZATION"] + allowed_values = ["CPU_UTILIZATION", "MEMORY_UTILIZATION"] if not value_allowed_none_or_none_sentinel(metric_type, allowed_values): metric_type = 'UNKNOWN_ENUM_VALUE' self._metric_type = metric_type diff --git a/src/oci/bds/models/batching_based_odh_patching_config.py b/src/oci/bds/models/batching_based_odh_patching_config.py new file mode 100644 index 000000000..f0a40a797 --- /dev/null +++ b/src/oci/bds/models/batching_based_odh_patching_config.py @@ -0,0 +1,113 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + +from .odh_patching_config import OdhPatchingConfig +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class BatchingBasedOdhPatchingConfig(OdhPatchingConfig): + """ + Patching configurations which allows patch the nodes batch by batch. + """ + + def __init__(self, **kwargs): + """ + Initializes a new BatchingBasedOdhPatchingConfig object with values from keyword arguments. The default value of the :py:attr:`~oci.bds.models.BatchingBasedOdhPatchingConfig.patching_config_strategy` attribute + of this class is ``BATCHING_BASED`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param patching_config_strategy: + The value to assign to the patching_config_strategy property of this BatchingBasedOdhPatchingConfig. + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" + :type patching_config_strategy: str + + :param batch_size: + The value to assign to the batch_size property of this BatchingBasedOdhPatchingConfig. + :type batch_size: int + + :param wait_time_between_batch_in_seconds: + The value to assign to the wait_time_between_batch_in_seconds property of this BatchingBasedOdhPatchingConfig. + :type wait_time_between_batch_in_seconds: int + + """ + self.swagger_types = { + 'patching_config_strategy': 'str', + 'batch_size': 'int', + 'wait_time_between_batch_in_seconds': 'int' + } + + self.attribute_map = { + 'patching_config_strategy': 'patchingConfigStrategy', + 'batch_size': 'batchSize', + 'wait_time_between_batch_in_seconds': 'waitTimeBetweenBatchInSeconds' + } + + self._patching_config_strategy = None + self._batch_size = None + self._wait_time_between_batch_in_seconds = None + self._patching_config_strategy = 'BATCHING_BASED' + + @property + def batch_size(self): + """ + **[Required]** Gets the batch_size of this BatchingBasedOdhPatchingConfig. + How many nodes to be patched in each iteration. + + + :return: The batch_size of this BatchingBasedOdhPatchingConfig. + :rtype: int + """ + return self._batch_size + + @batch_size.setter + def batch_size(self, batch_size): + """ + Sets the batch_size of this BatchingBasedOdhPatchingConfig. + How many nodes to be patched in each iteration. + + + :param batch_size: The batch_size of this BatchingBasedOdhPatchingConfig. + :type: int + """ + self._batch_size = batch_size + + @property + def wait_time_between_batch_in_seconds(self): + """ + **[Required]** Gets the wait_time_between_batch_in_seconds of this BatchingBasedOdhPatchingConfig. + The wait time between batches in seconds. + + + :return: The wait_time_between_batch_in_seconds of this BatchingBasedOdhPatchingConfig. + :rtype: int + """ + return self._wait_time_between_batch_in_seconds + + @wait_time_between_batch_in_seconds.setter + def wait_time_between_batch_in_seconds(self, wait_time_between_batch_in_seconds): + """ + Sets the wait_time_between_batch_in_seconds of this BatchingBasedOdhPatchingConfig. + The wait time between batches in seconds. + + + :param wait_time_between_batch_in_seconds: The wait_time_between_batch_in_seconds of this BatchingBasedOdhPatchingConfig. + :type: int + """ + self._wait_time_between_batch_in_seconds = wait_time_between_batch_in_seconds + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/batching_based_patching_configs.py b/src/oci/bds/models/batching_based_patching_configs.py index b2417f09e..06287b782 100644 --- a/src/oci/bds/models/batching_based_patching_configs.py +++ b/src/oci/bds/models/batching_based_patching_configs.py @@ -12,7 +12,7 @@ @init_model_state_from_kwargs class BatchingBasedPatchingConfigs(PatchingConfigs): """ - Patching configurations which allows patch the nodes batch by batch. + Configuration that applies the patch in batches, the batch size is a user defined parameter. """ def __init__(self, **kwargs): @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param patching_config_strategy: The value to assign to the patching_config_strategy property of this BatchingBasedPatchingConfigs. - Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED" + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" :type patching_config_strategy: str :param batch_size: diff --git a/src/oci/bds/models/create_resource_principal_configuration_details.py b/src/oci/bds/models/create_resource_principal_configuration_details.py new file mode 100644 index 000000000..7ece2ff0f --- /dev/null +++ b/src/oci/bds/models/create_resource_principal_configuration_details.py @@ -0,0 +1,134 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateResourcePrincipalConfigurationDetails(object): + """ + Details of creating a resource principal configuration for the cluster. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreateResourcePrincipalConfigurationDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param display_name: + The value to assign to the display_name property of this CreateResourcePrincipalConfigurationDetails. + :type display_name: str + + :param cluster_admin_password: + The value to assign to the cluster_admin_password property of this CreateResourcePrincipalConfigurationDetails. + :type cluster_admin_password: str + + :param session_token_life_span_duration_in_hours: + The value to assign to the session_token_life_span_duration_in_hours property of this CreateResourcePrincipalConfigurationDetails. + :type session_token_life_span_duration_in_hours: int + + """ + self.swagger_types = { + 'display_name': 'str', + 'cluster_admin_password': 'str', + 'session_token_life_span_duration_in_hours': 'int' + } + + self.attribute_map = { + 'display_name': 'displayName', + 'cluster_admin_password': 'clusterAdminPassword', + 'session_token_life_span_duration_in_hours': 'sessionTokenLifeSpanDurationInHours' + } + + self._display_name = None + self._cluster_admin_password = None + self._session_token_life_span_duration_in_hours = None + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this CreateResourcePrincipalConfigurationDetails. + A user-friendly name. Only ASCII alphanumeric characters with no spaces allowed. The name does not have to be unique, and it may be changed. Avoid entering confidential information. + + + :return: The display_name of this CreateResourcePrincipalConfigurationDetails. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this CreateResourcePrincipalConfigurationDetails. + A user-friendly name. Only ASCII alphanumeric characters with no spaces allowed. The name does not have to be unique, and it may be changed. Avoid entering confidential information. + + + :param display_name: The display_name of this CreateResourcePrincipalConfigurationDetails. + :type: str + """ + self._display_name = display_name + + @property + def cluster_admin_password(self): + """ + **[Required]** Gets the cluster_admin_password of this CreateResourcePrincipalConfigurationDetails. + Base-64 encoded Cluster Admin Password for cluster admin user. + + + :return: The cluster_admin_password of this CreateResourcePrincipalConfigurationDetails. + :rtype: str + """ + return self._cluster_admin_password + + @cluster_admin_password.setter + def cluster_admin_password(self, cluster_admin_password): + """ + Sets the cluster_admin_password of this CreateResourcePrincipalConfigurationDetails. + Base-64 encoded Cluster Admin Password for cluster admin user. + + + :param cluster_admin_password: The cluster_admin_password of this CreateResourcePrincipalConfigurationDetails. + :type: str + """ + self._cluster_admin_password = cluster_admin_password + + @property + def session_token_life_span_duration_in_hours(self): + """ + Gets the session_token_life_span_duration_in_hours of this CreateResourcePrincipalConfigurationDetails. + Life span in hours for the resource principal session token. + + + :return: The session_token_life_span_duration_in_hours of this CreateResourcePrincipalConfigurationDetails. + :rtype: int + """ + return self._session_token_life_span_duration_in_hours + + @session_token_life_span_duration_in_hours.setter + def session_token_life_span_duration_in_hours(self, session_token_life_span_duration_in_hours): + """ + Sets the session_token_life_span_duration_in_hours of this CreateResourcePrincipalConfigurationDetails. + Life span in hours for the resource principal session token. + + + :param session_token_life_span_duration_in_hours: The session_token_life_span_duration_in_hours of this CreateResourcePrincipalConfigurationDetails. + :type: int + """ + self._session_token_life_span_duration_in_hours = session_token_life_span_duration_in_hours + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/domain_based_odh_patching_config.py b/src/oci/bds/models/domain_based_odh_patching_config.py new file mode 100644 index 000000000..d0061d57b --- /dev/null +++ b/src/oci/bds/models/domain_based_odh_patching_config.py @@ -0,0 +1,82 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + +from .odh_patching_config import OdhPatchingConfig +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DomainBasedOdhPatchingConfig(OdhPatchingConfig): + """ + This patching config will patch all nodes in one AD/FD at a time. + """ + + def __init__(self, **kwargs): + """ + Initializes a new DomainBasedOdhPatchingConfig object with values from keyword arguments. The default value of the :py:attr:`~oci.bds.models.DomainBasedOdhPatchingConfig.patching_config_strategy` attribute + of this class is ``DOMAIN_BASED`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param patching_config_strategy: + The value to assign to the patching_config_strategy property of this DomainBasedOdhPatchingConfig. + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" + :type patching_config_strategy: str + + :param wait_time_between_domain_in_seconds: + The value to assign to the wait_time_between_domain_in_seconds property of this DomainBasedOdhPatchingConfig. + :type wait_time_between_domain_in_seconds: int + + """ + self.swagger_types = { + 'patching_config_strategy': 'str', + 'wait_time_between_domain_in_seconds': 'int' + } + + self.attribute_map = { + 'patching_config_strategy': 'patchingConfigStrategy', + 'wait_time_between_domain_in_seconds': 'waitTimeBetweenDomainInSeconds' + } + + self._patching_config_strategy = None + self._wait_time_between_domain_in_seconds = None + self._patching_config_strategy = 'DOMAIN_BASED' + + @property + def wait_time_between_domain_in_seconds(self): + """ + **[Required]** Gets the wait_time_between_domain_in_seconds of this DomainBasedOdhPatchingConfig. + The wait time between AD/FD in seconds. + + + :return: The wait_time_between_domain_in_seconds of this DomainBasedOdhPatchingConfig. + :rtype: int + """ + return self._wait_time_between_domain_in_seconds + + @wait_time_between_domain_in_seconds.setter + def wait_time_between_domain_in_seconds(self, wait_time_between_domain_in_seconds): + """ + Sets the wait_time_between_domain_in_seconds of this DomainBasedOdhPatchingConfig. + The wait time between AD/FD in seconds. + + + :param wait_time_between_domain_in_seconds: The wait_time_between_domain_in_seconds of this DomainBasedOdhPatchingConfig. + :type: int + """ + self._wait_time_between_domain_in_seconds = wait_time_between_domain_in_seconds + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/domain_based_patching_configs.py b/src/oci/bds/models/domain_based_patching_configs.py new file mode 100644 index 000000000..12dfe594a --- /dev/null +++ b/src/oci/bds/models/domain_based_patching_configs.py @@ -0,0 +1,113 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + +from .patching_configs import PatchingConfigs +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DomainBasedPatchingConfigs(PatchingConfigs): + """ + This patching config will patch all nodes in one AD/FD at a time. + """ + + def __init__(self, **kwargs): + """ + Initializes a new DomainBasedPatchingConfigs object with values from keyword arguments. The default value of the :py:attr:`~oci.bds.models.DomainBasedPatchingConfigs.patching_config_strategy` attribute + of this class is ``DOMAIN_BASED`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param patching_config_strategy: + The value to assign to the patching_config_strategy property of this DomainBasedPatchingConfigs. + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" + :type patching_config_strategy: str + + :param wait_time_between_domain_in_seconds: + The value to assign to the wait_time_between_domain_in_seconds property of this DomainBasedPatchingConfigs. + :type wait_time_between_domain_in_seconds: int + + :param tolerance_threshold_per_domain: + The value to assign to the tolerance_threshold_per_domain property of this DomainBasedPatchingConfigs. + :type tolerance_threshold_per_domain: int + + """ + self.swagger_types = { + 'patching_config_strategy': 'str', + 'wait_time_between_domain_in_seconds': 'int', + 'tolerance_threshold_per_domain': 'int' + } + + self.attribute_map = { + 'patching_config_strategy': 'patchingConfigStrategy', + 'wait_time_between_domain_in_seconds': 'waitTimeBetweenDomainInSeconds', + 'tolerance_threshold_per_domain': 'toleranceThresholdPerDomain' + } + + self._patching_config_strategy = None + self._wait_time_between_domain_in_seconds = None + self._tolerance_threshold_per_domain = None + self._patching_config_strategy = 'DOMAIN_BASED' + + @property + def wait_time_between_domain_in_seconds(self): + """ + **[Required]** Gets the wait_time_between_domain_in_seconds of this DomainBasedPatchingConfigs. + The wait time between AD/FD in seconds. + + + :return: The wait_time_between_domain_in_seconds of this DomainBasedPatchingConfigs. + :rtype: int + """ + return self._wait_time_between_domain_in_seconds + + @wait_time_between_domain_in_seconds.setter + def wait_time_between_domain_in_seconds(self, wait_time_between_domain_in_seconds): + """ + Sets the wait_time_between_domain_in_seconds of this DomainBasedPatchingConfigs. + The wait time between AD/FD in seconds. + + + :param wait_time_between_domain_in_seconds: The wait_time_between_domain_in_seconds of this DomainBasedPatchingConfigs. + :type: int + """ + self._wait_time_between_domain_in_seconds = wait_time_between_domain_in_seconds + + @property + def tolerance_threshold_per_domain(self): + """ + **[Required]** Gets the tolerance_threshold_per_domain of this DomainBasedPatchingConfigs. + Acceptable number of failed-to-be-patched nodes in each domain. The maximum number of failed-to-patch nodes cannot exceed 20% of the number of nodes. + + + :return: The tolerance_threshold_per_domain of this DomainBasedPatchingConfigs. + :rtype: int + """ + return self._tolerance_threshold_per_domain + + @tolerance_threshold_per_domain.setter + def tolerance_threshold_per_domain(self, tolerance_threshold_per_domain): + """ + Sets the tolerance_threshold_per_domain of this DomainBasedPatchingConfigs. + Acceptable number of failed-to-be-patched nodes in each domain. The maximum number of failed-to-patch nodes cannot exceed 20% of the number of nodes. + + + :param tolerance_threshold_per_domain: The tolerance_threshold_per_domain of this DomainBasedPatchingConfigs. + :type: int + """ + self._tolerance_threshold_per_domain = tolerance_threshold_per_domain + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/downtime_based_odh_patching_config.py b/src/oci/bds/models/downtime_based_odh_patching_config.py new file mode 100644 index 000000000..00b8ce5fd --- /dev/null +++ b/src/oci/bds/models/downtime_based_odh_patching_config.py @@ -0,0 +1,51 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + +from .odh_patching_config import OdhPatchingConfig +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DowntimeBasedOdhPatchingConfig(OdhPatchingConfig): + """ + Patching configurations which allows downtime. This patching config will patch all the nodes in parallel. + """ + + def __init__(self, **kwargs): + """ + Initializes a new DowntimeBasedOdhPatchingConfig object with values from keyword arguments. The default value of the :py:attr:`~oci.bds.models.DowntimeBasedOdhPatchingConfig.patching_config_strategy` attribute + of this class is ``DOWNTIME_BASED`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param patching_config_strategy: + The value to assign to the patching_config_strategy property of this DowntimeBasedOdhPatchingConfig. + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" + :type patching_config_strategy: str + + """ + self.swagger_types = { + 'patching_config_strategy': 'str' + } + + self.attribute_map = { + 'patching_config_strategy': 'patchingConfigStrategy' + } + + self._patching_config_strategy = None + self._patching_config_strategy = 'DOWNTIME_BASED' + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/downtime_based_patching_configs.py b/src/oci/bds/models/downtime_based_patching_configs.py index 4f005e244..9930c9a33 100644 --- a/src/oci/bds/models/downtime_based_patching_configs.py +++ b/src/oci/bds/models/downtime_based_patching_configs.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param patching_config_strategy: The value to assign to the patching_config_strategy property of this DowntimeBasedPatchingConfigs. - Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED" + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" :type patching_config_strategy: str """ diff --git a/src/oci/bds/models/force_refresh_resource_principal_details.py b/src/oci/bds/models/force_refresh_resource_principal_details.py new file mode 100644 index 000000000..69531d825 --- /dev/null +++ b/src/oci/bds/models/force_refresh_resource_principal_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ForceRefreshResourcePrincipalDetails(object): + """ + Force Refresh Resource Principal Session Token Details. + """ + + def __init__(self, **kwargs): + """ + Initializes a new ForceRefreshResourcePrincipalDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param cluster_admin_password: + The value to assign to the cluster_admin_password property of this ForceRefreshResourcePrincipalDetails. + :type cluster_admin_password: str + + """ + self.swagger_types = { + 'cluster_admin_password': 'str' + } + + self.attribute_map = { + 'cluster_admin_password': 'clusterAdminPassword' + } + + self._cluster_admin_password = None + + @property + def cluster_admin_password(self): + """ + **[Required]** Gets the cluster_admin_password of this ForceRefreshResourcePrincipalDetails. + Base-64 encoded Cluster Admin Password for cluster admin user. + + + :return: The cluster_admin_password of this ForceRefreshResourcePrincipalDetails. + :rtype: str + """ + return self._cluster_admin_password + + @cluster_admin_password.setter + def cluster_admin_password(self, cluster_admin_password): + """ + Sets the cluster_admin_password of this ForceRefreshResourcePrincipalDetails. + Base-64 encoded Cluster Admin Password for cluster admin user. + + + :param cluster_admin_password: The cluster_admin_password of this ForceRefreshResourcePrincipalDetails. + :type: str + """ + self._cluster_admin_password = cluster_admin_password + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/install_patch_details.py b/src/oci/bds/models/install_patch_details.py index 302383021..3bd20e936 100644 --- a/src/oci/bds/models/install_patch_details.py +++ b/src/oci/bds/models/install_patch_details.py @@ -28,19 +28,26 @@ def __init__(self, **kwargs): The value to assign to the cluster_admin_password property of this InstallPatchDetails. :type cluster_admin_password: str + :param patching_config: + The value to assign to the patching_config property of this InstallPatchDetails. + :type patching_config: oci.bds.models.OdhPatchingConfig + """ self.swagger_types = { 'version': 'str', - 'cluster_admin_password': 'str' + 'cluster_admin_password': 'str', + 'patching_config': 'OdhPatchingConfig' } self.attribute_map = { 'version': 'version', - 'cluster_admin_password': 'clusterAdminPassword' + 'cluster_admin_password': 'clusterAdminPassword', + 'patching_config': 'patchingConfig' } self._version = None self._cluster_admin_password = None + self._patching_config = None @property def version(self): @@ -90,6 +97,26 @@ def cluster_admin_password(self, cluster_admin_password): """ self._cluster_admin_password = cluster_admin_password + @property + def patching_config(self): + """ + Gets the patching_config of this InstallPatchDetails. + + :return: The patching_config of this InstallPatchDetails. + :rtype: oci.bds.models.OdhPatchingConfig + """ + return self._patching_config + + @patching_config.setter + def patching_config(self, patching_config): + """ + Sets the patching_config of this InstallPatchDetails. + + :param patching_config: The patching_config of this InstallPatchDetails. + :type: oci.bds.models.OdhPatchingConfig + """ + self._patching_config = patching_config + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/bds/models/node.py b/src/oci/bds/models/node.py index 383fea984..1a4ed07b8 100644 --- a/src/oci/bds/models/node.py +++ b/src/oci/bds/models/node.py @@ -184,6 +184,10 @@ def __init__(self, **kwargs): The value to assign to the is_reboot_required property of this Node. :type is_reboot_required: bool + :param odh_version: + The value to assign to the odh_version property of this Node. + :type odh_version: str + :param time_replaced: The value to assign to the time_replaced property of this Node. :type time_replaced: datetime @@ -216,6 +220,7 @@ def __init__(self, **kwargs): 'time_maintenance_reboot_due': 'datetime', 'os_version': 'str', 'is_reboot_required': 'bool', + 'odh_version': 'str', 'time_replaced': 'datetime', 'node_backup_id': 'str' } @@ -243,6 +248,7 @@ def __init__(self, **kwargs): 'time_maintenance_reboot_due': 'timeMaintenanceRebootDue', 'os_version': 'osVersion', 'is_reboot_required': 'isRebootRequired', + 'odh_version': 'odhVersion', 'time_replaced': 'timeReplaced', 'node_backup_id': 'nodeBackupId' } @@ -269,6 +275,7 @@ def __init__(self, **kwargs): self._time_maintenance_reboot_due = None self._os_version = None self._is_reboot_required = None + self._odh_version = None self._time_replaced = None self._node_backup_id = None @@ -812,6 +819,30 @@ def is_reboot_required(self, is_reboot_required): """ self._is_reboot_required = is_reboot_required + @property + def odh_version(self): + """ + Gets the odh_version of this Node. + Version of the ODH (Oracle Distribution including Apache Hadoop) for the node. + + + :return: The odh_version of this Node. + :rtype: str + """ + return self._odh_version + + @odh_version.setter + def odh_version(self, odh_version): + """ + Sets the odh_version of this Node. + Version of the ODH (Oracle Distribution including Apache Hadoop) for the node. + + + :param odh_version: The odh_version of this Node. + :type: str + """ + self._odh_version = odh_version + @property def time_replaced(self): """ diff --git a/src/oci/bds/models/odh_patching_config.py b/src/oci/bds/models/odh_patching_config.py new file mode 100644 index 000000000..e068a7645 --- /dev/null +++ b/src/oci/bds/models/odh_patching_config.py @@ -0,0 +1,117 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class OdhPatchingConfig(object): + """ + Detailed configurations for defining the behavior when installing ODH patches. If not provided, nodes will be patched with down time. + """ + + #: A constant which can be used with the patching_config_strategy property of a OdhPatchingConfig. + #: This constant has a value of "DOWNTIME_BASED" + PATCHING_CONFIG_STRATEGY_DOWNTIME_BASED = "DOWNTIME_BASED" + + #: A constant which can be used with the patching_config_strategy property of a OdhPatchingConfig. + #: This constant has a value of "BATCHING_BASED" + PATCHING_CONFIG_STRATEGY_BATCHING_BASED = "BATCHING_BASED" + + #: A constant which can be used with the patching_config_strategy property of a OdhPatchingConfig. + #: This constant has a value of "DOMAIN_BASED" + PATCHING_CONFIG_STRATEGY_DOMAIN_BASED = "DOMAIN_BASED" + + def __init__(self, **kwargs): + """ + Initializes a new OdhPatchingConfig object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.bds.models.DowntimeBasedOdhPatchingConfig` + * :class:`~oci.bds.models.DomainBasedOdhPatchingConfig` + * :class:`~oci.bds.models.BatchingBasedOdhPatchingConfig` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param patching_config_strategy: + The value to assign to the patching_config_strategy property of this OdhPatchingConfig. + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" + :type patching_config_strategy: str + + """ + self.swagger_types = { + 'patching_config_strategy': 'str' + } + + self.attribute_map = { + 'patching_config_strategy': 'patchingConfigStrategy' + } + + self._patching_config_strategy = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['patchingConfigStrategy'] + + if type == 'DOWNTIME_BASED': + return 'DowntimeBasedOdhPatchingConfig' + + if type == 'DOMAIN_BASED': + return 'DomainBasedOdhPatchingConfig' + + if type == 'BATCHING_BASED': + return 'BatchingBasedOdhPatchingConfig' + else: + return 'OdhPatchingConfig' + + @property + def patching_config_strategy(self): + """ + **[Required]** Gets the patching_config_strategy of this OdhPatchingConfig. + Type of strategy used for detailed patching configuration + + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" + + + :return: The patching_config_strategy of this OdhPatchingConfig. + :rtype: str + """ + return self._patching_config_strategy + + @patching_config_strategy.setter + def patching_config_strategy(self, patching_config_strategy): + """ + Sets the patching_config_strategy of this OdhPatchingConfig. + Type of strategy used for detailed patching configuration + + + :param patching_config_strategy: The patching_config_strategy of this OdhPatchingConfig. + :type: str + """ + allowed_values = ["DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED"] + if not value_allowed_none_or_none_sentinel(patching_config_strategy, allowed_values): + raise ValueError( + f"Invalid value for `patching_config_strategy`, must be None or one of {allowed_values}" + ) + self._patching_config_strategy = patching_config_strategy + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/patching_configs.py b/src/oci/bds/models/patching_configs.py index 776b03949..f68c07532 100644 --- a/src/oci/bds/models/patching_configs.py +++ b/src/oci/bds/models/patching_configs.py @@ -12,7 +12,7 @@ @init_model_state_from_kwargs class PatchingConfigs(object): """ - Detailed configurations for defining the behavior when installing os patches. If not provided, nodes will be patched and rebooted AD/FD by AD/FD. + Detailed configurations for defining the behavior when installing os patches. If not provided, nodes will be patched and rebooted AD/FD by AD/FD for regular patches or will be patched with down time if the patch is an emergent patch. """ #: A constant which can be used with the patching_config_strategy property of a PatchingConfigs. @@ -23,6 +23,10 @@ class PatchingConfigs(object): #: This constant has a value of "BATCHING_BASED" PATCHING_CONFIG_STRATEGY_BATCHING_BASED = "BATCHING_BASED" + #: A constant which can be used with the patching_config_strategy property of a PatchingConfigs. + #: This constant has a value of "DOMAIN_BASED" + PATCHING_CONFIG_STRATEGY_DOMAIN_BASED = "DOMAIN_BASED" + def __init__(self, **kwargs): """ Initializes a new PatchingConfigs object with values from keyword arguments. This class has the following subclasses and if you are using this class as input @@ -30,12 +34,13 @@ def __init__(self, **kwargs): * :class:`~oci.bds.models.BatchingBasedPatchingConfigs` * :class:`~oci.bds.models.DowntimeBasedPatchingConfigs` + * :class:`~oci.bds.models.DomainBasedPatchingConfigs` The following keyword arguments are supported (corresponding to the getters/setters of this class): :param patching_config_strategy: The value to assign to the patching_config_strategy property of this PatchingConfigs. - Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED" + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" :type patching_config_strategy: str """ @@ -62,6 +67,9 @@ def get_subtype(object_dictionary): if type == 'DOWNTIME_BASED': return 'DowntimeBasedPatchingConfigs' + + if type == 'DOMAIN_BASED': + return 'DomainBasedPatchingConfigs' else: return 'PatchingConfigs' @@ -71,7 +79,7 @@ def patching_config_strategy(self): **[Required]** Gets the patching_config_strategy of this PatchingConfigs. Type of strategy used for detailed patching configuration - Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED" + Allowed values for this property are: "DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED" :return: The patching_config_strategy of this PatchingConfigs. @@ -89,7 +97,7 @@ def patching_config_strategy(self, patching_config_strategy): :param patching_config_strategy: The patching_config_strategy of this PatchingConfigs. :type: str """ - allowed_values = ["DOWNTIME_BASED", "BATCHING_BASED"] + allowed_values = ["DOWNTIME_BASED", "BATCHING_BASED", "DOMAIN_BASED"] if not value_allowed_none_or_none_sentinel(patching_config_strategy, allowed_values): raise ValueError( f"Invalid value for `patching_config_strategy`, must be None or one of {allowed_values}" diff --git a/src/oci/bds/models/remove_resource_principal_configuration_details.py b/src/oci/bds/models/remove_resource_principal_configuration_details.py new file mode 100644 index 000000000..4b453c0c7 --- /dev/null +++ b/src/oci/bds/models/remove_resource_principal_configuration_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RemoveResourcePrincipalConfigurationDetails(object): + """ + Details of removing a resource principal configuration for the cluster. + """ + + def __init__(self, **kwargs): + """ + Initializes a new RemoveResourcePrincipalConfigurationDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param cluster_admin_password: + The value to assign to the cluster_admin_password property of this RemoveResourcePrincipalConfigurationDetails. + :type cluster_admin_password: str + + """ + self.swagger_types = { + 'cluster_admin_password': 'str' + } + + self.attribute_map = { + 'cluster_admin_password': 'clusterAdminPassword' + } + + self._cluster_admin_password = None + + @property + def cluster_admin_password(self): + """ + **[Required]** Gets the cluster_admin_password of this RemoveResourcePrincipalConfigurationDetails. + Base-64 encoded Cluster Admin Password for cluster admin user. + + + :return: The cluster_admin_password of this RemoveResourcePrincipalConfigurationDetails. + :rtype: str + """ + return self._cluster_admin_password + + @cluster_admin_password.setter + def cluster_admin_password(self, cluster_admin_password): + """ + Sets the cluster_admin_password of this RemoveResourcePrincipalConfigurationDetails. + Base-64 encoded Cluster Admin Password for cluster admin user. + + + :param cluster_admin_password: The cluster_admin_password of this RemoveResourcePrincipalConfigurationDetails. + :type: str + """ + self._cluster_admin_password = cluster_admin_password + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/resource_principal_configuration.py b/src/oci/bds/models/resource_principal_configuration.py new file mode 100644 index 000000000..e01822fe7 --- /dev/null +++ b/src/oci/bds/models/resource_principal_configuration.py @@ -0,0 +1,352 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ResourcePrincipalConfiguration(object): + """ + Resource Principal Session Token Details. + """ + + #: A constant which can be used with the lifecycle_state property of a ResourcePrincipalConfiguration. + #: This constant has a value of "CREATING" + LIFECYCLE_STATE_CREATING = "CREATING" + + #: A constant which can be used with the lifecycle_state property of a ResourcePrincipalConfiguration. + #: This constant has a value of "ACTIVE" + LIFECYCLE_STATE_ACTIVE = "ACTIVE" + + #: A constant which can be used with the lifecycle_state property of a ResourcePrincipalConfiguration. + #: This constant has a value of "UPDATING" + LIFECYCLE_STATE_UPDATING = "UPDATING" + + #: A constant which can be used with the lifecycle_state property of a ResourcePrincipalConfiguration. + #: This constant has a value of "DELETING" + LIFECYCLE_STATE_DELETING = "DELETING" + + #: A constant which can be used with the lifecycle_state property of a ResourcePrincipalConfiguration. + #: This constant has a value of "DELETED" + LIFECYCLE_STATE_DELETED = "DELETED" + + #: A constant which can be used with the lifecycle_state property of a ResourcePrincipalConfiguration. + #: This constant has a value of "FAILED" + LIFECYCLE_STATE_FAILED = "FAILED" + + def __init__(self, **kwargs): + """ + Initializes a new ResourcePrincipalConfiguration object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this ResourcePrincipalConfiguration. + :type id: str + + :param bds_instance_id: + The value to assign to the bds_instance_id property of this ResourcePrincipalConfiguration. + :type bds_instance_id: str + + :param display_name: + The value to assign to the display_name property of this ResourcePrincipalConfiguration. + :type display_name: str + + :param session_token_life_span_duration_in_hours: + The value to assign to the session_token_life_span_duration_in_hours property of this ResourcePrincipalConfiguration. + :type session_token_life_span_duration_in_hours: int + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this ResourcePrincipalConfiguration. + Allowed values for this property are: "CREATING", "ACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type lifecycle_state: str + + :param time_token_refreshed: + The value to assign to the time_token_refreshed property of this ResourcePrincipalConfiguration. + :type time_token_refreshed: datetime + + :param time_token_expiry: + The value to assign to the time_token_expiry property of this ResourcePrincipalConfiguration. + :type time_token_expiry: datetime + + :param time_created: + The value to assign to the time_created property of this ResourcePrincipalConfiguration. + :type time_created: datetime + + :param time_updated: + The value to assign to the time_updated property of this ResourcePrincipalConfiguration. + :type time_updated: datetime + + """ + self.swagger_types = { + 'id': 'str', + 'bds_instance_id': 'str', + 'display_name': 'str', + 'session_token_life_span_duration_in_hours': 'int', + 'lifecycle_state': 'str', + 'time_token_refreshed': 'datetime', + 'time_token_expiry': 'datetime', + 'time_created': 'datetime', + 'time_updated': 'datetime' + } + + self.attribute_map = { + 'id': 'id', + 'bds_instance_id': 'bdsInstanceId', + 'display_name': 'displayName', + 'session_token_life_span_duration_in_hours': 'sessionTokenLifeSpanDurationInHours', + 'lifecycle_state': 'lifecycleState', + 'time_token_refreshed': 'timeTokenRefreshed', + 'time_token_expiry': 'timeTokenExpiry', + 'time_created': 'timeCreated', + 'time_updated': 'timeUpdated' + } + + self._id = None + self._bds_instance_id = None + self._display_name = None + self._session_token_life_span_duration_in_hours = None + self._lifecycle_state = None + self._time_token_refreshed = None + self._time_token_expiry = None + self._time_created = None + self._time_updated = None + + @property + def id(self): + """ + **[Required]** Gets the id of this ResourcePrincipalConfiguration. + The id of the ResourcePrincipalConfiguration. + + + :return: The id of this ResourcePrincipalConfiguration. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this ResourcePrincipalConfiguration. + The id of the ResourcePrincipalConfiguration. + + + :param id: The id of this ResourcePrincipalConfiguration. + :type: str + """ + self._id = id + + @property + def bds_instance_id(self): + """ + **[Required]** Gets the bds_instance_id of this ResourcePrincipalConfiguration. + The OCID of the bdsInstance which is the parent resource id. + + + :return: The bds_instance_id of this ResourcePrincipalConfiguration. + :rtype: str + """ + return self._bds_instance_id + + @bds_instance_id.setter + def bds_instance_id(self, bds_instance_id): + """ + Sets the bds_instance_id of this ResourcePrincipalConfiguration. + The OCID of the bdsInstance which is the parent resource id. + + + :param bds_instance_id: The bds_instance_id of this ResourcePrincipalConfiguration. + :type: str + """ + self._bds_instance_id = bds_instance_id + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this ResourcePrincipalConfiguration. + A user-friendly name. Only ASCII alphanumeric characters with no spaces allowed. The name does not have to be unique, and it may be changed. Avoid entering confidential information. + + + :return: The display_name of this ResourcePrincipalConfiguration. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this ResourcePrincipalConfiguration. + A user-friendly name. Only ASCII alphanumeric characters with no spaces allowed. The name does not have to be unique, and it may be changed. Avoid entering confidential information. + + + :param display_name: The display_name of this ResourcePrincipalConfiguration. + :type: str + """ + self._display_name = display_name + + @property + def session_token_life_span_duration_in_hours(self): + """ + **[Required]** Gets the session_token_life_span_duration_in_hours of this ResourcePrincipalConfiguration. + Life span in hours of each resource principal session token. + + + :return: The session_token_life_span_duration_in_hours of this ResourcePrincipalConfiguration. + :rtype: int + """ + return self._session_token_life_span_duration_in_hours + + @session_token_life_span_duration_in_hours.setter + def session_token_life_span_duration_in_hours(self, session_token_life_span_duration_in_hours): + """ + Sets the session_token_life_span_duration_in_hours of this ResourcePrincipalConfiguration. + Life span in hours of each resource principal session token. + + + :param session_token_life_span_duration_in_hours: The session_token_life_span_duration_in_hours of this ResourcePrincipalConfiguration. + :type: int + """ + self._session_token_life_span_duration_in_hours = session_token_life_span_duration_in_hours + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this ResourcePrincipalConfiguration. + The state of the ResourcePrincipalConfiguration. + + Allowed values for this property are: "CREATING", "ACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The lifecycle_state of this ResourcePrincipalConfiguration. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this ResourcePrincipalConfiguration. + The state of the ResourcePrincipalConfiguration. + + + :param lifecycle_state: The lifecycle_state of this ResourcePrincipalConfiguration. + :type: str + """ + allowed_values = ["CREATING", "ACTIVE", "UPDATING", "DELETING", "DELETED", "FAILED"] + if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): + lifecycle_state = 'UNKNOWN_ENUM_VALUE' + self._lifecycle_state = lifecycle_state + + @property + def time_token_refreshed(self): + """ + Gets the time_token_refreshed of this ResourcePrincipalConfiguration. + the time the resource principal session token was refreshed, shown as an rfc 3339 formatted datetime string. + + + :return: The time_token_refreshed of this ResourcePrincipalConfiguration. + :rtype: datetime + """ + return self._time_token_refreshed + + @time_token_refreshed.setter + def time_token_refreshed(self, time_token_refreshed): + """ + Sets the time_token_refreshed of this ResourcePrincipalConfiguration. + the time the resource principal session token was refreshed, shown as an rfc 3339 formatted datetime string. + + + :param time_token_refreshed: The time_token_refreshed of this ResourcePrincipalConfiguration. + :type: datetime + """ + self._time_token_refreshed = time_token_refreshed + + @property + def time_token_expiry(self): + """ + Gets the time_token_expiry of this ResourcePrincipalConfiguration. + the time the resource principal session token will expired, shown as an rfc 3339 formatted datetime string. + + + :return: The time_token_expiry of this ResourcePrincipalConfiguration. + :rtype: datetime + """ + return self._time_token_expiry + + @time_token_expiry.setter + def time_token_expiry(self, time_token_expiry): + """ + Sets the time_token_expiry of this ResourcePrincipalConfiguration. + the time the resource principal session token will expired, shown as an rfc 3339 formatted datetime string. + + + :param time_token_expiry: The time_token_expiry of this ResourcePrincipalConfiguration. + :type: datetime + """ + self._time_token_expiry = time_token_expiry + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this ResourcePrincipalConfiguration. + The time the ResourcePrincipalConfiguration was created, shown as an RFC 3339 formatted datetime string. + + + :return: The time_created of this ResourcePrincipalConfiguration. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this ResourcePrincipalConfiguration. + The time the ResourcePrincipalConfiguration was created, shown as an RFC 3339 formatted datetime string. + + + :param time_created: The time_created of this ResourcePrincipalConfiguration. + :type: datetime + """ + self._time_created = time_created + + @property + def time_updated(self): + """ + **[Required]** Gets the time_updated of this ResourcePrincipalConfiguration. + The time the ResourcePrincipalConfiguration was updated, shown as an RFC 3339 formatted datetime string. + + + :return: The time_updated of this ResourcePrincipalConfiguration. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this ResourcePrincipalConfiguration. + The time the ResourcePrincipalConfiguration was updated, shown as an RFC 3339 formatted datetime string. + + + :param time_updated: The time_updated of this ResourcePrincipalConfiguration. + :type: datetime + """ + self._time_updated = time_updated + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/resource_principal_configuration_summary.py b/src/oci/bds/models/resource_principal_configuration_summary.py new file mode 100644 index 000000000..c8fd8d0d1 --- /dev/null +++ b/src/oci/bds/models/resource_principal_configuration_summary.py @@ -0,0 +1,289 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ResourcePrincipalConfigurationSummary(object): + """ + Resource Principal Session Token Details. + """ + + def __init__(self, **kwargs): + """ + Initializes a new ResourcePrincipalConfigurationSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this ResourcePrincipalConfigurationSummary. + :type id: str + + :param bds_instance_id: + The value to assign to the bds_instance_id property of this ResourcePrincipalConfigurationSummary. + :type bds_instance_id: str + + :param display_name: + The value to assign to the display_name property of this ResourcePrincipalConfigurationSummary. + :type display_name: str + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this ResourcePrincipalConfigurationSummary. + :type lifecycle_state: str + + :param time_token_refreshed: + The value to assign to the time_token_refreshed property of this ResourcePrincipalConfigurationSummary. + :type time_token_refreshed: datetime + + :param time_token_expiry: + The value to assign to the time_token_expiry property of this ResourcePrincipalConfigurationSummary. + :type time_token_expiry: datetime + + :param time_created: + The value to assign to the time_created property of this ResourcePrincipalConfigurationSummary. + :type time_created: datetime + + :param time_updated: + The value to assign to the time_updated property of this ResourcePrincipalConfigurationSummary. + :type time_updated: datetime + + """ + self.swagger_types = { + 'id': 'str', + 'bds_instance_id': 'str', + 'display_name': 'str', + 'lifecycle_state': 'str', + 'time_token_refreshed': 'datetime', + 'time_token_expiry': 'datetime', + 'time_created': 'datetime', + 'time_updated': 'datetime' + } + + self.attribute_map = { + 'id': 'id', + 'bds_instance_id': 'bdsInstanceId', + 'display_name': 'displayName', + 'lifecycle_state': 'lifecycleState', + 'time_token_refreshed': 'timeTokenRefreshed', + 'time_token_expiry': 'timeTokenExpiry', + 'time_created': 'timeCreated', + 'time_updated': 'timeUpdated' + } + + self._id = None + self._bds_instance_id = None + self._display_name = None + self._lifecycle_state = None + self._time_token_refreshed = None + self._time_token_expiry = None + self._time_created = None + self._time_updated = None + + @property + def id(self): + """ + **[Required]** Gets the id of this ResourcePrincipalConfigurationSummary. + the ID of the ResourcePrincipalConfiguration. + + + :return: The id of this ResourcePrincipalConfigurationSummary. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this ResourcePrincipalConfigurationSummary. + the ID of the ResourcePrincipalConfiguration. + + + :param id: The id of this ResourcePrincipalConfigurationSummary. + :type: str + """ + self._id = id + + @property + def bds_instance_id(self): + """ + **[Required]** Gets the bds_instance_id of this ResourcePrincipalConfigurationSummary. + the OCID of the bdsInstance which is the parent resource id. + + + :return: The bds_instance_id of this ResourcePrincipalConfigurationSummary. + :rtype: str + """ + return self._bds_instance_id + + @bds_instance_id.setter + def bds_instance_id(self, bds_instance_id): + """ + Sets the bds_instance_id of this ResourcePrincipalConfigurationSummary. + the OCID of the bdsInstance which is the parent resource id. + + + :param bds_instance_id: The bds_instance_id of this ResourcePrincipalConfigurationSummary. + :type: str + """ + self._bds_instance_id = bds_instance_id + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this ResourcePrincipalConfigurationSummary. + a user-friendly name. only ascii alphanumeric characters with no spaces allowed. the name does not have to be unique, and it may be changed. avoid entering confidential information. + + + :return: The display_name of this ResourcePrincipalConfigurationSummary. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this ResourcePrincipalConfigurationSummary. + a user-friendly name. only ascii alphanumeric characters with no spaces allowed. the name does not have to be unique, and it may be changed. avoid entering confidential information. + + + :param display_name: The display_name of this ResourcePrincipalConfigurationSummary. + :type: str + """ + self._display_name = display_name + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this ResourcePrincipalConfigurationSummary. + the state of the ResourcePrincipalConfiguration. + + + :return: The lifecycle_state of this ResourcePrincipalConfigurationSummary. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this ResourcePrincipalConfigurationSummary. + the state of the ResourcePrincipalConfiguration. + + + :param lifecycle_state: The lifecycle_state of this ResourcePrincipalConfigurationSummary. + :type: str + """ + self._lifecycle_state = lifecycle_state + + @property + def time_token_refreshed(self): + """ + Gets the time_token_refreshed of this ResourcePrincipalConfigurationSummary. + the time the resource principal session token was refreshed, shown as an rfc 3339 formatted datetime string. + + + :return: The time_token_refreshed of this ResourcePrincipalConfigurationSummary. + :rtype: datetime + """ + return self._time_token_refreshed + + @time_token_refreshed.setter + def time_token_refreshed(self, time_token_refreshed): + """ + Sets the time_token_refreshed of this ResourcePrincipalConfigurationSummary. + the time the resource principal session token was refreshed, shown as an rfc 3339 formatted datetime string. + + + :param time_token_refreshed: The time_token_refreshed of this ResourcePrincipalConfigurationSummary. + :type: datetime + """ + self._time_token_refreshed = time_token_refreshed + + @property + def time_token_expiry(self): + """ + Gets the time_token_expiry of this ResourcePrincipalConfigurationSummary. + the time the resource principal session token will expired, shown as an rfc 3339 formatted datetime string. + + + :return: The time_token_expiry of this ResourcePrincipalConfigurationSummary. + :rtype: datetime + """ + return self._time_token_expiry + + @time_token_expiry.setter + def time_token_expiry(self, time_token_expiry): + """ + Sets the time_token_expiry of this ResourcePrincipalConfigurationSummary. + the time the resource principal session token will expired, shown as an rfc 3339 formatted datetime string. + + + :param time_token_expiry: The time_token_expiry of this ResourcePrincipalConfigurationSummary. + :type: datetime + """ + self._time_token_expiry = time_token_expiry + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this ResourcePrincipalConfigurationSummary. + the time the ResourcePrincipalConfiguration was created, shown as an rfc 3339 formatted datetime string. + + + :return: The time_created of this ResourcePrincipalConfigurationSummary. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this ResourcePrincipalConfigurationSummary. + the time the ResourcePrincipalConfiguration was created, shown as an rfc 3339 formatted datetime string. + + + :param time_created: The time_created of this ResourcePrincipalConfigurationSummary. + :type: datetime + """ + self._time_created = time_created + + @property + def time_updated(self): + """ + **[Required]** Gets the time_updated of this ResourcePrincipalConfigurationSummary. + the time the ResourcePrincipalConfiguration was updated, shown as an rfc 3339 formatted datetime string. + + + :return: The time_updated of this ResourcePrincipalConfigurationSummary. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this ResourcePrincipalConfigurationSummary. + the time the ResourcePrincipalConfiguration was updated, shown as an rfc 3339 formatted datetime string. + + + :param time_updated: The time_updated of this ResourcePrincipalConfigurationSummary. + :type: datetime + """ + self._time_updated = time_updated + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/update_resource_principal_configuration_details.py b/src/oci/bds/models/update_resource_principal_configuration_details.py new file mode 100644 index 000000000..d76686620 --- /dev/null +++ b/src/oci/bds/models/update_resource_principal_configuration_details.py @@ -0,0 +1,103 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20190531 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateResourcePrincipalConfigurationDetails(object): + """ + Details of updating the resource principal configuration for the cluster. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateResourcePrincipalConfigurationDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param display_name: + The value to assign to the display_name property of this UpdateResourcePrincipalConfigurationDetails. + :type display_name: str + + :param session_token_life_span_duration_in_hours: + The value to assign to the session_token_life_span_duration_in_hours property of this UpdateResourcePrincipalConfigurationDetails. + :type session_token_life_span_duration_in_hours: int + + """ + self.swagger_types = { + 'display_name': 'str', + 'session_token_life_span_duration_in_hours': 'int' + } + + self.attribute_map = { + 'display_name': 'displayName', + 'session_token_life_span_duration_in_hours': 'sessionTokenLifeSpanDurationInHours' + } + + self._display_name = None + self._session_token_life_span_duration_in_hours = None + + @property + def display_name(self): + """ + Gets the display_name of this UpdateResourcePrincipalConfigurationDetails. + A user-friendly name. Only ASCII alphanumeric characters with no spaces allowed. The name does not have to be unique, and it may be changed. Avoid entering confidential information. + + + :return: The display_name of this UpdateResourcePrincipalConfigurationDetails. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this UpdateResourcePrincipalConfigurationDetails. + A user-friendly name. Only ASCII alphanumeric characters with no spaces allowed. The name does not have to be unique, and it may be changed. Avoid entering confidential information. + + + :param display_name: The display_name of this UpdateResourcePrincipalConfigurationDetails. + :type: str + """ + self._display_name = display_name + + @property + def session_token_life_span_duration_in_hours(self): + """ + Gets the session_token_life_span_duration_in_hours of this UpdateResourcePrincipalConfigurationDetails. + Life span in hours for the resource principal session token. + + + :return: The session_token_life_span_duration_in_hours of this UpdateResourcePrincipalConfigurationDetails. + :rtype: int + """ + return self._session_token_life_span_duration_in_hours + + @session_token_life_span_duration_in_hours.setter + def session_token_life_span_duration_in_hours(self, session_token_life_span_duration_in_hours): + """ + Sets the session_token_life_span_duration_in_hours of this UpdateResourcePrincipalConfigurationDetails. + Life span in hours for the resource principal session token. + + + :param session_token_life_span_duration_in_hours: The session_token_life_span_duration_in_hours of this UpdateResourcePrincipalConfigurationDetails. + :type: int + """ + self._session_token_life_span_duration_in_hours = session_token_life_span_duration_in_hours + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/bds/models/work_request.py b/src/oci/bds/models/work_request.py index 31b121650..a64b655b8 100644 --- a/src/oci/bds/models/work_request.py +++ b/src/oci/bds/models/work_request.py @@ -195,6 +195,22 @@ class WorkRequest(object): #: This constant has a value of "REPLACE_NODE" OPERATION_TYPE_REPLACE_NODE = "REPLACE_NODE" + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "CREATE_RESOURCE_PRINCIPAL_CONFIGURATION" + OPERATION_TYPE_CREATE_RESOURCE_PRINCIPAL_CONFIGURATION = "CREATE_RESOURCE_PRINCIPAL_CONFIGURATION" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "DELETE_RESOURCE_PRINCIPAL_CONFIGURATION" + OPERATION_TYPE_DELETE_RESOURCE_PRINCIPAL_CONFIGURATION = "DELETE_RESOURCE_PRINCIPAL_CONFIGURATION" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "UPDATE_RESOURCE_PRINCIPAL_CONFIGURATION" + OPERATION_TYPE_UPDATE_RESOURCE_PRINCIPAL_CONFIGURATION = "UPDATE_RESOURCE_PRINCIPAL_CONFIGURATION" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "REFRESH_RESOURCE_PRINCIPAL" + OPERATION_TYPE_REFRESH_RESOURCE_PRINCIPAL = "REFRESH_RESOURCE_PRINCIPAL" + #: A constant which can be used with the status property of a WorkRequest. #: This constant has a value of "ACCEPTED" STATUS_ACCEPTED = "ACCEPTED" @@ -234,7 +250,7 @@ def __init__(self, **kwargs): :param operation_type: The value to assign to the operation_type property of this WorkRequest. - Allowed values for this property are: "CREATE_BDS", "UPDATE_BDS", "DELETE_BDS", "ADD_BLOCK_STORAGE", "ADD_MASTER_NODES", "ADD_UTILITY_NODES", "ADD_WORKER_NODES", "ADD_CLOUD_SQL", "REMOVE_CLOUD_SQL", "CHANGE_COMPARTMENT_FOR_BDS", "CHANGE_SHAPE", "UPDATE_INFRA", "RESTART_NODE", "REMOVE_NODE", "CREATE_AUTOSCALE_CONFIG", "UPDATE_AUTOSCALE_CONFIG", "DELETE_AUTOSCALE_CONFIG", "AUTOSCALE_CONFIG", "AUTOSCALE_RUN", "CREATE_API_KEY", "DELETE_API_KEY", "TEST_OBJECT_STORE_CONNECTION", "CREATE_METASTORE_CONFIG", "DELETE_METASTORE_CONFIG", "UPDATE_METASTORE_CONFIG", "ACTIVATE_METASTORE_CONFIG", "TEST_METASTORE_CONFIG", "PATCH_BDS", "PATCH_ODH", "PATCH_OS", "STOP_BDS", "START_BDS", "ADD_KAFKA", "REMOVE_KAFKA", "EXECUTE_BOOTSTRAP_SCRIPT", "ODH_SERVICE_CERTIFICATE_UPDATE", "CREATE_BACKUP_CONFIG", "UPDATE_BACKUP_CONFIG", "DELETE_BACKUP_CONFIG", "CREATE_NODE_REPLACE_CONFIG", "UPDATE_NODE_REPLACE_CONFIG", "DELETE_NODE_REPLACE_CONFIG", "BACKUP_NODES", "DELETE_NODE_BACKUP", "REPLACE_NODE", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CREATE_BDS", "UPDATE_BDS", "DELETE_BDS", "ADD_BLOCK_STORAGE", "ADD_MASTER_NODES", "ADD_UTILITY_NODES", "ADD_WORKER_NODES", "ADD_CLOUD_SQL", "REMOVE_CLOUD_SQL", "CHANGE_COMPARTMENT_FOR_BDS", "CHANGE_SHAPE", "UPDATE_INFRA", "RESTART_NODE", "REMOVE_NODE", "CREATE_AUTOSCALE_CONFIG", "UPDATE_AUTOSCALE_CONFIG", "DELETE_AUTOSCALE_CONFIG", "AUTOSCALE_CONFIG", "AUTOSCALE_RUN", "CREATE_API_KEY", "DELETE_API_KEY", "TEST_OBJECT_STORE_CONNECTION", "CREATE_METASTORE_CONFIG", "DELETE_METASTORE_CONFIG", "UPDATE_METASTORE_CONFIG", "ACTIVATE_METASTORE_CONFIG", "TEST_METASTORE_CONFIG", "PATCH_BDS", "PATCH_ODH", "PATCH_OS", "STOP_BDS", "START_BDS", "ADD_KAFKA", "REMOVE_KAFKA", "EXECUTE_BOOTSTRAP_SCRIPT", "ODH_SERVICE_CERTIFICATE_UPDATE", "CREATE_BACKUP_CONFIG", "UPDATE_BACKUP_CONFIG", "DELETE_BACKUP_CONFIG", "CREATE_NODE_REPLACE_CONFIG", "UPDATE_NODE_REPLACE_CONFIG", "DELETE_NODE_REPLACE_CONFIG", "BACKUP_NODES", "DELETE_NODE_BACKUP", "REPLACE_NODE", "CREATE_RESOURCE_PRINCIPAL_CONFIGURATION", "DELETE_RESOURCE_PRINCIPAL_CONFIGURATION", "UPDATE_RESOURCE_PRINCIPAL_CONFIGURATION", "REFRESH_RESOURCE_PRINCIPAL", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type operation_type: str @@ -353,7 +369,7 @@ def operation_type(self): **[Required]** Gets the operation_type of this WorkRequest. The type of this work request. - Allowed values for this property are: "CREATE_BDS", "UPDATE_BDS", "DELETE_BDS", "ADD_BLOCK_STORAGE", "ADD_MASTER_NODES", "ADD_UTILITY_NODES", "ADD_WORKER_NODES", "ADD_CLOUD_SQL", "REMOVE_CLOUD_SQL", "CHANGE_COMPARTMENT_FOR_BDS", "CHANGE_SHAPE", "UPDATE_INFRA", "RESTART_NODE", "REMOVE_NODE", "CREATE_AUTOSCALE_CONFIG", "UPDATE_AUTOSCALE_CONFIG", "DELETE_AUTOSCALE_CONFIG", "AUTOSCALE_CONFIG", "AUTOSCALE_RUN", "CREATE_API_KEY", "DELETE_API_KEY", "TEST_OBJECT_STORE_CONNECTION", "CREATE_METASTORE_CONFIG", "DELETE_METASTORE_CONFIG", "UPDATE_METASTORE_CONFIG", "ACTIVATE_METASTORE_CONFIG", "TEST_METASTORE_CONFIG", "PATCH_BDS", "PATCH_ODH", "PATCH_OS", "STOP_BDS", "START_BDS", "ADD_KAFKA", "REMOVE_KAFKA", "EXECUTE_BOOTSTRAP_SCRIPT", "ODH_SERVICE_CERTIFICATE_UPDATE", "CREATE_BACKUP_CONFIG", "UPDATE_BACKUP_CONFIG", "DELETE_BACKUP_CONFIG", "CREATE_NODE_REPLACE_CONFIG", "UPDATE_NODE_REPLACE_CONFIG", "DELETE_NODE_REPLACE_CONFIG", "BACKUP_NODES", "DELETE_NODE_BACKUP", "REPLACE_NODE", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CREATE_BDS", "UPDATE_BDS", "DELETE_BDS", "ADD_BLOCK_STORAGE", "ADD_MASTER_NODES", "ADD_UTILITY_NODES", "ADD_WORKER_NODES", "ADD_CLOUD_SQL", "REMOVE_CLOUD_SQL", "CHANGE_COMPARTMENT_FOR_BDS", "CHANGE_SHAPE", "UPDATE_INFRA", "RESTART_NODE", "REMOVE_NODE", "CREATE_AUTOSCALE_CONFIG", "UPDATE_AUTOSCALE_CONFIG", "DELETE_AUTOSCALE_CONFIG", "AUTOSCALE_CONFIG", "AUTOSCALE_RUN", "CREATE_API_KEY", "DELETE_API_KEY", "TEST_OBJECT_STORE_CONNECTION", "CREATE_METASTORE_CONFIG", "DELETE_METASTORE_CONFIG", "UPDATE_METASTORE_CONFIG", "ACTIVATE_METASTORE_CONFIG", "TEST_METASTORE_CONFIG", "PATCH_BDS", "PATCH_ODH", "PATCH_OS", "STOP_BDS", "START_BDS", "ADD_KAFKA", "REMOVE_KAFKA", "EXECUTE_BOOTSTRAP_SCRIPT", "ODH_SERVICE_CERTIFICATE_UPDATE", "CREATE_BACKUP_CONFIG", "UPDATE_BACKUP_CONFIG", "DELETE_BACKUP_CONFIG", "CREATE_NODE_REPLACE_CONFIG", "UPDATE_NODE_REPLACE_CONFIG", "DELETE_NODE_REPLACE_CONFIG", "BACKUP_NODES", "DELETE_NODE_BACKUP", "REPLACE_NODE", "CREATE_RESOURCE_PRINCIPAL_CONFIGURATION", "DELETE_RESOURCE_PRINCIPAL_CONFIGURATION", "UPDATE_RESOURCE_PRINCIPAL_CONFIGURATION", "REFRESH_RESOURCE_PRINCIPAL", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -372,7 +388,7 @@ def operation_type(self, operation_type): :param operation_type: The operation_type of this WorkRequest. :type: str """ - allowed_values = ["CREATE_BDS", "UPDATE_BDS", "DELETE_BDS", "ADD_BLOCK_STORAGE", "ADD_MASTER_NODES", "ADD_UTILITY_NODES", "ADD_WORKER_NODES", "ADD_CLOUD_SQL", "REMOVE_CLOUD_SQL", "CHANGE_COMPARTMENT_FOR_BDS", "CHANGE_SHAPE", "UPDATE_INFRA", "RESTART_NODE", "REMOVE_NODE", "CREATE_AUTOSCALE_CONFIG", "UPDATE_AUTOSCALE_CONFIG", "DELETE_AUTOSCALE_CONFIG", "AUTOSCALE_CONFIG", "AUTOSCALE_RUN", "CREATE_API_KEY", "DELETE_API_KEY", "TEST_OBJECT_STORE_CONNECTION", "CREATE_METASTORE_CONFIG", "DELETE_METASTORE_CONFIG", "UPDATE_METASTORE_CONFIG", "ACTIVATE_METASTORE_CONFIG", "TEST_METASTORE_CONFIG", "PATCH_BDS", "PATCH_ODH", "PATCH_OS", "STOP_BDS", "START_BDS", "ADD_KAFKA", "REMOVE_KAFKA", "EXECUTE_BOOTSTRAP_SCRIPT", "ODH_SERVICE_CERTIFICATE_UPDATE", "CREATE_BACKUP_CONFIG", "UPDATE_BACKUP_CONFIG", "DELETE_BACKUP_CONFIG", "CREATE_NODE_REPLACE_CONFIG", "UPDATE_NODE_REPLACE_CONFIG", "DELETE_NODE_REPLACE_CONFIG", "BACKUP_NODES", "DELETE_NODE_BACKUP", "REPLACE_NODE"] + allowed_values = ["CREATE_BDS", "UPDATE_BDS", "DELETE_BDS", "ADD_BLOCK_STORAGE", "ADD_MASTER_NODES", "ADD_UTILITY_NODES", "ADD_WORKER_NODES", "ADD_CLOUD_SQL", "REMOVE_CLOUD_SQL", "CHANGE_COMPARTMENT_FOR_BDS", "CHANGE_SHAPE", "UPDATE_INFRA", "RESTART_NODE", "REMOVE_NODE", "CREATE_AUTOSCALE_CONFIG", "UPDATE_AUTOSCALE_CONFIG", "DELETE_AUTOSCALE_CONFIG", "AUTOSCALE_CONFIG", "AUTOSCALE_RUN", "CREATE_API_KEY", "DELETE_API_KEY", "TEST_OBJECT_STORE_CONNECTION", "CREATE_METASTORE_CONFIG", "DELETE_METASTORE_CONFIG", "UPDATE_METASTORE_CONFIG", "ACTIVATE_METASTORE_CONFIG", "TEST_METASTORE_CONFIG", "PATCH_BDS", "PATCH_ODH", "PATCH_OS", "STOP_BDS", "START_BDS", "ADD_KAFKA", "REMOVE_KAFKA", "EXECUTE_BOOTSTRAP_SCRIPT", "ODH_SERVICE_CERTIFICATE_UPDATE", "CREATE_BACKUP_CONFIG", "UPDATE_BACKUP_CONFIG", "DELETE_BACKUP_CONFIG", "CREATE_NODE_REPLACE_CONFIG", "UPDATE_NODE_REPLACE_CONFIG", "DELETE_NODE_REPLACE_CONFIG", "BACKUP_NODES", "DELETE_NODE_BACKUP", "REPLACE_NODE", "CREATE_RESOURCE_PRINCIPAL_CONFIGURATION", "DELETE_RESOURCE_PRINCIPAL_CONFIGURATION", "UPDATE_RESOURCE_PRINCIPAL_CONFIGURATION", "REFRESH_RESOURCE_PRINCIPAL"] if not value_allowed_none_or_none_sentinel(operation_type, allowed_values): operation_type = 'UNKNOWN_ENUM_VALUE' self._operation_type = operation_type diff --git a/src/oci/devops/devops_client.py b/src/oci/devops/devops_client.py index 05d3d0d96..ad64ed844 100644 --- a/src/oci/devops/devops_client.py +++ b/src/oci/devops/devops_client.py @@ -14,6 +14,7 @@ from oci.config import get_config_value_or_default, validate_config from oci.signer import Signer from oci.util import Sentinel, get_signer_from_authentication_type, AUTHENTICATION_TYPE_FIELD_NAME +from oci.util import back_up_body_calculate_stream_content_length, is_content_length_calculable_by_req_util from oci.exceptions import InvalidAlloyConfig from oci.alloy import OCI_SDK_ENABLED_SERVICES_SET from .models import devops_type_mapping @@ -1528,13 +1529,19 @@ def create_deployment(self, create_deployment_details, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) - def create_project(self, create_project_details, **kwargs): + def create_or_update_git_ref(self, repository_id, create_or_update_git_ref_details, **kwargs): """ - Creates a new project. + Creates a new reference or updates an existing one. - :param oci.devops.models.CreateProjectDetails create_project_details: (required) - Details for the new project. + :param str repository_id: (required) + Unique repository identifier. + + :param oci.devops.models.CreateOrUpdateGitRefDetails create_or_update_git_ref_details: (required) + The information to create a reference with the type specified in the query. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. @@ -1554,34 +1561,46 @@ def create_project(self, create_project_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Project` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRef` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use create_project API. + Click `here `__ to see an example of how to use create_or_update_git_ref API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/projects" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/actions/createOrUpdateGitRef" method = "POST" - operation_name = "create_project" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/CreateProject" + operation_name = "create_or_update_git_ref" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/CreateOrUpdateGitRef" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"create_project got unknown kwargs: {extra_kwargs!r}") + f"create_or_update_git_ref got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } @@ -1603,9 +1622,10 @@ def create_project(self, create_project_details, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, header_params=header_params, - body=create_project_details, - response_type="Project", + body=create_or_update_git_ref_details, + response_type="RepositoryRef", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -1614,21 +1634,28 @@ def create_project(self, create_project_details, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, header_params=header_params, - body=create_project_details, - response_type="Project", + body=create_or_update_git_ref_details, + response_type="RepositoryRef", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def create_repository(self, create_repository_details, **kwargs): + def create_or_update_protected_branch(self, repository_id, create_or_update_protected_branch_details, **kwargs): """ - Creates a new repository. + Creates a restriction on a branch that prevents certain actions on it. - :param oci.devops.models.CreateRepositoryDetails create_repository_details: (required) - Details for the new repository. + :param str repository_id: (required) + Unique repository identifier. + + :param oci.devops.models.CreateOrUpdateProtectedBranchDetails create_or_update_protected_branch_details: (required) + Details for a protected branch + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. @@ -1648,34 +1675,46 @@ def create_repository(self, create_repository_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Repository` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProtectedBranch` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use create_repository API. + Click `here `__ to see an example of how to use create_or_update_protected_branch API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/repositories" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/actions/createOrUpdateProtectedBranch" method = "POST" - operation_name = "create_repository" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/CreateRepository" + operation_name = "create_or_update_protected_branch" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProtectedBranch/CreateOrUpdateProtectedBranch" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"create_repository got unknown kwargs: {extra_kwargs!r}") + f"create_or_update_protected_branch got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } @@ -1697,9 +1736,10 @@ def create_repository(self, create_repository_details, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, header_params=header_params, - body=create_repository_details, - response_type="Repository", + body=create_or_update_protected_branch_details, + response_type="ProtectedBranch", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -1708,21 +1748,22 @@ def create_repository(self, create_repository_details, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, header_params=header_params, - body=create_repository_details, - response_type="Repository", + body=create_or_update_protected_branch_details, + response_type="ProtectedBranch", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def create_trigger(self, create_trigger_details, **kwargs): + def create_project(self, create_project_details, **kwargs): """ - Creates a new trigger. + Creates a new project. - :param oci.devops.models.CreateTriggerDetails create_trigger_details: (required) - Details for the new trigger. + :param oci.devops.models.CreateProjectDetails create_project_details: (required) + Details for the new project. :param str opc_retry_token: (optional) A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. @@ -1742,18 +1783,18 @@ def create_trigger(self, create_trigger_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.TriggerCreateResult` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Project` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use create_trigger API. + Click `here `__ to see an example of how to use create_project API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = [] - resource_path = "/triggers" + resource_path = "/projects" method = "POST" - operation_name = "create_trigger" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Trigger/CreateTrigger" + operation_name = "create_project" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/CreateProject" # Don't accept unknown kwargs expected_kwargs = [ @@ -1765,7 +1806,7 @@ def create_trigger(self, create_trigger_details, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"create_trigger got unknown kwargs: {extra_kwargs!r}") + f"create_project got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", @@ -1792,8 +1833,8 @@ def create_trigger(self, create_trigger_details, **kwargs): resource_path=resource_path, method=method, header_params=header_params, - body=create_trigger_details, - response_type="TriggerCreateResult", + body=create_project_details, + response_type="Project", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -1803,23 +1844,23 @@ def create_trigger(self, create_trigger_details, **kwargs): resource_path=resource_path, method=method, header_params=header_params, - body=create_trigger_details, - response_type="TriggerCreateResult", + body=create_project_details, + response_type="Project", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_build_pipeline(self, build_pipeline_id, **kwargs): + def create_pull_request(self, create_pull_request_details, **kwargs): """ - Deletes a build pipeline resource by identifier. + Creates a new PullRequest. - :param str build_pipeline_id: (required) - Unique build pipeline identifier. + :param oci.devops.models.CreatePullRequestDetails create_pull_request_details: (required) + Details for the new PullRequest. - :param str if_match: (optional) - For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -1836,45 +1877,35 @@ def delete_build_pipeline(self, build_pipeline_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_build_pipeline API. + Click `here `__ to see an example of how to use create_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildPipelineId'] - resource_path = "/buildPipelines/{buildPipelineId}" - method = "DELETE" - operation_name = "delete_build_pipeline" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipeline/DeleteBuildPipeline" + required_arguments = [] + resource_path = "/pullRequests" + method = "POST" + operation_name = "create_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/CreatePullRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_build_pipeline got unknown kwargs: {extra_kwargs!r}") - - path_params = { - "buildPipelineId": build_pipeline_id - } - - path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - - for (k, v) in six.iteritems(path_params): - if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): - raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + f"create_pull_request got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", - "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -1888,14 +1919,16 @@ def delete_build_pipeline(self, build_pipeline_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, + body=create_pull_request_details, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -1904,23 +1937,30 @@ def delete_build_pipeline(self, build_pipeline_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, + body=create_pull_request_details, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): + def create_pull_request_attachment(self, pull_request_id, content_disposition, create_pull_request_attachment_body, **kwargs): """ - Deletes a stage based on the stage ID provided in the request. + Creates PullRequest attachment - :param str build_pipeline_stage_id: (required) - Unique stage identifier. + :param str pull_request_id: (required) + unique PullRequest identifier - :param str if_match: (optional) - For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str content_disposition: (required) + The Content-Disposition response-header field has been proposed as a means for the origin server to suggest a default filename if the user requests that the content is saved to a file. + + :param stream create_pull_request_attachment_body: (required) + Uploads the content of the attachment. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -1936,34 +1976,42 @@ def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): :param bool allow_control_chars: (optional) allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings + :param int buffer_limit: (optional) + A buffer limit for the stream to be buffered. buffer_limit is used to set the buffer size capacity. Streams will be read until the size of the buffer reaches the buffer_limit. + If the stream size is greater than the buffer_limit, a BufferError exception will be thrown. - :return: A :class:`~oci.response.Response` object with data of type None + The buffer_limit parameter is used when the stream object does not have a `seek`, `tell`, or `fileno` property for the Python Request library to calculate out the content length. + If buffer_limit is not passed, then the buffer_limit will be defaulted to 100MB. + Large streams can cause the process to freeze, consider passing in content-length for large streams instead. + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestAttachment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_build_pipeline_stage API. + Click `here `__ to see an example of how to use create_pull_request_attachment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildPipelineStageId'] - resource_path = "/buildPipelineStages/{buildPipelineStageId}" - method = "DELETE" - operation_name = "delete_build_pipeline_stage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStage/DeleteBuildPipelineStage" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/attachments" + method = "POST" + operation_name = "create_pull_request_attachment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/CreatePullRequestAttachment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "if_match", + "buffer_limit", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_build_pipeline_stage got unknown kwargs: {extra_kwargs!r}") + f"create_pull_request_attachment got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildPipelineStageId": build_pipeline_stage_id + "pullRequestId": pull_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -1974,12 +2022,33 @@ def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): header_params = { "accept": "application/json", - "content-type": "application/json", - "if-match": kwargs.get("if_match", missing), + "content-disposition": content_disposition, + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + # If the body parameter is optional we need to assign it to a variable so additional type checking can be performed. + try: + create_pull_request_attachment_body + except NameError: + create_pull_request_attachment_body = kwargs.get("create_pull_request_attachment_body", missing) + + if create_pull_request_attachment_body is not missing and create_pull_request_attachment_body is not None: + if (not isinstance(create_pull_request_attachment_body, (six.binary_type, six.string_types)) and + not hasattr(create_pull_request_attachment_body, "read")): + raise TypeError('The body must be a string, bytes, or provide a read() method.') + + if hasattr(create_pull_request_attachment_body, 'fileno') and hasattr(create_pull_request_attachment_body, 'name') and create_pull_request_attachment_body.name != '': + if requests.utils.super_len(create_pull_request_attachment_body) == 0: + header_params['Content-Length'] = '0' + + # If content length is not given and stream object have no 'fileno' and is not a string or bytes, try to calculate content length + elif 'Content-Length' not in header_params and not is_content_length_calculable_by_req_util(create_pull_request_attachment_body): + calculated_obj = back_up_body_calculate_stream_content_length(create_pull_request_attachment_body, kwargs.get("buffer_limit")) + header_params['Content-Length'] = calculated_obj["content_length"] + create_pull_request_attachment_body = calculated_obj["byte_content"] + retry_strategy = self.base_client.get_preferred_retry_strategy( operation_retry_strategy=kwargs.get('retry_strategy'), client_retry_strategy=self.retry_strategy @@ -1989,6 +2058,7 @@ def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -1997,6 +2067,8 @@ def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=create_pull_request_attachment_body, + response_type="PullRequestAttachment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -2007,21 +2079,26 @@ def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=create_pull_request_attachment_body, + response_type="PullRequestAttachment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_connection(self, connection_id, **kwargs): + def create_pull_request_comment(self, pull_request_id, create_pull_request_comment_details, **kwargs): """ - Deletes a connection resource by identifier. + Creates a new PullRequest comment. - :param str connection_id: (required) - Unique connection identifier. + :param str pull_request_id: (required) + unique PullRequest identifier - :param str if_match: (optional) - For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param oci.devops.models.CreatePullRequestCommentDetails create_pull_request_comment_details: (required) + Details for the new PullRequest comment. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -2038,33 +2115,33 @@ def delete_connection(self, connection_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestComment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_connection API. + Click `here `__ to see an example of how to use create_pull_request_comment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['connectionId'] - resource_path = "/connections/{connectionId}" - method = "DELETE" - operation_name = "delete_connection" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Connection/DeleteConnection" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/comments" + method = "POST" + operation_name = "create_pull_request_comment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/CreatePullRequestComment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_connection got unknown kwargs: {extra_kwargs!r}") + f"create_pull_request_comment got unknown kwargs: {extra_kwargs!r}") path_params = { - "connectionId": connection_id + "pullRequestId": pull_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2076,7 +2153,7 @@ def delete_connection(self, connection_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", - "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -2090,6 +2167,7 @@ def delete_connection(self, connection_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -2098,6 +2176,8 @@ def delete_connection(self, connection_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=create_pull_request_comment_details, + response_type="PullRequestComment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -2108,21 +2188,23 @@ def delete_connection(self, connection_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=create_pull_request_comment_details, + response_type="PullRequestComment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_deploy_artifact(self, deploy_artifact_id, **kwargs): + def create_repository(self, create_repository_details, **kwargs): """ - Deletes a deployment artifact resource by identifier. + Creates a new repository. - :param str deploy_artifact_id: (required) - Unique artifact identifier. + :param oci.devops.models.CreateRepositoryDetails create_repository_details: (required) + Details for the new repository. - :param str if_match: (optional) - For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -2139,45 +2221,35 @@ def delete_deploy_artifact(self, deploy_artifact_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Repository` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_deploy_artifact API. + Click `here `__ to see an example of how to use create_repository API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployArtifactId'] - resource_path = "/deployArtifacts/{deployArtifactId}" - method = "DELETE" - operation_name = "delete_deploy_artifact" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifact/DeleteDeployArtifact" + required_arguments = [] + resource_path = "/repositories" + method = "POST" + operation_name = "create_repository" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/CreateRepository" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_deploy_artifact got unknown kwargs: {extra_kwargs!r}") - - path_params = { - "deployArtifactId": deploy_artifact_id - } - - path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - - for (k, v) in six.iteritems(path_params): - if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): - raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + f"create_repository got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", - "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -2191,14 +2263,16 @@ def delete_deploy_artifact(self, deploy_artifact_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, + body=create_repository_details, + response_type="Repository", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -2207,23 +2281,24 @@ def delete_deploy_artifact(self, deploy_artifact_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, + body=create_repository_details, + response_type="Repository", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_deploy_environment(self, deploy_environment_id, **kwargs): + def create_trigger(self, create_trigger_details, **kwargs): """ - Deletes a deployment environment resource by identifier. + Creates a new trigger. - :param str deploy_environment_id: (required) - Unique environment identifier. + :param oci.devops.models.CreateTriggerDetails create_trigger_details: (required) + Details for the new trigger. - :param str if_match: (optional) - For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -2240,45 +2315,35 @@ def delete_deploy_environment(self, deploy_environment_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.TriggerCreateResult` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_deploy_environment API. + Click `here `__ to see an example of how to use create_trigger API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployEnvironmentId'] - resource_path = "/deployEnvironments/{deployEnvironmentId}" - method = "DELETE" - operation_name = "delete_deploy_environment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironment/DeleteDeployEnvironment" + required_arguments = [] + resource_path = "/triggers" + method = "POST" + operation_name = "create_trigger" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Trigger/CreateTrigger" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_deploy_environment got unknown kwargs: {extra_kwargs!r}") - - path_params = { - "deployEnvironmentId": deploy_environment_id - } - - path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - - for (k, v) in six.iteritems(path_params): - if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): - raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + f"create_trigger got unknown kwargs: {extra_kwargs!r}") header_params = { "accept": "application/json", "content-type": "application/json", - "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -2292,14 +2357,16 @@ def delete_deploy_environment(self, deploy_environment_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, + body=create_trigger_details, + response_type="TriggerCreateResult", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -2308,20 +2375,21 @@ def delete_deploy_environment(self, deploy_environment_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, + body=create_trigger_details, + response_type="TriggerCreateResult", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_deploy_pipeline(self, deploy_pipeline_id, **kwargs): + def decline_pull_request(self, pull_request_id, **kwargs): """ - Deletes a deployment pipeline resource by identifier. + Decline a PullRequest - :param str deploy_pipeline_id: (required) - Unique pipeline identifier. + :param str pull_request_id: (required) + unique PullRequest identifier :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -2341,18 +2409,18 @@ def delete_deploy_pipeline(self, deploy_pipeline_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_deploy_pipeline API. + Click `here `__ to see an example of how to use decline_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployPipelineId'] - resource_path = "/deployPipelines/{deployPipelineId}" - method = "DELETE" - operation_name = "delete_deploy_pipeline" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipeline/DeleteDeployPipeline" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/actions/decline" + method = "POST" + operation_name = "decline_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/DeclinePullRequest" # Don't accept unknown kwargs expected_kwargs = [ @@ -2364,10 +2432,10 @@ def delete_deploy_pipeline(self, deploy_pipeline_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_deploy_pipeline got unknown kwargs: {extra_kwargs!r}") + f"decline_pull_request got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployPipelineId": deploy_pipeline_id + "pullRequestId": pull_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2401,6 +2469,7 @@ def delete_deploy_pipeline(self, deploy_pipeline_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -2411,18 +2480,19 @@ def delete_deploy_pipeline(self, deploy_pipeline_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_deploy_stage(self, deploy_stage_id, **kwargs): + def delete_build_pipeline(self, build_pipeline_id, **kwargs): """ - Deletes a deployment stage resource by identifier. + Deletes a build pipeline resource by identifier. - :param str deploy_stage_id: (required) - Unique stage identifier. + :param str build_pipeline_id: (required) + Unique build pipeline identifier. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -2446,14 +2516,14 @@ def delete_deploy_stage(self, deploy_stage_id, **kwargs): :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_deploy_stage API. + Click `here `__ to see an example of how to use delete_build_pipeline API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployStageId'] - resource_path = "/deployStages/{deployStageId}" + required_arguments = ['buildPipelineId'] + resource_path = "/buildPipelines/{buildPipelineId}" method = "DELETE" - operation_name = "delete_deploy_stage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStage/DeleteDeployStage" + operation_name = "delete_build_pipeline" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipeline/DeleteBuildPipeline" # Don't accept unknown kwargs expected_kwargs = [ @@ -2465,10 +2535,10 @@ def delete_deploy_stage(self, deploy_stage_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_deploy_stage got unknown kwargs: {extra_kwargs!r}") + f"delete_build_pipeline got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployStageId": deploy_stage_id + "buildPipelineId": build_pipeline_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2517,13 +2587,13 @@ def delete_deploy_stage(self, deploy_stage_id, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_project(self, project_id, **kwargs): + def delete_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): """ - Deletes a project resource by identifier + Deletes a stage based on the stage ID provided in the request. - :param str project_id: (required) - Unique project identifier. + :param str build_pipeline_stage_id: (required) + Unique stage identifier. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -2547,14 +2617,14 @@ def delete_project(self, project_id, **kwargs): :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_project API. + Click `here `__ to see an example of how to use delete_build_pipeline_stage API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['projectId'] - resource_path = "/projects/{projectId}" + required_arguments = ['buildPipelineStageId'] + resource_path = "/buildPipelineStages/{buildPipelineStageId}" method = "DELETE" - operation_name = "delete_project" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/DeleteProject" + operation_name = "delete_build_pipeline_stage" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStage/DeleteBuildPipelineStage" # Don't accept unknown kwargs expected_kwargs = [ @@ -2566,10 +2636,10 @@ def delete_project(self, project_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_project got unknown kwargs: {extra_kwargs!r}") + f"delete_build_pipeline_stage got unknown kwargs: {extra_kwargs!r}") path_params = { - "projectId": project_id + "buildPipelineStageId": build_pipeline_stage_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2618,23 +2688,17 @@ def delete_project(self, project_id, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_ref(self, repository_id, ref_name, **kwargs): + def delete_connection(self, connection_id, **kwargs): """ - Deletes a Repository's Ref by its name. Returns an error if the name is ambiguous. Can be disambiguated by using full names like \"heads/\" or \"tags/\". This API will be deprecated on Wed, 12 June 2024 01:00:00 GMT as it does not get recognized when refName has '/'. This will be replaced by \"/repositories/{repositoryId}/actions/deleteGitRef\". - + Deletes a connection resource by identifier. - :param str repository_id: (required) - Unique repository identifier. - :param str ref_name: (required) - A filter to return only resources that match the given reference name. + :param str connection_id: (required) + Unique connection identifier. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - :param str opc_retry_token: (optional) - A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. - :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -2654,31 +2718,29 @@ def delete_ref(self, repository_id, ref_name, **kwargs): :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_ref API. + Click `here `__ to see an example of how to use delete_connection API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'refName'] - resource_path = "/repositories/{repositoryId}/refs/{refName}" + required_arguments = ['connectionId'] + resource_path = "/connections/{connectionId}" method = "DELETE" - operation_name = "delete_ref" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/DeleteRef" + operation_name = "delete_connection" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Connection/DeleteConnection" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", "if_match", - "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_ref got unknown kwargs: {extra_kwargs!r}") + f"delete_connection got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "refName": ref_name + "connectionId": connection_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2691,7 +2753,6 @@ def delete_ref(self, repository_id, ref_name, **kwargs): "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), - "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -2705,7 +2766,6 @@ def delete_ref(self, repository_id, ref_name, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): - self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -2729,13 +2789,13 @@ def delete_ref(self, repository_id, ref_name, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_repository(self, repository_id, **kwargs): + def delete_deploy_artifact(self, deploy_artifact_id, **kwargs): """ - Deletes a repository resource by identifier. + Deletes a deployment artifact resource by identifier. - :param str repository_id: (required) - Unique repository identifier. + :param str deploy_artifact_id: (required) + Unique artifact identifier. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -2759,14 +2819,14 @@ def delete_repository(self, repository_id, **kwargs): :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_repository API. + Click `here `__ to see an example of how to use delete_deploy_artifact API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}" + required_arguments = ['deployArtifactId'] + resource_path = "/deployArtifacts/{deployArtifactId}" method = "DELETE" - operation_name = "delete_repository" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/DeleteRepository" + operation_name = "delete_deploy_artifact" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifact/DeleteDeployArtifact" # Don't accept unknown kwargs expected_kwargs = [ @@ -2778,10 +2838,10 @@ def delete_repository(self, repository_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_repository got unknown kwargs: {extra_kwargs!r}") + f"delete_deploy_artifact got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "deployArtifactId": deploy_artifact_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2830,13 +2890,13 @@ def delete_repository(self, repository_id, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) - def delete_trigger(self, trigger_id, **kwargs): + def delete_deploy_environment(self, deploy_environment_id, **kwargs): """ - Deletes a trigger resource by identifier. + Deletes a deployment environment resource by identifier. - :param str trigger_id: (required) - Unique trigger identifier. + :param str deploy_environment_id: (required) + Unique environment identifier. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -2860,14 +2920,14 @@ def delete_trigger(self, trigger_id, **kwargs): :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use delete_trigger API. + Click `here `__ to see an example of how to use delete_deploy_environment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['triggerId'] - resource_path = "/triggers/{triggerId}" + required_arguments = ['deployEnvironmentId'] + resource_path = "/deployEnvironments/{deployEnvironmentId}" method = "DELETE" - operation_name = "delete_trigger" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Trigger/DeleteTrigger" + operation_name = "delete_deploy_environment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironment/DeleteDeployEnvironment" # Don't accept unknown kwargs expected_kwargs = [ @@ -2879,10 +2939,10 @@ def delete_trigger(self, trigger_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"delete_trigger got unknown kwargs: {extra_kwargs!r}") + f"delete_deploy_environment got unknown kwargs: {extra_kwargs!r}") path_params = { - "triggerId": trigger_id + "deployEnvironmentId": deploy_environment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2931,13 +2991,16 @@ def delete_trigger(self, trigger_id, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_build_pipeline(self, build_pipeline_id, **kwargs): + def delete_deploy_pipeline(self, deploy_pipeline_id, **kwargs): """ - Retrieves a build pipeline by identifier. + Deletes a deployment pipeline resource by identifier. - :param str build_pipeline_id: (required) - Unique build pipeline identifier. + :param str deploy_pipeline_id: (required) + Unique pipeline identifier. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -2954,32 +3017,33 @@ def get_build_pipeline(self, build_pipeline_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipeline` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_build_pipeline API. + Click `here `__ to see an example of how to use delete_deploy_pipeline API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildPipelineId'] - resource_path = "/buildPipelines/{buildPipelineId}" - method = "GET" - operation_name = "get_build_pipeline" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipeline/GetBuildPipeline" + required_arguments = ['deployPipelineId'] + resource_path = "/deployPipelines/{deployPipelineId}" + method = "DELETE" + operation_name = "delete_deploy_pipeline" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipeline/DeleteDeployPipeline" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_build_pipeline got unknown kwargs: {extra_kwargs!r}") + f"delete_deploy_pipeline got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildPipelineId": build_pipeline_id + "deployPipelineId": deploy_pipeline_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -2991,6 +3055,7 @@ def get_build_pipeline(self, build_pipeline_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3012,7 +3077,6 @@ def get_build_pipeline(self, build_pipeline_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="BuildPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3023,20 +3087,22 @@ def get_build_pipeline(self, build_pipeline_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="BuildPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): + def delete_deploy_stage(self, deploy_stage_id, **kwargs): """ - Retrieves a stage based on the stage ID provided in the request. + Deletes a deployment stage resource by identifier. - :param str build_pipeline_stage_id: (required) + :param str deploy_stage_id: (required) Unique stage identifier. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3052,32 +3118,33 @@ def get_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineStage` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_build_pipeline_stage API. + Click `here `__ to see an example of how to use delete_deploy_stage API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildPipelineStageId'] - resource_path = "/buildPipelineStages/{buildPipelineStageId}" - method = "GET" - operation_name = "get_build_pipeline_stage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStage/GetBuildPipelineStage" + required_arguments = ['deployStageId'] + resource_path = "/deployStages/{deployStageId}" + method = "DELETE" + operation_name = "delete_deploy_stage" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStage/DeleteDeployStage" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_build_pipeline_stage got unknown kwargs: {extra_kwargs!r}") + f"delete_deploy_stage got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildPipelineStageId": build_pipeline_stage_id + "deployStageId": deploy_stage_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3089,6 +3156,7 @@ def get_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3110,7 +3178,6 @@ def get_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="BuildPipelineStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3121,19 +3188,27 @@ def get_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="BuildPipelineStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_build_run(self, build_run_id, **kwargs): + def delete_git_ref(self, repository_id, delete_git_ref_details, **kwargs): """ - Returns the details of a build run for a given build run ID. + Deletes a Repository's Ref by its name. Returns an error if the name is ambiguous. Can be disambiguated by using full names like \"heads/\" or \"tags/\". - :param str build_run_id: (required) - Unique build run identifier. + :param str repository_id: (required) + Unique repository identifier. + + :param oci.devops.models.DeleteGitRefDetails delete_git_ref_details: (required) + The information to delete a reference. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3150,32 +3225,34 @@ def get_build_run(self, build_run_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRun` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_build_run API. + Click `here `__ to see an example of how to use delete_git_ref API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildRunId'] - resource_path = "/buildRuns/{buildRunId}" - method = "GET" - operation_name = "get_build_run" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildRun/GetBuildRun" - + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/actions/deleteGitRef" + method = "POST" + operation_name = "delete_git_ref" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/DeleteGitRef" + # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_build_run got unknown kwargs: {extra_kwargs!r}") + f"delete_git_ref got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildRunId": build_run_id + "repositoryId": repository_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3187,6 +3264,8 @@ def get_build_run(self, build_run_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3200,6 +3279,7 @@ def get_build_run(self, build_run_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -3208,7 +3288,7 @@ def get_build_run(self, build_run_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="BuildRun", + body=delete_git_ref_details, allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3219,22 +3299,22 @@ def get_build_run(self, build_run_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="BuildRun", + body=delete_git_ref_details, allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_commit(self, repository_id, commit_id, **kwargs): + def delete_project(self, project_id, **kwargs): """ - Retrieves a repository's commit by commit ID. + Deletes a project resource by identifier - :param str repository_id: (required) - Unique repository identifier. + :param str project_id: (required) + Unique project identifier. - :param str commit_id: (required) - A filter to return only resources that match the given commit ID. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3251,33 +3331,33 @@ def get_commit(self, repository_id, commit_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCommit` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_commit API. + Click `here `__ to see an example of how to use delete_project API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'commitId'] - resource_path = "/repositories/{repositoryId}/commits/{commitId}" - method = "GET" - operation_name = "get_commit" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetCommit" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}" + method = "DELETE" + operation_name = "delete_project" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/DeleteProject" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_commit got unknown kwargs: {extra_kwargs!r}") + f"delete_project got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "commitId": commit_id + "projectId": project_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3289,6 +3369,7 @@ def get_commit(self, repository_id, commit_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3310,7 +3391,6 @@ def get_commit(self, repository_id, commit_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="RepositoryCommit", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3321,28 +3401,24 @@ def get_commit(self, repository_id, commit_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="RepositoryCommit", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_commit_diff(self, repository_id, target_version, **kwargs): + def delete_project_repository_settings(self, project_id, **kwargs): """ - Compares two revisions for their differences. Supports comparison between two references or commits. + Removes the custom repository settings configured for a project. - :param str repository_id: (required) - Unique repository identifier. - - :param str target_version: (required) - The commit or reference name that represents the newer changes against the base version. + :param str project_id: (required) + Unique project identifier. - :param str base_version: (optional) - The commit or reference name to compare changes against. If base version is not provided, the difference goes against an empty tree. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - :param bool is_comparison_from_merge_base: (optional) - Boolean value to indicate whether to use merge base or most recent revision. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3359,34 +3435,34 @@ def get_commit_diff(self, repository_id, target_version, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DiffResponse` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_commit_diff API. + Click `here `__ to see an example of how to use delete_project_repository_settings API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'targetVersion'] - resource_path = "/repositories/{repositoryId}/diff" - method = "GET" - operation_name = "get_commit_diff" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetCommitDiff" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}/repositorySettings" + method = "DELETE" + operation_name = "delete_project_repository_settings" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectRepositorySettings/DeleteProjectRepositorySettings" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "base_version", - "is_comparison_from_merge_base", + "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_commit_diff got unknown kwargs: {extra_kwargs!r}") + f"delete_project_repository_settings got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "projectId": project_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3395,16 +3471,11 @@ def get_commit_diff(self, repository_id, target_version, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "baseVersion": kwargs.get("base_version", missing), - "targetVersion": target_version, - "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3418,6 +3489,7 @@ def get_commit_diff(self, repository_id, target_version, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -3425,9 +3497,7 @@ def get_commit_diff(self, repository_id, target_version, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="DiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3437,21 +3507,28 @@ def get_commit_diff(self, repository_id, target_version, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="DiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_connection(self, connection_id, **kwargs): + def delete_protected_branch(self, repository_id, delete_protected_branch_details, **kwargs): """ - Retrieves a connection by identifier. + Removes the protection from a branch - :param str connection_id: (required) - Unique connection identifier. + :param str repository_id: (required) + Unique repository identifier. + + :param oci.devops.models.DeleteProtectedBranchDetails delete_protected_branch_details: (required) + Details for a protected branch + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3468,32 +3545,34 @@ def get_connection(self, connection_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Connection` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_connection API. + Click `here `__ to see an example of how to use delete_protected_branch API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['connectionId'] - resource_path = "/connections/{connectionId}" - method = "GET" - operation_name = "get_connection" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Connection/GetConnection" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/actions/deleteProtectedBranch" + method = "POST" + operation_name = "delete_protected_branch" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProtectedBranch/DeleteProtectedBranch" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_connection got unknown kwargs: {extra_kwargs!r}") + f"delete_protected_branch got unknown kwargs: {extra_kwargs!r}") path_params = { - "connectionId": connection_id + "repositoryId": repository_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3505,6 +3584,8 @@ def get_connection(self, connection_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3518,6 +3599,7 @@ def get_connection(self, connection_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -3526,7 +3608,7 @@ def get_connection(self, connection_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Connection", + body=delete_protected_branch_details, allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3537,19 +3619,22 @@ def get_connection(self, connection_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Connection", + body=delete_protected_branch_details, allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_deploy_artifact(self, deploy_artifact_id, **kwargs): + def delete_pull_request(self, pull_request_id, **kwargs): """ - Retrieves a deployment artifact by identifier. + Deletes a PullRequest resource by identifier - :param str deploy_artifact_id: (required) - Unique artifact identifier. + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3566,32 +3651,33 @@ def get_deploy_artifact(self, deploy_artifact_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployArtifact` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_deploy_artifact API. + Click `here `__ to see an example of how to use delete_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployArtifactId'] - resource_path = "/deployArtifacts/{deployArtifactId}" - method = "GET" - operation_name = "get_deploy_artifact" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifact/GetDeployArtifact" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}" + method = "DELETE" + operation_name = "delete_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/DeletePullRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_deploy_artifact got unknown kwargs: {extra_kwargs!r}") + f"delete_pull_request got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployArtifactId": deploy_artifact_id + "pullRequestId": pull_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3603,6 +3689,7 @@ def get_deploy_artifact(self, deploy_artifact_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3624,7 +3711,6 @@ def get_deploy_artifact(self, deploy_artifact_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployArtifact", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3635,19 +3721,24 @@ def get_deploy_artifact(self, deploy_artifact_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployArtifact", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_deploy_environment(self, deploy_environment_id, **kwargs): + def delete_pull_request_attachment(self, pull_request_id, attachment_id, **kwargs): """ - Retrieves a deployment environment by identifier. + Deletes a PullRequest attachment metadata by identifier - :param str deploy_environment_id: (required) - Unique environment identifier. + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str attachment_id: (required) + unique PullRequest attachment identifier + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3664,32 +3755,34 @@ def get_deploy_environment(self, deploy_environment_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployEnvironment` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_deploy_environment API. + Click `here `__ to see an example of how to use delete_pull_request_attachment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployEnvironmentId'] - resource_path = "/deployEnvironments/{deployEnvironmentId}" - method = "GET" - operation_name = "get_deploy_environment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironment/GetDeployEnvironment" + required_arguments = ['pullRequestId', 'attachmentId'] + resource_path = "/pullRequests/{pullRequestId}/attachments/{attachmentId}" + method = "DELETE" + operation_name = "delete_pull_request_attachment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/DeletePullRequestAttachment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_deploy_environment got unknown kwargs: {extra_kwargs!r}") + f"delete_pull_request_attachment got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployEnvironmentId": deploy_environment_id + "pullRequestId": pull_request_id, + "attachmentId": attachment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3701,6 +3794,7 @@ def get_deploy_environment(self, deploy_environment_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3722,7 +3816,6 @@ def get_deploy_environment(self, deploy_environment_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployEnvironment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3733,19 +3826,24 @@ def get_deploy_environment(self, deploy_environment_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployEnvironment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_deploy_pipeline(self, deploy_pipeline_id, **kwargs): + def delete_pull_request_comment(self, pull_request_id, comment_id, **kwargs): """ - Retrieves a deployment pipeline by identifier. + Deletes a PullRequest comment by identifier - :param str deploy_pipeline_id: (required) - Unique pipeline identifier. + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str comment_id: (required) + unique PullRequest Comment identifier + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3762,32 +3860,34 @@ def get_deploy_pipeline(self, deploy_pipeline_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployPipeline` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_deploy_pipeline API. + Click `here `__ to see an example of how to use delete_pull_request_comment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployPipelineId'] - resource_path = "/deployPipelines/{deployPipelineId}" - method = "GET" - operation_name = "get_deploy_pipeline" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipeline/GetDeployPipeline" + required_arguments = ['pullRequestId', 'commentId'] + resource_path = "/pullRequests/{pullRequestId}/comments/{commentId}" + method = "DELETE" + operation_name = "delete_pull_request_comment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/DeletePullRequestComment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_deploy_pipeline got unknown kwargs: {extra_kwargs!r}") + f"delete_pull_request_comment got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployPipelineId": deploy_pipeline_id + "pullRequestId": pull_request_id, + "commentId": comment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3799,6 +3899,7 @@ def get_deploy_pipeline(self, deploy_pipeline_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3820,7 +3921,6 @@ def get_deploy_pipeline(self, deploy_pipeline_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3831,19 +3931,27 @@ def get_deploy_pipeline(self, deploy_pipeline_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_deploy_stage(self, deploy_stage_id, **kwargs): + def delete_ref(self, repository_id, ref_name, **kwargs): """ - Retrieves a deployment stage by identifier. + Deletes a Repository's Ref by its name. Returns an error if the name is ambiguous. Can be disambiguated by using full names like \"heads/\" or \"tags/\". This API will be deprecated on Wed, 12 June 2024 01:00:00 GMT as it does not get recognized when refName has '/'. This will be replaced by \"/repositories/{repositoryId}/actions/deleteGitRef\". - :param str deploy_stage_id: (required) - Unique stage identifier. + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_name: (required) + A filter to return only resources that match the given reference name. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3860,32 +3968,35 @@ def get_deploy_stage(self, deploy_stage_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployStage` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_deploy_stage API. + Click `here `__ to see an example of how to use delete_ref API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployStageId'] - resource_path = "/deployStages/{deployStageId}" - method = "GET" - operation_name = "get_deploy_stage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStage/GetDeployStage" + required_arguments = ['repositoryId', 'refName'] + resource_path = "/repositories/{repositoryId}/refs/{refName}" + method = "DELETE" + operation_name = "delete_ref" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/DeleteRef" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_deploy_stage got unknown kwargs: {extra_kwargs!r}") + f"delete_ref got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployStageId": deploy_stage_id + "repositoryId": repository_id, + "refName": ref_name } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3897,6 +4008,8 @@ def get_deploy_stage(self, deploy_stage_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -3910,6 +4023,7 @@ def get_deploy_stage(self, deploy_stage_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -3918,7 +4032,6 @@ def get_deploy_stage(self, deploy_stage_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3929,19 +4042,21 @@ def get_deploy_stage(self, deploy_stage_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="DeployStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_deployment(self, deployment_id, **kwargs): + def delete_repository(self, repository_id, **kwargs): """ - Retrieves a deployment by identifier. + Deletes a repository resource by identifier. - :param str deployment_id: (required) - Unique deployment identifier. + :param str repository_id: (required) + Unique repository identifier. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -3958,32 +4073,33 @@ def get_deployment(self, deployment_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Deployment` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_deployment API. + Click `here `__ to see an example of how to use delete_repository API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deploymentId'] - resource_path = "/deployments/{deploymentId}" - method = "GET" - operation_name = "get_deployment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Deployment/GetDeployment" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}" + method = "DELETE" + operation_name = "delete_repository" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/DeleteRepository" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_deployment got unknown kwargs: {extra_kwargs!r}") + f"delete_repository got unknown kwargs: {extra_kwargs!r}") path_params = { - "deploymentId": deployment_id + "repositoryId": repository_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -3995,6 +4111,7 @@ def get_deployment(self, deployment_id, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -4016,7 +4133,6 @@ def get_deployment(self, deployment_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Deployment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4027,31 +4143,24 @@ def get_deployment(self, deployment_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Deployment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_file_diff(self, repository_id, file_path, base_version, target_version, **kwargs): + def delete_repository_settings(self, repository_id, **kwargs): """ - Gets the line-by-line difference between file on different commits. This API will be deprecated on Wed, 29 Mar 2023 01:00:00 GMT as it does not get recognized when filePath has '/'. This will be replaced by \"/repositories/{repositoryId}/file/diffs\" + Removes the custom settings configured for a repository :param str repository_id: (required) Unique repository identifier. - :param str file_path: (required) - Path to a file within a repository. - - :param str base_version: (required) - The branch to compare changes against. - - :param str target_version: (required) - The branch where changes are coming from. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - :param bool is_comparison_from_merge_base: (optional) - Boolean to indicate whether to use merge base or most recent revision. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4068,34 +4177,34 @@ def get_file_diff(self, repository_id, file_path, base_version, target_version, allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.FileDiffResponse` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_file_diff API. + Click `here `__ to see an example of how to use delete_repository_settings API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'filePath', 'baseVersion', 'targetVersion'] - resource_path = "/repositories/{repositoryId}/diffs/{filePath}" - method = "GET" - operation_name = "get_file_diff" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetFileDiff" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/repositorySettings" + method = "DELETE" + operation_name = "delete_repository_settings" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositorySettings/DeleteRepositorySettings" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "is_comparison_from_merge_base", + "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_file_diff got unknown kwargs: {extra_kwargs!r}") + f"delete_repository_settings got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "filePath": file_path + "repositoryId": repository_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4104,16 +4213,11 @@ def get_file_diff(self, repository_id, file_path, base_version, target_version, if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "baseVersion": base_version, - "targetVersion": target_version, - "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -4127,6 +4231,7 @@ def get_file_diff(self, repository_id, file_path, base_version, target_version, if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -4134,9 +4239,7 @@ def get_file_diff(self, repository_id, file_path, base_version, target_version, resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="FileDiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4146,28 +4249,22 @@ def get_file_diff(self, repository_id, file_path, base_version, target_version, resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="FileDiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_mirror_record(self, repository_id, mirror_record_type, **kwargs): + def delete_trigger(self, trigger_id, **kwargs): """ - Returns either current mirror record or last successful mirror record for a specific mirror repository. - + Deletes a trigger resource by identifier. - :param str repository_id: (required) - Unique repository identifier. - :param str mirror_record_type: (required) - The field of mirror record type. Only one mirror record type can be provided: - current - The current mirror record. - lastSuccessful - The last successful mirror record. + :param str trigger_id: (required) + Unique trigger identifier. - Allowed values are: "current", "lastSuccessful" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4184,33 +4281,33 @@ def get_mirror_record(self, repository_id, mirror_record_type, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryMirrorRecord` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_mirror_record API. + Click `here `__ to see an example of how to use delete_trigger API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'mirrorRecordType'] - resource_path = "/repositories/{repositoryId}/mirrorRecords/{mirrorRecordType}" - method = "GET" - operation_name = "get_mirror_record" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetMirrorRecord" + required_arguments = ['triggerId'] + resource_path = "/triggers/{triggerId}" + method = "DELETE" + operation_name = "delete_trigger" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Trigger/DeleteTrigger" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_mirror_record got unknown kwargs: {extra_kwargs!r}") + f"delete_trigger got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "mirrorRecordType": mirror_record_type + "triggerId": trigger_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4222,6 +4319,7 @@ def get_mirror_record(self, repository_id, mirror_record_type, **kwargs): header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -4243,7 +4341,6 @@ def get_mirror_record(self, repository_id, mirror_record_type, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="RepositoryMirrorRecord", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4254,25 +4351,18 @@ def get_mirror_record(self, repository_id, mirror_record_type, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="RepositoryMirrorRecord", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_object(self, repository_id, **kwargs): + def get_build_pipeline(self, build_pipeline_id, **kwargs): """ - Retrieves blob of specific branch name/commit ID and file path. - - - :param str repository_id: (required) - Unique repository identifier. + Retrieves a build pipeline by identifier. - :param str file_path: (optional) - A filter to return only commits that affect any of the specified paths. - :param str ref_name: (optional) - A filter to return only resources that match the given reference name. + :param str build_pipeline_id: (required) + Unique build pipeline identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4289,34 +4379,32 @@ def get_object(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryObject` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipeline` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_object API. + Click `here `__ to see an example of how to use get_build_pipeline API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/object" + required_arguments = ['buildPipelineId'] + resource_path = "/buildPipelines/{buildPipelineId}" method = "GET" - operation_name = "get_object" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryObject/GetObject" + operation_name = "get_build_pipeline" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipeline/GetBuildPipeline" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "file_path", - "ref_name", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_object got unknown kwargs: {extra_kwargs!r}") + f"get_build_pipeline got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "buildPipelineId": build_pipeline_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4325,12 +4413,6 @@ def get_object(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "filePath": kwargs.get("file_path", missing), - "refName": kwargs.get("ref_name", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -4354,9 +4436,8 @@ def get_object(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryObject", + response_type="BuildPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4366,27 +4447,20 @@ def get_object(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryObject", + response_type="BuildPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_object_content(self, repository_id, sha, **kwargs): + def get_build_pipeline_stage(self, build_pipeline_stage_id, **kwargs): """ - Retrieve contents of a specified object. - - - :param str repository_id: (required) - Unique repository identifier. + Retrieves a stage based on the stage ID provided in the request. - :param str sha: (required) - The SHA of a blob or tree. - :param str file_path: (optional) - A filter to return only commits that affect any of the specified paths. + :param str build_pipeline_stage_id: (required) + Unique stage identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4403,34 +4477,32 @@ def get_object_content(self, repository_id, sha, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type stream + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineStage` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_object_content API. + Click `here `__ to see an example of how to use get_build_pipeline_stage API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'sha'] - resource_path = "/repositories/{repositoryId}/objects/{sha}/content" + required_arguments = ['buildPipelineStageId'] + resource_path = "/buildPipelineStages/{buildPipelineStageId}" method = "GET" - operation_name = "get_object_content" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetObjectContent" + operation_name = "get_build_pipeline_stage" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStage/GetBuildPipelineStage" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "file_path", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_object_content got unknown kwargs: {extra_kwargs!r}") + f"get_build_pipeline_stage got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "sha": sha + "buildPipelineStageId": build_pipeline_stage_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4439,11 +4511,6 @@ def get_object_content(self, repository_id, sha, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "filePath": kwargs.get("file_path", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -4467,9 +4534,8 @@ def get_object_content(self, repository_id, sha, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="stream", + response_type="BuildPipelineStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4479,21 +4545,20 @@ def get_object_content(self, repository_id, sha, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="stream", + response_type="BuildPipelineStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_project(self, project_id, **kwargs): + def get_build_run(self, build_run_id, **kwargs): """ - Retrieves a project by identifier. + Returns the details of a build run for a given build run ID. - :param str project_id: (required) - Unique project identifier. + :param str build_run_id: (required) + Unique build run identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4510,18 +4575,18 @@ def get_project(self, project_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Project` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRun` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_project API. + Click `here `__ to see an example of how to use get_build_run API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['projectId'] - resource_path = "/projects/{projectId}" + required_arguments = ['buildRunId'] + resource_path = "/buildRuns/{buildRunId}" method = "GET" - operation_name = "get_project" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/GetProject" + operation_name = "get_build_run" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildRun/GetBuildRun" # Don't accept unknown kwargs expected_kwargs = [ @@ -4532,10 +4597,10 @@ def get_project(self, project_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_project got unknown kwargs: {extra_kwargs!r}") + f"get_build_run got unknown kwargs: {extra_kwargs!r}") path_params = { - "projectId": project_id + "buildRunId": build_run_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4568,7 +4633,7 @@ def get_project(self, project_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Project", + response_type="BuildRun", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4579,22 +4644,22 @@ def get_project(self, project_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Project", + response_type="BuildRun", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_ref(self, repository_id, ref_name, **kwargs): + def get_commit(self, repository_id, commit_id, **kwargs): """ - This API will be deprecated on Wed, 12 June 2024 01:00:00 GMT as it does not get recognized when refName has '/'. This will be replaced by \"/repositories/{repositoryId}/refs\". Retrieves a repository's reference by its name with preference for branches over tags if the name is ambiguous. This can be disambiguated by using full names like \"heads/\" or \"tags/\". + Retrieves a repository's commit by commit ID. :param str repository_id: (required) Unique repository identifier. - :param str ref_name: (required) - A filter to return only resources that match the given reference name. + :param str commit_id: (required) + A filter to return only resources that match the given commit ID. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4611,18 +4676,18 @@ def get_ref(self, repository_id, ref_name, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRef` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCommit` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_ref API. + Click `here `__ to see an example of how to use get_commit API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'refName'] - resource_path = "/repositories/{repositoryId}/refs/{refName}" + required_arguments = ['repositoryId', 'commitId'] + resource_path = "/repositories/{repositoryId}/commits/{commitId}" method = "GET" - operation_name = "get_ref" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRef" + operation_name = "get_commit" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetCommit" # Don't accept unknown kwargs expected_kwargs = [ @@ -4633,11 +4698,11 @@ def get_ref(self, repository_id, ref_name, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_ref got unknown kwargs: {extra_kwargs!r}") + f"get_commit got unknown kwargs: {extra_kwargs!r}") path_params = { "repositoryId": repository_id, - "refName": ref_name + "commitId": commit_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4670,7 +4735,7 @@ def get_ref(self, repository_id, ref_name, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="RepositoryRef", + response_type="RepositoryCommit", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4681,31 +4746,31 @@ def get_ref(self, repository_id, ref_name, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="RepositoryRef", + response_type="RepositoryCommit", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_repo_file_diff(self, repository_id, base_version, target_version, **kwargs): + def get_commit_diff(self, repository_id, target_version, **kwargs): """ - Gets the line-by-line difference between file on different commits. + Compares two revisions for their differences. Supports comparison between two references or commits. :param str repository_id: (required) Unique repository identifier. - :param str base_version: (required) - The branch to compare changes against. - :param str target_version: (required) - The branch where changes are coming from. + The commit or reference name that represents the newer changes against the base version. - :param str file_path: (optional) - A filter to return only commits that affect any of the specified paths. + :param str base_version: (optional) + The commit or reference name to compare changes against. If base version is not provided, the difference goes against an empty tree. + + :param str target_repository_id: (optional) + The target repository identifier :param bool is_comparison_from_merge_base: (optional) - Boolean to indicate whether to use merge base or most recent revision. + Boolean value to indicate whether to use merge base or most recent revision. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4722,31 +4787,32 @@ def get_repo_file_diff(self, repository_id, base_version, target_version, **kwar allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.FileDiffResponse` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DiffResponse` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_repo_file_diff API. + Click `here `__ to see an example of how to use get_commit_diff API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'baseVersion', 'targetVersion'] - resource_path = "/repositories/{repositoryId}/file/diffs" + required_arguments = ['repositoryId', 'targetVersion'] + resource_path = "/repositories/{repositoryId}/diff" method = "GET" - operation_name = "get_repo_file_diff" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepoFileDiff" + operation_name = "get_commit_diff" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetCommitDiff" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "file_path", + "base_version", + "target_repository_id", "is_comparison_from_merge_base", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_repo_file_diff got unknown kwargs: {extra_kwargs!r}") + f"get_commit_diff got unknown kwargs: {extra_kwargs!r}") path_params = { "repositoryId": repository_id @@ -4759,9 +4825,9 @@ def get_repo_file_diff(self, repository_id, base_version, target_version, **kwar raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') query_params = { - "filePath": kwargs.get("file_path", missing), - "baseVersion": base_version, + "baseVersion": kwargs.get("base_version", missing), "targetVersion": target_version, + "targetRepositoryId": kwargs.get("target_repository_id", missing), "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -4791,7 +4857,7 @@ def get_repo_file_diff(self, repository_id, base_version, target_version, **kwar path_params=path_params, query_params=query_params, header_params=header_params, - response_type="FileDiffResponse", + response_type="DiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4803,31 +4869,19 @@ def get_repo_file_diff(self, repository_id, base_version, target_version, **kwar path_params=path_params, query_params=query_params, header_params=header_params, - response_type="FileDiffResponse", + response_type="DiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_repo_file_lines(self, repository_id, revision, **kwargs): + def get_connection(self, connection_id, **kwargs): """ - Retrieve lines of a specified file. Supports starting line number and limit. - - - :param str repository_id: (required) - Unique repository identifier. - - :param str revision: (required) - Retrieve file lines from specific revision. - - :param str file_path: (optional) - A filter to return only commits that affect any of the specified paths. + Retrieves a connection by identifier. - :param int start_line_number: (optional) - Line number from where to start returning file lines. - :param int limit: (optional) - The maximum number of items to return. + :param str connection_id: (required) + Unique connection identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -4844,35 +4898,32 @@ def get_repo_file_lines(self, repository_id, revision, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryFileLines` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Connection` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_repo_file_lines API. + Click `here `__ to see an example of how to use get_connection API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'revision'] - resource_path = "/repositories/{repositoryId}/file/lines" + required_arguments = ['connectionId'] + resource_path = "/connections/{connectionId}" method = "GET" - operation_name = "get_repo_file_lines" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepoFileLines" + operation_name = "get_connection" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Connection/GetConnection" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "file_path", - "start_line_number", - "limit", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_repo_file_lines got unknown kwargs: {extra_kwargs!r}") + f"get_connection got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "connectionId": connection_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4881,14 +4932,6 @@ def get_repo_file_lines(self, repository_id, revision, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "filePath": kwargs.get("file_path", missing), - "revision": revision, - "startLineNumber": kwargs.get("start_line_number", missing), - "limit": kwargs.get("limit", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -4912,9 +4955,8 @@ def get_repo_file_lines(self, repository_id, revision, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryFileLines", + response_type="Connection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4924,30 +4966,24 @@ def get_repo_file_lines(self, repository_id, revision, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryFileLines", + response_type="Connection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_repository(self, repository_id, **kwargs): + def get_deploy_artifact(self, deploy_artifact_id, **kwargs): """ - Retrieves a repository by identifier. + Retrieves a deployment artifact by identifier. - :param str repository_id: (required) - Unique repository identifier. + :param str deploy_artifact_id: (required) + Unique artifact identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - :param list[str] fields: (optional) - Fields parameter can contain multiple flags useful in deciding the API functionality. - - Allowed values are: "branchCount", "commitCount", "sizeInBytes" - :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -4960,33 +4996,32 @@ def get_repository(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Repository` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployArtifact` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_repository API. + Click `here `__ to see an example of how to use get_deploy_artifact API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}" + required_arguments = ['deployArtifactId'] + resource_path = "/deployArtifacts/{deployArtifactId}" method = "GET" - operation_name = "get_repository" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepository" + operation_name = "get_deploy_artifact" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifact/GetDeployArtifact" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "opc_request_id", - "fields" + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_repository got unknown kwargs: {extra_kwargs!r}") + f"get_deploy_artifact got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "deployArtifactId": deploy_artifact_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -4995,19 +5030,6 @@ def get_repository(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'fields' in kwargs: - fields_allowed_values = ["branchCount", "commitCount", "sizeInBytes"] - for fields_item in kwargs['fields']: - if fields_item not in fields_allowed_values: - raise ValueError( - f"Invalid value for `fields`, must be one of { fields_allowed_values }" - ) - - query_params = { - "fields": self.base_client.generate_collection_format_param(kwargs.get("fields", missing), 'multi') - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -5031,9 +5053,8 @@ def get_repository(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="Repository", + response_type="DeployArtifact", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5043,27 +5064,20 @@ def get_repository(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="Repository", + response_type="DeployArtifact", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_repository_archive_content(self, repository_id, **kwargs): + def get_deploy_environment(self, deploy_environment_id, **kwargs): """ - Returns the archived repository information. - - - :param str repository_id: (required) - Unique repository identifier. + Retrieves a deployment environment by identifier. - :param str ref_name: (optional) - A filter to return only resources that match the given reference name. - :param str format: (optional) - The archive format query parameter for downloading repository endpoint. + :param str deploy_environment_id: (required) + Unique environment identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5080,34 +5094,32 @@ def get_repository_archive_content(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type stream + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployEnvironment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_repository_archive_content API. + Click `here `__ to see an example of how to use get_deploy_environment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/archive/content" + required_arguments = ['deployEnvironmentId'] + resource_path = "/deployEnvironments/{deployEnvironmentId}" method = "GET" - operation_name = "get_repository_archive_content" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepositoryArchiveContent" + operation_name = "get_deploy_environment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironment/GetDeployEnvironment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "ref_name", - "format", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_repository_archive_content got unknown kwargs: {extra_kwargs!r}") + f"get_deploy_environment got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "deployEnvironmentId": deploy_environment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -5116,12 +5128,6 @@ def get_repository_archive_content(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "refName": kwargs.get("ref_name", missing), - "format": kwargs.get("format", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -5145,9 +5151,8 @@ def get_repository_archive_content(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="stream", + response_type="DeployEnvironment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5157,33 +5162,20 @@ def get_repository_archive_content(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="stream", + response_type="DeployEnvironment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_repository_file_lines(self, repository_id, file_path, revision, **kwargs): + def get_deploy_pipeline(self, deploy_pipeline_id, **kwargs): """ - Retrieve lines of a specified file. Supports starting line number and limit. This API will be deprecated on Wed, 29 Mar 2023 01:00:00 GMT as it does not get recognized when filePath has '/'. This will be replaced by \"/repositories/{repositoryId}/file/lines\" - - - :param str repository_id: (required) - Unique repository identifier. - - :param str file_path: (required) - Path to a file within a repository. - - :param str revision: (required) - Retrieve file lines from specific revision. + Retrieves a deployment pipeline by identifier. - :param int start_line_number: (optional) - Line number from where to start returning file lines. - :param int limit: (optional) - The maximum number of items to return. + :param str deploy_pipeline_id: (required) + Unique pipeline identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5200,35 +5192,32 @@ def get_repository_file_lines(self, repository_id, file_path, revision, **kwargs allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryFileLines` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployPipeline` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_repository_file_lines API. + Click `here `__ to see an example of how to use get_deploy_pipeline API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'filePath', 'revision'] - resource_path = "/repositories/{repositoryId}/files/{filePath}/lines" + required_arguments = ['deployPipelineId'] + resource_path = "/deployPipelines/{deployPipelineId}" method = "GET" - operation_name = "get_repository_file_lines" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepositoryFileLines" + operation_name = "get_deploy_pipeline" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipeline/GetDeployPipeline" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "start_line_number", - "limit", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_repository_file_lines got unknown kwargs: {extra_kwargs!r}") + f"get_deploy_pipeline got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "filePath": file_path + "deployPipelineId": deploy_pipeline_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -5237,13 +5226,6 @@ def get_repository_file_lines(self, repository_id, file_path, revision, **kwargs if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "revision": revision, - "startLineNumber": kwargs.get("start_line_number", missing), - "limit": kwargs.get("limit", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -5267,9 +5249,8 @@ def get_repository_file_lines(self, repository_id, file_path, revision, **kwargs resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryFileLines", + response_type="DeployPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5279,21 +5260,20 @@ def get_repository_file_lines(self, repository_id, file_path, revision, **kwargs resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryFileLines", + response_type="DeployPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_trigger(self, trigger_id, **kwargs): + def get_deploy_stage(self, deploy_stage_id, **kwargs): """ - Retrieves a trigger by identifier. + Retrieves a deployment stage by identifier. - :param str trigger_id: (required) - Unique trigger identifier. + :param str deploy_stage_id: (required) + Unique stage identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5310,18 +5290,18 @@ def get_trigger(self, trigger_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Trigger` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployStage` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_trigger API. + Click `here `__ to see an example of how to use get_deploy_stage API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['triggerId'] - resource_path = "/triggers/{triggerId}" + required_arguments = ['deployStageId'] + resource_path = "/deployStages/{deployStageId}" method = "GET" - operation_name = "get_trigger" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Trigger/GetTrigger" + operation_name = "get_deploy_stage" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStage/GetDeployStage" # Don't accept unknown kwargs expected_kwargs = [ @@ -5332,10 +5312,10 @@ def get_trigger(self, trigger_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_trigger got unknown kwargs: {extra_kwargs!r}") + f"get_deploy_stage got unknown kwargs: {extra_kwargs!r}") path_params = { - "triggerId": trigger_id + "deployStageId": deploy_stage_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -5368,7 +5348,7 @@ def get_trigger(self, trigger_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Trigger", + response_type="DeployStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5379,19 +5359,19 @@ def get_trigger(self, trigger_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="Trigger", + response_type="DeployStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def get_work_request(self, work_request_id, **kwargs): + def get_deployment(self, deployment_id, **kwargs): """ - Retrieves the status of the work request with the given ID. + Retrieves a deployment by identifier. - :param str work_request_id: (required) - The ID of the asynchronous work request. + :param str deployment_id: (required) + Unique deployment identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5408,18 +5388,18 @@ def get_work_request(self, work_request_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequest` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Deployment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use get_work_request API. + Click `here `__ to see an example of how to use get_deployment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['workRequestId'] - resource_path = "/workRequests/{workRequestId}" + required_arguments = ['deploymentId'] + resource_path = "/deployments/{deploymentId}" method = "GET" - operation_name = "get_work_request" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequest/GetWorkRequest" + operation_name = "get_deployment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Deployment/GetDeployment" # Don't accept unknown kwargs expected_kwargs = [ @@ -5430,10 +5410,10 @@ def get_work_request(self, work_request_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"get_work_request got unknown kwargs: {extra_kwargs!r}") + f"get_deployment got unknown kwargs: {extra_kwargs!r}") path_params = { - "workRequestId": work_request_id + "deploymentId": deployment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -5466,7 +5446,7 @@ def get_work_request(self, work_request_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="WorkRequest", + response_type="Deployment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5477,33 +5457,31 @@ def get_work_request(self, work_request_id, **kwargs): method=method, path_params=path_params, header_params=header_params, - response_type="WorkRequest", + response_type="Deployment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_authors(self, repository_id, **kwargs): + def get_file_diff(self, repository_id, file_path, base_version, target_version, **kwargs): """ - Retrieve a list of all the authors. + Gets the line-by-line difference between file on different commits. This API will be deprecated on Wed, 29 Mar 2023 01:00:00 GMT as it does not get recognized when filePath has '/'. This will be replaced by \"/repositories/{repositoryId}/file/diffs\" :param str repository_id: (required) Unique repository identifier. - :param str ref_name: (optional) - A filter to return only resources that match the given reference name. - - :param int limit: (optional) - The maximum number of items to return. + :param str file_path: (required) + Path to a file within a repository. - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + :param str base_version: (required) + The branch to compare changes against. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + :param str target_version: (required) + The branch where changes are coming from. - Allowed values are: "ASC", "DESC" + :param bool is_comparison_from_merge_base: (optional) + Boolean to indicate whether to use merge base or most recent revision. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5520,36 +5498,34 @@ def list_authors(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryAuthorCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.FileDiffResponse` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_authors API. + Click `here `__ to see an example of how to use get_file_diff API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/authors" + required_arguments = ['repositoryId', 'filePath', 'baseVersion', 'targetVersion'] + resource_path = "/repositories/{repositoryId}/diffs/{filePath}" method = "GET" - operation_name = "list_authors" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListAuthors" + operation_name = "get_file_diff" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetFileDiff" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "ref_name", - "limit", - "page", - "sort_order", + "is_comparison_from_merge_base", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_authors got unknown kwargs: {extra_kwargs!r}") + f"get_file_diff got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "repositoryId": repository_id, + "filePath": file_path } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -5558,18 +5534,10 @@ def list_authors(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) - query_params = { - "refName": kwargs.get("ref_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing) + "baseVersion": base_version, + "targetVersion": target_version, + "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -5598,7 +5566,7 @@ def list_authors(self, repository_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryAuthorCollection", + response_type="FileDiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5610,49 +5578,26 @@ def list_authors(self, repository_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryAuthorCollection", + response_type="FileDiffResponse", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_build_pipeline_stages(self, **kwargs): + def get_mirror_record(self, repository_id, mirror_record_type, **kwargs): """ - Returns a list of all stages in a compartment or build pipeline. - - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str build_pipeline_id: (optional) - The OCID of the parent build pipeline. - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str lifecycle_state: (optional) - A filter to return the stages that matches the given lifecycle state. - - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Returns either current mirror record or last successful mirror record for a specific mirror repository. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str repository_id: (required) + Unique repository identifier. - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param str mirror_record_type: (required) + The field of mirror record type. Only one mirror record type can be provided: + current - The current mirror record. + lastSuccessful - The last successful mirror record. - Allowed values are: "timeCreated", "displayName" + Allowed values are: "current", "lastSuccessful" :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5669,72 +5614,40 @@ def list_build_pipeline_stages(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineStageCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryMirrorRecord` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_build_pipeline_stages API. + Click `here `__ to see an example of how to use get_mirror_record API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/buildPipelineStages" + required_arguments = ['repositoryId', 'mirrorRecordType'] + resource_path = "/repositories/{repositoryId}/mirrorRecords/{mirrorRecordType}" method = "GET" - operation_name = "list_build_pipeline_stages" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStageSummary/ListBuildPipelineStages" + operation_name = "get_mirror_record" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetMirrorRecord" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "build_pipeline_id", - "compartment_id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_build_pipeline_stages got unknown kwargs: {extra_kwargs!r}") - - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + f"get_mirror_record got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "repositoryId": repository_id, + "mirrorRecordType": mirror_record_type + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "id": kwargs.get("id", missing), - "buildPipelineId": kwargs.get("build_pipeline_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", @@ -5758,9 +5671,9 @@ def list_build_pipeline_stages(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="BuildPipelineStageCollection", + response_type="RepositoryMirrorRecord", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5769,51 +5682,27 @@ def list_build_pipeline_stages(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="BuildPipelineStageCollection", + response_type="RepositoryMirrorRecord", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_build_pipelines(self, **kwargs): + def get_object(self, repository_id, **kwargs): """ - Returns a list of build pipelines. - - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str project_id: (optional) - unique project identifier - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str lifecycle_state: (optional) - A filter to return only build pipelines that matches the given lifecycle state. - - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Retrieves blob of specific branch name/commit ID and file path. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str repository_id: (required) + Unique repository identifier. - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param str file_path: (optional) + A filter to return only commits that affect any of the specified paths. - Allowed values are: "timeCreated", "displayName" + :param str ref_name: (optional) + A filter to return only resources that match the given reference name. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5830,70 +5719,45 @@ def list_build_pipelines(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryObject` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_build_pipelines API. + Click `here `__ to see an example of how to use get_object API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/buildPipelines" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/object" method = "GET" - operation_name = "list_build_pipelines" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineCollection/ListBuildPipelines" + operation_name = "get_object" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryObject/GetObject" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "project_id", - "compartment_id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", + "file_path", + "ref_name", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_build_pipelines got unknown kwargs: {extra_kwargs!r}") + f"get_object got unknown kwargs: {extra_kwargs!r}") - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + path_params = { + "repositoryId": repository_id + } - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') query_params = { - "id": kwargs.get("id", missing), - "projectId": kwargs.get("project_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + "filePath": kwargs.get("file_path", missing), + "refName": kwargs.get("ref_name", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -5919,9 +5783,10 @@ def list_build_pipelines(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="BuildPipelineCollection", + response_type="RepositoryObject", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -5930,54 +5795,28 @@ def list_build_pipelines(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="BuildPipelineCollection", + response_type="RepositoryObject", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_build_runs(self, **kwargs): + def get_object_content(self, repository_id, sha, **kwargs): """ - Returns a list of build run summary. - - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str build_pipeline_id: (optional) - Unique build pipeline identifier. - - :param str project_id: (optional) - unique project identifier - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param str lifecycle_state: (optional) - A filter to return only build runs that matches the given lifecycle state. - - Allowed values are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "DELETING" - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Retrieve contents of a specified object. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str repository_id: (required) + Unique repository identifier. - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param str sha: (required) + The SHA of a blob or tree. - Allowed values are: "timeCreated", "displayName" + :param str file_path: (optional) + A filter to return only commits that affect any of the specified paths. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -5994,72 +5833,44 @@ def list_build_runs(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRunSummaryCollection` + :return: A :class:`~oci.response.Response` object with data of type stream :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_build_runs API. + Click `here `__ to see an example of how to use get_object_content API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/buildRuns" + required_arguments = ['repositoryId', 'sha'] + resource_path = "/repositories/{repositoryId}/objects/{sha}/content" method = "GET" - operation_name = "list_build_runs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildRunSummary/ListBuildRuns" + operation_name = "get_object_content" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetObjectContent" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "build_pipeline_id", - "project_id", - "compartment_id", - "display_name", - "lifecycle_state", - "limit", - "page", - "sort_order", - "sort_by", + "file_path", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_build_runs got unknown kwargs: {extra_kwargs!r}") + f"get_object_content got unknown kwargs: {extra_kwargs!r}") - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "DELETING"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + path_params = { + "repositoryId": repository_id, + "sha": sha + } - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') query_params = { - "id": kwargs.get("id", missing), - "buildPipelineId": kwargs.get("build_pipeline_id", missing), - "projectId": kwargs.get("project_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "displayName": kwargs.get("display_name", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + "filePath": kwargs.get("file_path", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -6085,9 +5896,10 @@ def list_build_runs(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="BuildRunSummaryCollection", + response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6096,36 +5908,22 @@ def list_build_runs(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="BuildRunSummaryCollection", + response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_commit_diffs(self, repository_id, base_version, target_version, **kwargs): + def get_project(self, project_id, **kwargs): """ - Compares two revisions and lists the differences. Supports comparison between two references or commits. - - - :param str repository_id: (required) - Unique repository identifier. - - :param str base_version: (required) - The commit or reference name to compare changes against. - - :param str target_version: (required) - The commit or reference name where changes are coming from. - - :param bool is_comparison_from_merge_base: (optional) - Boolean value to indicate whether to use merge base or most recent revision. + Retrieves a project by identifier. - :param int limit: (optional) - The maximum number of items to return. - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + :param str project_id: (required) + Unique project identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -6142,35 +5940,32 @@ def list_commit_diffs(self, repository_id, base_version, target_version, **kwarg allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DiffCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Project` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_commit_diffs API. + Click `here `__ to see an example of how to use get_project API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'baseVersion', 'targetVersion'] - resource_path = "/repositories/{repositoryId}/diffs" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}" method = "GET" - operation_name = "list_commit_diffs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListCommitDiffs" + operation_name = "get_project" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/GetProject" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "is_comparison_from_merge_base", - "limit", - "page", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_commit_diffs got unknown kwargs: {extra_kwargs!r}") + f"get_project got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "projectId": project_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -6179,15 +5974,6 @@ def list_commit_diffs(self, repository_id, base_version, target_version, **kwarg if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "baseVersion": base_version, - "targetVersion": target_version, - "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -6211,9 +5997,8 @@ def list_commit_diffs(self, repository_id, base_version, target_version, **kwarg resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="DiffCollection", + response_type="Project", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6223,48 +6008,23 @@ def list_commit_diffs(self, repository_id, base_version, target_version, **kwarg resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="DiffCollection", + response_type="Project", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_commits(self, repository_id, **kwargs): + def get_project_notification_preference(self, project_id, principal_id, **kwargs): """ - Returns a list of commits. - + Get the project notification preference for the user passed as path param - :param str repository_id: (required) - Unique repository identifier. - - :param str ref_name: (optional) - A filter to return only resources that match the given reference name. - - :param str exclude_ref_name: (optional) - A filter to exclude commits that match the given reference name. - - :param str file_path: (optional) - A filter to return only commits that affect any of the specified paths. - - :param datetime timestamp_greater_than_or_equal_to: (optional) - A filter to return commits only created after the specified timestamp value. - - :param datetime timestamp_less_than_or_equal_to: (optional) - A filter to return commits only created before the specified timestamp value. - - :param str commit_message: (optional) - A filter to return any commits that contains the given message. - :param str author_name: (optional) - A filter to return any commits that are pushed by the requested author. - - :param int limit: (optional) - The maximum number of items to return. + :param str project_id: (required) + Unique project identifier. - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + :param str principal_id: (required) + Unique principal identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -6281,41 +6041,33 @@ def list_commits(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCommitCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProjectNotificationPreference` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_commits API. + Click `here `__ to see an example of how to use get_project_notification_preference API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/commits" + required_arguments = ['projectId', 'principalId'] + resource_path = "/projects/{projectId}/principals/{principalId}/pullRequestNotificationPreference" method = "GET" - operation_name = "list_commits" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryCommit/ListCommits" + operation_name = "get_project_notification_preference" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectNotificationPreference/GetProjectNotificationPreference" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "ref_name", - "exclude_ref_name", - "file_path", - "timestamp_greater_than_or_equal_to", - "timestamp_less_than_or_equal_to", - "commit_message", - "author_name", - "limit", - "page", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_commits got unknown kwargs: {extra_kwargs!r}") + f"get_project_notification_preference got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "projectId": project_id, + "principalId": principal_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -6324,19 +6076,6 @@ def list_commits(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "refName": kwargs.get("ref_name", missing), - "excludeRefName": kwargs.get("exclude_ref_name", missing), - "filePath": kwargs.get("file_path", missing), - "timestampGreaterThanOrEqualTo": kwargs.get("timestamp_greater_than_or_equal_to", missing), - "timestampLessThanOrEqualTo": kwargs.get("timestamp_less_than_or_equal_to", missing), - "commitMessage": kwargs.get("commit_message", missing), - "authorName": kwargs.get("author_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", @@ -6360,9 +6099,8 @@ def list_commits(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryCommitCollection", + response_type="ProjectNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6372,56 +6110,20 @@ def list_commits(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryCommitCollection", + response_type="ProjectNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_connections(self, **kwargs): + def get_project_repository_settings(self, project_id, **kwargs): """ - Returns a list of connections. - - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str project_id: (optional) - unique project identifier - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str lifecycle_state: (optional) - A filter to return only connections that matches the given lifecycle state. - - Allowed values are: "ACTIVE", "DELETING" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param str connection_type: (optional) - A filter to return only resources that match the given connection type. - - Allowed values are: "GITHUB_ACCESS_TOKEN", "GITLAB_ACCESS_TOKEN", "GITLAB_SERVER_ACCESS_TOKEN", "BITBUCKET_SERVER_ACCESS_TOKEN", "BITBUCKET_CLOUD_APP_PASSWORD", "VBS_ACCESS_TOKEN" - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - - Allowed values are: "ASC", "DESC" + Retrieves a project's repository settings details. - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. - Allowed values are: "timeCreated", "displayName" + :param str project_id: (required) + Unique project identifier. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -6438,81 +6140,39 @@ def list_connections(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ConnectionCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProjectRepositorySettings` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_connections API. + Click `here `__ to see an example of how to use get_project_repository_settings API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/connections" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}/repositorySettings" method = "GET" - operation_name = "list_connections" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ConnectionCollection/ListConnections" + operation_name = "get_project_repository_settings" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectRepositorySettings/GetProjectRepositorySettings" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "project_id", - "compartment_id", - "lifecycle_state", - "display_name", - "connection_type", - "limit", - "page", - "sort_order", - "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_connections got unknown kwargs: {extra_kwargs!r}") - - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["ACTIVE", "DELETING"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) - - if 'connection_type' in kwargs: - connection_type_allowed_values = ["GITHUB_ACCESS_TOKEN", "GITLAB_ACCESS_TOKEN", "GITLAB_SERVER_ACCESS_TOKEN", "BITBUCKET_SERVER_ACCESS_TOKEN", "BITBUCKET_CLOUD_APP_PASSWORD", "VBS_ACCESS_TOKEN"] - if kwargs['connection_type'] not in connection_type_allowed_values: - raise ValueError( - f"Invalid value for `connection_type`, must be one of { connection_type_allowed_values }" - ) + f"get_project_repository_settings got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "projectId": project_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "id": kwargs.get("id", missing), - "projectId": kwargs.get("project_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "connectionType": kwargs.get("connection_type", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", @@ -6536,9 +6196,9 @@ def list_connections(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="ConnectionCollection", + response_type="ProjectRepositorySettings", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6547,51 +6207,21 @@ def list_connections(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="ConnectionCollection", + response_type="ProjectRepositorySettings", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_deploy_artifacts(self, **kwargs): + def get_pull_request(self, pull_request_id, **kwargs): """ - Returns a list of deployment artifacts. - - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str project_id: (optional) - unique project identifier - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str lifecycle_state: (optional) - A filter to return only DeployArtifacts that matches the given lifecycleState. - - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Gets a PullRequest by identifier - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - - Allowed values are: "ASC", "DESC" - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. - - Allowed values are: "timeCreated", "displayName" + :param str pull_request_id: (required) + unique PullRequest identifier :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -6608,72 +6238,39 @@ def list_deploy_artifacts(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployArtifactCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_deploy_artifacts API. + Click `here `__ to see an example of how to use get_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/deployArtifacts" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}" method = "GET" - operation_name = "list_deploy_artifacts" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifactSummary/ListDeployArtifacts" + operation_name = "get_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/GetPullRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "project_id", - "compartment_id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_deploy_artifacts got unknown kwargs: {extra_kwargs!r}") + f"get_pull_request got unknown kwargs: {extra_kwargs!r}") - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) - - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "pullRequestId": pull_request_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "id": kwargs.get("id", missing), - "projectId": kwargs.get("project_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", @@ -6697,9 +6294,9 @@ def list_deploy_artifacts(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployArtifactCollection", + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6708,51 +6305,126 @@ def list_deploy_artifacts(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployArtifactCollection", + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_deploy_environments(self, **kwargs): + def get_pull_request_attachment(self, pull_request_id, attachment_id, **kwargs): """ - Returns a list of deployment environments. + Get PullRequest attachment metadata by identifier - :param str project_id: (optional) - unique project identifier + :param str pull_request_id: (required) + unique PullRequest identifier - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. + :param str attachment_id: (required) + unique PullRequest attachment identifier - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - :param str lifecycle_state: (optional) - A filter to return only DeployEnvironments that matches the given lifecycleState. + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION" + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. - :param int limit: (optional) - The maximum number of items to return. + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestAttachment` + :rtype: :class:`~oci.response.Response` - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + :example: + Click `here `__ to see an example of how to use get_pull_request_attachment API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId', 'attachmentId'] + resource_path = "/pullRequests/{pullRequestId}/attachments/{attachmentId}" + method = "GET" + operation_name = "get_pull_request_attachment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/GetPullRequestAttachment" - Allowed values are: "ASC", "DESC" + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_pull_request_attachment got unknown kwargs: {extra_kwargs!r}") - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + path_params = { + "pullRequestId": pull_request_id, + "attachmentId": attachment_id + } - Allowed values are: "timeCreated", "displayName" + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestAttachment", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestAttachment", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_pull_request_attachment_content(self, pull_request_id, attachment_id, **kwargs): + """ + Gets the content of the attachment. + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str attachment_id: (required) + unique PullRequest attachment identifier :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -6769,72 +6441,138 @@ def list_deploy_environments(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployEnvironmentCollection` + :return: A :class:`~oci.response.Response` object with data of type stream :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_deploy_environments API. + Click `here `__ to see an example of how to use get_pull_request_attachment_content API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/deployEnvironments" + required_arguments = ['pullRequestId', 'attachmentId'] + resource_path = "/pullRequests/{pullRequestId}/attachments/{attachmentId}/content" method = "GET" - operation_name = "list_deploy_environments" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironmentSummary/ListDeployEnvironments" + operation_name = "get_pull_request_attachment_content" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/GetPullRequestAttachmentContent" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "project_id", - "compartment_id", - "id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_deploy_environments got unknown kwargs: {extra_kwargs!r}") + f"get_pull_request_attachment_content got unknown kwargs: {extra_kwargs!r}") - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + path_params = { + "pullRequestId": pull_request_id, + "attachmentId": attachment_id + } - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "projectId": kwargs.get("project_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "id": kwargs.get("id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + header_params = { + "accept": "application/octet-stream", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="stream", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="stream", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_pull_request_change_summary_metrics(self, pull_request_id, **kwargs): + """ + Get pull request diff summary metric + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestChangeSummaryMetrics` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_pull_request_change_summary_metrics API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/changeSummaryMetrics" + method = "GET" + operation_name = "get_pull_request_change_summary_metrics" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/GetPullRequestChangeSummaryMetrics" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_pull_request_change_summary_metrics got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", @@ -6858,9 +6596,9 @@ def list_deploy_environments(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployEnvironmentCollection", + response_type="PullRequestChangeSummaryMetrics", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -6869,51 +6607,6871 @@ def list_deploy_environments(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployEnvironmentCollection", + response_type="PullRequestChangeSummaryMetrics", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_deploy_pipelines(self, **kwargs): + def get_pull_request_comment(self, pull_request_id, comment_id, **kwargs): """ - Returns a list of deployment pipelines. + Get PullRequest comment by identifier - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. + :param str pull_request_id: (required) + unique PullRequest identifier - :param str project_id: (optional) - unique project identifier + :param str comment_id: (required) + unique PullRequest Comment identifier - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - :param str lifecycle_state: (optional) - A filter to return only DeployPipelines that matches the given lifecycleState. + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED" + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. - :param int limit: (optional) - The maximum number of items to return. + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestComment` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_pull_request_comment API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId', 'commentId'] + resource_path = "/pullRequests/{pullRequestId}/comments/{commentId}" + method = "GET" + operation_name = "get_pull_request_comment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/GetPullRequestComment" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_pull_request_comment got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id, + "commentId": comment_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestComment", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestComment", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_pull_request_notification_preference(self, pull_request_id, principal_id, **kwargs): + """ + Get the pull request notification preference for the user passed as path param + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str principal_id: (required) + Unique principal identifier. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestNotificationPreference` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_pull_request_notification_preference API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId', 'principalId'] + resource_path = "/pullRequests/{pullRequestId}/principals/{principalId}/pullRequestNotificationPreference" + method = "GET" + operation_name = "get_pull_request_notification_preference" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequestNotificationPreference/GetPullRequestNotificationPreference" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_pull_request_notification_preference got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id, + "principalId": principal_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestNotificationPreference", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestNotificationPreference", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_ref(self, repository_id, ref_name, **kwargs): + """ + This API will be deprecated on Wed, 12 June 2024 01:00:00 GMT as it does not get recognized when refName has '/'. This will be replaced by \"/repositories/{repositoryId}/refs\". Retrieves a repository's reference by its name with preference for branches over tags if the name is ambiguous. This can be disambiguated by using full names like \"heads/\" or \"tags/\". + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_name: (required) + A filter to return only resources that match the given reference name. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRef` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_ref API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'refName'] + resource_path = "/repositories/{repositoryId}/refs/{refName}" + method = "GET" + operation_name = "get_ref" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRef" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_ref got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id, + "refName": ref_name + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="RepositoryRef", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="RepositoryRef", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repo_file_diff(self, repository_id, base_version, target_version, **kwargs): + """ + Gets the line-by-line difference between file on different commits. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str base_version: (required) + The branch to compare changes against. + + :param str target_version: (required) + The branch where changes are coming from. + + :param str file_path: (optional) + A filter to return only commits that affect any of the specified paths. + + :param bool is_comparison_from_merge_base: (optional) + Boolean to indicate whether to use merge base or most recent revision. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.FileDiffResponse` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repo_file_diff API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'baseVersion', 'targetVersion'] + resource_path = "/repositories/{repositoryId}/file/diffs" + method = "GET" + operation_name = "get_repo_file_diff" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepoFileDiff" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "file_path", + "is_comparison_from_merge_base", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repo_file_diff got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "filePath": kwargs.get("file_path", missing), + "baseVersion": base_version, + "targetVersion": target_version, + "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="FileDiffResponse", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="FileDiffResponse", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repo_file_lines(self, repository_id, revision, **kwargs): + """ + Retrieve lines of a specified file. Supports starting line number and limit. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str revision: (required) + Retrieve file lines from specific revision. + + :param str file_path: (optional) + A filter to return only commits that affect any of the specified paths. + + :param int start_line_number: (optional) + Line number from where to start returning file lines. + + :param int limit: (optional) + The maximum number of items to return. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryFileLines` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repo_file_lines API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'revision'] + resource_path = "/repositories/{repositoryId}/file/lines" + method = "GET" + operation_name = "get_repo_file_lines" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepoFileLines" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "file_path", + "start_line_number", + "limit", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repo_file_lines got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "filePath": kwargs.get("file_path", missing), + "revision": revision, + "startLineNumber": kwargs.get("start_line_number", missing), + "limit": kwargs.get("limit", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryFileLines", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryFileLines", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repository(self, repository_id, **kwargs): + """ + Retrieves a repository by identifier. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param list[str] fields: (optional) + Fields parameter can contain multiple flags useful in deciding the API functionality. + + Allowed values are: "branchCount", "commitCount", "sizeInBytes" + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Repository` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repository API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}" + method = "GET" + operation_name = "get_repository" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepository" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "fields" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repository got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'fields' in kwargs: + fields_allowed_values = ["branchCount", "commitCount", "sizeInBytes"] + for fields_item in kwargs['fields']: + if fields_item not in fields_allowed_values: + raise ValueError( + f"Invalid value for `fields`, must be one of { fields_allowed_values }" + ) + + query_params = { + "fields": self.base_client.generate_collection_format_param(kwargs.get("fields", missing), 'multi') + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="Repository", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="Repository", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repository_archive_content(self, repository_id, **kwargs): + """ + Returns the archived repository information. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_name: (optional) + A filter to return only resources that match the given reference name. + + :param str format: (optional) + The archive format query parameter for downloading repository endpoint. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type stream + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repository_archive_content API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/archive/content" + method = "GET" + operation_name = "get_repository_archive_content" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepositoryArchiveContent" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "ref_name", + "format", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repository_archive_content got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "refName": kwargs.get("ref_name", missing), + "format": kwargs.get("format", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="stream", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="stream", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repository_file_lines(self, repository_id, file_path, revision, **kwargs): + """ + Retrieve lines of a specified file. Supports starting line number and limit. This API will be deprecated on Wed, 29 Mar 2023 01:00:00 GMT as it does not get recognized when filePath has '/'. This will be replaced by \"/repositories/{repositoryId}/file/lines\" + + + :param str repository_id: (required) + Unique repository identifier. + + :param str file_path: (required) + Path to a file within a repository. + + :param str revision: (required) + Retrieve file lines from specific revision. + + :param int start_line_number: (optional) + Line number from where to start returning file lines. + + :param int limit: (optional) + The maximum number of items to return. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryFileLines` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repository_file_lines API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'filePath', 'revision'] + resource_path = "/repositories/{repositoryId}/files/{filePath}/lines" + method = "GET" + operation_name = "get_repository_file_lines" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/GetRepositoryFileLines" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "start_line_number", + "limit", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repository_file_lines got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id, + "filePath": file_path + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "revision": revision, + "startLineNumber": kwargs.get("start_line_number", missing), + "limit": kwargs.get("limit", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryFileLines", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryFileLines", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repository_notification_preference(self, repository_id, principal_id, **kwargs): + """ + Get the repository notification preference for the user passed as path param + + + :param str repository_id: (required) + Unique repository identifier. + + :param str principal_id: (required) + Unique principal identifier. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryNotificationPreference` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repository_notification_preference API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'principalId'] + resource_path = "/repositories/{repositoryId}/principals/{principalId}/pullRequestNotificationPreference" + method = "GET" + operation_name = "get_repository_notification_preference" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryNotificationPreference/GetRepositoryNotificationPreference" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repository_notification_preference got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id, + "principalId": principal_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="RepositoryNotificationPreference", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="RepositoryNotificationPreference", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_repository_settings(self, repository_id, **kwargs): + """ + Retrieves a repository's settings details. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositorySettings` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_repository_settings API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/repositorySettings" + method = "GET" + operation_name = "get_repository_settings" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositorySettings/GetRepositorySettings" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_repository_settings got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="RepositorySettings", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="RepositorySettings", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_trigger(self, trigger_id, **kwargs): + """ + Retrieves a trigger by identifier. + + + :param str trigger_id: (required) + Unique trigger identifier. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Trigger` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_trigger API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['triggerId'] + resource_path = "/triggers/{triggerId}" + method = "GET" + operation_name = "get_trigger" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Trigger/GetTrigger" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_trigger got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "triggerId": trigger_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="Trigger", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="Trigger", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def get_work_request(self, work_request_id, **kwargs): + """ + Retrieves the status of the work request with the given ID. + + + :param str work_request_id: (required) + The ID of the asynchronous work request. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequest` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_work_request API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['workRequestId'] + resource_path = "/workRequests/{workRequestId}" + method = "GET" + operation_name = "get_work_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequest/GetWorkRequest" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_work_request got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "workRequestId": work_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="WorkRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="WorkRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def like_pull_request_comment(self, pull_request_id, comment_id, **kwargs): + """ + Like a PullRequest comment + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str comment_id: (required) + unique PullRequest Comment identifier + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestComment` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use like_pull_request_comment API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId', 'commentId'] + resource_path = "/pullRequests/{pullRequestId}/comments/{commentId}/actions/like" + method = "POST" + operation_name = "like_pull_request_comment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/LikePullRequestComment" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"like_pull_request_comment got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id, + "commentId": comment_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestComment", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="PullRequestComment", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_authors(self, repository_id, **kwargs): + """ + Retrieve a list of all the authors. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_name: (optional) + A filter to return only resources that match the given reference name. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryAuthorCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_authors API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/authors" + method = "GET" + operation_name = "list_authors" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListAuthors" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "ref_name", + "limit", + "page", + "sort_order", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_authors got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + query_params = { + "refName": kwargs.get("ref_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_build_pipeline_stages(self, **kwargs): + """ + Returns a list of all stages in a compartment or build pipeline. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str build_pipeline_id: (optional) + The OCID of the parent build pipeline. + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return the stages that matches the given lifecycle state. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineStageCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_build_pipeline_stages API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/buildPipelineStages" + method = "GET" + operation_name = "list_build_pipeline_stages" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStageSummary/ListBuildPipelineStages" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "build_pipeline_id", + "compartment_id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_build_pipeline_stages got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "buildPipelineId": kwargs.get("build_pipeline_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="BuildPipelineStageCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="BuildPipelineStageCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_build_pipelines(self, **kwargs): + """ + Returns a list of build pipelines. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str project_id: (optional) + unique project identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return only build pipelines that matches the given lifecycle state. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_build_pipelines API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/buildPipelines" + method = "GET" + operation_name = "list_build_pipelines" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineCollection/ListBuildPipelines" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "project_id", + "compartment_id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_build_pipelines got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "projectId": kwargs.get("project_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="BuildPipelineCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="BuildPipelineCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_build_run_snapshots(self, pull_request_id, **kwargs): + """ + Returns a list of build run snapshots for a given commit or the latest commit on a pull request if no commit is provided. + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str pipeline_id: (optional) + Unique build pipeline identifier. + + :param str build_run_id: (optional) + Unique build run identifier. + + :param str commit_id: (optional) + Commit ID in a repository. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for name is ascending. If no value is specified time created is default. + + Allowed values are: "timeCreated", "name" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRunSnapshotCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_build_run_snapshots API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/buildRunSnapshots" + method = "GET" + operation_name = "list_build_run_snapshots" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListBuildRunSnapshots" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "pipeline_id", + "build_run_id", + "commit_id", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_build_run_snapshots got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "name"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "pipelineId": kwargs.get("pipeline_id", missing), + "buildRunId": kwargs.get("build_run_id", missing), + "commitId": kwargs.get("commit_id", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="BuildRunSnapshotCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="BuildRunSnapshotCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_build_runs(self, **kwargs): + """ + Returns a list of build run summary. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str build_pipeline_id: (optional) + Unique build pipeline identifier. + + :param str project_id: (optional) + unique project identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param str lifecycle_state: (optional) + A filter to return only build runs that matches the given lifecycle state. + + Allowed values are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "DELETING" + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRunSummaryCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_build_runs API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/buildRuns" + method = "GET" + operation_name = "list_build_runs" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildRunSummary/ListBuildRuns" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "build_pipeline_id", + "project_id", + "compartment_id", + "display_name", + "lifecycle_state", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_build_runs got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "DELETING"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "buildPipelineId": kwargs.get("build_pipeline_id", missing), + "projectId": kwargs.get("project_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "displayName": kwargs.get("display_name", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="BuildRunSummaryCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="BuildRunSummaryCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_commit_diffs(self, repository_id, base_version, target_version, **kwargs): + """ + Compares two revisions and lists the differences. Supports comparison between two references or commits. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str base_version: (required) + The commit or reference name to compare changes against. + + :param str target_version: (required) + The commit or reference name where changes are coming from. + + :param str target_repository_id: (optional) + The target repository identifier + + :param bool is_comparison_from_merge_base: (optional) + Boolean value to indicate whether to use merge base or most recent revision. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DiffCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_commit_diffs API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'baseVersion', 'targetVersion'] + resource_path = "/repositories/{repositoryId}/diffs" + method = "GET" + operation_name = "list_commit_diffs" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListCommitDiffs" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "target_repository_id", + "is_comparison_from_merge_base", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_commit_diffs got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "baseVersion": base_version, + "targetVersion": target_version, + "targetRepositoryId": kwargs.get("target_repository_id", missing), + "isComparisonFromMergeBase": kwargs.get("is_comparison_from_merge_base", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="DiffCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="DiffCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_commits(self, repository_id, **kwargs): + """ + Returns a list of commits. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_name: (optional) + A filter to return only resources that match the given reference name. + + :param str exclude_ref_name: (optional) + A filter to exclude commits that match the given reference name. + + :param str file_path: (optional) + A filter to return only commits that affect any of the specified paths. + + :param datetime timestamp_greater_than_or_equal_to: (optional) + A filter to return commits only created after the specified timestamp value. + + :param datetime timestamp_less_than_or_equal_to: (optional) + A filter to return commits only created before the specified timestamp value. + + :param str commit_message: (optional) + A filter to return any commits that contains the given message. + + :param str author_name: (optional) + A filter to return any commits that are pushed by the requested author. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCommitCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_commits API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/commits" + method = "GET" + operation_name = "list_commits" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryCommit/ListCommits" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "ref_name", + "exclude_ref_name", + "file_path", + "timestamp_greater_than_or_equal_to", + "timestamp_less_than_or_equal_to", + "commit_message", + "author_name", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_commits got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "refName": kwargs.get("ref_name", missing), + "excludeRefName": kwargs.get("exclude_ref_name", missing), + "filePath": kwargs.get("file_path", missing), + "timestampGreaterThanOrEqualTo": kwargs.get("timestamp_greater_than_or_equal_to", missing), + "timestampLessThanOrEqualTo": kwargs.get("timestamp_less_than_or_equal_to", missing), + "commitMessage": kwargs.get("commit_message", missing), + "authorName": kwargs.get("author_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryCommitCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryCommitCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_connections(self, **kwargs): + """ + Returns a list of connections. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str project_id: (optional) + unique project identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return only connections that matches the given lifecycle state. + + Allowed values are: "ACTIVE", "DELETING" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param str connection_type: (optional) + A filter to return only resources that match the given connection type. + + Allowed values are: "GITHUB_ACCESS_TOKEN", "GITLAB_ACCESS_TOKEN", "GITLAB_SERVER_ACCESS_TOKEN", "BITBUCKET_SERVER_ACCESS_TOKEN", "BITBUCKET_CLOUD_APP_PASSWORD", "VBS_ACCESS_TOKEN" + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ConnectionCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_connections API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/connections" + method = "GET" + operation_name = "list_connections" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ConnectionCollection/ListConnections" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "project_id", + "compartment_id", + "lifecycle_state", + "display_name", + "connection_type", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_connections got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["ACTIVE", "DELETING"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'connection_type' in kwargs: + connection_type_allowed_values = ["GITHUB_ACCESS_TOKEN", "GITLAB_ACCESS_TOKEN", "GITLAB_SERVER_ACCESS_TOKEN", "BITBUCKET_SERVER_ACCESS_TOKEN", "BITBUCKET_CLOUD_APP_PASSWORD", "VBS_ACCESS_TOKEN"] + if kwargs['connection_type'] not in connection_type_allowed_values: + raise ValueError( + f"Invalid value for `connection_type`, must be one of { connection_type_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "projectId": kwargs.get("project_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "connectionType": kwargs.get("connection_type", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="ConnectionCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="ConnectionCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_deploy_artifacts(self, **kwargs): + """ + Returns a list of deployment artifacts. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str project_id: (optional) + unique project identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return only DeployArtifacts that matches the given lifecycleState. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployArtifactCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_deploy_artifacts API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/deployArtifacts" + method = "GET" + operation_name = "list_deploy_artifacts" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifactSummary/ListDeployArtifacts" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "project_id", + "compartment_id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_deploy_artifacts got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "projectId": kwargs.get("project_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployArtifactCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployArtifactCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_deploy_environments(self, **kwargs): + """ + Returns a list of deployment environments. + + + :param str project_id: (optional) + unique project identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str lifecycle_state: (optional) + A filter to return only DeployEnvironments that matches the given lifecycleState. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployEnvironmentCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_deploy_environments API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/deployEnvironments" + method = "GET" + operation_name = "list_deploy_environments" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironmentSummary/ListDeployEnvironments" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "project_id", + "compartment_id", + "id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_deploy_environments got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "projectId": kwargs.get("project_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "id": kwargs.get("id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployEnvironmentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployEnvironmentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_deploy_pipelines(self, **kwargs): + """ + Returns a list of deployment pipelines. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str project_id: (optional) + unique project identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return only DeployPipelines that matches the given lifecycleState. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployPipelineCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_deploy_pipelines API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/deployPipelines" + method = "GET" + operation_name = "list_deploy_pipelines" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipelineSummary/ListDeployPipelines" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "project_id", + "compartment_id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_deploy_pipelines got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "projectId": kwargs.get("project_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployPipelineCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployPipelineCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_deploy_stages(self, **kwargs): + """ + Retrieves a list of deployment stages. + + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str deploy_pipeline_id: (optional) + The ID of the parent pipeline. + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return only deployment stages that matches the given lifecycle state. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployStageCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_deploy_stages API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/deployStages" + method = "GET" + operation_name = "list_deploy_stages" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStageSummary/ListDeployStages" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "deploy_pipeline_id", + "compartment_id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_deploy_stages got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "deployPipelineId": kwargs.get("deploy_pipeline_id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployStageCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeployStageCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_deployments(self, **kwargs): + """ + Returns a list of deployments. + + + :param str deploy_pipeline_id: (optional) + The ID of the parent pipeline. + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str project_id: (optional) + unique project identifier + + :param str lifecycle_state: (optional) + A filter to return only Deployments that matches the given lifecycleState. + + Allowed values are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param datetime time_created_less_than: (optional) + Search for DevOps resources that were created before a specific date. Specifying this parameter corresponding to `timeCreatedLessThan` parameter will retrieve all assessments created before the specified created date, in \"YYYY-MM-ddThh:mmZ\" format with a Z offset, as defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param datetime time_created_greater_than_or_equal_to: (optional) + Search for DevOps resources that were created after a specific date. Specifying this parameter corresponding to `timeCreatedGreaterThanOrEqualTo` parameter will retrieve all security assessments created after the specified created date, in \"YYYY-MM-ddThh:mmZ\" format with a Z offset, as defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeploymentCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_deployments API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/deployments" + method = "GET" + operation_name = "list_deployments" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeploymentSummary/ListDeployments" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "deploy_pipeline_id", + "id", + "compartment_id", + "project_id", + "lifecycle_state", + "display_name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id", + "time_created_less_than", + "time_created_greater_than_or_equal_to" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_deployments got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "deployPipelineId": kwargs.get("deploy_pipeline_id", missing), + "id": kwargs.get("id", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "projectId": kwargs.get("project_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing), + "timeCreatedLessThan": kwargs.get("time_created_less_than", missing), + "timeCreatedGreaterThanOrEqualTo": kwargs.get("time_created_greater_than_or_equal_to", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeploymentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="DeploymentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_fork_sync_statuses(self, repository_id, branch_name_query_param, **kwargs): + """ + LIST operation that returns a collection of fork sync status objects. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str branch_name_query_param: (required) + Specifies the branch for which the fork sync status will be checked. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ForkSyncStatusCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_fork_sync_statuses API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'branchNameQueryParam'] + resource_path = "/repositories/{repositoryId}/forkSyncStatuses" + method = "GET" + operation_name = "list_fork_sync_statuses" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListForkSyncStatuses" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_fork_sync_statuses got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "branchNameQueryParam": branch_name_query_param + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="ForkSyncStatusCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="ForkSyncStatusCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_mirror_records(self, repository_id, **kwargs): + """ + Returns a list of mirror entry in history within 30 days. + + + :param str repository_id: (required) + Unique repository identifier. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryMirrorRecordCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_mirror_records API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/mirrorRecords" + method = "GET" + operation_name = "list_mirror_records" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListMirrorRecords" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "limit", + "page", + "sort_order", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_mirror_records got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + query_params = { + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryMirrorRecordCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryMirrorRecordCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_paths(self, repository_id, **kwargs): + """ + Retrieves a list of files and directories in a repository. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref: (optional) + The name of branch/tag or commit hash it points to. If names conflict, order of preference is commit > branch > tag. + You can disambiguate with \"heads/foobar\" and \"tags/foobar\". If left blank repository's default branch will be used. + + :param bool paths_in_subtree: (optional) + Flag to determine if files must be retrived recursively. Flag is False by default. + + :param str folder_path: (optional) + The fully qualified path to the folder whose contents are returned, including the folder name. For example, /examples is a fully-qualified path to a folder named examples that was created off of the root directory (/) of a repository. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order is ascending. If no value is specified name is default. + + Allowed values are: "type", "sizeInBytes", "name" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryPathCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_paths API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/paths" + method = "GET" + operation_name = "list_paths" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryPathSummary/ListPaths" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "ref", + "paths_in_subtree", + "folder_path", + "limit", + "page", + "display_name", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_paths got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["type", "sizeInBytes", "name"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "ref": kwargs.get("ref", missing), + "pathsInSubtree": kwargs.get("paths_in_subtree", missing), + "folderPath": kwargs.get("folder_path", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "displayName": kwargs.get("display_name", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryPathCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryPathCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_project_commit_analytics_authors(self, project_id, **kwargs): + """ + Retrieve a list of all the Commit Analytics authors. + + + :param str project_id: (required) + Unique project identifier. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param str sort_by: (optional) + The field to sort by. Only one sort by value is supported for this parameter. Default order for author name is ascending. + + Allowed values are: "authorName" + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.CommitAnalyticsAuthorCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_project_commit_analytics_authors API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}/commitAnalyticsAuthors" + method = "GET" + operation_name = "list_project_commit_analytics_authors" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListProjectCommitAnalyticsAuthors" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "limit", + "page", + "sort_order", + "opc_request_id", + "sort_by" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_project_commit_analytics_authors got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "projectId": project_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["authorName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="CommitAnalyticsAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="CommitAnalyticsAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_projects(self, compartment_id, **kwargs): + """ + Returns a list of projects. + + + :param str compartment_id: (required) + The OCID of the compartment in which to list resources. + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str lifecycle_state: (optional) + A filter to return only Projects that matches the given lifecycleState. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION" + + :param str name: (optional) + A filter to return only resources that match the entire name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProjectCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_projects API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['compartmentId'] + resource_path = "/projects" + method = "GET" + operation_name = "list_projects" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectSummary/ListProjects" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "id", + "lifecycle_state", + "name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_projects got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "id": kwargs.get("id", missing), + "compartmentId": compartment_id, + "lifecycleState": kwargs.get("lifecycle_state", missing), + "name": kwargs.get("name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="ProjectCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="ProjectCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_protected_branches(self, repository_id, **kwargs): + """ + Returns a list of Protected Branches. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str name: (optional) + A filter to return only resources that match the given branch name. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for branch name is ascending. If no value is specified branch name is default. + + Allowed values are: "branchName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProtectedBranchCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_protected_branches API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/protectedBranches" + method = "GET" + operation_name = "list_protected_branches" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProtectedBranchCollection/ListProtectedBranches" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_protected_branches got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["branchName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "name": kwargs.get("name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="ProtectedBranchCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="ProtectedBranchCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_request_activities(self, pull_request_id, **kwargs): + """ + List actions that have been taken on a pull request + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str activity_type: (optional) + An optional filter to list activities based on activity type. If no value is specified, all activity types will returned. + + Allowed values are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT" + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestActivityCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_request_activities API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/activities" + method = "GET" + operation_name = "list_pull_request_activities" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ListPullRequestActivities" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "activity_type", + "sort_order", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_request_activities got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'activity_type' in kwargs: + activity_type_allowed_values = ["LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT"] + if kwargs['activity_type'] not in activity_type_allowed_values: + raise ValueError( + f"Invalid value for `activity_type`, must be one of { activity_type_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + query_params = { + "activityType": kwargs.get("activity_type", missing), + "sortOrder": kwargs.get("sort_order", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestActivityCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestActivityCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_request_attachments(self, pull_request_id, **kwargs): + """ + List PullRequest level attachments by identifier + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order is ascending. If no value is specified timeCreated is default. + + Allowed values are: "fileName", "timeCreated", "createdBy" + + :param str file_name: (optional) + A filter to return only resources that match the entire file name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestAttachmentCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_request_attachments API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/attachments" + method = "GET" + operation_name = "list_pull_request_attachments" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ListPullRequestAttachments" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "sort_order", + "sort_by", + "file_name", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_request_attachments got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["fileName", "timeCreated", "createdBy"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": kwargs.get("compartment_id", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing), + "fileName": kwargs.get("file_name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestAttachmentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestAttachmentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_request_authors(self, repository_id, **kwargs): + """ + Retrieve a list of all the PR authors. + + + :param str repository_id: (required) + Unique repository identifier. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestAuthorCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_request_authors API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/pullRequestAuthors" + method = "GET" + operation_name = "list_pull_request_authors" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListPullRequestAuthors" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "limit", + "page", + "sort_order", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_request_authors got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + query_params = { + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_request_comments(self, pull_request_id, **kwargs): + """ + List PullRequest level comments by identifier + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order is ascending. If no value is specified timeCreated is default. + + Allowed values are: "timeCreated", "createdBy" + + :param str comment_id: (optional) + unique PullRequest Comment identifier + + :param str commit_id: (optional) + PullRequest Comment Commit SHA + + :param str file_path: (optional) + PullRequest File Path + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestCommentCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_request_comments API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/comments" + method = "GET" + operation_name = "list_pull_request_comments" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ListPullRequestComments" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "sort_order", + "sort_by", + "comment_id", + "commit_id", + "file_path", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_request_comments got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "createdBy"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": kwargs.get("compartment_id", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing), + "commentId": kwargs.get("comment_id", missing), + "commitId": kwargs.get("commit_id", missing), + "filePath": kwargs.get("file_path", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestCommentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestCommentCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_request_commits(self, pull_request_id, **kwargs): + """ + List pull request commits + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCommitCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_request_commits API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/commits" + method = "GET" + operation_name = "list_pull_request_commits" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ListPullRequestCommits" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_request_commits got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryCommitCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryCommitCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_request_file_changes(self, pull_request_id, **kwargs): + """ + List pull request file changes + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str file_path: (optional) + PullRequest File Path + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestFileChangeCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_request_file_changes API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/fileChanges" + method = "GET" + operation_name = "list_pull_request_file_changes" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ListPullRequestFileChanges" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "file_path", + "limit", + "page", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_request_file_changes got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + query_params = { + "filePath": kwargs.get("file_path", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestFileChangeCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="PullRequestFileChangeCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_pull_requests(self, **kwargs): + """ + Returns a list of PullRequests. + + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str lifecycle_state: (optional) + A filter to return only pull requests that match the given lifecycle state. + + Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" + + :param str lifecycle_details: (optional) + A filter to return only pull requests that match the given lifecycle state. + + Allowed values are: "OPEN", "CONFLICT", "CLOSED", "MERGING", "MERGED" + + :param str repository_id: (optional) + The OCID of the repository in which to list resources. + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param str id: (optional) + Unique identifier or OCID for listing a single resource by ID. + + :param str created_by: (optional) + PullRequest Created By + + :param str destination_branch: (optional) + PullRequest Target Branch + + :param str source_branch: (optional) + PullRequest Source Branch. + + :param str reviewer_principal_id: (optional) + PullRequest Reviewer Id + + :param str source_repository_id: (optional) + PullRequest Source Repository Id + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_pull_requests API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/pullRequests" + method = "GET" + operation_name = "list_pull_requests" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequestCollection/ListPullRequests" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "lifecycle_state", + "lifecycle_details", + "repository_id", + "display_name", + "id", + "created_by", + "destination_branch", + "source_branch", + "reviewer_principal_id", + "source_repository_id", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_pull_requests got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'lifecycle_details' in kwargs: + lifecycle_details_allowed_values = ["OPEN", "CONFLICT", "CLOSED", "MERGING", "MERGED"] + if kwargs['lifecycle_details'] not in lifecycle_details_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_details`, must be one of { lifecycle_details_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": kwargs.get("compartment_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "lifecycleDetails": kwargs.get("lifecycle_details", missing), + "repositoryId": kwargs.get("repository_id", missing), + "displayName": kwargs.get("display_name", missing), + "id": kwargs.get("id", missing), + "createdBy": kwargs.get("created_by", missing), + "destinationBranch": kwargs.get("destination_branch", missing), + "sourceBranch": kwargs.get("source_branch", missing), + "reviewerPrincipalId": kwargs.get("reviewer_principal_id", missing), + "sourceRepositoryId": kwargs.get("source_repository_id", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="PullRequestCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="PullRequestCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_refs(self, repository_id, **kwargs): + """ + Returns a list of references. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_type: (optional) + Reference type to distinguish between branch and tag. If it is not specified, all references are returned. + + Allowed values are: "BRANCH", "TAG" + + :param str commit_id: (optional) + Commit ID in a repository. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str ref_name: (optional) + A filter to return only resources that match the given reference name. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for reference name is ascending. Default order for reference type is ascending. If no value is specified reference name is default. + + Allowed values are: "refType", "refName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRefCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_refs API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/refs" + method = "GET" + operation_name = "list_refs" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryRef/ListRefs" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "ref_type", + "commit_id", + "limit", + "page", + "ref_name", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_refs got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'ref_type' in kwargs: + ref_type_allowed_values = ["BRANCH", "TAG"] + if kwargs['ref_type'] not in ref_type_allowed_values: + raise ValueError( + f"Invalid value for `ref_type`, must be one of { ref_type_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["refType", "refName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "refType": kwargs.get("ref_type", missing), + "commitId": kwargs.get("commit_id", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "refName": kwargs.get("ref_name", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryRefCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="RepositoryRefCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_repositories(self, **kwargs): + """ + Returns a list of repositories given a compartment ID or a project ID. + + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str project_id: (optional) + unique project identifier + + :param str repository_id: (optional) + Unique repository identifier. + + :param str lifecycle_state: (optional) + A filter to return only resources whose lifecycle state matches the given lifecycle state. + + Allowed values are: "ACTIVE", "CREATING", "DELETED", "FAILED", "DELETING" + + :param str name: (optional) + A filter to return only resources that match the entire name given. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for name is ascending. If no value is specified time created is default. + + Allowed values are: "timeCreated", "name" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_repositories API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/repositories" + method = "GET" + operation_name = "list_repositories" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListRepositories" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "project_id", + "repository_id", + "lifecycle_state", + "name", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_repositories got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["ACTIVE", "CREATING", "DELETED", "FAILED", "DELETING"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "name"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": kwargs.get("compartment_id", missing), + "projectId": kwargs.get("project_id", missing), + "repositoryId": kwargs.get("repository_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "name": kwargs.get("name", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="RepositoryCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="RepositoryCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_repository_commit_analytics_authors(self, repository_id, **kwargs): + """ + Retrieve a list of all the Commit Analytics authors. + + + :param str repository_id: (required) + Unique repository identifier. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param str sort_by: (optional) + The field to sort by. Only one sort by value is supported for this parameter. Default order for author name is ascending. + + Allowed values are: "authorName" + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.CommitAnalyticsAuthorCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_repository_commit_analytics_authors API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/commitAnalyticsAuthors" + method = "GET" + operation_name = "list_repository_commit_analytics_authors" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListRepositoryCommitAnalyticsAuthors" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "limit", + "page", + "sort_order", + "opc_request_id", + "sort_by" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_repository_commit_analytics_authors got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["authorName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="CommitAnalyticsAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="CommitAnalyticsAuthorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_triggers(self, **kwargs): + """ + Returns a list of triggers. + + + :param str compartment_id: (optional) + The OCID of the compartment in which to list resources. + + :param str project_id: (optional) + unique project identifier + + :param str lifecycle_state: (optional) + A filter to return only triggers that matches the given lifecycle state. + + Allowed values are: "ACTIVE", "DELETING" + + :param str display_name: (optional) + A filter to return only resources that match the entire display name given. + + :param str id: (optional) + Unique trigger identifier. + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + + Allowed values are: "timeCreated", "displayName" + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.TriggerCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_triggers API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/triggers" + method = "GET" + operation_name = "list_triggers" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/TriggerCollection/ListTriggers" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "project_id", + "lifecycle_state", + "display_name", + "id", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_triggers got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["ACTIVE", "DELETING"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeCreated", "displayName"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": kwargs.get("compartment_id", missing), + "projectId": kwargs.get("project_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "displayName": kwargs.get("display_name", missing), + "id": kwargs.get("id", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="TriggerCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="TriggerCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_work_request_errors(self, work_request_id, **kwargs): + """ + Returns a list of errors for a given work request. + + + :param str work_request_id: (required) + The ID of the asynchronous work request. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param int limit: (optional) + The maximum number of items to return. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order can be provided. Default sort order is descending and is based on the timeAccepted field. + + Allowed values are: "timeAccepted" + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequestErrorCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_work_request_errors API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['workRequestId'] + resource_path = "/workRequests/{workRequestId}/errors" + method = "GET" + operation_name = "list_work_request_errors" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequestError/ListWorkRequestErrors" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "page", + "limit", + "sort_order", + "sort_by" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_work_request_errors got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "workRequestId": work_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeAccepted"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "page": kwargs.get("page", missing), + "limit": kwargs.get("limit", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="WorkRequestErrorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="WorkRequestErrorCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_work_request_logs(self, work_request_id, **kwargs): + """ + Returns a list of logs for a given work request. + + + :param str work_request_id: (required) + The ID of the asynchronous work request. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param int limit: (optional) + The maximum number of items to return. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order can be provided. Default sort order is descending and is based on the timeAccepted field. + + Allowed values are: "timeAccepted" + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequestLogEntryCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_work_request_logs API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['workRequestId'] + resource_path = "/workRequests/{workRequestId}/logs" + method = "GET" + operation_name = "list_work_request_logs" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequestLogEntry/ListWorkRequestLogs" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "page", + "limit", + "sort_order", + "sort_by" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_work_request_logs got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "workRequestId": work_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeAccepted"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "page": kwargs.get("page", missing), + "limit": kwargs.get("limit", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="WorkRequestLogEntryCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + query_params=query_params, + header_params=header_params, + response_type="WorkRequestLogEntryCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_work_requests(self, compartment_id, **kwargs): + """ + Lists the work requests in a compartment. + + + :param str compartment_id: (required) + The OCID of the compartment in which to list resources. + + :param str work_request_id: (optional) + The ID of the asynchronous work request. + + :param str status: (optional) + A filter to return only resources where the lifecycle state matches the given operation status. + + Allowed values are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "WAITING", "NEEDS_ATTENTION" + + :param str resource_id: (optional) + The ID of the resource affected by the work request. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + + :param int limit: (optional) + The maximum number of items to return. + + :param str sort_order: (optional) + The sort order to use. Use either ascending or descending. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort by. Only one sort order can be provided. Default sort order is descending and is based on the timeAccepted field. + + Allowed values are: "timeAccepted" + + :param list[str] operation_type_multi_value_query: (optional) + A filter to return only resources where their Operation Types matches the parameter operation types + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequestCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_work_requests API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['compartmentId'] + resource_path = "/workRequests" + method = "GET" + operation_name = "list_work_requests" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequest/ListWorkRequests" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "work_request_id", + "status", + "resource_id", + "opc_request_id", + "page", + "limit", + "sort_order", + "sort_by", + "operation_type_multi_value_query" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_work_requests got unknown kwargs: {extra_kwargs!r}") + + if 'status' in kwargs: + status_allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "WAITING", "NEEDS_ATTENTION"] + if kwargs['status'] not in status_allowed_values: + raise ValueError( + f"Invalid value for `status`, must be one of { status_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["timeAccepted"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": compartment_id, + "workRequestId": kwargs.get("work_request_id", missing), + "status": kwargs.get("status", missing), + "resourceId": kwargs.get("resource_id", missing), + "page": kwargs.get("page", missing), + "limit": kwargs.get("limit", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing), + "operationTypeMultiValueQuery": self.base_client.generate_collection_format_param(kwargs.get("operation_type_multi_value_query", missing), 'multi') + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="WorkRequestCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="WorkRequestCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def merge_pull_request(self, pull_request_id, merge_pull_request_details, **kwargs): + """ + Merge the PullRequest + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param oci.devops.models.MergePullRequestDetails merge_pull_request_details: (required) + The details about the merge operation. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use merge_pull_request API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/actions/merge" + method = "POST" + operation_name = "merge_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/MergePullRequest" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_request_id", + "opc_retry_token" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"merge_pull_request got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=merge_pull_request_details, + response_type="PullRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=merge_pull_request_details, + response_type="PullRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def mirror_repository(self, repository_id, **kwargs): + """ + Synchronize a mirrored repository to the latest version from external providers. + + + :param str repository_id: (required) + Unique repository identifier. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use mirror_repository API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}/actions/mirror" + method = "POST" + operation_name = "mirror_repository" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/MirrorRepository" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"mirror_repository got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def patch_pull_request(self, pull_request_id, patch_pull_request_details, **kwargs): + """ + Updates the reviewer list of a pull request + + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param oci.devops.models.PatchPullRequestDetails patch_pull_request_details: (required) + Details for the PullRequest update. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use patch_pull_request API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}" + method = "PATCH" + operation_name = "patch_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/PatchPullRequest" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"patch_pull_request got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "pullRequestId": pull_request_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=patch_pull_request_details, + response_type="PullRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=patch_pull_request_details, + response_type="PullRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details, **kwargs): + """ + Creates a new reference or updates an existing one. This API will be deprecated on Wed, 12 June 2024 01:00:00 GMT as it does not get recognized when refName has '/'. This will be replaced by \"/repositories/{repositoryId}/actions/createOrUpdateGitRef\". + + + :param str repository_id: (required) + Unique repository identifier. + + :param str ref_name: (required) + A filter to return only resources that match the given reference name. + + :param oci.devops.models.PutRepositoryRefDetails put_repository_ref_details: (required) + The information to create a reference with the type specified in the query. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. + + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRef` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use put_repository_ref API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['repositoryId', 'refName'] + resource_path = "/repositories/{repositoryId}/refs/{refName}" + method = "PUT" + operation_name = "put_repository_ref" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/PutRepositoryRef" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_retry_token", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"put_repository_ref got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "repositoryId": repository_id, + "refName": ref_name + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=put_repository_ref_details, + response_type="RepositoryRef", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=put_repository_ref_details, + response_type="RepositoryRef", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + def reopen_pull_request(self, pull_request_id, **kwargs): + """ + Reopen a PullRequest - Allowed values are: "ASC", "DESC" - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param str pull_request_id: (required) + unique PullRequest identifier - Allowed values are: "timeCreated", "displayName" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -6930,76 +13488,45 @@ def list_deploy_pipelines(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployPipelineCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_deploy_pipelines API. + Click `here `__ to see an example of how to use reopen_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/deployPipelines" - method = "GET" - operation_name = "list_deploy_pipelines" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipelineSummary/ListDeployPipelines" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/actions/reopen" + method = "POST" + operation_name = "reopen_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ReopenPullRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "project_id", - "compartment_id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_deploy_pipelines got unknown kwargs: {extra_kwargs!r}") - - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "INACTIVE", "DELETING", "DELETED", "FAILED"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + f"reopen_pull_request got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "pullRequestId": pull_request_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "id": kwargs.get("id", missing), - "projectId": kwargs.get("project_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -7019,9 +13546,9 @@ def list_deploy_pipelines(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployPipelineCollection", + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7030,51 +13557,30 @@ def list_deploy_pipelines(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployPipelineCollection", + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_deploy_stages(self, **kwargs): + def review_pull_request(self, pull_request_id, review_pull_request_details, **kwargs): """ - Retrieves a list of deployment stages. - - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str deploy_pipeline_id: (optional) - The ID of the parent pipeline. - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str lifecycle_state: (optional) - A filter to return only deployment stages that matches the given lifecycle state. - - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. + Review a PullRequest - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + :param str pull_request_id: (required) + unique PullRequest identifier - Allowed values are: "ASC", "DESC" + :param oci.devops.models.ReviewPullRequestDetails review_pull_request_details: (required) + Details to submit a review. - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - Allowed values are: "timeCreated", "displayName" + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -7091,76 +13597,47 @@ def list_deploy_stages(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployStageCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_deploy_stages API. + Click `here `__ to see an example of how to use review_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/deployStages" - method = "GET" - operation_name = "list_deploy_stages" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStageSummary/ListDeployStages" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}/actions/review" + method = "POST" + operation_name = "review_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/ReviewPullRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "deploy_pipeline_id", - "compartment_id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", + "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_deploy_stages got unknown kwargs: {extra_kwargs!r}") - - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + f"review_pull_request got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "pullRequestId": pull_request_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "id": kwargs.get("id", missing), - "deployPipelineId": kwargs.get("deploy_pipeline_id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -7174,15 +13651,17 @@ def list_deploy_stages(self, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployStageCollection", + body=review_pull_request_details, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7191,67 +13670,31 @@ def list_deploy_stages(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeployStageCollection", + body=review_pull_request_details, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_deployments(self, **kwargs): + def schedule_cascading_project_deletion(self, project_id, **kwargs): """ - Returns a list of deployments. - - - :param str deploy_pipeline_id: (optional) - The ID of the parent pipeline. - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str project_id: (optional) - unique project identifier - - :param str lifecycle_state: (optional) - A filter to return only Deployments that matches the given lifecycleState. - - Allowed values are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + Cascading operation that marks Project and child DevOps resources in a DELETING state for a retention period - Allowed values are: "ASC", "DESC" - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param str project_id: (required) + Unique project identifier. - Allowed values are: "timeCreated", "displayName" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - :param datetime time_created_less_than: (optional) - Search for DevOps resources that were created before a specific date. Specifying this parameter corresponding to `timeCreatedLessThan` parameter will retrieve all assessments created before the specified created date, in \"YYYY-MM-ddThh:mmZ\" format with a Z offset, as defined by `RFC3339`__. - - __ https://datatracker.ietf.org/doc/html/rfc3339 - - :param datetime time_created_greater_than_or_equal_to: (optional) - Search for DevOps resources that were created after a specific date. Specifying this parameter corresponding to `timeCreatedGreaterThanOrEqualTo` parameter will retrieve all security assessments created after the specified created date, in \"YYYY-MM-ddThh:mmZ\" format with a Z offset, as defined by `RFC3339`__. - - __ https://datatracker.ietf.org/doc/html/rfc3339 + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -7265,83 +13708,48 @@ def list_deployments(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeploymentCollection` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_deployments API. + Click `here `__ to see an example of how to use schedule_cascading_project_deletion API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/deployments" - method = "GET" - operation_name = "list_deployments" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeploymentSummary/ListDeployments" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}/actions/scheduleCascadingProjectDeletion" + method = "POST" + operation_name = "schedule_cascading_project_deletion" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/ScheduleCascadingProjectDeletion" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "deploy_pipeline_id", - "id", - "compartment_id", - "project_id", - "lifecycle_state", - "display_name", - "limit", - "page", - "sort_order", - "sort_by", + "if_match", "opc_request_id", - "time_created_less_than", - "time_created_greater_than_or_equal_to" + "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_deployments got unknown kwargs: {extra_kwargs!r}") - - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + f"schedule_cascading_project_deletion got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "projectId": project_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "deployPipelineId": kwargs.get("deploy_pipeline_id", missing), - "id": kwargs.get("id", missing), - "compartmentId": kwargs.get("compartment_id", missing), - "projectId": kwargs.get("project_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing), - "timeCreatedLessThan": kwargs.get("time_created_less_than", missing), - "timeCreatedGreaterThanOrEqualTo": kwargs.get("time_created_greater_than_or_equal_to", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", - "opc-request-id": kwargs.get("opc_request_id", missing) + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -7354,15 +13762,15 @@ def list_deployments(self, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeploymentCollection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7371,21 +13779,23 @@ def list_deployments(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="DeploymentCollection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_mirror_records(self, repository_id, **kwargs): + def summarize_project_repository_analytics(self, project_id, summarize_project_repository_analytics_details, **kwargs): """ - Returns a list of mirror entry in history within 30 days. + Retrieves repository analytics for a given project. - :param str repository_id: (required) - Unique repository identifier. + :param str project_id: (required) + Unique project identifier. + + :param oci.devops.models.SummarizeProjectRepositoryAnalyticsDetails summarize_project_repository_analytics_details: (required) + Details to fetch the repository analytics. :param int limit: (optional) The maximum number of items to return. @@ -7393,11 +13803,6 @@ def list_mirror_records(self, repository_id, **kwargs): :param str page: (optional) The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - - Allowed values are: "ASC", "DESC" - :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -7413,18 +13818,18 @@ def list_mirror_records(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryMirrorRecordCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryMetricAggregation` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_mirror_records API. + Click `here `__ to see an example of how to use summarize_project_repository_analytics API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/mirrorRecords" - method = "GET" - operation_name = "list_mirror_records" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListMirrorRecords" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}/repositoryAnalytics" + method = "POST" + operation_name = "summarize_project_repository_analytics" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryMetricAggregation/SummarizeProjectRepositoryAnalytics" # Don't accept unknown kwargs expected_kwargs = [ @@ -7432,16 +13837,15 @@ def list_mirror_records(self, repository_id, **kwargs): "retry_strategy", "limit", "page", - "sort_order", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_mirror_records got unknown kwargs: {extra_kwargs!r}") + f"summarize_project_repository_analytics got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "projectId": project_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -7450,17 +13854,9 @@ def list_mirror_records(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) - query_params = { "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing) + "page": kwargs.get("page", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -7489,7 +13885,8 @@ def list_mirror_records(self, repository_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryMirrorRecordCollection", + body=summarize_project_repository_analytics_details, + response_type="RepositoryMetricAggregation", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7501,29 +13898,23 @@ def list_mirror_records(self, repository_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryMirrorRecordCollection", + body=summarize_project_repository_analytics_details, + response_type="RepositoryMetricAggregation", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_paths(self, repository_id, **kwargs): + def summarize_repository_analytics(self, repository_id, summarize_repository_analytics_details, **kwargs): """ - Retrieves a list of files and directories in a repository. + Retrieves repository analytics for a given repository. :param str repository_id: (required) Unique repository identifier. - :param str ref: (optional) - The name of branch/tag or commit hash it points to. If names conflict, order of preference is commit > branch > tag. - You can disambiguate with \"heads/foobar\" and \"tags/foobar\". If left blank repository's default branch will be used. - - :param bool paths_in_subtree: (optional) - Flag to determine if files must be retrived recursively. Flag is False by default. - - :param str folder_path: (optional) - The fully qualified path to the folder whose contents are returned, including the folder name. For example, /examples is a fully-qualified path to a folder named examples that was created off of the root directory (/) of a repository. + :param oci.devops.models.SummarizeRepositoryAnalyticsDetails summarize_repository_analytics_details: (required) + Details to fetch the repository analytics. :param int limit: (optional) The maximum number of items to return. @@ -7531,19 +13922,6 @@ def list_paths(self, repository_id, **kwargs): :param str page: (optional) The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - - Allowed values are: "ASC", "DESC" - - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order is ascending. If no value is specified name is default. - - Allowed values are: "type", "sizeInBytes", "name" - :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -7559,37 +13937,31 @@ def list_paths(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryPathCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryMetricAggregation` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_paths API. + Click `here `__ to see an example of how to use summarize_repository_analytics API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/paths" - method = "GET" - operation_name = "list_paths" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryPathSummary/ListPaths" + resource_path = "/repository/{repositoryId}/repositoryAnalytics" + method = "POST" + operation_name = "summarize_repository_analytics" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryMetricAggregation/SummarizeRepositoryAnalytics" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "ref", - "paths_in_subtree", - "folder_path", "limit", "page", - "display_name", - "sort_order", - "sort_by", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_paths got unknown kwargs: {extra_kwargs!r}") + f"summarize_repository_analytics got unknown kwargs: {extra_kwargs!r}") path_params = { "repositoryId": repository_id @@ -7601,29 +13973,9 @@ def list_paths(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) - - if 'sort_by' in kwargs: - sort_by_allowed_values = ["type", "sizeInBytes", "name"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) - query_params = { - "ref": kwargs.get("ref", missing), - "pathsInSubtree": kwargs.get("paths_in_subtree", missing), - "folderPath": kwargs.get("folder_path", missing), "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "displayName": kwargs.get("display_name", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + "page": kwargs.get("page", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -7652,7 +14004,8 @@ def list_paths(self, repository_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryPathCollection", + body=summarize_repository_analytics_details, + response_type="RepositoryMetricAggregation", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7664,50 +14017,39 @@ def list_paths(self, repository_id, **kwargs): path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryPathCollection", + body=summarize_repository_analytics_details, + response_type="RepositoryMetricAggregation", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_projects(self, compartment_id, **kwargs): + def sync_repository(self, repository_id, sync_merge_strategy, sync_repository_details, **kwargs): """ - Returns a list of projects. - - - :param str compartment_id: (required) - The OCID of the compartment in which to list resources. - - :param str id: (optional) - Unique identifier or OCID for listing a single resource by ID. + Synchronize a forked repository to the latest version - :param str lifecycle_state: (optional) - A filter to return only Projects that matches the given lifecycleState. - - Allowed values are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION" - - :param str name: (optional) - A filter to return only resources that match the entire name given. - - :param int limit: (optional) - The maximum number of items to return. - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + :param str repository_id: (required) + Unique repository identifier. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + :param str sync_merge_strategy: (required) + If fetch and merge is passed in, the changes from the upstream will be fetched and merged into the destination branch. + If discard is passed in, the changes in the fork will be overwritten with the changes brought in from the upstream. - Allowed values are: "ASC", "DESC" + Allowed values are: "FETCH_AND_MERGE", "DISCARD" - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param oci.devops.models.SyncRepositoryDetails sync_repository_details: (required) + Details required for syncing a repository with its upstream. - Allowed values are: "timeCreated", "displayName" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. + :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -7720,74 +14062,59 @@ def list_projects(self, compartment_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProjectCollection` + :return: A :class:`~oci.response.Response` object with data of type None :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_projects API. + Click `here `__ to see an example of how to use sync_repository API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['compartmentId'] - resource_path = "/projects" - method = "GET" - operation_name = "list_projects" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectSummary/ListProjects" + required_arguments = ['repositoryId', 'syncMergeStrategy'] + resource_path = "/repositories/{repositoryId}/actions/sync" + method = "POST" + operation_name = "sync_repository" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/SyncRepository" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "id", - "lifecycle_state", - "name", - "limit", - "page", - "sort_order", - "sort_by", - "opc_request_id" + "if_match", + "opc_request_id", + "opc_retry_token" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_projects got unknown kwargs: {extra_kwargs!r}") + f"sync_repository got unknown kwargs: {extra_kwargs!r}") - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", "NEEDS_ATTENTION"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + path_params = { + "repositoryId": repository_id + } - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - query_params = { - "id": kwargs.get("id", missing), - "compartmentId": compartment_id, - "lifecycleState": kwargs.get("lifecycle_state", missing), - "name": kwargs.get("name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + sync_merge_strategy_allowed_values = ["FETCH_AND_MERGE", "DISCARD"] + if sync_merge_strategy not in sync_merge_strategy_allowed_values: + raise ValueError( + f"Invalid value for `sync_merge_strategy`, must be one of { sync_merge_strategy_allowed_values }" + ) + + query_params = { + "syncMergeStrategy": sync_merge_strategy } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { "accept": "application/json", "content-type": "application/json", - "opc-request-id": kwargs.get("opc_request_id", missing) + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -7800,15 +14127,17 @@ def list_projects(self, compartment_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="ProjectCollection", + body=sync_repository_details, allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7817,48 +14146,28 @@ def list_projects(self, compartment_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="ProjectCollection", + body=sync_repository_details, allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_refs(self, repository_id, **kwargs): + def unlike_pull_request_comment(self, pull_request_id, comment_id, **kwargs): """ - Returns a list of references. - - - :param str repository_id: (required) - Unique repository identifier. - - :param str ref_type: (optional) - Reference type to distinguish between branch and tag. If it is not specified, all references are returned. - - Allowed values are: "BRANCH", "TAG" - - :param str commit_id: (optional) - Commit ID in a repository. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. - - :param str ref_name: (optional) - A filter to return only resources that match the given reference name. + Unlike a PullRequest comment - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str pull_request_id: (required) + unique PullRequest identifier - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for reference name is ascending. Default order for reference type is ascending. If no value is specified reference name is default. + :param str comment_id: (required) + unique PullRequest Comment identifier - Allowed values are: "refType", "refName" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -7875,39 +14184,34 @@ def list_refs(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRefCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestComment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_refs API. + Click `here `__ to see an example of how to use unlike_pull_request_comment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/refs" - method = "GET" - operation_name = "list_refs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryRef/ListRefs" + required_arguments = ['pullRequestId', 'commentId'] + resource_path = "/pullRequests/{pullRequestId}/comments/{commentId}/actions/unlike" + method = "POST" + operation_name = "unlike_pull_request_comment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/UnlikePullRequestComment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "ref_type", - "commit_id", - "limit", - "page", - "ref_name", - "sort_order", - "sort_by", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_refs got unknown kwargs: {extra_kwargs!r}") + f"unlike_pull_request_comment got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "pullRequestId": pull_request_id, + "commentId": comment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -7916,41 +14220,10 @@ def list_refs(self, repository_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'ref_type' in kwargs: - ref_type_allowed_values = ["BRANCH", "TAG"] - if kwargs['ref_type'] not in ref_type_allowed_values: - raise ValueError( - f"Invalid value for `ref_type`, must be one of { ref_type_allowed_values }" - ) - - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) - - if 'sort_by' in kwargs: - sort_by_allowed_values = ["refType", "refName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) - - query_params = { - "refType": kwargs.get("ref_type", missing), - "commitId": kwargs.get("commit_id", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "refName": kwargs.get("ref_name", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -7971,9 +14244,8 @@ def list_refs(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryRefCollection", + response_type="PullRequestComment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -7983,51 +14255,26 @@ def list_refs(self, repository_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="RepositoryRefCollection", + response_type="PullRequestComment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_repositories(self, **kwargs): + def unsubscribe_pull_request(self, pull_request_id, token, **kwargs): """ - Returns a list of repositories given a compartment ID or a project ID. - - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str project_id: (optional) - unique project identifier - - :param str repository_id: (optional) - Unique repository identifier. - - :param str lifecycle_state: (optional) - A filter to return only resources whose lifecycle state matches the given lifecycle state. - - Allowed values are: "ACTIVE", "CREATING", "DELETED", "DELETING" - - :param str name: (optional) - A filter to return only resources that match the entire name given. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + unsubscribe the PullRequest - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str pull_request_id: (required) + unique PullRequest identifier - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for name is ascending. If no value is specified time created is default. + :param str token: (required) + The unsubscription token. - Allowed values are: "timeCreated", "name" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -8044,76 +14291,50 @@ def list_repositories(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryCollection` + :return: A :class:`~oci.response.Response` object with data of type stream :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_repositories API. + Click `here `__ to see an example of how to use unsubscribe_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/repositories" + required_arguments = ['pullRequestId', 'token'] + resource_path = "/pullRequests/{pullRequestId}/actions/unsubscribe" method = "GET" - operation_name = "list_repositories" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/ListRepositories" + operation_name = "unsubscribe_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/UnsubscribePullRequest" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "compartment_id", - "project_id", - "repository_id", - "lifecycle_state", - "name", - "limit", - "page", - "sort_order", - "sort_by", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_repositories got unknown kwargs: {extra_kwargs!r}") + f"unsubscribe_pull_request got unknown kwargs: {extra_kwargs!r}") - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["ACTIVE", "CREATING", "DELETED", "DELETING"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + path_params = { + "pullRequestId": pull_request_id + } - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "name"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') query_params = { - "compartmentId": kwargs.get("compartment_id", missing), - "projectId": kwargs.get("project_id", missing), - "repositoryId": kwargs.get("repository_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "name": kwargs.get("name", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + "token": token } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} header_params = { - "accept": "application/json", + "accept": "text/html", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -8133,9 +14354,10 @@ def list_repositories(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryCollection", + response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8144,51 +14366,28 @@ def list_repositories(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, + path_params=path_params, query_params=query_params, header_params=header_params, - response_type="RepositoryCollection", + response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_triggers(self, **kwargs): + def update_build_pipeline(self, build_pipeline_id, update_build_pipeline_details, **kwargs): """ - Returns a list of triggers. - - - :param str compartment_id: (optional) - The OCID of the compartment in which to list resources. - - :param str project_id: (optional) - unique project identifier - - :param str lifecycle_state: (optional) - A filter to return only triggers that matches the given lifecycle state. - - Allowed values are: "ACTIVE", "DELETING" - - :param str display_name: (optional) - A filter to return only resources that match the entire display name given. - - :param str id: (optional) - Unique trigger identifier. - - :param int limit: (optional) - The maximum number of items to return. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Updates the build pipeline. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str build_pipeline_id: (required) + Unique build pipeline identifier. - :param str sort_by: (optional) - The field to sort by. Only one sort order may be provided. Default order for time created is descending. Default order for display name is ascending. If no value is specified, then the default time created value is considered. + :param oci.devops.models.UpdateBuildPipelineDetails update_build_pipeline_details: (required) + The information to be updated. - Allowed values are: "timeCreated", "displayName" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -8205,76 +14404,45 @@ def list_triggers(self, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.TriggerCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipeline` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_triggers API. + Click `here `__ to see an example of how to use update_build_pipeline API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = [] - resource_path = "/triggers" - method = "GET" - operation_name = "list_triggers" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/TriggerCollection/ListTriggers" + required_arguments = ['buildPipelineId'] + resource_path = "/buildPipelines/{buildPipelineId}" + method = "PUT" + operation_name = "update_build_pipeline" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipeline/UpdateBuildPipeline" # Don't accept unknown kwargs - expected_kwargs = [ - "allow_control_chars", - "retry_strategy", - "compartment_id", - "project_id", - "lifecycle_state", - "display_name", - "id", - "limit", - "page", - "sort_order", - "sort_by", + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_triggers got unknown kwargs: {extra_kwargs!r}") - - if 'lifecycle_state' in kwargs: - lifecycle_state_allowed_values = ["ACTIVE", "DELETING"] - if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: - raise ValueError( - f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" - ) + f"update_build_pipeline got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "buildPipelineId": build_pipeline_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "displayName"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "compartmentId": kwargs.get("compartment_id", missing), - "projectId": kwargs.get("project_id", missing), - "lifecycleState": kwargs.get("lifecycle_state", missing), - "displayName": kwargs.get("display_name", missing), - "id": kwargs.get("id", missing), - "limit": kwargs.get("limit", missing), - "page": kwargs.get("page", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -8294,9 +14462,10 @@ def list_triggers(self, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="TriggerCollection", + body=update_build_pipeline_details, + response_type="BuildPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8305,40 +14474,31 @@ def list_triggers(self, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="TriggerCollection", + body=update_build_pipeline_details, + response_type="BuildPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_work_request_errors(self, work_request_id, **kwargs): + def update_build_pipeline_stage(self, build_pipeline_stage_id, update_build_pipeline_stage_details, **kwargs): """ - Returns a list of errors for a given work request. - - - :param str work_request_id: (required) - The ID of the asynchronous work request. - - :param str opc_request_id: (optional) - Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Updates the stage based on the stage ID provided in the request. - :param int limit: (optional) - The maximum number of items to return. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + :param str build_pipeline_stage_id: (required) + Unique stage identifier. - Allowed values are: "ASC", "DESC" + :param oci.devops.models.UpdateBuildPipelineStageDetails update_build_pipeline_stage_details: (required) + The information to be updated. - :param str sort_by: (optional) - The field to sort by. Only one sort order can be provided. Default sort order is descending and is based on the timeAccepted field. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - Allowed values are: "timeAccepted" + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -8352,36 +14512,33 @@ def list_work_request_errors(self, work_request_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequestErrorCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineStage` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_work_request_errors API. + Click `here `__ to see an example of how to use update_build_pipeline_stage API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['workRequestId'] - resource_path = "/workRequests/{workRequestId}/errors" - method = "GET" - operation_name = "list_work_request_errors" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequestError/ListWorkRequestErrors" + required_arguments = ['buildPipelineStageId'] + resource_path = "/buildPipelineStages/{buildPipelineStageId}" + method = "PUT" + operation_name = "update_build_pipeline_stage" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStage/UpdateBuildPipelineStage" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "opc_request_id", - "page", - "limit", - "sort_order", - "sort_by" + "if_match", + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_work_request_errors got unknown kwargs: {extra_kwargs!r}") + f"update_build_pipeline_stage got unknown kwargs: {extra_kwargs!r}") path_params = { - "workRequestId": work_request_id + "buildPipelineStageId": build_pipeline_stage_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -8390,31 +14547,10 @@ def list_work_request_errors(self, work_request_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) - - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeAccepted"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) - - query_params = { - "page": kwargs.get("page", missing), - "limit": kwargs.get("limit", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -8435,9 +14571,9 @@ def list_work_request_errors(self, work_request_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="WorkRequestErrorCollection", + body=update_build_pipeline_stage_details, + response_type="BuildPipelineStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8447,40 +14583,30 @@ def list_work_request_errors(self, work_request_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="WorkRequestErrorCollection", + body=update_build_pipeline_stage_details, + response_type="BuildPipelineStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def list_work_request_logs(self, work_request_id, **kwargs): + def update_build_run(self, build_run_id, update_build_run_details, **kwargs): """ - Returns a list of logs for a given work request. - - - :param str work_request_id: (required) - The ID of the asynchronous work request. - - :param str opc_request_id: (optional) - Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + Updates the build run. - :param int limit: (optional) - The maximum number of items to return. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. + :param str build_run_id: (required) + Unique build run identifier. - Allowed values are: "ASC", "DESC" + :param oci.devops.models.UpdateBuildRunDetails update_build_run_details: (required) + The information to be updated. - :param str sort_by: (optional) - The field to sort by. Only one sort order can be provided. Default sort order is descending and is based on the timeAccepted field. + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - Allowed values are: "timeAccepted" + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -8494,36 +14620,33 @@ def list_work_request_logs(self, work_request_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequestLogEntryCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRun` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_work_request_logs API. + Click `here `__ to see an example of how to use update_build_run API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['workRequestId'] - resource_path = "/workRequests/{workRequestId}/logs" - method = "GET" - operation_name = "list_work_request_logs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequestLogEntry/ListWorkRequestLogs" + required_arguments = ['buildRunId'] + resource_path = "/buildRuns/{buildRunId}" + method = "PUT" + operation_name = "update_build_run" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildRun/UpdateBuildRun" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "opc_request_id", - "page", - "limit", - "sort_order", - "sort_by" + "if_match", + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_work_request_logs got unknown kwargs: {extra_kwargs!r}") + f"update_build_run got unknown kwargs: {extra_kwargs!r}") path_params = { - "workRequestId": work_request_id + "buildRunId": build_run_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -8532,31 +14655,10 @@ def list_work_request_logs(self, work_request_id, **kwargs): if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) - - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeAccepted"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) - - query_params = { - "page": kwargs.get("page", missing), - "limit": kwargs.get("limit", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} - header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -8577,9 +14679,9 @@ def list_work_request_logs(self, work_request_id, **kwargs): resource_path=resource_path, method=method, path_params=path_params, - query_params=query_params, header_params=header_params, - response_type="WorkRequestLogEntryCollection", + body=update_build_run_details, + response_type="BuildRun", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8588,55 +14690,31 @@ def list_work_request_logs(self, work_request_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - path_params=path_params, - query_params=query_params, - header_params=header_params, - response_type="WorkRequestLogEntryCollection", - allow_control_chars=kwargs.get('allow_control_chars'), - operation_name=operation_name, - api_reference_link=api_reference_link, - required_arguments=required_arguments) - - def list_work_requests(self, compartment_id, **kwargs): - """ - Lists the work requests in a compartment. - - - :param str compartment_id: (required) - The OCID of the compartment in which to list resources. - - :param str work_request_id: (optional) - The ID of the asynchronous work request. - - :param str status: (optional) - A filter to return only resources where the lifecycle state matches the given operation status. - - Allowed values are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "WAITING", "NEEDS_ATTENTION" - - :param str resource_id: (optional) - The ID of the resource affected by the work request. - - :param str opc_request_id: (optional) - Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - - :param str page: (optional) - The page token representing the page at which to start retrieving results. This is usually retrieved from a previous list call. + path_params=path_params, + header_params=header_params, + body=update_build_run_details, + response_type="BuildRun", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) - :param int limit: (optional) - The maximum number of items to return. + def update_connection(self, connection_id, update_connection_details, **kwargs): + """ + Updates the connection. - :param str sort_order: (optional) - The sort order to use. Use either ascending or descending. - Allowed values are: "ASC", "DESC" + :param str connection_id: (required) + Unique connection identifier. - :param str sort_by: (optional) - The field to sort by. Only one sort order can be provided. Default sort order is descending and is based on the timeAccepted field. + :param oci.devops.models.UpdateConnectionDetails update_connection_details: (required) + The information to be updated. - Allowed values are: "timeAccepted" + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - :param list[str] operation_type_multi_value_query: (optional) - A filter to return only resources where their Operation Types matches the parameter operation types + :param str opc_request_id: (optional) + Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -8650,75 +14728,45 @@ def list_work_requests(self, compartment_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.WorkRequestCollection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Connection` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use list_work_requests API. + Click `here `__ to see an example of how to use update_connection API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['compartmentId'] - resource_path = "/workRequests" - method = "GET" - operation_name = "list_work_requests" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/WorkRequest/ListWorkRequests" + required_arguments = ['connectionId'] + resource_path = "/connections/{connectionId}" + method = "PUT" + operation_name = "update_connection" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Connection/UpdateConnection" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", - "work_request_id", - "status", - "resource_id", - "opc_request_id", - "page", - "limit", - "sort_order", - "sort_by", - "operation_type_multi_value_query" + "if_match", + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"list_work_requests got unknown kwargs: {extra_kwargs!r}") - - if 'status' in kwargs: - status_allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED", "WAITING", "NEEDS_ATTENTION"] - if kwargs['status'] not in status_allowed_values: - raise ValueError( - f"Invalid value for `status`, must be one of { status_allowed_values }" - ) + f"update_connection got unknown kwargs: {extra_kwargs!r}") - if 'sort_order' in kwargs: - sort_order_allowed_values = ["ASC", "DESC"] - if kwargs['sort_order'] not in sort_order_allowed_values: - raise ValueError( - f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" - ) + path_params = { + "connectionId": connection_id + } - if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeAccepted"] - if kwargs['sort_by'] not in sort_by_allowed_values: - raise ValueError( - f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" - ) + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} - query_params = { - "compartmentId": compartment_id, - "workRequestId": kwargs.get("work_request_id", missing), - "status": kwargs.get("status", missing), - "resourceId": kwargs.get("resource_id", missing), - "page": kwargs.get("page", missing), - "limit": kwargs.get("limit", missing), - "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing), - "operationTypeMultiValueQuery": self.base_client.generate_collection_format_param(kwargs.get("operation_type_multi_value_query", missing), 'multi') - } - query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { "accept": "application/json", "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -8738,9 +14786,10 @@ def list_work_requests(self, compartment_id, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="WorkRequestCollection", + body=update_connection_details, + response_type="Connection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8749,21 +14798,25 @@ def list_work_requests(self, compartment_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - query_params=query_params, + path_params=path_params, header_params=header_params, - response_type="WorkRequestCollection", + body=update_connection_details, + response_type="Connection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def mirror_repository(self, repository_id, **kwargs): + def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_details, **kwargs): """ - Synchronize a mirrored repository to the latest version from external providers. + Updates the deployment artifact. - :param str repository_id: (required) - Unique repository identifier. + :param str deploy_artifact_id: (required) + Unique artifact identifier. + + :param oci.devops.models.UpdateDeployArtifactDetails update_deploy_artifact_details: (required) + The information to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -8783,18 +14836,18 @@ def mirror_repository(self, repository_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployArtifact` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use mirror_repository API. + Click `here `__ to see an example of how to use update_deploy_artifact API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}/actions/mirror" - method = "POST" - operation_name = "mirror_repository" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/MirrorRepository" + required_arguments = ['deployArtifactId'] + resource_path = "/deployArtifacts/{deployArtifactId}" + method = "PUT" + operation_name = "update_deploy_artifact" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifact/UpdateDeployArtifact" # Don't accept unknown kwargs expected_kwargs = [ @@ -8806,10 +14859,10 @@ def mirror_repository(self, repository_id, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"mirror_repository got unknown kwargs: {extra_kwargs!r}") + f"update_deploy_artifact got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id + "deployArtifactId": deploy_artifact_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -8843,6 +14896,8 @@ def mirror_repository(self, repository_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=update_deploy_artifact_details, + response_type="DeployArtifact", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8853,31 +14908,27 @@ def mirror_repository(self, repository_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=update_deploy_artifact_details, + response_type="DeployArtifact", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details, **kwargs): + def update_deploy_environment(self, deploy_environment_id, update_deploy_environment_details, **kwargs): """ - Creates a new reference or updates an existing one. This API will be deprecated on Wed, 12 June 2024 01:00:00 GMT as it does not get recognized when refName has '/'. This will be replaced by \"/repositories/{repositoryId}/actions/createOrUpdateGitRef\". - + Updates the deployment environment. - :param str repository_id: (required) - Unique repository identifier. - :param str ref_name: (required) - A filter to return only resources that match the given reference name. + :param str deploy_environment_id: (required) + Unique environment identifier. - :param oci.devops.models.PutRepositoryRefDetails put_repository_ref_details: (required) - The information to create a reference with the type specified in the query. + :param oci.devops.models.UpdateDeployEnvironmentDetails update_deploy_environment_details: (required) + The information to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. - :param str opc_retry_token: (optional) - A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. - :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -8893,35 +14944,33 @@ def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryRef` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployEnvironment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use put_repository_ref API. + Click `here `__ to see an example of how to use update_deploy_environment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['repositoryId', 'refName'] - resource_path = "/repositories/{repositoryId}/refs/{refName}" + required_arguments = ['deployEnvironmentId'] + resource_path = "/deployEnvironments/{deployEnvironmentId}" method = "PUT" - operation_name = "put_repository_ref" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/PutRepositoryRef" + operation_name = "update_deploy_environment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironment/UpdateDeployEnvironment" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", "if_match", - "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"put_repository_ref got unknown kwargs: {extra_kwargs!r}") + f"update_deploy_environment got unknown kwargs: {extra_kwargs!r}") path_params = { - "repositoryId": repository_id, - "refName": ref_name + "deployEnvironmentId": deploy_environment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -8934,7 +14983,6 @@ def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), - "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -8948,7 +14996,6 @@ def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): - self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -8957,8 +15004,8 @@ def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details method=method, path_params=path_params, header_params=header_params, - body=put_repository_ref_details, - response_type="RepositoryRef", + body=update_deploy_environment_details, + response_type="DeployEnvironment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -8969,20 +15016,23 @@ def put_repository_ref(self, repository_id, ref_name, put_repository_ref_details method=method, path_params=path_params, header_params=header_params, - body=put_repository_ref_details, - response_type="RepositoryRef", + body=update_deploy_environment_details, + response_type="DeployEnvironment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def schedule_cascading_project_deletion(self, project_id, **kwargs): + def update_deploy_pipeline(self, deploy_pipeline_id, update_deploy_pipeline_details, **kwargs): """ - Cascading operation that marks Project and child DevOps resources in a DELETING state for a retention period + Updates the deployment pipeline. - :param str project_id: (required) - Unique project identifier. + :param str deploy_pipeline_id: (required) + Unique pipeline identifier. + + :param oci.devops.models.UpdateDeployPipelineDetails update_deploy_pipeline_details: (required) + The information to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -8990,9 +15040,6 @@ def schedule_cascading_project_deletion(self, project_id, **kwargs): :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. - :param str opc_retry_token: (optional) - A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. - :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -9005,34 +15052,33 @@ def schedule_cascading_project_deletion(self, project_id, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type None + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployPipeline` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use schedule_cascading_project_deletion API. + Click `here `__ to see an example of how to use update_deploy_pipeline API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['projectId'] - resource_path = "/projects/{projectId}/actions/scheduleCascadingProjectDeletion" - method = "POST" - operation_name = "schedule_cascading_project_deletion" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/ScheduleCascadingProjectDeletion" + required_arguments = ['deployPipelineId'] + resource_path = "/deployPipelines/{deployPipelineId}" + method = "PUT" + operation_name = "update_deploy_pipeline" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipeline/UpdateDeployPipeline" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", "if_match", - "opc_request_id", - "opc_retry_token" + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"schedule_cascading_project_deletion got unknown kwargs: {extra_kwargs!r}") + f"update_deploy_pipeline got unknown kwargs: {extra_kwargs!r}") path_params = { - "projectId": project_id + "deployPipelineId": deploy_pipeline_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9045,8 +15091,7 @@ def schedule_cascading_project_deletion(self, project_id, **kwargs): "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), - "opc-request-id": kwargs.get("opc_request_id", missing), - "opc-retry-token": kwargs.get("opc_retry_token", missing) + "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -9059,7 +15104,6 @@ def schedule_cascading_project_deletion(self, project_id, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): - self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -9068,6 +15112,8 @@ def schedule_cascading_project_deletion(self, project_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=update_deploy_pipeline_details, + response_type="DeployPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9078,20 +15124,22 @@ def schedule_cascading_project_deletion(self, project_id, **kwargs): method=method, path_params=path_params, header_params=header_params, + body=update_deploy_pipeline_details, + response_type="DeployPipeline", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_build_pipeline(self, build_pipeline_id, update_build_pipeline_details, **kwargs): + def update_deploy_stage(self, deploy_stage_id, update_deploy_stage_details, **kwargs): """ - Updates the build pipeline. + Updates the deployment stage. - :param str build_pipeline_id: (required) - Unique build pipeline identifier. + :param str deploy_stage_id: (required) + Unique stage identifier. - :param oci.devops.models.UpdateBuildPipelineDetails update_build_pipeline_details: (required) + :param oci.devops.models.UpdateDeployStageDetails update_deploy_stage_details: (required) The information to be updated. :param str if_match: (optional) @@ -9112,18 +15160,18 @@ def update_build_pipeline(self, build_pipeline_id, update_build_pipeline_details allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipeline` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployStage` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_build_pipeline API. + Click `here `__ to see an example of how to use update_deploy_stage API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildPipelineId'] - resource_path = "/buildPipelines/{buildPipelineId}" + required_arguments = ['deployStageId'] + resource_path = "/deployStages/{deployStageId}" method = "PUT" - operation_name = "update_build_pipeline" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipeline/UpdateBuildPipeline" + operation_name = "update_deploy_stage" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStage/UpdateDeployStage" # Don't accept unknown kwargs expected_kwargs = [ @@ -9135,10 +15183,10 @@ def update_build_pipeline(self, build_pipeline_id, update_build_pipeline_details extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_build_pipeline got unknown kwargs: {extra_kwargs!r}") + f"update_deploy_stage got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildPipelineId": build_pipeline_id + "deployStageId": deploy_stage_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9172,8 +15220,8 @@ def update_build_pipeline(self, build_pipeline_id, update_build_pipeline_details method=method, path_params=path_params, header_params=header_params, - body=update_build_pipeline_details, - response_type="BuildPipeline", + body=update_deploy_stage_details, + response_type="DeployStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9184,22 +15232,22 @@ def update_build_pipeline(self, build_pipeline_id, update_build_pipeline_details method=method, path_params=path_params, header_params=header_params, - body=update_build_pipeline_details, - response_type="BuildPipeline", + body=update_deploy_stage_details, + response_type="DeployStage", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_build_pipeline_stage(self, build_pipeline_stage_id, update_build_pipeline_stage_details, **kwargs): + def update_deployment(self, deployment_id, update_deployment_details, **kwargs): """ - Updates the stage based on the stage ID provided in the request. + Updates the deployment. - :param str build_pipeline_stage_id: (required) - Unique stage identifier. + :param str deployment_id: (required) + Unique deployment identifier. - :param oci.devops.models.UpdateBuildPipelineStageDetails update_build_pipeline_stage_details: (required) + :param oci.devops.models.UpdateDeploymentDetails update_deployment_details: (required) The information to be updated. :param str if_match: (optional) @@ -9220,18 +15268,18 @@ def update_build_pipeline_stage(self, build_pipeline_stage_id, update_build_pipe allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildPipelineStage` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Deployment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_build_pipeline_stage API. + Click `here `__ to see an example of how to use update_deployment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildPipelineStageId'] - resource_path = "/buildPipelineStages/{buildPipelineStageId}" + required_arguments = ['deploymentId'] + resource_path = "/deployments/{deploymentId}" method = "PUT" - operation_name = "update_build_pipeline_stage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildPipelineStage/UpdateBuildPipelineStage" + operation_name = "update_deployment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Deployment/UpdateDeployment" # Don't accept unknown kwargs expected_kwargs = [ @@ -9243,10 +15291,10 @@ def update_build_pipeline_stage(self, build_pipeline_stage_id, update_build_pipe extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_build_pipeline_stage got unknown kwargs: {extra_kwargs!r}") + f"update_deployment got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildPipelineStageId": build_pipeline_stage_id + "deploymentId": deployment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9280,8 +15328,8 @@ def update_build_pipeline_stage(self, build_pipeline_stage_id, update_build_pipe method=method, path_params=path_params, header_params=header_params, - body=update_build_pipeline_stage_details, - response_type="BuildPipelineStage", + body=update_deployment_details, + response_type="Deployment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9292,22 +15340,22 @@ def update_build_pipeline_stage(self, build_pipeline_stage_id, update_build_pipe method=method, path_params=path_params, header_params=header_params, - body=update_build_pipeline_stage_details, - response_type="BuildPipelineStage", + body=update_deployment_details, + response_type="Deployment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_build_run(self, build_run_id, update_build_run_details, **kwargs): + def update_project(self, project_id, update_project_details, **kwargs): """ - Updates the build run. + Updates the project. - :param str build_run_id: (required) - Unique build run identifier. + :param str project_id: (required) + Unique project identifier. - :param oci.devops.models.UpdateBuildRunDetails update_build_run_details: (required) + :param oci.devops.models.UpdateProjectDetails update_project_details: (required) The information to be updated. :param str if_match: (optional) @@ -9328,18 +15376,18 @@ def update_build_run(self, build_run_id, update_build_run_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.BuildRun` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Project` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_build_run API. + Click `here `__ to see an example of how to use update_project API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['buildRunId'] - resource_path = "/buildRuns/{buildRunId}" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}" method = "PUT" - operation_name = "update_build_run" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/BuildRun/UpdateBuildRun" + operation_name = "update_project" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/UpdateProject" # Don't accept unknown kwargs expected_kwargs = [ @@ -9351,10 +15399,10 @@ def update_build_run(self, build_run_id, update_build_run_details, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_build_run got unknown kwargs: {extra_kwargs!r}") + f"update_project got unknown kwargs: {extra_kwargs!r}") path_params = { - "buildRunId": build_run_id + "projectId": project_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9388,8 +15436,8 @@ def update_build_run(self, build_run_id, update_build_run_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_build_run_details, - response_type="BuildRun", + body=update_project_details, + response_type="Project", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9400,24 +15448,27 @@ def update_build_run(self, build_run_id, update_build_run_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_build_run_details, - response_type="BuildRun", + body=update_project_details, + response_type="Project", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_connection(self, connection_id, update_connection_details, **kwargs): + def update_project_notification_preference(self, update_project_notification_preference_details, project_id, principal_id, **kwargs): """ - Updates the connection. - + Update the project notification preference for the user passed as path param - :param str connection_id: (required) - Unique connection identifier. - :param oci.devops.models.UpdateConnectionDetails update_connection_details: (required) + :param oci.devops.models.UpdateProjectNotificationPreferenceDetails update_project_notification_preference_details: (required) The information to be updated. + :param str project_id: (required) + Unique project identifier. + + :param str principal_id: (required) + Unique principal identifier. + :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -9436,18 +15487,18 @@ def update_connection(self, connection_id, update_connection_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Connection` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProjectNotificationPreference` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_connection API. + Click `here `__ to see an example of how to use update_project_notification_preference API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['connectionId'] - resource_path = "/connections/{connectionId}" + required_arguments = ['projectId', 'principalId'] + resource_path = "/projects/{projectId}/principals/{principalId}/pullRequestNotificationPreference" method = "PUT" - operation_name = "update_connection" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Connection/UpdateConnection" + operation_name = "update_project_notification_preference" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectNotificationPreference/UpdateProjectNotificationPreference" # Don't accept unknown kwargs expected_kwargs = [ @@ -9459,10 +15510,11 @@ def update_connection(self, connection_id, update_connection_details, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_connection got unknown kwargs: {extra_kwargs!r}") + f"update_project_notification_preference got unknown kwargs: {extra_kwargs!r}") path_params = { - "connectionId": connection_id + "projectId": project_id, + "principalId": principal_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9496,8 +15548,8 @@ def update_connection(self, connection_id, update_connection_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_connection_details, - response_type="Connection", + body=update_project_notification_preference_details, + response_type="ProjectNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9508,27 +15560,30 @@ def update_connection(self, connection_id, update_connection_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_connection_details, - response_type="Connection", + body=update_project_notification_preference_details, + response_type="ProjectNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_details, **kwargs): + def update_project_repository_settings(self, project_id, update_project_repository_settings_details, **kwargs): """ - Updates the deployment artifact. + Updates the repository settings for a project. - :param str deploy_artifact_id: (required) - Unique artifact identifier. + :param str project_id: (required) + Unique project identifier. - :param oci.devops.models.UpdateDeployArtifactDetails update_deploy_artifact_details: (required) - The information to be updated. + :param oci.devops.models.UpdateProjectRepositorySettingsDetails update_project_repository_settings_details: (required) + Details to update the repository settings for a project. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. + :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -9544,33 +15599,34 @@ def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_deta allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployArtifact` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.ProjectRepositorySettings` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_deploy_artifact API. + Click `here `__ to see an example of how to use update_project_repository_settings API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployArtifactId'] - resource_path = "/deployArtifacts/{deployArtifactId}" + required_arguments = ['projectId'] + resource_path = "/projects/{projectId}/repositorySettings" method = "PUT" - operation_name = "update_deploy_artifact" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployArtifact/UpdateDeployArtifact" + operation_name = "update_project_repository_settings" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/ProjectRepositorySettings/UpdateProjectRepositorySettings" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_deploy_artifact got unknown kwargs: {extra_kwargs!r}") + f"update_project_repository_settings got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployArtifactId": deploy_artifact_id + "projectId": project_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9583,6 +15639,7 @@ def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_deta "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -9596,6 +15653,7 @@ def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_deta if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -9604,8 +15662,8 @@ def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_deta method=method, path_params=path_params, header_params=header_params, - body=update_deploy_artifact_details, - response_type="DeployArtifact", + body=update_project_repository_settings_details, + response_type="ProjectRepositorySettings", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9616,22 +15674,22 @@ def update_deploy_artifact(self, deploy_artifact_id, update_deploy_artifact_deta method=method, path_params=path_params, header_params=header_params, - body=update_deploy_artifact_details, - response_type="DeployArtifact", + body=update_project_repository_settings_details, + response_type="ProjectRepositorySettings", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_deploy_environment(self, deploy_environment_id, update_deploy_environment_details, **kwargs): + def update_pull_request(self, pull_request_id, update_pull_request_details, **kwargs): """ - Updates the deployment environment. + Updates the PullRequest - :param str deploy_environment_id: (required) - Unique environment identifier. + :param str pull_request_id: (required) + unique PullRequest identifier - :param oci.devops.models.UpdateDeployEnvironmentDetails update_deploy_environment_details: (required) + :param oci.devops.models.UpdatePullRequestDetails update_pull_request_details: (required) The information to be updated. :param str if_match: (optional) @@ -9652,18 +15710,18 @@ def update_deploy_environment(self, deploy_environment_id, update_deploy_environ allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployEnvironment` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequest` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_deploy_environment API. + Click `here `__ to see an example of how to use update_pull_request API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployEnvironmentId'] - resource_path = "/deployEnvironments/{deployEnvironmentId}" + required_arguments = ['pullRequestId'] + resource_path = "/pullRequests/{pullRequestId}" method = "PUT" - operation_name = "update_deploy_environment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployEnvironment/UpdateDeployEnvironment" + operation_name = "update_pull_request" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/UpdatePullRequest" # Don't accept unknown kwargs expected_kwargs = [ @@ -9675,10 +15733,10 @@ def update_deploy_environment(self, deploy_environment_id, update_deploy_environ extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_deploy_environment got unknown kwargs: {extra_kwargs!r}") + f"update_pull_request got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployEnvironmentId": deploy_environment_id + "pullRequestId": pull_request_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9712,8 +15770,8 @@ def update_deploy_environment(self, deploy_environment_id, update_deploy_environ method=method, path_params=path_params, header_params=header_params, - body=update_deploy_environment_details, - response_type="DeployEnvironment", + body=update_pull_request_details, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9724,23 +15782,26 @@ def update_deploy_environment(self, deploy_environment_id, update_deploy_environ method=method, path_params=path_params, header_params=header_params, - body=update_deploy_environment_details, - response_type="DeployEnvironment", + body=update_pull_request_details, + response_type="PullRequest", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_deploy_pipeline(self, deploy_pipeline_id, update_deploy_pipeline_details, **kwargs): + def update_pull_request_comment(self, pull_request_id, comment_id, update_pull_request_comment_details, **kwargs): """ - Updates the deployment pipeline. + Updates the PullRequest comment - :param str deploy_pipeline_id: (required) - Unique pipeline identifier. + :param str pull_request_id: (required) + unique PullRequest identifier - :param oci.devops.models.UpdateDeployPipelineDetails update_deploy_pipeline_details: (required) - The information to be updated. + :param str comment_id: (required) + unique PullRequest Comment identifier + + :param oci.devops.models.UpdatePullRequestCommentDetails update_pull_request_comment_details: (required) + The new comment content to be updated. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -9760,18 +15821,18 @@ def update_deploy_pipeline(self, deploy_pipeline_id, update_deploy_pipeline_deta allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployPipeline` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestComment` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_deploy_pipeline API. + Click `here `__ to see an example of how to use update_pull_request_comment API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployPipelineId'] - resource_path = "/deployPipelines/{deployPipelineId}" + required_arguments = ['pullRequestId', 'commentId'] + resource_path = "/pullRequests/{pullRequestId}/comments/{commentId}" method = "PUT" - operation_name = "update_deploy_pipeline" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployPipeline/UpdateDeployPipeline" + operation_name = "update_pull_request_comment" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequest/UpdatePullRequestComment" # Don't accept unknown kwargs expected_kwargs = [ @@ -9783,10 +15844,11 @@ def update_deploy_pipeline(self, deploy_pipeline_id, update_deploy_pipeline_deta extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_deploy_pipeline got unknown kwargs: {extra_kwargs!r}") + f"update_pull_request_comment got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployPipelineId": deploy_pipeline_id + "pullRequestId": pull_request_id, + "commentId": comment_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9820,8 +15882,8 @@ def update_deploy_pipeline(self, deploy_pipeline_id, update_deploy_pipeline_deta method=method, path_params=path_params, header_params=header_params, - body=update_deploy_pipeline_details, - response_type="DeployPipeline", + body=update_pull_request_comment_details, + response_type="PullRequestComment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9832,24 +15894,27 @@ def update_deploy_pipeline(self, deploy_pipeline_id, update_deploy_pipeline_deta method=method, path_params=path_params, header_params=header_params, - body=update_deploy_pipeline_details, - response_type="DeployPipeline", + body=update_pull_request_comment_details, + response_type="PullRequestComment", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_deploy_stage(self, deploy_stage_id, update_deploy_stage_details, **kwargs): + def update_pull_request_notification_preference(self, update_pull_request_notification_preference_details, pull_request_id, principal_id, **kwargs): """ - Updates the deployment stage. - + Update the pull request notification preference for the user passed as path param - :param str deploy_stage_id: (required) - Unique stage identifier. - :param oci.devops.models.UpdateDeployStageDetails update_deploy_stage_details: (required) + :param oci.devops.models.UpdatePullRequestNotificationPreferenceDetails update_pull_request_notification_preference_details: (required) The information to be updated. + :param str pull_request_id: (required) + unique PullRequest identifier + + :param str principal_id: (required) + Unique principal identifier. + :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -9868,18 +15933,18 @@ def update_deploy_stage(self, deploy_stage_id, update_deploy_stage_details, **kw allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.DeployStage` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.PullRequestNotificationPreference` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_deploy_stage API. + Click `here `__ to see an example of how to use update_pull_request_notification_preference API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deployStageId'] - resource_path = "/deployStages/{deployStageId}" + required_arguments = ['pullRequestId', 'principalId'] + resource_path = "/pullRequests/{pullRequestId}/principals/{principalId}/pullRequestNotificationPreference" method = "PUT" - operation_name = "update_deploy_stage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/DeployStage/UpdateDeployStage" + operation_name = "update_pull_request_notification_preference" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/PullRequestNotificationPreference/UpdatePullRequestNotificationPreference" # Don't accept unknown kwargs expected_kwargs = [ @@ -9891,10 +15956,11 @@ def update_deploy_stage(self, deploy_stage_id, update_deploy_stage_details, **kw extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_deploy_stage got unknown kwargs: {extra_kwargs!r}") + f"update_pull_request_notification_preference got unknown kwargs: {extra_kwargs!r}") path_params = { - "deployStageId": deploy_stage_id + "pullRequestId": pull_request_id, + "principalId": principal_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -9928,8 +15994,8 @@ def update_deploy_stage(self, deploy_stage_id, update_deploy_stage_details, **kw method=method, path_params=path_params, header_params=header_params, - body=update_deploy_stage_details, - response_type="DeployStage", + body=update_pull_request_notification_preference_details, + response_type="PullRequestNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -9940,22 +16006,22 @@ def update_deploy_stage(self, deploy_stage_id, update_deploy_stage_details, **kw method=method, path_params=path_params, header_params=header_params, - body=update_deploy_stage_details, - response_type="DeployStage", + body=update_pull_request_notification_preference_details, + response_type="PullRequestNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_deployment(self, deployment_id, update_deployment_details, **kwargs): + def update_repository(self, repository_id, update_repository_details, **kwargs): """ - Updates the deployment. + Updates the repository. - :param str deployment_id: (required) - Unique deployment identifier. + :param str repository_id: (required) + Unique repository identifier. - :param oci.devops.models.UpdateDeploymentDetails update_deployment_details: (required) + :param oci.devops.models.UpdateRepositoryDetails update_repository_details: (required) The information to be updated. :param str if_match: (optional) @@ -9976,18 +16042,18 @@ def update_deployment(self, deployment_id, update_deployment_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Deployment` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Repository` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_deployment API. + Click `here `__ to see an example of how to use update_repository API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['deploymentId'] - resource_path = "/deployments/{deploymentId}" + required_arguments = ['repositoryId'] + resource_path = "/repositories/{repositoryId}" method = "PUT" - operation_name = "update_deployment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Deployment/UpdateDeployment" + operation_name = "update_repository" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/UpdateRepository" # Don't accept unknown kwargs expected_kwargs = [ @@ -9999,10 +16065,10 @@ def update_deployment(self, deployment_id, update_deployment_details, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_deployment got unknown kwargs: {extra_kwargs!r}") + f"update_repository got unknown kwargs: {extra_kwargs!r}") path_params = { - "deploymentId": deployment_id + "repositoryId": repository_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -10036,8 +16102,8 @@ def update_deployment(self, deployment_id, update_deployment_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_deployment_details, - response_type="Deployment", + body=update_repository_details, + response_type="Repository", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -10048,24 +16114,27 @@ def update_deployment(self, deployment_id, update_deployment_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_deployment_details, - response_type="Deployment", + body=update_repository_details, + response_type="Repository", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_project(self, project_id, update_project_details, **kwargs): + def update_repository_notification_preference(self, update_repository_notification_preference_details, repository_id, principal_id, **kwargs): """ - Updates the project. - + Update the repository notification preference for the user passed as path param - :param str project_id: (required) - Unique project identifier. - :param oci.devops.models.UpdateProjectDetails update_project_details: (required) + :param oci.devops.models.UpdateRepositoryNotificationPreferenceDetails update_repository_notification_preference_details: (required) The information to be updated. + :param str repository_id: (required) + Unique repository identifier. + + :param str principal_id: (required) + Unique principal identifier. + :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. @@ -10084,18 +16153,18 @@ def update_project(self, project_id, update_project_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Project` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositoryNotificationPreference` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_project API. + Click `here `__ to see an example of how to use update_repository_notification_preference API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. - required_arguments = ['projectId'] - resource_path = "/projects/{projectId}" + required_arguments = ['repositoryId', 'principalId'] + resource_path = "/repositories/{repositoryId}/principals/{principalId}/pullRequestNotificationPreference" method = "PUT" - operation_name = "update_project" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Project/UpdateProject" + operation_name = "update_repository_notification_preference" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositoryNotificationPreference/UpdateRepositoryNotificationPreference" # Don't accept unknown kwargs expected_kwargs = [ @@ -10107,10 +16176,11 @@ def update_project(self, project_id, update_project_details, **kwargs): extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_project got unknown kwargs: {extra_kwargs!r}") + f"update_repository_notification_preference got unknown kwargs: {extra_kwargs!r}") path_params = { - "projectId": project_id + "repositoryId": repository_id, + "principalId": principal_id } path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} @@ -10144,8 +16214,8 @@ def update_project(self, project_id, update_project_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_project_details, - response_type="Project", + body=update_repository_notification_preference_details, + response_type="RepositoryNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -10156,27 +16226,30 @@ def update_project(self, project_id, update_project_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_project_details, - response_type="Project", + body=update_repository_notification_preference_details, + response_type="RepositoryNotificationPreference", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def update_repository(self, repository_id, update_repository_details, **kwargs): + def update_repository_settings(self, repository_id, update_repository_settings_details, **kwargs): """ - Updates the repository. + Updates the settings for a repository. :param str repository_id: (required) Unique repository identifier. - :param oci.devops.models.UpdateRepositoryDetails update_repository_details: (required) - The information to be updated. + :param oci.devops.models.UpdateRepositorySettingsDetails update_repository_settings_details: (required) + Details to update settings for a repository. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value. + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated earlier due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected. + :param str opc_request_id: (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, provide the request ID. @@ -10192,30 +16265,31 @@ def update_repository(self, repository_id, update_repository_details, **kwargs): allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. By default, the response will not allow control characters in strings - :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.Repository` + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.devops.models.RepositorySettings` :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use update_repository API. + Click `here `__ to see an example of how to use update_repository_settings API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['repositoryId'] - resource_path = "/repositories/{repositoryId}" + resource_path = "/repositories/{repositoryId}/repositorySettings" method = "PUT" - operation_name = "update_repository" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/Repository/UpdateRepository" + operation_name = "update_repository_settings" + api_reference_link = "https://docs.oracle.com/iaas/api/#/en/devops/20210630/RepositorySettings/UpdateRepositorySettings" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", "if_match", + "opc_retry_token", "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"update_repository got unknown kwargs: {extra_kwargs!r}") + f"update_repository_settings got unknown kwargs: {extra_kwargs!r}") path_params = { "repositoryId": repository_id @@ -10231,6 +16305,7 @@ def update_repository(self, repository_id, update_repository_details, **kwargs): "accept": "application/json", "content-type": "application/json", "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing), "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -10244,6 +16319,7 @@ def update_repository(self, repository_id, update_repository_details, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( @@ -10252,8 +16328,8 @@ def update_repository(self, repository_id, update_repository_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_repository_details, - response_type="Repository", + body=update_repository_settings_details, + response_type="RepositorySettings", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -10264,8 +16340,8 @@ def update_repository(self, repository_id, update_repository_details, **kwargs): method=method, path_params=path_params, header_params=header_params, - body=update_repository_details, - response_type="Repository", + body=update_repository_settings_details, + response_type="RepositorySettings", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, diff --git a/src/oci/devops/devops_client_composite_operations.py b/src/oci/devops/devops_client_composite_operations.py index 6c12a3d18..76b6abc7b 100644 --- a/src/oci/devops/devops_client_composite_operations.py +++ b/src/oci/devops/devops_client_composite_operations.py @@ -598,6 +598,48 @@ def create_deployment_and_wait_for_state(self, create_deployment_details, wait_f except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def create_or_update_git_ref_and_wait_for_state(self, repository_id, create_or_update_git_ref_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.create_or_update_git_ref` and waits for the :py:class:`~oci.devops.models.WorkRequest` + to enter the given state(s). + + :param str repository_id: (required) + Unique repository identifier. + + :param oci.devops.models.CreateOrUpdateGitRefDetails create_or_update_git_ref_details: (required) + The information to create a reference with the type specified in the query. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.create_or_update_git_ref` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.create_or_update_git_ref(repository_id, create_or_update_git_ref_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def create_project_and_wait_for_state(self, create_project_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.create_project` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -637,6 +679,45 @@ def create_project_and_wait_for_state(self, create_project_details, wait_for_sta except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def create_pull_request_and_wait_for_state(self, create_pull_request_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.create_pull_request` and waits for the :py:class:`~oci.devops.models.WorkRequest` + to enter the given state(s). + + :param oci.devops.models.CreatePullRequestDetails create_pull_request_details: (required) + Details for the new PullRequest. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.create_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.create_pull_request(create_pull_request_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def create_repository_and_wait_for_state(self, create_repository_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.create_repository` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -715,6 +796,48 @@ def create_trigger_and_wait_for_state(self, create_trigger_details, wait_for_sta except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def decline_pull_request_and_wait_for_state(self, pull_request_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.decline_pull_request` and waits for the :py:class:`~oci.devops.models.PullRequest` acted upon + to enter the given state(s). + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.PullRequest.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.decline_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.decline_pull_request(pull_request_id, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + pull_request_id = operation_result.data.id + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_pull_request(pull_request_id), # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_build_pipeline_and_wait_for_state(self, build_pipeline_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.delete_build_pipeline` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -1044,6 +1167,48 @@ def delete_deploy_stage_and_wait_for_state(self, deploy_stage_id, wait_for_state except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_git_ref_and_wait_for_state(self, repository_id, delete_git_ref_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.delete_git_ref` and waits for the :py:class:`~oci.devops.models.WorkRequest` + to enter the given state(s). + + :param str repository_id: (required) + Unique repository identifier. + + :param oci.devops.models.DeleteGitRefDetails delete_git_ref_details: (required) + The information to delete a reference. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.delete_git_ref` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.delete_git_ref(repository_id, delete_git_ref_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_project_and_wait_for_state(self, project_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.delete_project` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -1091,6 +1256,65 @@ def delete_project_and_wait_for_state(self, project_id, wait_for_states=[], oper except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_pull_request_and_wait_for_state(self, pull_request_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.delete_pull_request` and waits for the :py:class:`~oci.devops.models.PullRequest` acted upon + to enter the given state(s). + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.PullRequest.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.delete_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + initial_get_result = self.client.get_pull_request(pull_request_id) + operation_result = None + try: + operation_result = self.client.delete_pull_request(pull_request_id, **operation_kwargs) + except oci.exceptions.ServiceError as e: + if e.status == 404: + return WAIT_RESOURCE_NOT_FOUND + else: + raise e + + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + + try: + if ("succeed_on_not_found" in waiter_kwargs) and (waiter_kwargs["succeed_on_not_found"] is False): + self.client.base_client.logger.warning("The waiter kwarg succeed_on_not_found was passed as False for the delete composite operation delete_pull_request, this would result in the operation to fail if the resource is not found! Please, do not pass this kwarg if this was not intended") + else: + """ + If the user does not send in this value, we set it to True by default. + We are doing this because during a delete resource scenario and waiting on its state, the service can + return a 404 NOT FOUND exception as the resource was deleted and a get on its state would fail + """ + waiter_kwargs["succeed_on_not_found"] = True + waiter_result = oci.wait_until( + self.client, + initial_get_result, # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_ref_and_wait_for_state(self, repository_id, ref_name, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.delete_ref` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -1235,6 +1459,48 @@ def delete_trigger_and_wait_for_state(self, trigger_id, wait_for_states=[], oper except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def merge_pull_request_and_wait_for_state(self, pull_request_id, merge_pull_request_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.merge_pull_request` and waits for the :py:class:`~oci.devops.models.WorkRequest` + to enter the given state(s). + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param oci.devops.models.MergePullRequestDetails merge_pull_request_details: (required) + The details about the merge operation. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.merge_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.merge_pull_request(pull_request_id, merge_pull_request_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def mirror_repository_and_wait_for_state(self, repository_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.mirror_repository` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -1319,6 +1585,93 @@ def put_repository_ref_and_wait_for_state(self, repository_id, ref_name, put_rep except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def reopen_pull_request_and_wait_for_state(self, pull_request_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.reopen_pull_request` and waits for the :py:class:`~oci.devops.models.PullRequest` acted upon + to enter the given state(s). + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.PullRequest.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.reopen_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.reopen_pull_request(pull_request_id, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + pull_request_id = operation_result.data.id + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_pull_request(pull_request_id), # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + + def review_pull_request_and_wait_for_state(self, pull_request_id, review_pull_request_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.review_pull_request` and waits for the :py:class:`~oci.devops.models.PullRequest` acted upon + to enter the given state(s). + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param oci.devops.models.ReviewPullRequestDetails review_pull_request_details: (required) + Details to submit a review. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.PullRequest.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.review_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.review_pull_request(pull_request_id, review_pull_request_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + pull_request_id = operation_result.data.id + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_pull_request(pull_request_id), # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def schedule_cascading_project_deletion_and_wait_for_state(self, project_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.schedule_cascading_project_deletion` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -1358,6 +1711,54 @@ def schedule_cascading_project_deletion_and_wait_for_state(self, project_id, wai except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def sync_repository_and_wait_for_state(self, repository_id, sync_merge_strategy, sync_repository_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.sync_repository` and waits for the :py:class:`~oci.devops.models.WorkRequest` + to enter the given state(s). + + :param str repository_id: (required) + Unique repository identifier. + + :param str sync_merge_strategy: (required) + If fetch and merge is passed in, the changes from the upstream will be fetched and merged into the destination branch. + If discard is passed in, the changes in the fork will be overwritten with the changes brought in from the upstream. + + Allowed values are: "FETCH_AND_MERGE", "DISCARD" + + :param oci.devops.models.SyncRepositoryDetails sync_repository_details: (required) + Details required for syncing a repository with its upstream. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.sync_repository` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.sync_repository(repository_id, sync_merge_strategy, sync_repository_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def update_build_pipeline_and_wait_for_state(self, build_pipeline_id, update_build_pipeline_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.update_build_pipeline` and waits for the :py:class:`~oci.devops.models.WorkRequest` @@ -1784,6 +2185,48 @@ def update_project_and_wait_for_state(self, project_id, update_project_details, except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def update_pull_request_and_wait_for_state(self, pull_request_id, update_pull_request_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.devops.DevopsClient.update_pull_request` and waits for the :py:class:`~oci.devops.models.WorkRequest` + to enter the given state(s). + + :param str pull_request_id: (required) + unique PullRequest identifier + + :param oci.devops.models.UpdatePullRequestDetails update_pull_request_details: (required) + The information to be updated. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.devops.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.devops.DevopsClient.update_pull_request` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.update_pull_request(pull_request_id, update_pull_request_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def update_repository_and_wait_for_state(self, repository_id, update_repository_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.devops.DevopsClient.update_repository` and waits for the :py:class:`~oci.devops.models.WorkRequest` diff --git a/src/oci/devops/models/__init__.py b/src/oci/devops/models/__init__.py index 6464d9862..6636de0e3 100644 --- a/src/oci/devops/models/__init__.py +++ b/src/oci/devops/models/__init__.py @@ -10,7 +10,11 @@ from .absolute_wait_criteria_summary import AbsoluteWaitCriteriaSummary from .actual_build_runner_shape_config import ActualBuildRunnerShapeConfig from .approval_action import ApprovalAction +from .approval_activity_summary import ApprovalActivitySummary from .approval_policy import ApprovalPolicy +from .approval_rule import ApprovalRule +from .approval_rule_collection import ApprovalRuleCollection +from .approval_rule_merge_check import ApprovalRuleMergeCheck from .approve_deployment_details import ApproveDeploymentDetails from .automated_deploy_stage_rollback_policy import AutomatedDeployStageRollbackPolicy from .backend_set_ip_collection import BackendSetIpCollection @@ -33,6 +37,7 @@ from .bitbucket_server_trigger import BitbucketServerTrigger from .bitbucket_server_trigger_create_result import BitbucketServerTriggerCreateResult from .bitbucket_server_trigger_summary import BitbucketServerTriggerSummary +from .build_merge_check import BuildMergeCheck from .build_outputs import BuildOutputs from .build_pipeline import BuildPipeline from .build_pipeline_collection import BuildPipelineCollection @@ -50,6 +55,9 @@ from .build_run_argument_collection import BuildRunArgumentCollection from .build_run_progress import BuildRunProgress from .build_run_progress_summary import BuildRunProgressSummary +from .build_run_snapshot import BuildRunSnapshot +from .build_run_snapshot_collection import BuildRunSnapshotCollection +from .build_run_snapshot_summary import BuildRunSnapshotSummary from .build_run_source import BuildRunSource from .build_run_summary import BuildRunSummary from .build_run_summary_collection import BuildRunSummaryCollection @@ -64,6 +72,10 @@ from .cancel_build_run_details import CancelBuildRunDetails from .cancel_deployment_details import CancelDeploymentDetails from .change_project_compartment_details import ChangeProjectCompartmentDetails +from .comment_activity_summary import CommentActivitySummary +from .commit_activity_summary import CommitActivitySummary +from .commit_analytics_author_collection import CommitAnalyticsAuthorCollection +from .commit_analytics_author_summary import CommitAnalyticsAuthorSummary from .commit_info import CommitInfo from .compute_instance_group_blue_green_deploy_stage import ComputeInstanceGroupBlueGreenDeployStage from .compute_instance_group_blue_green_deploy_stage_execution_progress import ComputeInstanceGroupBlueGreenDeployStageExecutionProgress @@ -95,6 +107,7 @@ from .compute_instance_group_rollout_policy import ComputeInstanceGroupRolloutPolicy from .compute_instance_group_selector import ComputeInstanceGroupSelector from .compute_instance_group_selector_collection import ComputeInstanceGroupSelectorCollection +from .conflict_merge_check import ConflictMergeCheck from .connection import Connection from .connection_collection import ConnectionCollection from .connection_summary import ConnectionSummary @@ -148,8 +161,15 @@ from .create_oke_cluster_deploy_environment_details import CreateOkeClusterDeployEnvironmentDetails from .create_oke_deploy_stage_details import CreateOkeDeployStageDetails from .create_oke_helm_chart_deploy_stage_details import CreateOkeHelmChartDeployStageDetails +from .create_or_update_git_branch_details import CreateOrUpdateGitBranchDetails +from .create_or_update_git_ref_details import CreateOrUpdateGitRefDetails +from .create_or_update_git_tag_details import CreateOrUpdateGitTagDetails +from .create_or_update_protected_branch_details import CreateOrUpdateProtectedBranchDetails from .create_project_details import CreateProjectDetails +from .create_pull_request_comment_details import CreatePullRequestCommentDetails +from .create_pull_request_details import CreatePullRequestDetails from .create_repository_details import CreateRepositoryDetails +from .create_reviewer_details import CreateReviewerDetails from .create_shell_deploy_stage_details import CreateShellDeployStageDetails from .create_single_deploy_stage_deployment_details import CreateSingleDeployStageDeploymentDetails from .create_single_deploy_stage_redeployment_details import CreateSingleDeployStageRedeploymentDetails @@ -162,6 +182,8 @@ from .create_wait_stage_details import CreateWaitStageDetails from .custom_build_runner_shape_config import CustomBuildRunnerShapeConfig from .default_build_runner_shape_config import DefaultBuildRunnerShapeConfig +from .delete_git_ref_details import DeleteGitRefDetails +from .delete_protected_branch_details import DeleteProtectedBranchDetails from .deliver_artifact import DeliverArtifact from .deliver_artifact_collection import DeliverArtifactCollection from .deliver_artifact_stage import DeliverArtifactStage @@ -225,17 +247,22 @@ from .diff_response_entry import DiffResponseEntry from .diff_section import DiffSection from .diff_summary import DiffSummary +from .execute_merge_pull_request_details import ExecuteMergePullRequestDetails from .exported_variable import ExportedVariable from .exported_variable_collection import ExportedVariableCollection from .file_diff_response import FileDiffResponse from .file_filter import FileFilter from .file_line_details import FileLineDetails from .filter import Filter +from .fork_sync_status_collection import ForkSyncStatusCollection +from .fork_sync_status_summary import ForkSyncStatusSummary from .function_deploy_environment import FunctionDeployEnvironment from .function_deploy_environment_summary import FunctionDeployEnvironmentSummary from .function_deploy_stage import FunctionDeployStage from .function_deploy_stage_execution_progress import FunctionDeployStageExecutionProgress from .function_deploy_stage_summary import FunctionDeployStageSummary +from .generic_artifact_location_details import GenericArtifactLocationDetails +from .generic_artifacts import GenericArtifacts from .generic_delivered_artifact import GenericDeliveredArtifact from .generic_deploy_artifact_source import GenericDeployArtifactSource from .github_access_token_connection import GithubAccessTokenConnection @@ -286,6 +313,11 @@ from .manual_approval_deploy_stage_execution_progress import ManualApprovalDeployStageExecutionProgress from .manual_approval_deploy_stage_summary import ManualApprovalDeployStageSummary from .manual_build_run_source import ManualBuildRunSource +from .merge_check import MergeCheck +from .merge_check_collection import MergeCheckCollection +from .merge_checks import MergeChecks +from .merge_pull_request_details import MergePullRequestDetails +from .merge_settings import MergeSettings from .mirror_repository_config import MirrorRepositoryConfig from .network_channel import NetworkChannel from .nginx_blue_green_strategy import NginxBlueGreenStrategy @@ -293,6 +325,7 @@ from .no_deploy_stage_rollback_policy import NoDeployStageRollbackPolicy from .none_verification_key_source import NoneVerificationKeySource from .notification_config import NotificationConfig +from .object_storage_generic_artifact_location_details import ObjectStorageGenericArtifactLocationDetails from .ocir_deploy_artifact_source import OcirDeployArtifactSource from .oke_blue_green_deploy_stage import OkeBlueGreenDeployStage from .oke_blue_green_deploy_stage_execution_progress import OkeBlueGreenDeployStageExecutionProgress @@ -319,14 +352,49 @@ from .oke_helm_chart_deploy_stage import OkeHelmChartDeployStage from .oke_helm_chart_deploy_stage_summary import OkeHelmChartDeployStageSummary from .oke_helm_chart_deployment_stage_execution_progress import OkeHelmChartDeploymentStageExecutionProgress +from .patch_insert_instruction import PatchInsertInstruction +from .patch_instruction import PatchInstruction +from .patch_merge_instruction import PatchMergeInstruction +from .patch_move_instruction import PatchMoveInstruction +from .patch_prohibit_instruction import PatchProhibitInstruction +from .patch_pull_request_details import PatchPullRequestDetails +from .patch_remove_instruction import PatchRemoveInstruction +from .patch_replace_instruction import PatchReplaceInstruction +from .patch_require_instruction import PatchRequireInstruction +from .principal_details import PrincipalDetails from .private_endpoint_channel import PrivateEndpointChannel from .project import Project from .project_collection import ProjectCollection +from .project_notification_preference import ProjectNotificationPreference +from .project_repository_settings import ProjectRepositorySettings from .project_summary import ProjectSummary +from .protected_branch import ProtectedBranch +from .protected_branch_collection import ProtectedBranchCollection +from .protected_branch_summary import ProtectedBranchSummary +from .pull_request import PullRequest +from .pull_request_activity_collection import PullRequestActivityCollection +from .pull_request_activity_summary import PullRequestActivitySummary +from .pull_request_attachment import PullRequestAttachment +from .pull_request_attachment_collection import PullRequestAttachmentCollection +from .pull_request_attachment_summary import PullRequestAttachmentSummary +from .pull_request_author_collection import PullRequestAuthorCollection +from .pull_request_author_summary import PullRequestAuthorSummary +from .pull_request_change_summary_metrics import PullRequestChangeSummaryMetrics +from .pull_request_collection import PullRequestCollection +from .pull_request_comment import PullRequestComment +from .pull_request_comment_collection import PullRequestCommentCollection +from .pull_request_comment_like_collection import PullRequestCommentLikeCollection +from .pull_request_comment_summary import PullRequestCommentSummary +from .pull_request_file_change_collection import PullRequestFileChangeCollection +from .pull_request_file_change_summary import PullRequestFileChangeSummary +from .pull_request_lifecycle_activity_summary import PullRequestLifecycleActivitySummary +from .pull_request_notification_preference import PullRequestNotificationPreference +from .pull_request_summary import PullRequestSummary from .put_repository_branch_details import PutRepositoryBranchDetails from .put_repository_ref_details import PutRepositoryRefDetails from .put_repository_tag_details import PutRepositoryTagDetails from .repository import Repository +from .repository_analytics_details import RepositoryAnalyticsDetails from .repository_author_collection import RepositoryAuthorCollection from .repository_author_summary import RepositoryAuthorSummary from .repository_branch import RepositoryBranch @@ -336,18 +404,25 @@ from .repository_commit_collection import RepositoryCommitCollection from .repository_commit_summary import RepositoryCommitSummary from .repository_file_lines import RepositoryFileLines +from .repository_metric_aggregation import RepositoryMetricAggregation +from .repository_metric_summary import RepositoryMetricSummary from .repository_mirror_record import RepositoryMirrorRecord from .repository_mirror_record_collection import RepositoryMirrorRecordCollection from .repository_mirror_record_summary import RepositoryMirrorRecordSummary +from .repository_notification_preference import RepositoryNotificationPreference from .repository_object import RepositoryObject from .repository_path_collection import RepositoryPathCollection from .repository_path_summary import RepositoryPathSummary from .repository_ref import RepositoryRef from .repository_ref_collection import RepositoryRefCollection from .repository_ref_summary import RepositoryRefSummary +from .repository_settings import RepositorySettings from .repository_summary import RepositorySummary from .repository_tag import RepositoryTag from .repository_tag_summary import RepositoryTagSummary +from .review_pull_request_details import ReviewPullRequestDetails +from .reviewer import Reviewer +from .reviewer_activity_summary import ReviewerActivitySummary from .service_vnic_channel import ServiceVnicChannel from .shape_config import ShapeConfig from .shell_deploy_stage import ShellDeployStage @@ -357,6 +432,11 @@ from .single_deploy_stage_deployment_summary import SingleDeployStageDeploymentSummary from .single_deploy_stage_redeployment import SingleDeployStageRedeployment from .single_deploy_stage_redeployment_summary import SingleDeployStageRedeploymentSummary +from .stage_output import StageOutput +from .summarize_project_repository_analytics_details import SummarizeProjectRepositoryAnalyticsDetails +from .summarize_repository_analytics_details import SummarizeRepositoryAnalyticsDetails +from .sync_repository_details import SyncRepositoryDetails +from .test_report_output import TestReportOutput from .tls_verify_config import TlsVerifyConfig from .trigger import Trigger from .trigger_action import TriggerAction @@ -370,6 +450,8 @@ from .trigger_schedule import TriggerSchedule from .trigger_summary import TriggerSummary from .update_absolute_wait_criteria_details import UpdateAbsoluteWaitCriteriaDetails +from .update_approval_rule_details import UpdateApprovalRuleDetails +from .update_approval_rule_details_collection import UpdateApprovalRuleDetailsCollection from .update_bitbucket_cloud_app_password_connection_details import UpdateBitbucketCloudAppPasswordConnectionDetails from .update_bitbucket_cloud_trigger_details import UpdateBitbucketCloudTriggerDetails from .update_bitbucket_server_access_token_connection_details import UpdateBitbucketServerAccessTokenConnectionDetails @@ -415,7 +497,15 @@ from .update_oke_deploy_stage_details import UpdateOkeDeployStageDetails from .update_oke_helm_chart_deploy_stage_details import UpdateOkeHelmChartDeployStageDetails from .update_project_details import UpdateProjectDetails +from .update_project_notification_preference_details import UpdateProjectNotificationPreferenceDetails +from .update_project_repository_settings_details import UpdateProjectRepositorySettingsDetails +from .update_pull_request_comment_details import UpdatePullRequestCommentDetails +from .update_pull_request_details import UpdatePullRequestDetails +from .update_pull_request_notification_preference_details import UpdatePullRequestNotificationPreferenceDetails from .update_repository_details import UpdateRepositoryDetails +from .update_repository_notification_preference_details import UpdateRepositoryNotificationPreferenceDetails +from .update_repository_settings_details import UpdateRepositorySettingsDetails +from .update_reviewer_details import UpdateReviewerDetails from .update_shell_deploy_stage_details import UpdateShellDeployStageDetails from .update_single_deploy_stage_deployment_details import UpdateSingleDeployStageDeploymentDetails from .update_single_deploy_stage_redeployment_details import UpdateSingleDeployStageRedeploymentDetails @@ -426,6 +516,7 @@ from .update_wait_criteria_details import UpdateWaitCriteriaDetails from .update_wait_deploy_stage_details import UpdateWaitDeployStageDetails from .update_wait_stage_details import UpdateWaitStageDetails +from .validate_merge_pull_request_details import ValidateMergePullRequestDetails from .vault_secret_verification_key_source import VaultSecretVerificationKeySource from .vbs_access_token_connection import VbsAccessTokenConnection from .vbs_access_token_connection_summary import VbsAccessTokenConnectionSummary @@ -463,7 +554,11 @@ "AbsoluteWaitCriteriaSummary": AbsoluteWaitCriteriaSummary, "ActualBuildRunnerShapeConfig": ActualBuildRunnerShapeConfig, "ApprovalAction": ApprovalAction, + "ApprovalActivitySummary": ApprovalActivitySummary, "ApprovalPolicy": ApprovalPolicy, + "ApprovalRule": ApprovalRule, + "ApprovalRuleCollection": ApprovalRuleCollection, + "ApprovalRuleMergeCheck": ApprovalRuleMergeCheck, "ApproveDeploymentDetails": ApproveDeploymentDetails, "AutomatedDeployStageRollbackPolicy": AutomatedDeployStageRollbackPolicy, "BackendSetIpCollection": BackendSetIpCollection, @@ -486,6 +581,7 @@ "BitbucketServerTrigger": BitbucketServerTrigger, "BitbucketServerTriggerCreateResult": BitbucketServerTriggerCreateResult, "BitbucketServerTriggerSummary": BitbucketServerTriggerSummary, + "BuildMergeCheck": BuildMergeCheck, "BuildOutputs": BuildOutputs, "BuildPipeline": BuildPipeline, "BuildPipelineCollection": BuildPipelineCollection, @@ -503,6 +599,9 @@ "BuildRunArgumentCollection": BuildRunArgumentCollection, "BuildRunProgress": BuildRunProgress, "BuildRunProgressSummary": BuildRunProgressSummary, + "BuildRunSnapshot": BuildRunSnapshot, + "BuildRunSnapshotCollection": BuildRunSnapshotCollection, + "BuildRunSnapshotSummary": BuildRunSnapshotSummary, "BuildRunSource": BuildRunSource, "BuildRunSummary": BuildRunSummary, "BuildRunSummaryCollection": BuildRunSummaryCollection, @@ -517,6 +616,10 @@ "CancelBuildRunDetails": CancelBuildRunDetails, "CancelDeploymentDetails": CancelDeploymentDetails, "ChangeProjectCompartmentDetails": ChangeProjectCompartmentDetails, + "CommentActivitySummary": CommentActivitySummary, + "CommitActivitySummary": CommitActivitySummary, + "CommitAnalyticsAuthorCollection": CommitAnalyticsAuthorCollection, + "CommitAnalyticsAuthorSummary": CommitAnalyticsAuthorSummary, "CommitInfo": CommitInfo, "ComputeInstanceGroupBlueGreenDeployStage": ComputeInstanceGroupBlueGreenDeployStage, "ComputeInstanceGroupBlueGreenDeployStageExecutionProgress": ComputeInstanceGroupBlueGreenDeployStageExecutionProgress, @@ -548,6 +651,7 @@ "ComputeInstanceGroupRolloutPolicy": ComputeInstanceGroupRolloutPolicy, "ComputeInstanceGroupSelector": ComputeInstanceGroupSelector, "ComputeInstanceGroupSelectorCollection": ComputeInstanceGroupSelectorCollection, + "ConflictMergeCheck": ConflictMergeCheck, "Connection": Connection, "ConnectionCollection": ConnectionCollection, "ConnectionSummary": ConnectionSummary, @@ -601,8 +705,15 @@ "CreateOkeClusterDeployEnvironmentDetails": CreateOkeClusterDeployEnvironmentDetails, "CreateOkeDeployStageDetails": CreateOkeDeployStageDetails, "CreateOkeHelmChartDeployStageDetails": CreateOkeHelmChartDeployStageDetails, + "CreateOrUpdateGitBranchDetails": CreateOrUpdateGitBranchDetails, + "CreateOrUpdateGitRefDetails": CreateOrUpdateGitRefDetails, + "CreateOrUpdateGitTagDetails": CreateOrUpdateGitTagDetails, + "CreateOrUpdateProtectedBranchDetails": CreateOrUpdateProtectedBranchDetails, "CreateProjectDetails": CreateProjectDetails, + "CreatePullRequestCommentDetails": CreatePullRequestCommentDetails, + "CreatePullRequestDetails": CreatePullRequestDetails, "CreateRepositoryDetails": CreateRepositoryDetails, + "CreateReviewerDetails": CreateReviewerDetails, "CreateShellDeployStageDetails": CreateShellDeployStageDetails, "CreateSingleDeployStageDeploymentDetails": CreateSingleDeployStageDeploymentDetails, "CreateSingleDeployStageRedeploymentDetails": CreateSingleDeployStageRedeploymentDetails, @@ -615,6 +726,8 @@ "CreateWaitStageDetails": CreateWaitStageDetails, "CustomBuildRunnerShapeConfig": CustomBuildRunnerShapeConfig, "DefaultBuildRunnerShapeConfig": DefaultBuildRunnerShapeConfig, + "DeleteGitRefDetails": DeleteGitRefDetails, + "DeleteProtectedBranchDetails": DeleteProtectedBranchDetails, "DeliverArtifact": DeliverArtifact, "DeliverArtifactCollection": DeliverArtifactCollection, "DeliverArtifactStage": DeliverArtifactStage, @@ -678,17 +791,22 @@ "DiffResponseEntry": DiffResponseEntry, "DiffSection": DiffSection, "DiffSummary": DiffSummary, + "ExecuteMergePullRequestDetails": ExecuteMergePullRequestDetails, "ExportedVariable": ExportedVariable, "ExportedVariableCollection": ExportedVariableCollection, "FileDiffResponse": FileDiffResponse, "FileFilter": FileFilter, "FileLineDetails": FileLineDetails, "Filter": Filter, + "ForkSyncStatusCollection": ForkSyncStatusCollection, + "ForkSyncStatusSummary": ForkSyncStatusSummary, "FunctionDeployEnvironment": FunctionDeployEnvironment, "FunctionDeployEnvironmentSummary": FunctionDeployEnvironmentSummary, "FunctionDeployStage": FunctionDeployStage, "FunctionDeployStageExecutionProgress": FunctionDeployStageExecutionProgress, "FunctionDeployStageSummary": FunctionDeployStageSummary, + "GenericArtifactLocationDetails": GenericArtifactLocationDetails, + "GenericArtifacts": GenericArtifacts, "GenericDeliveredArtifact": GenericDeliveredArtifact, "GenericDeployArtifactSource": GenericDeployArtifactSource, "GithubAccessTokenConnection": GithubAccessTokenConnection, @@ -739,6 +857,11 @@ "ManualApprovalDeployStageExecutionProgress": ManualApprovalDeployStageExecutionProgress, "ManualApprovalDeployStageSummary": ManualApprovalDeployStageSummary, "ManualBuildRunSource": ManualBuildRunSource, + "MergeCheck": MergeCheck, + "MergeCheckCollection": MergeCheckCollection, + "MergeChecks": MergeChecks, + "MergePullRequestDetails": MergePullRequestDetails, + "MergeSettings": MergeSettings, "MirrorRepositoryConfig": MirrorRepositoryConfig, "NetworkChannel": NetworkChannel, "NginxBlueGreenStrategy": NginxBlueGreenStrategy, @@ -746,6 +869,7 @@ "NoDeployStageRollbackPolicy": NoDeployStageRollbackPolicy, "NoneVerificationKeySource": NoneVerificationKeySource, "NotificationConfig": NotificationConfig, + "ObjectStorageGenericArtifactLocationDetails": ObjectStorageGenericArtifactLocationDetails, "OcirDeployArtifactSource": OcirDeployArtifactSource, "OkeBlueGreenDeployStage": OkeBlueGreenDeployStage, "OkeBlueGreenDeployStageExecutionProgress": OkeBlueGreenDeployStageExecutionProgress, @@ -772,14 +896,49 @@ "OkeHelmChartDeployStage": OkeHelmChartDeployStage, "OkeHelmChartDeployStageSummary": OkeHelmChartDeployStageSummary, "OkeHelmChartDeploymentStageExecutionProgress": OkeHelmChartDeploymentStageExecutionProgress, + "PatchInsertInstruction": PatchInsertInstruction, + "PatchInstruction": PatchInstruction, + "PatchMergeInstruction": PatchMergeInstruction, + "PatchMoveInstruction": PatchMoveInstruction, + "PatchProhibitInstruction": PatchProhibitInstruction, + "PatchPullRequestDetails": PatchPullRequestDetails, + "PatchRemoveInstruction": PatchRemoveInstruction, + "PatchReplaceInstruction": PatchReplaceInstruction, + "PatchRequireInstruction": PatchRequireInstruction, + "PrincipalDetails": PrincipalDetails, "PrivateEndpointChannel": PrivateEndpointChannel, "Project": Project, "ProjectCollection": ProjectCollection, + "ProjectNotificationPreference": ProjectNotificationPreference, + "ProjectRepositorySettings": ProjectRepositorySettings, "ProjectSummary": ProjectSummary, + "ProtectedBranch": ProtectedBranch, + "ProtectedBranchCollection": ProtectedBranchCollection, + "ProtectedBranchSummary": ProtectedBranchSummary, + "PullRequest": PullRequest, + "PullRequestActivityCollection": PullRequestActivityCollection, + "PullRequestActivitySummary": PullRequestActivitySummary, + "PullRequestAttachment": PullRequestAttachment, + "PullRequestAttachmentCollection": PullRequestAttachmentCollection, + "PullRequestAttachmentSummary": PullRequestAttachmentSummary, + "PullRequestAuthorCollection": PullRequestAuthorCollection, + "PullRequestAuthorSummary": PullRequestAuthorSummary, + "PullRequestChangeSummaryMetrics": PullRequestChangeSummaryMetrics, + "PullRequestCollection": PullRequestCollection, + "PullRequestComment": PullRequestComment, + "PullRequestCommentCollection": PullRequestCommentCollection, + "PullRequestCommentLikeCollection": PullRequestCommentLikeCollection, + "PullRequestCommentSummary": PullRequestCommentSummary, + "PullRequestFileChangeCollection": PullRequestFileChangeCollection, + "PullRequestFileChangeSummary": PullRequestFileChangeSummary, + "PullRequestLifecycleActivitySummary": PullRequestLifecycleActivitySummary, + "PullRequestNotificationPreference": PullRequestNotificationPreference, + "PullRequestSummary": PullRequestSummary, "PutRepositoryBranchDetails": PutRepositoryBranchDetails, "PutRepositoryRefDetails": PutRepositoryRefDetails, "PutRepositoryTagDetails": PutRepositoryTagDetails, "Repository": Repository, + "RepositoryAnalyticsDetails": RepositoryAnalyticsDetails, "RepositoryAuthorCollection": RepositoryAuthorCollection, "RepositoryAuthorSummary": RepositoryAuthorSummary, "RepositoryBranch": RepositoryBranch, @@ -789,18 +948,25 @@ "RepositoryCommitCollection": RepositoryCommitCollection, "RepositoryCommitSummary": RepositoryCommitSummary, "RepositoryFileLines": RepositoryFileLines, + "RepositoryMetricAggregation": RepositoryMetricAggregation, + "RepositoryMetricSummary": RepositoryMetricSummary, "RepositoryMirrorRecord": RepositoryMirrorRecord, "RepositoryMirrorRecordCollection": RepositoryMirrorRecordCollection, "RepositoryMirrorRecordSummary": RepositoryMirrorRecordSummary, + "RepositoryNotificationPreference": RepositoryNotificationPreference, "RepositoryObject": RepositoryObject, "RepositoryPathCollection": RepositoryPathCollection, "RepositoryPathSummary": RepositoryPathSummary, "RepositoryRef": RepositoryRef, "RepositoryRefCollection": RepositoryRefCollection, "RepositoryRefSummary": RepositoryRefSummary, + "RepositorySettings": RepositorySettings, "RepositorySummary": RepositorySummary, "RepositoryTag": RepositoryTag, "RepositoryTagSummary": RepositoryTagSummary, + "ReviewPullRequestDetails": ReviewPullRequestDetails, + "Reviewer": Reviewer, + "ReviewerActivitySummary": ReviewerActivitySummary, "ServiceVnicChannel": ServiceVnicChannel, "ShapeConfig": ShapeConfig, "ShellDeployStage": ShellDeployStage, @@ -810,6 +976,11 @@ "SingleDeployStageDeploymentSummary": SingleDeployStageDeploymentSummary, "SingleDeployStageRedeployment": SingleDeployStageRedeployment, "SingleDeployStageRedeploymentSummary": SingleDeployStageRedeploymentSummary, + "StageOutput": StageOutput, + "SummarizeProjectRepositoryAnalyticsDetails": SummarizeProjectRepositoryAnalyticsDetails, + "SummarizeRepositoryAnalyticsDetails": SummarizeRepositoryAnalyticsDetails, + "SyncRepositoryDetails": SyncRepositoryDetails, + "TestReportOutput": TestReportOutput, "TlsVerifyConfig": TlsVerifyConfig, "Trigger": Trigger, "TriggerAction": TriggerAction, @@ -823,6 +994,8 @@ "TriggerSchedule": TriggerSchedule, "TriggerSummary": TriggerSummary, "UpdateAbsoluteWaitCriteriaDetails": UpdateAbsoluteWaitCriteriaDetails, + "UpdateApprovalRuleDetails": UpdateApprovalRuleDetails, + "UpdateApprovalRuleDetailsCollection": UpdateApprovalRuleDetailsCollection, "UpdateBitbucketCloudAppPasswordConnectionDetails": UpdateBitbucketCloudAppPasswordConnectionDetails, "UpdateBitbucketCloudTriggerDetails": UpdateBitbucketCloudTriggerDetails, "UpdateBitbucketServerAccessTokenConnectionDetails": UpdateBitbucketServerAccessTokenConnectionDetails, @@ -868,7 +1041,15 @@ "UpdateOkeDeployStageDetails": UpdateOkeDeployStageDetails, "UpdateOkeHelmChartDeployStageDetails": UpdateOkeHelmChartDeployStageDetails, "UpdateProjectDetails": UpdateProjectDetails, + "UpdateProjectNotificationPreferenceDetails": UpdateProjectNotificationPreferenceDetails, + "UpdateProjectRepositorySettingsDetails": UpdateProjectRepositorySettingsDetails, + "UpdatePullRequestCommentDetails": UpdatePullRequestCommentDetails, + "UpdatePullRequestDetails": UpdatePullRequestDetails, + "UpdatePullRequestNotificationPreferenceDetails": UpdatePullRequestNotificationPreferenceDetails, "UpdateRepositoryDetails": UpdateRepositoryDetails, + "UpdateRepositoryNotificationPreferenceDetails": UpdateRepositoryNotificationPreferenceDetails, + "UpdateRepositorySettingsDetails": UpdateRepositorySettingsDetails, + "UpdateReviewerDetails": UpdateReviewerDetails, "UpdateShellDeployStageDetails": UpdateShellDeployStageDetails, "UpdateSingleDeployStageDeploymentDetails": UpdateSingleDeployStageDeploymentDetails, "UpdateSingleDeployStageRedeploymentDetails": UpdateSingleDeployStageRedeploymentDetails, @@ -879,6 +1060,7 @@ "UpdateWaitCriteriaDetails": UpdateWaitCriteriaDetails, "UpdateWaitDeployStageDetails": UpdateWaitDeployStageDetails, "UpdateWaitStageDetails": UpdateWaitStageDetails, + "ValidateMergePullRequestDetails": ValidateMergePullRequestDetails, "VaultSecretVerificationKeySource": VaultSecretVerificationKeySource, "VbsAccessTokenConnection": VbsAccessTokenConnection, "VbsAccessTokenConnectionSummary": VbsAccessTokenConnectionSummary, diff --git a/src/oci/devops/models/approval_activity_summary.py b/src/oci/devops/models/approval_activity_summary.py new file mode 100644 index 000000000..eba21355b --- /dev/null +++ b/src/oci/devops/models/approval_activity_summary.py @@ -0,0 +1,127 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .pull_request_activity_summary import PullRequestActivitySummary +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ApprovalActivitySummary(PullRequestActivitySummary): + """ + activity describing a reviewer's approval decision + """ + + #: A constant which can be used with the status property of a ApprovalActivitySummary. + #: This constant has a value of "APPROVED" + STATUS_APPROVED = "APPROVED" + + #: A constant which can be used with the status property of a ApprovalActivitySummary. + #: This constant has a value of "UNAPPROVED" + STATUS_UNAPPROVED = "UNAPPROVED" + + def __init__(self, **kwargs): + """ + Initializes a new ApprovalActivitySummary object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ApprovalActivitySummary.activity_type` attribute + of this class is ``APPROVAL`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this ApprovalActivitySummary. + :type id: str + + :param principal: + The value to assign to the principal property of this ApprovalActivitySummary. + :type principal: oci.devops.models.PrincipalDetails + + :param pull_request_id: + The value to assign to the pull_request_id property of this ApprovalActivitySummary. + :type pull_request_id: str + + :param time_occurred: + The value to assign to the time_occurred property of this ApprovalActivitySummary. + :type time_occurred: datetime + + :param activity_type: + The value to assign to the activity_type property of this ApprovalActivitySummary. + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type activity_type: str + + :param status: + The value to assign to the status property of this ApprovalActivitySummary. + Allowed values for this property are: "APPROVED", "UNAPPROVED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type status: str + + """ + self.swagger_types = { + 'id': 'str', + 'principal': 'PrincipalDetails', + 'pull_request_id': 'str', + 'time_occurred': 'datetime', + 'activity_type': 'str', + 'status': 'str' + } + + self.attribute_map = { + 'id': 'id', + 'principal': 'principal', + 'pull_request_id': 'pullRequestId', + 'time_occurred': 'timeOccurred', + 'activity_type': 'activityType', + 'status': 'status' + } + + self._id = None + self._principal = None + self._pull_request_id = None + self._time_occurred = None + self._activity_type = None + self._status = None + self._activity_type = 'APPROVAL' + + @property + def status(self): + """ + **[Required]** Gets the status of this ApprovalActivitySummary. + The approval status of a reviewer + + Allowed values for this property are: "APPROVED", "UNAPPROVED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The status of this ApprovalActivitySummary. + :rtype: str + """ + return self._status + + @status.setter + def status(self, status): + """ + Sets the status of this ApprovalActivitySummary. + The approval status of a reviewer + + + :param status: The status of this ApprovalActivitySummary. + :type: str + """ + allowed_values = ["APPROVED", "UNAPPROVED"] + if not value_allowed_none_or_none_sentinel(status, allowed_values): + status = 'UNKNOWN_ENUM_VALUE' + self._status = status + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/approval_rule.py b/src/oci/devops/models/approval_rule.py new file mode 100644 index 000000000..12c3aa589 --- /dev/null +++ b/src/oci/devops/models/approval_rule.py @@ -0,0 +1,165 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ApprovalRule(object): + """ + A rule which must be satisfied for matching pull requests before the pull request can be merged + """ + + def __init__(self, **kwargs): + """ + Initializes a new ApprovalRule object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param name: + The value to assign to the name property of this ApprovalRule. + :type name: str + + :param destination_branch: + The value to assign to the destination_branch property of this ApprovalRule. + :type destination_branch: str + + :param reviewers: + The value to assign to the reviewers property of this ApprovalRule. + :type reviewers: list[oci.devops.models.PrincipalDetails] + + :param min_approvals_count: + The value to assign to the min_approvals_count property of this ApprovalRule. + :type min_approvals_count: int + + """ + self.swagger_types = { + 'name': 'str', + 'destination_branch': 'str', + 'reviewers': 'list[PrincipalDetails]', + 'min_approvals_count': 'int' + } + + self.attribute_map = { + 'name': 'name', + 'destination_branch': 'destinationBranch', + 'reviewers': 'reviewers', + 'min_approvals_count': 'minApprovalsCount' + } + + self._name = None + self._destination_branch = None + self._reviewers = None + self._min_approvals_count = None + + @property + def name(self): + """ + **[Required]** Gets the name of this ApprovalRule. + Name which is used to uniquely identify an approval rule. + + + :return: The name of this ApprovalRule. + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """ + Sets the name of this ApprovalRule. + Name which is used to uniquely identify an approval rule. + + + :param name: The name of this ApprovalRule. + :type: str + """ + self._name = name + + @property + def destination_branch(self): + """ + Gets the destination_branch of this ApprovalRule. + Branch name where pull requests targeting the branch must satisfy the approval rule. This value being null means the rule applies to all pull requests + + + :return: The destination_branch of this ApprovalRule. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this ApprovalRule. + Branch name where pull requests targeting the branch must satisfy the approval rule. This value being null means the rule applies to all pull requests + + + :param destination_branch: The destination_branch of this ApprovalRule. + :type: str + """ + self._destination_branch = destination_branch + + @property + def reviewers(self): + """ + Gets the reviewers of this ApprovalRule. + List of users who must provide approvals up to the minApprovalsCount specified in the rule. An empty list means the approvals can come from any user. + + + :return: The reviewers of this ApprovalRule. + :rtype: list[oci.devops.models.PrincipalDetails] + """ + return self._reviewers + + @reviewers.setter + def reviewers(self, reviewers): + """ + Sets the reviewers of this ApprovalRule. + List of users who must provide approvals up to the minApprovalsCount specified in the rule. An empty list means the approvals can come from any user. + + + :param reviewers: The reviewers of this ApprovalRule. + :type: list[oci.devops.models.PrincipalDetails] + """ + self._reviewers = reviewers + + @property + def min_approvals_count(self): + """ + **[Required]** Gets the min_approvals_count of this ApprovalRule. + Minimum number of approvals which must be provided by the reviewers specified in the list before the rule can be satisfied + + + :return: The min_approvals_count of this ApprovalRule. + :rtype: int + """ + return self._min_approvals_count + + @min_approvals_count.setter + def min_approvals_count(self, min_approvals_count): + """ + Sets the min_approvals_count of this ApprovalRule. + Minimum number of approvals which must be provided by the reviewers specified in the list before the rule can be satisfied + + + :param min_approvals_count: The min_approvals_count of this ApprovalRule. + :type: int + """ + self._min_approvals_count = min_approvals_count + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/approval_rule_collection.py b/src/oci/devops/models/approval_rule_collection.py new file mode 100644 index 000000000..fe3c6eacd --- /dev/null +++ b/src/oci/devops/models/approval_rule_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ApprovalRuleCollection(object): + """ + List of approval rules which must be statisfied before pull requests which match the rules can be merged + """ + + def __init__(self, **kwargs): + """ + Initializes a new ApprovalRuleCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this ApprovalRuleCollection. + :type items: list[oci.devops.models.ApprovalRule] + + """ + self.swagger_types = { + 'items': 'list[ApprovalRule]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this ApprovalRuleCollection. + List of approval rules. + + + :return: The items of this ApprovalRuleCollection. + :rtype: list[oci.devops.models.ApprovalRule] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this ApprovalRuleCollection. + List of approval rules. + + + :param items: The items of this ApprovalRuleCollection. + :type: list[oci.devops.models.ApprovalRule] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/approval_rule_merge_check.py b/src/oci/devops/models/approval_rule_merge_check.py new file mode 100644 index 000000000..959c8a7fa --- /dev/null +++ b/src/oci/devops/models/approval_rule_merge_check.py @@ -0,0 +1,270 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .merge_check import MergeCheck +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ApprovalRuleMergeCheck(MergeCheck): + """ + The status of the approval rules. + """ + + #: A constant which can be used with the status property of a ApprovalRuleMergeCheck. + #: This constant has a value of "NEEDS_APPROVAL" + STATUS_NEEDS_APPROVAL = "NEEDS_APPROVAL" + + #: A constant which can be used with the status property of a ApprovalRuleMergeCheck. + #: This constant has a value of "SUCCEEDED" + STATUS_SUCCEEDED = "SUCCEEDED" + + #: A constant which can be used with the level property of a ApprovalRuleMergeCheck. + #: This constant has a value of "PROJECT" + LEVEL_PROJECT = "PROJECT" + + #: A constant which can be used with the level property of a ApprovalRuleMergeCheck. + #: This constant has a value of "REPOSITORY" + LEVEL_REPOSITORY = "REPOSITORY" + + def __init__(self, **kwargs): + """ + Initializes a new ApprovalRuleMergeCheck object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ApprovalRuleMergeCheck.type` attribute + of this class is ``APPROVAL_RULE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param type: + The value to assign to the type property of this ApprovalRuleMergeCheck. + Allowed values for this property are: "CONFLICT", "APPROVAL_RULE", "BUILD", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type type: str + + :param rule_name: + The value to assign to the rule_name property of this ApprovalRuleMergeCheck. + :type rule_name: str + + :param status: + The value to assign to the status property of this ApprovalRuleMergeCheck. + Allowed values for this property are: "NEEDS_APPROVAL", "SUCCEEDED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type status: str + + :param total_approval_count: + The value to assign to the total_approval_count property of this ApprovalRuleMergeCheck. + :type total_approval_count: int + + :param current_approval_count: + The value to assign to the current_approval_count property of this ApprovalRuleMergeCheck. + :type current_approval_count: int + + :param reviewers: + The value to assign to the reviewers property of this ApprovalRuleMergeCheck. + :type reviewers: list[oci.devops.models.PrincipalDetails] + + :param level: + The value to assign to the level property of this ApprovalRuleMergeCheck. + Allowed values for this property are: "PROJECT", "REPOSITORY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type level: str + + """ + self.swagger_types = { + 'type': 'str', + 'rule_name': 'str', + 'status': 'str', + 'total_approval_count': 'int', + 'current_approval_count': 'int', + 'reviewers': 'list[PrincipalDetails]', + 'level': 'str' + } + + self.attribute_map = { + 'type': 'type', + 'rule_name': 'ruleName', + 'status': 'status', + 'total_approval_count': 'totalApprovalCount', + 'current_approval_count': 'currentApprovalCount', + 'reviewers': 'reviewers', + 'level': 'level' + } + + self._type = None + self._rule_name = None + self._status = None + self._total_approval_count = None + self._current_approval_count = None + self._reviewers = None + self._level = None + self._type = 'APPROVAL_RULE' + + @property + def rule_name(self): + """ + Gets the rule_name of this ApprovalRuleMergeCheck. + The name of the rule. + + + :return: The rule_name of this ApprovalRuleMergeCheck. + :rtype: str + """ + return self._rule_name + + @rule_name.setter + def rule_name(self, rule_name): + """ + Sets the rule_name of this ApprovalRuleMergeCheck. + The name of the rule. + + + :param rule_name: The rule_name of this ApprovalRuleMergeCheck. + :type: str + """ + self._rule_name = rule_name + + @property + def status(self): + """ + Gets the status of this ApprovalRuleMergeCheck. + The status of the approval rule. + + Allowed values for this property are: "NEEDS_APPROVAL", "SUCCEEDED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The status of this ApprovalRuleMergeCheck. + :rtype: str + """ + return self._status + + @status.setter + def status(self, status): + """ + Sets the status of this ApprovalRuleMergeCheck. + The status of the approval rule. + + + :param status: The status of this ApprovalRuleMergeCheck. + :type: str + """ + allowed_values = ["NEEDS_APPROVAL", "SUCCEEDED"] + if not value_allowed_none_or_none_sentinel(status, allowed_values): + status = 'UNKNOWN_ENUM_VALUE' + self._status = status + + @property + def total_approval_count(self): + """ + Gets the total_approval_count of this ApprovalRuleMergeCheck. + The number of total approvals needed. + + + :return: The total_approval_count of this ApprovalRuleMergeCheck. + :rtype: int + """ + return self._total_approval_count + + @total_approval_count.setter + def total_approval_count(self, total_approval_count): + """ + Sets the total_approval_count of this ApprovalRuleMergeCheck. + The number of total approvals needed. + + + :param total_approval_count: The total_approval_count of this ApprovalRuleMergeCheck. + :type: int + """ + self._total_approval_count = total_approval_count + + @property + def current_approval_count(self): + """ + Gets the current_approval_count of this ApprovalRuleMergeCheck. + The current number of approvals. + + + :return: The current_approval_count of this ApprovalRuleMergeCheck. + :rtype: int + """ + return self._current_approval_count + + @current_approval_count.setter + def current_approval_count(self, current_approval_count): + """ + Sets the current_approval_count of this ApprovalRuleMergeCheck. + The current number of approvals. + + + :param current_approval_count: The current_approval_count of this ApprovalRuleMergeCheck. + :type: int + """ + self._current_approval_count = current_approval_count + + @property + def reviewers(self): + """ + Gets the reviewers of this ApprovalRuleMergeCheck. + The list of default reviewers. + + + :return: The reviewers of this ApprovalRuleMergeCheck. + :rtype: list[oci.devops.models.PrincipalDetails] + """ + return self._reviewers + + @reviewers.setter + def reviewers(self, reviewers): + """ + Sets the reviewers of this ApprovalRuleMergeCheck. + The list of default reviewers. + + + :param reviewers: The reviewers of this ApprovalRuleMergeCheck. + :type: list[oci.devops.models.PrincipalDetails] + """ + self._reviewers = reviewers + + @property + def level(self): + """ + Gets the level of this ApprovalRuleMergeCheck. + The level of rule. + + Allowed values for this property are: "PROJECT", "REPOSITORY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The level of this ApprovalRuleMergeCheck. + :rtype: str + """ + return self._level + + @level.setter + def level(self, level): + """ + Sets the level of this ApprovalRuleMergeCheck. + The level of rule. + + + :param level: The level of this ApprovalRuleMergeCheck. + :type: str + """ + allowed_values = ["PROJECT", "REPOSITORY"] + if not value_allowed_none_or_none_sentinel(level, allowed_values): + level = 'UNKNOWN_ENUM_VALUE' + self._level = level + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/build_merge_check.py b/src/oci/devops/models/build_merge_check.py new file mode 100644 index 000000000..915424d22 --- /dev/null +++ b/src/oci/devops/models/build_merge_check.py @@ -0,0 +1,144 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .merge_check import MergeCheck +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class BuildMergeCheck(MergeCheck): + """ + The status of the build pipelines. + """ + + def __init__(self, **kwargs): + """ + Initializes a new BuildMergeCheck object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.BuildMergeCheck.type` attribute + of this class is ``BUILD`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param type: + The value to assign to the type property of this BuildMergeCheck. + Allowed values for this property are: "CONFLICT", "APPROVAL_RULE", "BUILD" + :type type: str + + :param pipeline_id: + The value to assign to the pipeline_id property of this BuildMergeCheck. + :type pipeline_id: str + + :param build_run_id: + The value to assign to the build_run_id property of this BuildMergeCheck. + :type build_run_id: str + + :param build_status: + The value to assign to the build_status property of this BuildMergeCheck. + :type build_status: str + + """ + self.swagger_types = { + 'type': 'str', + 'pipeline_id': 'str', + 'build_run_id': 'str', + 'build_status': 'str' + } + + self.attribute_map = { + 'type': 'type', + 'pipeline_id': 'pipelineId', + 'build_run_id': 'buildRunId', + 'build_status': 'buildStatus' + } + + self._type = None + self._pipeline_id = None + self._build_run_id = None + self._build_status = None + self._type = 'BUILD' + + @property + def pipeline_id(self): + """ + Gets the pipeline_id of this BuildMergeCheck. + The pipeline OCID. + + + :return: The pipeline_id of this BuildMergeCheck. + :rtype: str + """ + return self._pipeline_id + + @pipeline_id.setter + def pipeline_id(self, pipeline_id): + """ + Sets the pipeline_id of this BuildMergeCheck. + The pipeline OCID. + + + :param pipeline_id: The pipeline_id of this BuildMergeCheck. + :type: str + """ + self._pipeline_id = pipeline_id + + @property + def build_run_id(self): + """ + Gets the build_run_id of this BuildMergeCheck. + The build run OCID. + + + :return: The build_run_id of this BuildMergeCheck. + :rtype: str + """ + return self._build_run_id + + @build_run_id.setter + def build_run_id(self, build_run_id): + """ + Sets the build_run_id of this BuildMergeCheck. + The build run OCID. + + + :param build_run_id: The build_run_id of this BuildMergeCheck. + :type: str + """ + self._build_run_id = build_run_id + + @property + def build_status(self): + """ + Gets the build_status of this BuildMergeCheck. + The status of the build. + + + :return: The build_status of this BuildMergeCheck. + :rtype: str + """ + return self._build_status + + @build_status.setter + def build_status(self, build_status): + """ + Sets the build_status of this BuildMergeCheck. + The status of the build. + + + :param build_status: The build_status of this BuildMergeCheck. + :type: str + """ + self._build_status = build_status + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/build_run_snapshot.py b/src/oci/devops/models/build_run_snapshot.py new file mode 100644 index 000000000..27df8e373 --- /dev/null +++ b/src/oci/devops/models/build_run_snapshot.py @@ -0,0 +1,329 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class BuildRunSnapshot(object): + """ + Snapshot of a build run. Contains information including pipelineId, commitId. + """ + + #: A constant which can be used with the lifecycle_state property of a BuildRunSnapshot. + #: This constant has a value of "ACCEPTED" + LIFECYCLE_STATE_ACCEPTED = "ACCEPTED" + + #: A constant which can be used with the lifecycle_state property of a BuildRunSnapshot. + #: This constant has a value of "IN_PROGRESS" + LIFECYCLE_STATE_IN_PROGRESS = "IN_PROGRESS" + + #: A constant which can be used with the lifecycle_state property of a BuildRunSnapshot. + #: This constant has a value of "FAILED" + LIFECYCLE_STATE_FAILED = "FAILED" + + #: A constant which can be used with the lifecycle_state property of a BuildRunSnapshot. + #: This constant has a value of "SUCCEEDED" + LIFECYCLE_STATE_SUCCEEDED = "SUCCEEDED" + + #: A constant which can be used with the lifecycle_state property of a BuildRunSnapshot. + #: This constant has a value of "CANCELING" + LIFECYCLE_STATE_CANCELING = "CANCELING" + + #: A constant which can be used with the lifecycle_state property of a BuildRunSnapshot. + #: This constant has a value of "CANCELED" + LIFECYCLE_STATE_CANCELED = "CANCELED" + + def __init__(self, **kwargs): + """ + Initializes a new BuildRunSnapshot object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param build_pipeline_id: + The value to assign to the build_pipeline_id property of this BuildRunSnapshot. + :type build_pipeline_id: str + + :param display_name: + The value to assign to the display_name property of this BuildRunSnapshot. + :type display_name: str + + :param commit_id: + The value to assign to the commit_id property of this BuildRunSnapshot. + :type commit_id: str + + :param build_run_id: + The value to assign to the build_run_id property of this BuildRunSnapshot. + :type build_run_id: str + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this BuildRunSnapshot. + Allowed values for this property are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED" + :type lifecycle_state: str + + :param lifecycle_details: + The value to assign to the lifecycle_details property of this BuildRunSnapshot. + :type lifecycle_details: str + + :param time_created: + The value to assign to the time_created property of this BuildRunSnapshot. + :type time_created: datetime + + :param time_updated: + The value to assign to the time_updated property of this BuildRunSnapshot. + :type time_updated: datetime + + """ + self.swagger_types = { + 'build_pipeline_id': 'str', + 'display_name': 'str', + 'commit_id': 'str', + 'build_run_id': 'str', + 'lifecycle_state': 'str', + 'lifecycle_details': 'str', + 'time_created': 'datetime', + 'time_updated': 'datetime' + } + + self.attribute_map = { + 'build_pipeline_id': 'buildPipelineId', + 'display_name': 'displayName', + 'commit_id': 'commitId', + 'build_run_id': 'buildRunId', + 'lifecycle_state': 'lifecycleState', + 'lifecycle_details': 'lifecycleDetails', + 'time_created': 'timeCreated', + 'time_updated': 'timeUpdated' + } + + self._build_pipeline_id = None + self._display_name = None + self._commit_id = None + self._build_run_id = None + self._lifecycle_state = None + self._lifecycle_details = None + self._time_created = None + self._time_updated = None + + @property + def build_pipeline_id(self): + """ + **[Required]** Gets the build_pipeline_id of this BuildRunSnapshot. + The OCID of the build pipeline where the build was triggered. + + + :return: The build_pipeline_id of this BuildRunSnapshot. + :rtype: str + """ + return self._build_pipeline_id + + @build_pipeline_id.setter + def build_pipeline_id(self, build_pipeline_id): + """ + Sets the build_pipeline_id of this BuildRunSnapshot. + The OCID of the build pipeline where the build was triggered. + + + :param build_pipeline_id: The build_pipeline_id of this BuildRunSnapshot. + :type: str + """ + self._build_pipeline_id = build_pipeline_id + + @property + def display_name(self): + """ + Gets the display_name of this BuildRunSnapshot. + The display name of the build run. + + + :return: The display_name of this BuildRunSnapshot. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this BuildRunSnapshot. + The display name of the build run. + + + :param display_name: The display_name of this BuildRunSnapshot. + :type: str + """ + self._display_name = display_name + + @property + def commit_id(self): + """ + **[Required]** Gets the commit_id of this BuildRunSnapshot. + The commit id which the build was triggered from. + + + :return: The commit_id of this BuildRunSnapshot. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this BuildRunSnapshot. + The commit id which the build was triggered from. + + + :param commit_id: The commit_id of this BuildRunSnapshot. + :type: str + """ + self._commit_id = commit_id + + @property + def build_run_id(self): + """ + **[Required]** Gets the build_run_id of this BuildRunSnapshot. + The OCID of the build run. + + + :return: The build_run_id of this BuildRunSnapshot. + :rtype: str + """ + return self._build_run_id + + @build_run_id.setter + def build_run_id(self, build_run_id): + """ + Sets the build_run_id of this BuildRunSnapshot. + The OCID of the build run. + + + :param build_run_id: The build_run_id of this BuildRunSnapshot. + :type: str + """ + self._build_run_id = build_run_id + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this BuildRunSnapshot. + The current status of the build run. + + Allowed values for this property are: "ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED" + + + :return: The lifecycle_state of this BuildRunSnapshot. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this BuildRunSnapshot. + The current status of the build run. + + + :param lifecycle_state: The lifecycle_state of this BuildRunSnapshot. + :type: str + """ + allowed_values = ["ACCEPTED", "IN_PROGRESS", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"] + if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): + raise ValueError( + f"Invalid value for `lifecycle_state`, must be None or one of {allowed_values}" + ) + self._lifecycle_state = lifecycle_state + + @property + def lifecycle_details(self): + """ + **[Required]** Gets the lifecycle_details of this BuildRunSnapshot. + A message describing the current state in more detail. + + + :return: The lifecycle_details of this BuildRunSnapshot. + :rtype: str + """ + return self._lifecycle_details + + @lifecycle_details.setter + def lifecycle_details(self, lifecycle_details): + """ + Sets the lifecycle_details of this BuildRunSnapshot. + A message describing the current state in more detail. + + + :param lifecycle_details: The lifecycle_details of this BuildRunSnapshot. + :type: str + """ + self._lifecycle_details = lifecycle_details + + @property + def time_created(self): + """ + Gets the time_created of this BuildRunSnapshot. + The time the build run was created. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_created of this BuildRunSnapshot. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this BuildRunSnapshot. + The time the build run was created. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_created: The time_created of this BuildRunSnapshot. + :type: datetime + """ + self._time_created = time_created + + @property + def time_updated(self): + """ + Gets the time_updated of this BuildRunSnapshot. + The time the build run was updated. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_updated of this BuildRunSnapshot. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this BuildRunSnapshot. + The time the build run was updated. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_updated: The time_updated of this BuildRunSnapshot. + :type: datetime + """ + self._time_updated = time_updated + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/build_run_snapshot_collection.py b/src/oci/devops/models/build_run_snapshot_collection.py new file mode 100644 index 000000000..30dd283b6 --- /dev/null +++ b/src/oci/devops/models/build_run_snapshot_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class BuildRunSnapshotCollection(object): + """ + Results of a build run search. Contains build run summary items. + """ + + def __init__(self, **kwargs): + """ + Initializes a new BuildRunSnapshotCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this BuildRunSnapshotCollection. + :type items: list[oci.devops.models.BuildRunSnapshotSummary] + + """ + self.swagger_types = { + 'items': 'list[BuildRunSnapshotSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this BuildRunSnapshotCollection. + List of build runs. + + + :return: The items of this BuildRunSnapshotCollection. + :rtype: list[oci.devops.models.BuildRunSnapshotSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this BuildRunSnapshotCollection. + List of build runs. + + + :param items: The items of this BuildRunSnapshotCollection. + :type: list[oci.devops.models.BuildRunSnapshotSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/build_run_snapshot_summary.py b/src/oci/devops/models/build_run_snapshot_summary.py new file mode 100644 index 000000000..7d827ddb7 --- /dev/null +++ b/src/oci/devops/models/build_run_snapshot_summary.py @@ -0,0 +1,297 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class BuildRunSnapshotSummary(object): + """ + Summary of a single build run snapshot. Contains information including pipelineId, commitId. + """ + + def __init__(self, **kwargs): + """ + Initializes a new BuildRunSnapshotSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param build_pipeline_id: + The value to assign to the build_pipeline_id property of this BuildRunSnapshotSummary. + :type build_pipeline_id: str + + :param commit_id: + The value to assign to the commit_id property of this BuildRunSnapshotSummary. + :type commit_id: str + + :param build_run_id: + The value to assign to the build_run_id property of this BuildRunSnapshotSummary. + :type build_run_id: str + + :param display_name: + The value to assign to the display_name property of this BuildRunSnapshotSummary. + :type display_name: str + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this BuildRunSnapshotSummary. + :type lifecycle_state: str + + :param lifecycle_details: + The value to assign to the lifecycle_details property of this BuildRunSnapshotSummary. + :type lifecycle_details: str + + :param time_created: + The value to assign to the time_created property of this BuildRunSnapshotSummary. + :type time_created: datetime + + :param time_updated: + The value to assign to the time_updated property of this BuildRunSnapshotSummary. + :type time_updated: datetime + + """ + self.swagger_types = { + 'build_pipeline_id': 'str', + 'commit_id': 'str', + 'build_run_id': 'str', + 'display_name': 'str', + 'lifecycle_state': 'str', + 'lifecycle_details': 'str', + 'time_created': 'datetime', + 'time_updated': 'datetime' + } + + self.attribute_map = { + 'build_pipeline_id': 'buildPipelineId', + 'commit_id': 'commitId', + 'build_run_id': 'buildRunId', + 'display_name': 'displayName', + 'lifecycle_state': 'lifecycleState', + 'lifecycle_details': 'lifecycleDetails', + 'time_created': 'timeCreated', + 'time_updated': 'timeUpdated' + } + + self._build_pipeline_id = None + self._commit_id = None + self._build_run_id = None + self._display_name = None + self._lifecycle_state = None + self._lifecycle_details = None + self._time_created = None + self._time_updated = None + + @property + def build_pipeline_id(self): + """ + **[Required]** Gets the build_pipeline_id of this BuildRunSnapshotSummary. + The OCID of the build pipeline where the build was triggered. + + + :return: The build_pipeline_id of this BuildRunSnapshotSummary. + :rtype: str + """ + return self._build_pipeline_id + + @build_pipeline_id.setter + def build_pipeline_id(self, build_pipeline_id): + """ + Sets the build_pipeline_id of this BuildRunSnapshotSummary. + The OCID of the build pipeline where the build was triggered. + + + :param build_pipeline_id: The build_pipeline_id of this BuildRunSnapshotSummary. + :type: str + """ + self._build_pipeline_id = build_pipeline_id + + @property + def commit_id(self): + """ + **[Required]** Gets the commit_id of this BuildRunSnapshotSummary. + The commit id which the build was triggered from. + + + :return: The commit_id of this BuildRunSnapshotSummary. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this BuildRunSnapshotSummary. + The commit id which the build was triggered from. + + + :param commit_id: The commit_id of this BuildRunSnapshotSummary. + :type: str + """ + self._commit_id = commit_id + + @property + def build_run_id(self): + """ + **[Required]** Gets the build_run_id of this BuildRunSnapshotSummary. + The OCID of the build run. + + + :return: The build_run_id of this BuildRunSnapshotSummary. + :rtype: str + """ + return self._build_run_id + + @build_run_id.setter + def build_run_id(self, build_run_id): + """ + Sets the build_run_id of this BuildRunSnapshotSummary. + The OCID of the build run. + + + :param build_run_id: The build_run_id of this BuildRunSnapshotSummary. + :type: str + """ + self._build_run_id = build_run_id + + @property + def display_name(self): + """ + Gets the display_name of this BuildRunSnapshotSummary. + The display name of the build run. + + + :return: The display_name of this BuildRunSnapshotSummary. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this BuildRunSnapshotSummary. + The display name of the build run. + + + :param display_name: The display_name of this BuildRunSnapshotSummary. + :type: str + """ + self._display_name = display_name + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this BuildRunSnapshotSummary. + The current status of the build run. + + + :return: The lifecycle_state of this BuildRunSnapshotSummary. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this BuildRunSnapshotSummary. + The current status of the build run. + + + :param lifecycle_state: The lifecycle_state of this BuildRunSnapshotSummary. + :type: str + """ + self._lifecycle_state = lifecycle_state + + @property + def lifecycle_details(self): + """ + **[Required]** Gets the lifecycle_details of this BuildRunSnapshotSummary. + A message describing the current state in more detail. + + + :return: The lifecycle_details of this BuildRunSnapshotSummary. + :rtype: str + """ + return self._lifecycle_details + + @lifecycle_details.setter + def lifecycle_details(self, lifecycle_details): + """ + Sets the lifecycle_details of this BuildRunSnapshotSummary. + A message describing the current state in more detail. + + + :param lifecycle_details: The lifecycle_details of this BuildRunSnapshotSummary. + :type: str + """ + self._lifecycle_details = lifecycle_details + + @property + def time_created(self): + """ + Gets the time_created of this BuildRunSnapshotSummary. + The time the build run was created. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_created of this BuildRunSnapshotSummary. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this BuildRunSnapshotSummary. + The time the build run was created. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_created: The time_created of this BuildRunSnapshotSummary. + :type: datetime + """ + self._time_created = time_created + + @property + def time_updated(self): + """ + Gets the time_updated of this BuildRunSnapshotSummary. + The time the build run was updated. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_updated of this BuildRunSnapshotSummary. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this BuildRunSnapshotSummary. + The time the build run was updated. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_updated: The time_updated of this BuildRunSnapshotSummary. + :type: datetime + """ + self._time_updated = time_updated + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/comment_activity_summary.py b/src/oci/devops/models/comment_activity_summary.py new file mode 100644 index 000000000..ea30e1209 --- /dev/null +++ b/src/oci/devops/models/comment_activity_summary.py @@ -0,0 +1,110 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .pull_request_activity_summary import PullRequestActivitySummary +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CommentActivitySummary(PullRequestActivitySummary): + """ + activity describing comment addition to a pull request + """ + + def __init__(self, **kwargs): + """ + Initializes a new CommentActivitySummary object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.CommentActivitySummary.activity_type` attribute + of this class is ``COMMENT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this CommentActivitySummary. + :type id: str + + :param principal: + The value to assign to the principal property of this CommentActivitySummary. + :type principal: oci.devops.models.PrincipalDetails + + :param pull_request_id: + The value to assign to the pull_request_id property of this CommentActivitySummary. + :type pull_request_id: str + + :param time_occurred: + The value to assign to the time_occurred property of this CommentActivitySummary. + :type time_occurred: datetime + + :param activity_type: + The value to assign to the activity_type property of this CommentActivitySummary. + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT" + :type activity_type: str + + :param comment_id: + The value to assign to the comment_id property of this CommentActivitySummary. + :type comment_id: str + + """ + self.swagger_types = { + 'id': 'str', + 'principal': 'PrincipalDetails', + 'pull_request_id': 'str', + 'time_occurred': 'datetime', + 'activity_type': 'str', + 'comment_id': 'str' + } + + self.attribute_map = { + 'id': 'id', + 'principal': 'principal', + 'pull_request_id': 'pullRequestId', + 'time_occurred': 'timeOccurred', + 'activity_type': 'activityType', + 'comment_id': 'commentId' + } + + self._id = None + self._principal = None + self._pull_request_id = None + self._time_occurred = None + self._activity_type = None + self._comment_id = None + self._activity_type = 'COMMENT' + + @property + def comment_id(self): + """ + **[Required]** Gets the comment_id of this CommentActivitySummary. + Identifier of comment added to a PR + + + :return: The comment_id of this CommentActivitySummary. + :rtype: str + """ + return self._comment_id + + @comment_id.setter + def comment_id(self, comment_id): + """ + Sets the comment_id of this CommentActivitySummary. + Identifier of comment added to a PR + + + :param comment_id: The comment_id of this CommentActivitySummary. + :type: str + """ + self._comment_id = comment_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/commit_activity_summary.py b/src/oci/devops/models/commit_activity_summary.py new file mode 100644 index 000000000..65a41f0cc --- /dev/null +++ b/src/oci/devops/models/commit_activity_summary.py @@ -0,0 +1,141 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .pull_request_activity_summary import PullRequestActivitySummary +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CommitActivitySummary(PullRequestActivitySummary): + """ + activity describing commit updates to a pull request + """ + + def __init__(self, **kwargs): + """ + Initializes a new CommitActivitySummary object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.CommitActivitySummary.activity_type` attribute + of this class is ``COMMIT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this CommitActivitySummary. + :type id: str + + :param principal: + The value to assign to the principal property of this CommitActivitySummary. + :type principal: oci.devops.models.PrincipalDetails + + :param pull_request_id: + The value to assign to the pull_request_id property of this CommitActivitySummary. + :type pull_request_id: str + + :param time_occurred: + The value to assign to the time_occurred property of this CommitActivitySummary. + :type time_occurred: datetime + + :param activity_type: + The value to assign to the activity_type property of this CommitActivitySummary. + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT" + :type activity_type: str + + :param commits_added: + The value to assign to the commits_added property of this CommitActivitySummary. + :type commits_added: list[oci.devops.models.RepositoryCommit] + + :param commits_removed: + The value to assign to the commits_removed property of this CommitActivitySummary. + :type commits_removed: list[oci.devops.models.RepositoryCommit] + + """ + self.swagger_types = { + 'id': 'str', + 'principal': 'PrincipalDetails', + 'pull_request_id': 'str', + 'time_occurred': 'datetime', + 'activity_type': 'str', + 'commits_added': 'list[RepositoryCommit]', + 'commits_removed': 'list[RepositoryCommit]' + } + + self.attribute_map = { + 'id': 'id', + 'principal': 'principal', + 'pull_request_id': 'pullRequestId', + 'time_occurred': 'timeOccurred', + 'activity_type': 'activityType', + 'commits_added': 'commitsAdded', + 'commits_removed': 'commitsRemoved' + } + + self._id = None + self._principal = None + self._pull_request_id = None + self._time_occurred = None + self._activity_type = None + self._commits_added = None + self._commits_removed = None + self._activity_type = 'COMMIT' + + @property + def commits_added(self): + """ + **[Required]** Gets the commits_added of this CommitActivitySummary. + list of commits added to a PR source branch after git push + + + :return: The commits_added of this CommitActivitySummary. + :rtype: list[oci.devops.models.RepositoryCommit] + """ + return self._commits_added + + @commits_added.setter + def commits_added(self, commits_added): + """ + Sets the commits_added of this CommitActivitySummary. + list of commits added to a PR source branch after git push + + + :param commits_added: The commits_added of this CommitActivitySummary. + :type: list[oci.devops.models.RepositoryCommit] + """ + self._commits_added = commits_added + + @property + def commits_removed(self): + """ + **[Required]** Gets the commits_removed of this CommitActivitySummary. + list of commits removed from a PR source branch after git push + + + :return: The commits_removed of this CommitActivitySummary. + :rtype: list[oci.devops.models.RepositoryCommit] + """ + return self._commits_removed + + @commits_removed.setter + def commits_removed(self, commits_removed): + """ + Sets the commits_removed of this CommitActivitySummary. + list of commits removed from a PR source branch after git push + + + :param commits_removed: The commits_removed of this CommitActivitySummary. + :type: list[oci.devops.models.RepositoryCommit] + """ + self._commits_removed = commits_removed + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/commit_analytics_author_collection.py b/src/oci/devops/models/commit_analytics_author_collection.py new file mode 100644 index 000000000..ebd462cfc --- /dev/null +++ b/src/oci/devops/models/commit_analytics_author_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CommitAnalyticsAuthorCollection(object): + """ + Result of listing Commit Analytics authors. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CommitAnalyticsAuthorCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this CommitAnalyticsAuthorCollection. + :type items: list[oci.devops.models.CommitAnalyticsAuthorSummary] + + """ + self.swagger_types = { + 'items': 'list[CommitAnalyticsAuthorSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this CommitAnalyticsAuthorCollection. + List of authors. + + + :return: The items of this CommitAnalyticsAuthorCollection. + :rtype: list[oci.devops.models.CommitAnalyticsAuthorSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this CommitAnalyticsAuthorCollection. + List of authors. + + + :param items: The items of this CommitAnalyticsAuthorCollection. + :type: list[oci.devops.models.CommitAnalyticsAuthorSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/commit_analytics_author_summary.py b/src/oci/devops/models/commit_analytics_author_summary.py new file mode 100644 index 000000000..e503a7baf --- /dev/null +++ b/src/oci/devops/models/commit_analytics_author_summary.py @@ -0,0 +1,103 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CommitAnalyticsAuthorSummary(object): + """ + Object containing summary of Commit Analytics author. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CommitAnalyticsAuthorSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param author_name: + The value to assign to the author_name property of this CommitAnalyticsAuthorSummary. + :type author_name: str + + :param author_email: + The value to assign to the author_email property of this CommitAnalyticsAuthorSummary. + :type author_email: str + + """ + self.swagger_types = { + 'author_name': 'str', + 'author_email': 'str' + } + + self.attribute_map = { + 'author_name': 'authorName', + 'author_email': 'authorEmail' + } + + self._author_name = None + self._author_email = None + + @property + def author_name(self): + """ + **[Required]** Gets the author_name of this CommitAnalyticsAuthorSummary. + Author name. + + + :return: The author_name of this CommitAnalyticsAuthorSummary. + :rtype: str + """ + return self._author_name + + @author_name.setter + def author_name(self, author_name): + """ + Sets the author_name of this CommitAnalyticsAuthorSummary. + Author name. + + + :param author_name: The author_name of this CommitAnalyticsAuthorSummary. + :type: str + """ + self._author_name = author_name + + @property + def author_email(self): + """ + **[Required]** Gets the author_email of this CommitAnalyticsAuthorSummary. + Author email. + + + :return: The author_email of this CommitAnalyticsAuthorSummary. + :rtype: str + """ + return self._author_email + + @author_email.setter + def author_email(self, author_email): + """ + Sets the author_email of this CommitAnalyticsAuthorSummary. + Author email. + + + :param author_email: The author_email of this CommitAnalyticsAuthorSummary. + :type: str + """ + self._author_email = author_email + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/conflict_merge_check.py b/src/oci/devops/models/conflict_merge_check.py new file mode 100644 index 000000000..b9c562907 --- /dev/null +++ b/src/oci/devops/models/conflict_merge_check.py @@ -0,0 +1,99 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .merge_check import MergeCheck +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ConflictMergeCheck(MergeCheck): + """ + The status of the merge conflict. + """ + + #: A constant which can be used with the status property of a ConflictMergeCheck. + #: This constant has a value of "SUCCEEDED" + STATUS_SUCCEEDED = "SUCCEEDED" + + #: A constant which can be used with the status property of a ConflictMergeCheck. + #: This constant has a value of "FAILED" + STATUS_FAILED = "FAILED" + + def __init__(self, **kwargs): + """ + Initializes a new ConflictMergeCheck object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ConflictMergeCheck.type` attribute + of this class is ``CONFLICT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param type: + The value to assign to the type property of this ConflictMergeCheck. + Allowed values for this property are: "CONFLICT", "APPROVAL_RULE", "BUILD", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type type: str + + :param status: + The value to assign to the status property of this ConflictMergeCheck. + Allowed values for this property are: "SUCCEEDED", "FAILED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type status: str + + """ + self.swagger_types = { + 'type': 'str', + 'status': 'str' + } + + self.attribute_map = { + 'type': 'type', + 'status': 'status' + } + + self._type = None + self._status = None + self._type = 'CONFLICT' + + @property + def status(self): + """ + Gets the status of this ConflictMergeCheck. + The status of the conflict. + + Allowed values for this property are: "SUCCEEDED", "FAILED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The status of this ConflictMergeCheck. + :rtype: str + """ + return self._status + + @status.setter + def status(self, status): + """ + Sets the status of this ConflictMergeCheck. + The status of the conflict. + + + :param status: The status of this ConflictMergeCheck. + :type: str + """ + allowed_values = ["SUCCEEDED", "FAILED"] + if not value_allowed_none_or_none_sentinel(status, allowed_values): + status = 'UNKNOWN_ENUM_VALUE' + self._status = status + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_or_update_git_branch_details.py b/src/oci/devops/models/create_or_update_git_branch_details.py new file mode 100644 index 000000000..d7a46aef0 --- /dev/null +++ b/src/oci/devops/models/create_or_update_git_branch_details.py @@ -0,0 +1,89 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .create_or_update_git_ref_details import CreateOrUpdateGitRefDetails +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateOrUpdateGitBranchDetails(CreateOrUpdateGitRefDetails): + """ + The information needed to create a branch. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreateOrUpdateGitBranchDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.CreateOrUpdateGitBranchDetails.ref_type` attribute + of this class is ``BRANCH`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param ref_name: + The value to assign to the ref_name property of this CreateOrUpdateGitBranchDetails. + :type ref_name: str + + :param ref_type: + The value to assign to the ref_type property of this CreateOrUpdateGitBranchDetails. + Allowed values for this property are: "BRANCH", "TAG" + :type ref_type: str + + :param commit_id: + The value to assign to the commit_id property of this CreateOrUpdateGitBranchDetails. + :type commit_id: str + + """ + self.swagger_types = { + 'ref_name': 'str', + 'ref_type': 'str', + 'commit_id': 'str' + } + + self.attribute_map = { + 'ref_name': 'refName', + 'ref_type': 'refType', + 'commit_id': 'commitId' + } + + self._ref_name = None + self._ref_type = None + self._commit_id = None + self._ref_type = 'BRANCH' + + @property + def commit_id(self): + """ + **[Required]** Gets the commit_id of this CreateOrUpdateGitBranchDetails. + Commit ID pointed to by the new branch. + + + :return: The commit_id of this CreateOrUpdateGitBranchDetails. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this CreateOrUpdateGitBranchDetails. + Commit ID pointed to by the new branch. + + + :param commit_id: The commit_id of this CreateOrUpdateGitBranchDetails. + :type: str + """ + self._commit_id = commit_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_or_update_git_ref_details.py b/src/oci/devops/models/create_or_update_git_ref_details.py new file mode 100644 index 000000000..75819002a --- /dev/null +++ b/src/oci/devops/models/create_or_update_git_ref_details.py @@ -0,0 +1,140 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateOrUpdateGitRefDetails(object): + """ + The information needed to create a reference. If the reference already exists, then it can be used to update the reference. + """ + + #: A constant which can be used with the ref_type property of a CreateOrUpdateGitRefDetails. + #: This constant has a value of "BRANCH" + REF_TYPE_BRANCH = "BRANCH" + + #: A constant which can be used with the ref_type property of a CreateOrUpdateGitRefDetails. + #: This constant has a value of "TAG" + REF_TYPE_TAG = "TAG" + + def __init__(self, **kwargs): + """ + Initializes a new CreateOrUpdateGitRefDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.CreateOrUpdateGitBranchDetails` + * :class:`~oci.devops.models.CreateOrUpdateGitTagDetails` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param ref_name: + The value to assign to the ref_name property of this CreateOrUpdateGitRefDetails. + :type ref_name: str + + :param ref_type: + The value to assign to the ref_type property of this CreateOrUpdateGitRefDetails. + Allowed values for this property are: "BRANCH", "TAG" + :type ref_type: str + + """ + self.swagger_types = { + 'ref_name': 'str', + 'ref_type': 'str' + } + + self.attribute_map = { + 'ref_name': 'refName', + 'ref_type': 'refType' + } + + self._ref_name = None + self._ref_type = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['refType'] + + if type == 'BRANCH': + return 'CreateOrUpdateGitBranchDetails' + + if type == 'TAG': + return 'CreateOrUpdateGitTagDetails' + else: + return 'CreateOrUpdateGitRefDetails' + + @property + def ref_name(self): + """ + **[Required]** Gets the ref_name of this CreateOrUpdateGitRefDetails. + The name of the reference to create or update. + + + :return: The ref_name of this CreateOrUpdateGitRefDetails. + :rtype: str + """ + return self._ref_name + + @ref_name.setter + def ref_name(self, ref_name): + """ + Sets the ref_name of this CreateOrUpdateGitRefDetails. + The name of the reference to create or update. + + + :param ref_name: The ref_name of this CreateOrUpdateGitRefDetails. + :type: str + """ + self._ref_name = ref_name + + @property + def ref_type(self): + """ + **[Required]** Gets the ref_type of this CreateOrUpdateGitRefDetails. + The type of reference (BRANCH or TAG). + + Allowed values for this property are: "BRANCH", "TAG" + + + :return: The ref_type of this CreateOrUpdateGitRefDetails. + :rtype: str + """ + return self._ref_type + + @ref_type.setter + def ref_type(self, ref_type): + """ + Sets the ref_type of this CreateOrUpdateGitRefDetails. + The type of reference (BRANCH or TAG). + + + :param ref_type: The ref_type of this CreateOrUpdateGitRefDetails. + :type: str + """ + allowed_values = ["BRANCH", "TAG"] + if not value_allowed_none_or_none_sentinel(ref_type, allowed_values): + raise ValueError( + f"Invalid value for `ref_type`, must be None or one of {allowed_values}" + ) + self._ref_type = ref_type + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_or_update_git_tag_details.py b/src/oci/devops/models/create_or_update_git_tag_details.py new file mode 100644 index 000000000..caafb7e16 --- /dev/null +++ b/src/oci/devops/models/create_or_update_git_tag_details.py @@ -0,0 +1,89 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .create_or_update_git_ref_details import CreateOrUpdateGitRefDetails +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateOrUpdateGitTagDetails(CreateOrUpdateGitRefDetails): + """ + The information needed to create a lightweight tag. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreateOrUpdateGitTagDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.CreateOrUpdateGitTagDetails.ref_type` attribute + of this class is ``TAG`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param ref_name: + The value to assign to the ref_name property of this CreateOrUpdateGitTagDetails. + :type ref_name: str + + :param ref_type: + The value to assign to the ref_type property of this CreateOrUpdateGitTagDetails. + Allowed values for this property are: "BRANCH", "TAG" + :type ref_type: str + + :param object_id: + The value to assign to the object_id property of this CreateOrUpdateGitTagDetails. + :type object_id: str + + """ + self.swagger_types = { + 'ref_name': 'str', + 'ref_type': 'str', + 'object_id': 'str' + } + + self.attribute_map = { + 'ref_name': 'refName', + 'ref_type': 'refType', + 'object_id': 'objectId' + } + + self._ref_name = None + self._ref_type = None + self._object_id = None + self._ref_type = 'TAG' + + @property + def object_id(self): + """ + **[Required]** Gets the object_id of this CreateOrUpdateGitTagDetails. + SHA-1 hash value of the object pointed to by the tag. + + + :return: The object_id of this CreateOrUpdateGitTagDetails. + :rtype: str + """ + return self._object_id + + @object_id.setter + def object_id(self, object_id): + """ + Sets the object_id of this CreateOrUpdateGitTagDetails. + SHA-1 hash value of the object pointed to by the tag. + + + :param object_id: The object_id of this CreateOrUpdateGitTagDetails. + :type: str + """ + self._object_id = object_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_or_update_protected_branch_details.py b/src/oci/devops/models/create_or_update_protected_branch_details.py new file mode 100644 index 000000000..4bdbc24e1 --- /dev/null +++ b/src/oci/devops/models/create_or_update_protected_branch_details.py @@ -0,0 +1,122 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateOrUpdateProtectedBranchDetails(object): + """ + Information to create a protected branch + """ + + #: A constant which can be used with the protection_levels property of a CreateOrUpdateProtectedBranchDetails. + #: This constant has a value of "READ_ONLY" + PROTECTION_LEVELS_READ_ONLY = "READ_ONLY" + + #: A constant which can be used with the protection_levels property of a CreateOrUpdateProtectedBranchDetails. + #: This constant has a value of "PULL_REQUEST_MERGE_ONLY" + PROTECTION_LEVELS_PULL_REQUEST_MERGE_ONLY = "PULL_REQUEST_MERGE_ONLY" + + def __init__(self, **kwargs): + """ + Initializes a new CreateOrUpdateProtectedBranchDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param branch_name: + The value to assign to the branch_name property of this CreateOrUpdateProtectedBranchDetails. + :type branch_name: str + + :param protection_levels: + The value to assign to the protection_levels property of this CreateOrUpdateProtectedBranchDetails. + Allowed values for items in this list are: "READ_ONLY", "PULL_REQUEST_MERGE_ONLY" + :type protection_levels: list[str] + + """ + self.swagger_types = { + 'branch_name': 'str', + 'protection_levels': 'list[str]' + } + + self.attribute_map = { + 'branch_name': 'branchName', + 'protection_levels': 'protectionLevels' + } + + self._branch_name = None + self._protection_levels = None + + @property + def branch_name(self): + """ + **[Required]** Gets the branch_name of this CreateOrUpdateProtectedBranchDetails. + Name of a branch to protect. + + + :return: The branch_name of this CreateOrUpdateProtectedBranchDetails. + :rtype: str + """ + return self._branch_name + + @branch_name.setter + def branch_name(self, branch_name): + """ + Sets the branch_name of this CreateOrUpdateProtectedBranchDetails. + Name of a branch to protect. + + + :param branch_name: The branch_name of this CreateOrUpdateProtectedBranchDetails. + :type: str + """ + self._branch_name = branch_name + + @property + def protection_levels(self): + """ + Gets the protection_levels of this CreateOrUpdateProtectedBranchDetails. + Level of protection to add on a branch. + + Allowed values for items in this list are: "READ_ONLY", "PULL_REQUEST_MERGE_ONLY" + + + :return: The protection_levels of this CreateOrUpdateProtectedBranchDetails. + :rtype: list[str] + """ + return self._protection_levels + + @protection_levels.setter + def protection_levels(self, protection_levels): + """ + Sets the protection_levels of this CreateOrUpdateProtectedBranchDetails. + Level of protection to add on a branch. + + + :param protection_levels: The protection_levels of this CreateOrUpdateProtectedBranchDetails. + :type: list[str] + """ + allowed_values = ["READ_ONLY", "PULL_REQUEST_MERGE_ONLY"] + + if protection_levels and protection_levels is not NONE_SENTINEL: + for value in protection_levels: + if not value_allowed_none_or_none_sentinel(value, allowed_values): + raise ValueError( + f"Invalid value for `protection_levels`, must be None or one of {allowed_values}" + ) + self._protection_levels = protection_levels + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_pull_request_comment_details.py b/src/oci/devops/models/create_pull_request_comment_details.py new file mode 100644 index 000000000..a8c51dc0c --- /dev/null +++ b/src/oci/devops/models/create_pull_request_comment_details.py @@ -0,0 +1,227 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreatePullRequestCommentDetails(object): + """ + The information about new Comment. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreatePullRequestCommentDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param data: + The value to assign to the data property of this CreatePullRequestCommentDetails. + :type data: str + + :param parent_id: + The value to assign to the parent_id property of this CreatePullRequestCommentDetails. + :type parent_id: str + + :param file_path: + The value to assign to the file_path property of this CreatePullRequestCommentDetails. + :type file_path: str + + :param commit_id: + The value to assign to the commit_id property of this CreatePullRequestCommentDetails. + :type commit_id: str + + :param file_type: + The value to assign to the file_type property of this CreatePullRequestCommentDetails. + :type file_type: str + + :param line_number: + The value to assign to the line_number property of this CreatePullRequestCommentDetails. + :type line_number: int + + """ + self.swagger_types = { + 'data': 'str', + 'parent_id': 'str', + 'file_path': 'str', + 'commit_id': 'str', + 'file_type': 'str', + 'line_number': 'int' + } + + self.attribute_map = { + 'data': 'data', + 'parent_id': 'parentId', + 'file_path': 'filePath', + 'commit_id': 'commitId', + 'file_type': 'fileType', + 'line_number': 'lineNumber' + } + + self._data = None + self._parent_id = None + self._file_path = None + self._commit_id = None + self._file_type = None + self._line_number = None + + @property + def data(self): + """ + **[Required]** Gets the data of this CreatePullRequestCommentDetails. + Content of the Comment. + + + :return: The data of this CreatePullRequestCommentDetails. + :rtype: str + """ + return self._data + + @data.setter + def data(self, data): + """ + Sets the data of this CreatePullRequestCommentDetails. + Content of the Comment. + + + :param data: The data of this CreatePullRequestCommentDetails. + :type: str + """ + self._data = data + + @property + def parent_id(self): + """ + Gets the parent_id of this CreatePullRequestCommentDetails. + ID of parent Comment + + + :return: The parent_id of this CreatePullRequestCommentDetails. + :rtype: str + """ + return self._parent_id + + @parent_id.setter + def parent_id(self, parent_id): + """ + Sets the parent_id of this CreatePullRequestCommentDetails. + ID of parent Comment + + + :param parent_id: The parent_id of this CreatePullRequestCommentDetails. + :type: str + """ + self._parent_id = parent_id + + @property + def file_path(self): + """ + Gets the file_path of this CreatePullRequestCommentDetails. + File path in the commit + + + :return: The file_path of this CreatePullRequestCommentDetails. + :rtype: str + """ + return self._file_path + + @file_path.setter + def file_path(self, file_path): + """ + Sets the file_path of this CreatePullRequestCommentDetails. + File path in the commit + + + :param file_path: The file_path of this CreatePullRequestCommentDetails. + :type: str + """ + self._file_path = file_path + + @property + def commit_id(self): + """ + Gets the commit_id of this CreatePullRequestCommentDetails. + Commit SHA + + + :return: The commit_id of this CreatePullRequestCommentDetails. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this CreatePullRequestCommentDetails. + Commit SHA + + + :param commit_id: The commit_id of this CreatePullRequestCommentDetails. + :type: str + """ + self._commit_id = commit_id + + @property + def file_type(self): + """ + Gets the file_type of this CreatePullRequestCommentDetails. + File path in the target commit + + + :return: The file_type of this CreatePullRequestCommentDetails. + :rtype: str + """ + return self._file_type + + @file_type.setter + def file_type(self, file_type): + """ + Sets the file_type of this CreatePullRequestCommentDetails. + File path in the target commit + + + :param file_type: The file_type of this CreatePullRequestCommentDetails. + :type: str + """ + self._file_type = file_type + + @property + def line_number(self): + """ + Gets the line_number of this CreatePullRequestCommentDetails. + Line number in the file + + + :return: The line_number of this CreatePullRequestCommentDetails. + :rtype: int + """ + return self._line_number + + @line_number.setter + def line_number(self, line_number): + """ + Sets the line_number of this CreatePullRequestCommentDetails. + Line number in the file + + + :param line_number: The line_number of this CreatePullRequestCommentDetails. + :type: int + """ + self._line_number = line_number + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_pull_request_details.py b/src/oci/devops/models/create_pull_request_details.py new file mode 100644 index 000000000..581c0b219 --- /dev/null +++ b/src/oci/devops/models/create_pull_request_details.py @@ -0,0 +1,328 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreatePullRequestDetails(object): + """ + The information about new Pull Request. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreatePullRequestDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param display_name: + The value to assign to the display_name property of this CreatePullRequestDetails. + :type display_name: str + + :param source_branch: + The value to assign to the source_branch property of this CreatePullRequestDetails. + :type source_branch: str + + :param destination_branch: + The value to assign to the destination_branch property of this CreatePullRequestDetails. + :type destination_branch: str + + :param repository_id: + The value to assign to the repository_id property of this CreatePullRequestDetails. + :type repository_id: str + + :param source_repository_id: + The value to assign to the source_repository_id property of this CreatePullRequestDetails. + :type source_repository_id: str + + :param description: + The value to assign to the description property of this CreatePullRequestDetails. + :type description: str + + :param reviewers: + The value to assign to the reviewers property of this CreatePullRequestDetails. + :type reviewers: list[oci.devops.models.CreateReviewerDetails] + + :param freeform_tags: + The value to assign to the freeform_tags property of this CreatePullRequestDetails. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this CreatePullRequestDetails. + :type defined_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'display_name': 'str', + 'source_branch': 'str', + 'destination_branch': 'str', + 'repository_id': 'str', + 'source_repository_id': 'str', + 'description': 'str', + 'reviewers': 'list[CreateReviewerDetails]', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'display_name': 'displayName', + 'source_branch': 'sourceBranch', + 'destination_branch': 'destinationBranch', + 'repository_id': 'repositoryId', + 'source_repository_id': 'sourceRepositoryId', + 'description': 'description', + 'reviewers': 'reviewers', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags' + } + + self._display_name = None + self._source_branch = None + self._destination_branch = None + self._repository_id = None + self._source_repository_id = None + self._description = None + self._reviewers = None + self._freeform_tags = None + self._defined_tags = None + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this CreatePullRequestDetails. + Pull Request title + + + :return: The display_name of this CreatePullRequestDetails. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this CreatePullRequestDetails. + Pull Request title + + + :param display_name: The display_name of this CreatePullRequestDetails. + :type: str + """ + self._display_name = display_name + + @property + def source_branch(self): + """ + **[Required]** Gets the source_branch of this CreatePullRequestDetails. + The source branch of the pull request. + + + :return: The source_branch of this CreatePullRequestDetails. + :rtype: str + """ + return self._source_branch + + @source_branch.setter + def source_branch(self, source_branch): + """ + Sets the source_branch of this CreatePullRequestDetails. + The source branch of the pull request. + + + :param source_branch: The source_branch of this CreatePullRequestDetails. + :type: str + """ + self._source_branch = source_branch + + @property + def destination_branch(self): + """ + Gets the destination_branch of this CreatePullRequestDetails. + The destination branch of the pull request. If not provided, default branch will be used as the destination branch. + + + :return: The destination_branch of this CreatePullRequestDetails. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this CreatePullRequestDetails. + The destination branch of the pull request. If not provided, default branch will be used as the destination branch. + + + :param destination_branch: The destination_branch of this CreatePullRequestDetails. + :type: str + """ + self._destination_branch = destination_branch + + @property + def repository_id(self): + """ + **[Required]** Gets the repository_id of this CreatePullRequestDetails. + The OCID of the repository. + + + :return: The repository_id of this CreatePullRequestDetails. + :rtype: str + """ + return self._repository_id + + @repository_id.setter + def repository_id(self, repository_id): + """ + Sets the repository_id of this CreatePullRequestDetails. + The OCID of the repository. + + + :param repository_id: The repository_id of this CreatePullRequestDetails. + :type: str + """ + self._repository_id = repository_id + + @property + def source_repository_id(self): + """ + Gets the source_repository_id of this CreatePullRequestDetails. + The OCID of the forked repository that will act as the source of the changes to be included in the pull request against the parent repository. + + + :return: The source_repository_id of this CreatePullRequestDetails. + :rtype: str + """ + return self._source_repository_id + + @source_repository_id.setter + def source_repository_id(self, source_repository_id): + """ + Sets the source_repository_id of this CreatePullRequestDetails. + The OCID of the forked repository that will act as the source of the changes to be included in the pull request against the parent repository. + + + :param source_repository_id: The source_repository_id of this CreatePullRequestDetails. + :type: str + """ + self._source_repository_id = source_repository_id + + @property + def description(self): + """ + Gets the description of this CreatePullRequestDetails. + Details of the pull request. Avoid entering confidential information. + + + :return: The description of this CreatePullRequestDetails. + :rtype: str + """ + return self._description + + @description.setter + def description(self, description): + """ + Sets the description of this CreatePullRequestDetails. + Details of the pull request. Avoid entering confidential information. + + + :param description: The description of this CreatePullRequestDetails. + :type: str + """ + self._description = description + + @property + def reviewers(self): + """ + Gets the reviewers of this CreatePullRequestDetails. + Reviewers for this pull request. + + + :return: The reviewers of this CreatePullRequestDetails. + :rtype: list[oci.devops.models.CreateReviewerDetails] + """ + return self._reviewers + + @reviewers.setter + def reviewers(self, reviewers): + """ + Sets the reviewers of this CreatePullRequestDetails. + Reviewers for this pull request. + + + :param reviewers: The reviewers of this CreatePullRequestDetails. + :type: list[oci.devops.models.CreateReviewerDetails] + """ + self._reviewers = reviewers + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this CreatePullRequestDetails. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this CreatePullRequestDetails. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this CreatePullRequestDetails. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this CreatePullRequestDetails. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + Gets the defined_tags of this CreatePullRequestDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this CreatePullRequestDetails. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this CreatePullRequestDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this CreatePullRequestDetails. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/create_repository_details.py b/src/oci/devops/models/create_repository_details.py index 1cdf7b1c8..2d1d09285 100644 --- a/src/oci/devops/models/create_repository_details.py +++ b/src/oci/devops/models/create_repository_details.py @@ -28,6 +28,10 @@ def __init__(self, **kwargs): The value to assign to the project_id property of this CreateRepositoryDetails. :type project_id: str + :param parent_repository_id: + The value to assign to the parent_repository_id property of this CreateRepositoryDetails. + :type parent_repository_id: str + :param default_branch: The value to assign to the default_branch property of this CreateRepositoryDetails. :type default_branch: str @@ -56,6 +60,7 @@ def __init__(self, **kwargs): self.swagger_types = { 'name': 'str', 'project_id': 'str', + 'parent_repository_id': 'str', 'default_branch': 'str', 'repository_type': 'str', 'mirror_repository_config': 'MirrorRepositoryConfig', @@ -67,6 +72,7 @@ def __init__(self, **kwargs): self.attribute_map = { 'name': 'name', 'project_id': 'projectId', + 'parent_repository_id': 'parentRepositoryId', 'default_branch': 'defaultBranch', 'repository_type': 'repositoryType', 'mirror_repository_config': 'mirrorRepositoryConfig', @@ -77,6 +83,7 @@ def __init__(self, **kwargs): self._name = None self._project_id = None + self._parent_repository_id = None self._default_branch = None self._repository_type = None self._mirror_repository_config = None @@ -132,6 +139,30 @@ def project_id(self, project_id): """ self._project_id = project_id + @property + def parent_repository_id(self): + """ + Gets the parent_repository_id of this CreateRepositoryDetails. + The OCID of the parent repository. + + + :return: The parent_repository_id of this CreateRepositoryDetails. + :rtype: str + """ + return self._parent_repository_id + + @parent_repository_id.setter + def parent_repository_id(self, parent_repository_id): + """ + Sets the parent_repository_id of this CreateRepositoryDetails. + The OCID of the parent repository. + + + :param parent_repository_id: The parent_repository_id of this CreateRepositoryDetails. + :type: str + """ + self._parent_repository_id = parent_repository_id + @property def default_branch(self): """ @@ -163,6 +194,7 @@ def repository_type(self): Type of repository. Allowed values: `MIRRORED` `HOSTED` + `FORKED` :return: The repository_type of this CreateRepositoryDetails. @@ -177,6 +209,7 @@ def repository_type(self, repository_type): Type of repository. Allowed values: `MIRRORED` `HOSTED` + `FORKED` :param repository_type: The repository_type of this CreateRepositoryDetails. diff --git a/src/oci/devops/models/create_reviewer_details.py b/src/oci/devops/models/create_reviewer_details.py new file mode 100644 index 000000000..9ca845eeb --- /dev/null +++ b/src/oci/devops/models/create_reviewer_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateReviewerDetails(object): + """ + The reviewer to be created. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreateReviewerDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param principal_id: + The value to assign to the principal_id property of this CreateReviewerDetails. + :type principal_id: str + + """ + self.swagger_types = { + 'principal_id': 'str' + } + + self.attribute_map = { + 'principal_id': 'principalId' + } + + self._principal_id = None + + @property + def principal_id(self): + """ + **[Required]** Gets the principal_id of this CreateReviewerDetails. + Pull Request reviewer id + + + :return: The principal_id of this CreateReviewerDetails. + :rtype: str + """ + return self._principal_id + + @principal_id.setter + def principal_id(self, principal_id): + """ + Sets the principal_id of this CreateReviewerDetails. + Pull Request reviewer id + + + :param principal_id: The principal_id of this CreateReviewerDetails. + :type: str + """ + self._principal_id = principal_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/delete_git_ref_details.py b/src/oci/devops/models/delete_git_ref_details.py new file mode 100644 index 000000000..f6ba699cd --- /dev/null +++ b/src/oci/devops/models/delete_git_ref_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DeleteGitRefDetails(object): + """ + The information needed to delete a reference. + """ + + def __init__(self, **kwargs): + """ + Initializes a new DeleteGitRefDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param ref_name: + The value to assign to the ref_name property of this DeleteGitRefDetails. + :type ref_name: str + + """ + self.swagger_types = { + 'ref_name': 'str' + } + + self.attribute_map = { + 'ref_name': 'refName' + } + + self._ref_name = None + + @property + def ref_name(self): + """ + **[Required]** Gets the ref_name of this DeleteGitRefDetails. + A filter to return only resources that match the given reference name. + + + :return: The ref_name of this DeleteGitRefDetails. + :rtype: str + """ + return self._ref_name + + @ref_name.setter + def ref_name(self, ref_name): + """ + Sets the ref_name of this DeleteGitRefDetails. + A filter to return only resources that match the given reference name. + + + :param ref_name: The ref_name of this DeleteGitRefDetails. + :type: str + """ + self._ref_name = ref_name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/delete_protected_branch_details.py b/src/oci/devops/models/delete_protected_branch_details.py new file mode 100644 index 000000000..d2ac5f225 --- /dev/null +++ b/src/oci/devops/models/delete_protected_branch_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DeleteProtectedBranchDetails(object): + """ + Information to delete a protected branch + """ + + def __init__(self, **kwargs): + """ + Initializes a new DeleteProtectedBranchDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param branch_name: + The value to assign to the branch_name property of this DeleteProtectedBranchDetails. + :type branch_name: str + + """ + self.swagger_types = { + 'branch_name': 'str' + } + + self.attribute_map = { + 'branch_name': 'branchName' + } + + self._branch_name = None + + @property + def branch_name(self): + """ + **[Required]** Gets the branch_name of this DeleteProtectedBranchDetails. + Name of a protected branch. + + + :return: The branch_name of this DeleteProtectedBranchDetails. + :rtype: str + """ + return self._branch_name + + @branch_name.setter + def branch_name(self, branch_name): + """ + Sets the branch_name of this DeleteProtectedBranchDetails. + Name of a protected branch. + + + :param branch_name: The branch_name of this DeleteProtectedBranchDetails. + :type: str + """ + self._branch_name = branch_name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/deploy_artifact_source.py b/src/oci/devops/models/deploy_artifact_source.py index ec63eaf5d..6193c6896 100644 --- a/src/oci/devops/models/deploy_artifact_source.py +++ b/src/oci/devops/models/deploy_artifact_source.py @@ -31,6 +31,10 @@ class DeployArtifactSource(object): #: This constant has a value of "HELM_CHART" DEPLOY_ARTIFACT_SOURCE_TYPE_HELM_CHART = "HELM_CHART" + #: A constant which can be used with the deploy_artifact_source_type property of a DeployArtifactSource. + #: This constant has a value of "HELM_COMMAND_SPEC" + DEPLOY_ARTIFACT_SOURCE_TYPE_HELM_COMMAND_SPEC = "HELM_COMMAND_SPEC" + def __init__(self, **kwargs): """ Initializes a new DeployArtifactSource object with values from keyword arguments. This class has the following subclasses and if you are using this class as input @@ -46,7 +50,7 @@ def __init__(self, **kwargs): :param deploy_artifact_source_type: The value to assign to the deploy_artifact_source_type property of this DeployArtifactSource. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type deploy_artifact_source_type: str @@ -92,7 +96,7 @@ def deploy_artifact_source_type(self): **[Required]** Gets the deploy_artifact_source_type of this DeployArtifactSource. Specifies types of artifact sources. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -111,7 +115,7 @@ def deploy_artifact_source_type(self, deploy_artifact_source_type): :param deploy_artifact_source_type: The deploy_artifact_source_type of this DeployArtifactSource. :type: str """ - allowed_values = ["INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART"] + allowed_values = ["INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC"] if not value_allowed_none_or_none_sentinel(deploy_artifact_source_type, allowed_values): deploy_artifact_source_type = 'UNKNOWN_ENUM_VALUE' self._deploy_artifact_source_type = deploy_artifact_source_type diff --git a/src/oci/devops/models/devops_code_repository_filter.py b/src/oci/devops/models/devops_code_repository_filter.py index af9a569cf..6cdbf944d 100644 --- a/src/oci/devops/models/devops_code_repository_filter.py +++ b/src/oci/devops/models/devops_code_repository_filter.py @@ -19,6 +19,14 @@ class DevopsCodeRepositoryFilter(Filter): #: This constant has a value of "PUSH" EVENTS_PUSH = "PUSH" + #: A constant which can be used with the events property of a DevopsCodeRepositoryFilter. + #: This constant has a value of "PULL_REQUEST_CREATED" + EVENTS_PULL_REQUEST_CREATED = "PULL_REQUEST_CREATED" + + #: A constant which can be used with the events property of a DevopsCodeRepositoryFilter. + #: This constant has a value of "PULL_REQUEST_UPDATED" + EVENTS_PULL_REQUEST_UPDATED = "PULL_REQUEST_UPDATED" + def __init__(self, **kwargs): """ Initializes a new DevopsCodeRepositoryFilter object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.DevopsCodeRepositoryFilter.trigger_source` attribute @@ -31,7 +39,7 @@ def __init__(self, **kwargs): :param events: The value to assign to the events property of this DevopsCodeRepositoryFilter. - Allowed values for items in this list are: "PUSH", 'UNKNOWN_ENUM_VALUE'. + Allowed values for items in this list are: "PUSH", "PULL_REQUEST_CREATED", "PULL_REQUEST_UPDATED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type events: list[str] @@ -70,7 +78,7 @@ def events(self): Gets the events of this DevopsCodeRepositoryFilter. The events, for example, PUSH, PULL_REQUEST_CREATED, PULL_REQUEST_UPDATED. - Allowed values for items in this list are: "PUSH", 'UNKNOWN_ENUM_VALUE'. + Allowed values for items in this list are: "PUSH", "PULL_REQUEST_CREATED", "PULL_REQUEST_UPDATED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -89,7 +97,7 @@ def events(self, events): :param events: The events of this DevopsCodeRepositoryFilter. :type: list[str] """ - allowed_values = ["PUSH"] + allowed_values = ["PUSH", "PULL_REQUEST_CREATED", "PULL_REQUEST_UPDATED"] if events: events[:] = ['UNKNOWN_ENUM_VALUE' if not value_allowed_none_or_none_sentinel(x, allowed_values) else x for x in events] self._events = events diff --git a/src/oci/devops/models/devops_code_repository_filter_attributes.py b/src/oci/devops/models/devops_code_repository_filter_attributes.py index 9fe1258a7..91c0fcf25 100644 --- a/src/oci/devops/models/devops_code_repository_filter_attributes.py +++ b/src/oci/devops/models/devops_code_repository_filter_attributes.py @@ -24,6 +24,10 @@ def __init__(self, **kwargs): The value to assign to the head_ref property of this DevopsCodeRepositoryFilterAttributes. :type head_ref: str + :param base_ref: + The value to assign to the base_ref property of this DevopsCodeRepositoryFilterAttributes. + :type base_ref: str + :param file_filter: The value to assign to the file_filter property of this DevopsCodeRepositoryFilterAttributes. :type file_filter: oci.devops.models.FileFilter @@ -31,15 +35,18 @@ def __init__(self, **kwargs): """ self.swagger_types = { 'head_ref': 'str', + 'base_ref': 'str', 'file_filter': 'FileFilter' } self.attribute_map = { 'head_ref': 'headRef', + 'base_ref': 'baseRef', 'file_filter': 'fileFilter' } self._head_ref = None + self._base_ref = None self._file_filter = None @property @@ -66,6 +73,30 @@ def head_ref(self, head_ref): """ self._head_ref = head_ref + @property + def base_ref(self): + """ + Gets the base_ref of this DevopsCodeRepositoryFilterAttributes. + The target branch for pull requests; not applicable for push requests. + + + :return: The base_ref of this DevopsCodeRepositoryFilterAttributes. + :rtype: str + """ + return self._base_ref + + @base_ref.setter + def base_ref(self, base_ref): + """ + Sets the base_ref of this DevopsCodeRepositoryFilterAttributes. + The target branch for pull requests; not applicable for push requests. + + + :param base_ref: The base_ref of this DevopsCodeRepositoryFilterAttributes. + :type: str + """ + self._base_ref = base_ref + @property def file_filter(self): """ diff --git a/src/oci/devops/models/execute_merge_pull_request_details.py b/src/oci/devops/models/execute_merge_pull_request_details.py new file mode 100644 index 000000000..bcdfe5984 --- /dev/null +++ b/src/oci/devops/models/execute_merge_pull_request_details.py @@ -0,0 +1,196 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .merge_pull_request_details import MergePullRequestDetails +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ExecuteMergePullRequestDetails(MergePullRequestDetails): + """ + The information about the merge. + """ + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "MERGE_COMMIT" + MERGE_STRATEGY_MERGE_COMMIT = "MERGE_COMMIT" + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "FAST_FORWARD" + MERGE_STRATEGY_FAST_FORWARD = "FAST_FORWARD" + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "FAST_FORWARD_ONLY" + MERGE_STRATEGY_FAST_FORWARD_ONLY = "FAST_FORWARD_ONLY" + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "REBASE_AND_MERGE" + MERGE_STRATEGY_REBASE_AND_MERGE = "REBASE_AND_MERGE" + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "REBASE_AND_FAST_FORWARD" + MERGE_STRATEGY_REBASE_AND_FAST_FORWARD = "REBASE_AND_FAST_FORWARD" + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "SQUASH" + MERGE_STRATEGY_SQUASH = "SQUASH" + + #: A constant which can be used with the merge_strategy property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "SQUASH_FAST_FORWARD_ONLY" + MERGE_STRATEGY_SQUASH_FAST_FORWARD_ONLY = "SQUASH_FAST_FORWARD_ONLY" + + #: A constant which can be used with the post_merge_action property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "DELETE_SOURCE_BRANCH" + POST_MERGE_ACTION_DELETE_SOURCE_BRANCH = "DELETE_SOURCE_BRANCH" + + #: A constant which can be used with the post_merge_action property of a ExecuteMergePullRequestDetails. + #: This constant has a value of "KEEP_SOURCE_BRANCH" + POST_MERGE_ACTION_KEEP_SOURCE_BRANCH = "KEEP_SOURCE_BRANCH" + + def __init__(self, **kwargs): + """ + Initializes a new ExecuteMergePullRequestDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ExecuteMergePullRequestDetails.action_type` attribute + of this class is ``EXECUTE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param action_type: + The value to assign to the action_type property of this ExecuteMergePullRequestDetails. + Allowed values for this property are: "EXECUTE", "VALIDATE" + :type action_type: str + + :param commit_message: + The value to assign to the commit_message property of this ExecuteMergePullRequestDetails. + :type commit_message: str + + :param merge_strategy: + The value to assign to the merge_strategy property of this ExecuteMergePullRequestDetails. + Allowed values for this property are: "MERGE_COMMIT", "FAST_FORWARD", "FAST_FORWARD_ONLY", "REBASE_AND_MERGE", "REBASE_AND_FAST_FORWARD", "SQUASH", "SQUASH_FAST_FORWARD_ONLY" + :type merge_strategy: str + + :param post_merge_action: + The value to assign to the post_merge_action property of this ExecuteMergePullRequestDetails. + Allowed values for this property are: "DELETE_SOURCE_BRANCH", "KEEP_SOURCE_BRANCH" + :type post_merge_action: str + + """ + self.swagger_types = { + 'action_type': 'str', + 'commit_message': 'str', + 'merge_strategy': 'str', + 'post_merge_action': 'str' + } + + self.attribute_map = { + 'action_type': 'actionType', + 'commit_message': 'commitMessage', + 'merge_strategy': 'mergeStrategy', + 'post_merge_action': 'postMergeAction' + } + + self._action_type = None + self._commit_message = None + self._merge_strategy = None + self._post_merge_action = None + self._action_type = 'EXECUTE' + + @property + def commit_message(self): + """ + **[Required]** Gets the commit_message of this ExecuteMergePullRequestDetails. + The commit message to be shown for this pull request in the destination branch after merge is done. + + + :return: The commit_message of this ExecuteMergePullRequestDetails. + :rtype: str + """ + return self._commit_message + + @commit_message.setter + def commit_message(self, commit_message): + """ + Sets the commit_message of this ExecuteMergePullRequestDetails. + The commit message to be shown for this pull request in the destination branch after merge is done. + + + :param commit_message: The commit_message of this ExecuteMergePullRequestDetails. + :type: str + """ + self._commit_message = commit_message + + @property + def merge_strategy(self): + """ + **[Required]** Gets the merge_strategy of this ExecuteMergePullRequestDetails. + the strategy of merging. + + Allowed values for this property are: "MERGE_COMMIT", "FAST_FORWARD", "FAST_FORWARD_ONLY", "REBASE_AND_MERGE", "REBASE_AND_FAST_FORWARD", "SQUASH", "SQUASH_FAST_FORWARD_ONLY" + + + :return: The merge_strategy of this ExecuteMergePullRequestDetails. + :rtype: str + """ + return self._merge_strategy + + @merge_strategy.setter + def merge_strategy(self, merge_strategy): + """ + Sets the merge_strategy of this ExecuteMergePullRequestDetails. + the strategy of merging. + + + :param merge_strategy: The merge_strategy of this ExecuteMergePullRequestDetails. + :type: str + """ + allowed_values = ["MERGE_COMMIT", "FAST_FORWARD", "FAST_FORWARD_ONLY", "REBASE_AND_MERGE", "REBASE_AND_FAST_FORWARD", "SQUASH", "SQUASH_FAST_FORWARD_ONLY"] + if not value_allowed_none_or_none_sentinel(merge_strategy, allowed_values): + raise ValueError( + f"Invalid value for `merge_strategy`, must be None or one of {allowed_values}" + ) + self._merge_strategy = merge_strategy + + @property + def post_merge_action(self): + """ + Gets the post_merge_action of this ExecuteMergePullRequestDetails. + What needs to happen after the merge is done successfully. + + Allowed values for this property are: "DELETE_SOURCE_BRANCH", "KEEP_SOURCE_BRANCH" + + + :return: The post_merge_action of this ExecuteMergePullRequestDetails. + :rtype: str + """ + return self._post_merge_action + + @post_merge_action.setter + def post_merge_action(self, post_merge_action): + """ + Sets the post_merge_action of this ExecuteMergePullRequestDetails. + What needs to happen after the merge is done successfully. + + + :param post_merge_action: The post_merge_action of this ExecuteMergePullRequestDetails. + :type: str + """ + allowed_values = ["DELETE_SOURCE_BRANCH", "KEEP_SOURCE_BRANCH"] + if not value_allowed_none_or_none_sentinel(post_merge_action, allowed_values): + raise ValueError( + f"Invalid value for `post_merge_action`, must be None or one of {allowed_values}" + ) + self._post_merge_action = post_merge_action + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/fork_sync_status_collection.py b/src/oci/devops/models/fork_sync_status_collection.py new file mode 100644 index 000000000..7ea019893 --- /dev/null +++ b/src/oci/devops/models/fork_sync_status_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ForkSyncStatusCollection(object): + """ + A collection of Fork Sync Status summaries. + """ + + def __init__(self, **kwargs): + """ + Initializes a new ForkSyncStatusCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this ForkSyncStatusCollection. + :type items: list[oci.devops.models.ForkSyncStatusSummary] + + """ + self.swagger_types = { + 'items': 'list[ForkSyncStatusSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this ForkSyncStatusCollection. + List of fork sync status objects. + + + :return: The items of this ForkSyncStatusCollection. + :rtype: list[oci.devops.models.ForkSyncStatusSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this ForkSyncStatusCollection. + List of fork sync status objects. + + + :param items: The items of this ForkSyncStatusCollection. + :type: list[oci.devops.models.ForkSyncStatusSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/fork_sync_status_summary.py b/src/oci/devops/models/fork_sync_status_summary.py new file mode 100644 index 000000000..7f6e14cde --- /dev/null +++ b/src/oci/devops/models/fork_sync_status_summary.py @@ -0,0 +1,154 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ForkSyncStatusSummary(object): + """ + Object that contains the sync status for a specific branch name. + """ + + #: A constant which can be used with the sync_status property of a ForkSyncStatusSummary. + #: This constant has a value of "IN_SYNC" + SYNC_STATUS_IN_SYNC = "IN_SYNC" + + #: A constant which can be used with the sync_status property of a ForkSyncStatusSummary. + #: This constant has a value of "SYNC_IN_PROGRESS" + SYNC_STATUS_SYNC_IN_PROGRESS = "SYNC_IN_PROGRESS" + + #: A constant which can be used with the sync_status property of a ForkSyncStatusSummary. + #: This constant has a value of "OUT_OF_SYNC" + SYNC_STATUS_OUT_OF_SYNC = "OUT_OF_SYNC" + + def __init__(self, **kwargs): + """ + Initializes a new ForkSyncStatusSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param sync_status: + The value to assign to the sync_status property of this ForkSyncStatusSummary. + Allowed values for this property are: "IN_SYNC", "SYNC_IN_PROGRESS", "OUT_OF_SYNC", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type sync_status: str + + :param repository_id: + The value to assign to the repository_id property of this ForkSyncStatusSummary. + :type repository_id: str + + :param branch_name: + The value to assign to the branch_name property of this ForkSyncStatusSummary. + :type branch_name: str + + """ + self.swagger_types = { + 'sync_status': 'str', + 'repository_id': 'str', + 'branch_name': 'str' + } + + self.attribute_map = { + 'sync_status': 'syncStatus', + 'repository_id': 'repositoryId', + 'branch_name': 'branchName' + } + + self._sync_status = None + self._repository_id = None + self._branch_name = None + + @property + def sync_status(self): + """ + **[Required]** Gets the sync_status of this ForkSyncStatusSummary. + Sync status for the provided branch. + + Allowed values for this property are: "IN_SYNC", "SYNC_IN_PROGRESS", "OUT_OF_SYNC", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The sync_status of this ForkSyncStatusSummary. + :rtype: str + """ + return self._sync_status + + @sync_status.setter + def sync_status(self, sync_status): + """ + Sets the sync_status of this ForkSyncStatusSummary. + Sync status for the provided branch. + + + :param sync_status: The sync_status of this ForkSyncStatusSummary. + :type: str + """ + allowed_values = ["IN_SYNC", "SYNC_IN_PROGRESS", "OUT_OF_SYNC"] + if not value_allowed_none_or_none_sentinel(sync_status, allowed_values): + sync_status = 'UNKNOWN_ENUM_VALUE' + self._sync_status = sync_status + + @property + def repository_id(self): + """ + **[Required]** Gets the repository_id of this ForkSyncStatusSummary. + The OCID of the child repository. + + + :return: The repository_id of this ForkSyncStatusSummary. + :rtype: str + """ + return self._repository_id + + @repository_id.setter + def repository_id(self, repository_id): + """ + Sets the repository_id of this ForkSyncStatusSummary. + The OCID of the child repository. + + + :param repository_id: The repository_id of this ForkSyncStatusSummary. + :type: str + """ + self._repository_id = repository_id + + @property + def branch_name(self): + """ + **[Required]** Gets the branch_name of this ForkSyncStatusSummary. + The branch in the child repository we are checking the sync status of. + + + :return: The branch_name of this ForkSyncStatusSummary. + :rtype: str + """ + return self._branch_name + + @branch_name.setter + def branch_name(self, branch_name): + """ + Sets the branch_name of this ForkSyncStatusSummary. + The branch in the child repository we are checking the sync status of. + + + :param branch_name: The branch_name of this ForkSyncStatusSummary. + :type: str + """ + self._branch_name = branch_name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/generic_artifact_location_details.py b/src/oci/devops/models/generic_artifact_location_details.py new file mode 100644 index 000000000..963a10c6f --- /dev/null +++ b/src/oci/devops/models/generic_artifact_location_details.py @@ -0,0 +1,101 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class GenericArtifactLocationDetails(object): + """ + Location where artifact is uploaded for user access. + """ + + #: A constant which can be used with the storage_type property of a GenericArtifactLocationDetails. + #: This constant has a value of "OBJECT_STORAGE" + STORAGE_TYPE_OBJECT_STORAGE = "OBJECT_STORAGE" + + def __init__(self, **kwargs): + """ + Initializes a new GenericArtifactLocationDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.ObjectStorageGenericArtifactLocationDetails` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param storage_type: + The value to assign to the storage_type property of this GenericArtifactLocationDetails. + Allowed values for this property are: "OBJECT_STORAGE" + :type storage_type: str + + """ + self.swagger_types = { + 'storage_type': 'str' + } + + self.attribute_map = { + 'storage_type': 'storageType' + } + + self._storage_type = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['storageType'] + + if type == 'OBJECT_STORAGE': + return 'ObjectStorageGenericArtifactLocationDetails' + else: + return 'GenericArtifactLocationDetails' + + @property + def storage_type(self): + """ + **[Required]** Gets the storage_type of this GenericArtifactLocationDetails. + Storage source like ObjectStorage, etc. + + Allowed values for this property are: "OBJECT_STORAGE" + + + :return: The storage_type of this GenericArtifactLocationDetails. + :rtype: str + """ + return self._storage_type + + @storage_type.setter + def storage_type(self, storage_type): + """ + Sets the storage_type of this GenericArtifactLocationDetails. + Storage source like ObjectStorage, etc. + + + :param storage_type: The storage_type of this GenericArtifactLocationDetails. + :type: str + """ + allowed_values = ["OBJECT_STORAGE"] + if not value_allowed_none_or_none_sentinel(storage_type, allowed_values): + raise ValueError( + f"Invalid value for `storage_type`, must be None or one of {allowed_values}" + ) + self._storage_type = storage_type + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/generic_artifacts.py b/src/oci/devops/models/generic_artifacts.py new file mode 100644 index 000000000..606a42a0e --- /dev/null +++ b/src/oci/devops/models/generic_artifacts.py @@ -0,0 +1,116 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .stage_output import StageOutput +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class GenericArtifacts(StageOutput): + """ + Details of artifact generated via pipeline run + """ + + def __init__(self, **kwargs): + """ + Initializes a new GenericArtifacts object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.GenericArtifacts.output_type` attribute + of this class is ``ARTIFACT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param output_type: + The value to assign to the output_type property of this GenericArtifacts. + Allowed values for this property are: "ARTIFACT", "TEST_REPORT" + :type output_type: str + + :param step_name: + The value to assign to the step_name property of this GenericArtifacts. + :type step_name: str + + :param name: + The value to assign to the name property of this GenericArtifacts. + :type name: str + + :param location_details: + The value to assign to the location_details property of this GenericArtifacts. + :type location_details: oci.devops.models.GenericArtifactLocationDetails + + """ + self.swagger_types = { + 'output_type': 'str', + 'step_name': 'str', + 'name': 'str', + 'location_details': 'GenericArtifactLocationDetails' + } + + self.attribute_map = { + 'output_type': 'outputType', + 'step_name': 'stepName', + 'name': 'name', + 'location_details': 'locationDetails' + } + + self._output_type = None + self._step_name = None + self._name = None + self._location_details = None + self._output_type = 'ARTIFACT' + + @property + def name(self): + """ + **[Required]** Gets the name of this GenericArtifacts. + Name of artifact. + + + :return: The name of this GenericArtifacts. + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """ + Sets the name of this GenericArtifacts. + Name of artifact. + + + :param name: The name of this GenericArtifacts. + :type: str + """ + self._name = name + + @property + def location_details(self): + """ + **[Required]** Gets the location_details of this GenericArtifacts. + + :return: The location_details of this GenericArtifacts. + :rtype: oci.devops.models.GenericArtifactLocationDetails + """ + return self._location_details + + @location_details.setter + def location_details(self, location_details): + """ + Sets the location_details of this GenericArtifacts. + + :param location_details: The location_details of this GenericArtifacts. + :type: oci.devops.models.GenericArtifactLocationDetails + """ + self._location_details = location_details + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/generic_deploy_artifact_source.py b/src/oci/devops/models/generic_deploy_artifact_source.py index e874a92a2..08f29363e 100644 --- a/src/oci/devops/models/generic_deploy_artifact_source.py +++ b/src/oci/devops/models/generic_deploy_artifact_source.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param deploy_artifact_source_type: The value to assign to the deploy_artifact_source_type property of this GenericDeployArtifactSource. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART" + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC" :type deploy_artifact_source_type: str :param repository_id: diff --git a/src/oci/devops/models/helm_command_spec_artifact_source.py b/src/oci/devops/models/helm_command_spec_artifact_source.py index c9e422ea9..814b69ee0 100644 --- a/src/oci/devops/models/helm_command_spec_artifact_source.py +++ b/src/oci/devops/models/helm_command_spec_artifact_source.py @@ -27,7 +27,7 @@ def __init__(self, **kwargs): :param deploy_artifact_source_type: The value to assign to the deploy_artifact_source_type property of this HelmCommandSpecArtifactSource. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type deploy_artifact_source_type: str diff --git a/src/oci/devops/models/helm_repository_deploy_artifact_source.py b/src/oci/devops/models/helm_repository_deploy_artifact_source.py index 934d77356..3f93d2df6 100644 --- a/src/oci/devops/models/helm_repository_deploy_artifact_source.py +++ b/src/oci/devops/models/helm_repository_deploy_artifact_source.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param deploy_artifact_source_type: The value to assign to the deploy_artifact_source_type property of this HelmRepositoryDeployArtifactSource. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART" + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC" :type deploy_artifact_source_type: str :param chart_url: diff --git a/src/oci/devops/models/inline_deploy_artifact_source.py b/src/oci/devops/models/inline_deploy_artifact_source.py index 3cf2d9eda..bc9fcc72e 100644 --- a/src/oci/devops/models/inline_deploy_artifact_source.py +++ b/src/oci/devops/models/inline_deploy_artifact_source.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param deploy_artifact_source_type: The value to assign to the deploy_artifact_source_type property of this InlineDeployArtifactSource. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART" + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC" :type deploy_artifact_source_type: str :param base64_encoded_content: diff --git a/src/oci/devops/models/merge_check.py b/src/oci/devops/models/merge_check.py new file mode 100644 index 000000000..a2258e72b --- /dev/null +++ b/src/oci/devops/models/merge_check.py @@ -0,0 +1,117 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class MergeCheck(object): + """ + Merge Check summary + """ + + #: A constant which can be used with the type property of a MergeCheck. + #: This constant has a value of "CONFLICT" + TYPE_CONFLICT = "CONFLICT" + + #: A constant which can be used with the type property of a MergeCheck. + #: This constant has a value of "APPROVAL_RULE" + TYPE_APPROVAL_RULE = "APPROVAL_RULE" + + #: A constant which can be used with the type property of a MergeCheck. + #: This constant has a value of "BUILD" + TYPE_BUILD = "BUILD" + + def __init__(self, **kwargs): + """ + Initializes a new MergeCheck object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.BuildMergeCheck` + * :class:`~oci.devops.models.ConflictMergeCheck` + * :class:`~oci.devops.models.ApprovalRuleMergeCheck` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param type: + The value to assign to the type property of this MergeCheck. + Allowed values for this property are: "CONFLICT", "APPROVAL_RULE", "BUILD", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type type: str + + """ + self.swagger_types = { + 'type': 'str' + } + + self.attribute_map = { + 'type': 'type' + } + + self._type = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['type'] + + if type == 'BUILD': + return 'BuildMergeCheck' + + if type == 'CONFLICT': + return 'ConflictMergeCheck' + + if type == 'APPROVAL_RULE': + return 'ApprovalRuleMergeCheck' + else: + return 'MergeCheck' + + @property + def type(self): + """ + **[Required]** Gets the type of this MergeCheck. + the type of this merge check. + + Allowed values for this property are: "CONFLICT", "APPROVAL_RULE", "BUILD", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The type of this MergeCheck. + :rtype: str + """ + return self._type + + @type.setter + def type(self, type): + """ + Sets the type of this MergeCheck. + the type of this merge check. + + + :param type: The type of this MergeCheck. + :type: str + """ + allowed_values = ["CONFLICT", "APPROVAL_RULE", "BUILD"] + if not value_allowed_none_or_none_sentinel(type, allowed_values): + type = 'UNKNOWN_ENUM_VALUE' + self._type = type + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/merge_check_collection.py b/src/oci/devops/models/merge_check_collection.py new file mode 100644 index 000000000..c458b47d3 --- /dev/null +++ b/src/oci/devops/models/merge_check_collection.py @@ -0,0 +1,145 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class MergeCheckCollection(object): + """ + list of merge checks. + """ + + def __init__(self, **kwargs): + """ + Initializes a new MergeCheckCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this MergeCheckCollection. + :type items: list[oci.devops.models.MergeCheck] + + :param time_validated: + The value to assign to the time_validated property of this MergeCheckCollection. + :type time_validated: datetime + + """ + self.swagger_types = { + 'items': 'list[MergeCheck]', + 'time_validated': 'datetime' + } + + self.attribute_map = { + 'items': 'items', + 'time_validated': 'timeValidated' + } + + self._items = None + self._time_validated = None + + @property + def items(self): + """ + Gets the items of this MergeCheckCollection. + List of pullRequest mergeCheck objects. + Example: {\"items\": [{ \"type\" : \"CONFLICT(ENUM values)\", + \"status\" : \"FAILED(ENUM values)\"}, + {\"type\": \"APPROVAL_RULE(ENUM VALUE)\", + \"ruleName\": \"rule 1\", + \"status\" : \"NEEDS_APPROVAL(ENUM values)\", + \"totalApprovalCount\":\"5\", + \"currentApprovalCount\":\"1\", + \"reviewers\":[], + \"level\": \"PROJECT/REPOSITORY(ENUM values)\"}, + {\"type\": \"APPROVAL_RULE(ENUM VALUE)\", + \"ruleName\": \"rule 2\", + \"status\" : \"SUCCEEDED(ENUM values)\", + \"totalApprovalCount\":\"5\", + \"currentApprovalCount\":\"5\", + \"reviewers\":[], + \"level\": \"PROJECT/REPOSITORY(ENUM values)\"} , + {\"type\": \"BUILD(ENUM VALUE)\", + \"pipelineId\": \"PipelineOCID\", + \"buildRunId\": \"BuildRunOCID\", + \"status\" : \"SUCCEEDED/PENDING/FAIlED/IN-PROGRESS(ENUM values)\"} + ]} + + + :return: The items of this MergeCheckCollection. + :rtype: list[oci.devops.models.MergeCheck] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this MergeCheckCollection. + List of pullRequest mergeCheck objects. + Example: {\"items\": [{ \"type\" : \"CONFLICT(ENUM values)\", + \"status\" : \"FAILED(ENUM values)\"}, + {\"type\": \"APPROVAL_RULE(ENUM VALUE)\", + \"ruleName\": \"rule 1\", + \"status\" : \"NEEDS_APPROVAL(ENUM values)\", + \"totalApprovalCount\":\"5\", + \"currentApprovalCount\":\"1\", + \"reviewers\":[], + \"level\": \"PROJECT/REPOSITORY(ENUM values)\"}, + {\"type\": \"APPROVAL_RULE(ENUM VALUE)\", + \"ruleName\": \"rule 2\", + \"status\" : \"SUCCEEDED(ENUM values)\", + \"totalApprovalCount\":\"5\", + \"currentApprovalCount\":\"5\", + \"reviewers\":[], + \"level\": \"PROJECT/REPOSITORY(ENUM values)\"} , + {\"type\": \"BUILD(ENUM VALUE)\", + \"pipelineId\": \"PipelineOCID\", + \"buildRunId\": \"BuildRunOCID\", + \"status\" : \"SUCCEEDED/PENDING/FAIlED/IN-PROGRESS(ENUM values)\"} + ]} + + + :param items: The items of this MergeCheckCollection. + :type: list[oci.devops.models.MergeCheck] + """ + self._items = items + + @property + def time_validated(self): + """ + Gets the time_validated of this MergeCheckCollection. + The time Stamp of the validation check. + + + :return: The time_validated of this MergeCheckCollection. + :rtype: datetime + """ + return self._time_validated + + @time_validated.setter + def time_validated(self, time_validated): + """ + Sets the time_validated of this MergeCheckCollection. + The time Stamp of the validation check. + + + :param time_validated: The time_validated of this MergeCheckCollection. + :type: datetime + """ + self._time_validated = time_validated + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/merge_checks.py b/src/oci/devops/models/merge_checks.py new file mode 100644 index 000000000..d623f771a --- /dev/null +++ b/src/oci/devops/models/merge_checks.py @@ -0,0 +1,88 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class MergeChecks(object): + """ + Criteria which must be satisfied to merge a pull request. + """ + + #: A constant which can be used with the last_build_succeeded property of a MergeChecks. + #: This constant has a value of "ENABLED" + LAST_BUILD_SUCCEEDED_ENABLED = "ENABLED" + + #: A constant which can be used with the last_build_succeeded property of a MergeChecks. + #: This constant has a value of "DISABLED" + LAST_BUILD_SUCCEEDED_DISABLED = "DISABLED" + + def __init__(self, **kwargs): + """ + Initializes a new MergeChecks object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param last_build_succeeded: + The value to assign to the last_build_succeeded property of this MergeChecks. + Allowed values for this property are: "ENABLED", "DISABLED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type last_build_succeeded: str + + """ + self.swagger_types = { + 'last_build_succeeded': 'str' + } + + self.attribute_map = { + 'last_build_succeeded': 'lastBuildSucceeded' + } + + self._last_build_succeeded = None + + @property + def last_build_succeeded(self): + """ + **[Required]** Gets the last_build_succeeded of this MergeChecks. + Indicates whether or not a pull request must have a successful build run and no queued builds before it can be merged + + Allowed values for this property are: "ENABLED", "DISABLED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The last_build_succeeded of this MergeChecks. + :rtype: str + """ + return self._last_build_succeeded + + @last_build_succeeded.setter + def last_build_succeeded(self, last_build_succeeded): + """ + Sets the last_build_succeeded of this MergeChecks. + Indicates whether or not a pull request must have a successful build run and no queued builds before it can be merged + + + :param last_build_succeeded: The last_build_succeeded of this MergeChecks. + :type: str + """ + allowed_values = ["ENABLED", "DISABLED"] + if not value_allowed_none_or_none_sentinel(last_build_succeeded, allowed_values): + last_build_succeeded = 'UNKNOWN_ENUM_VALUE' + self._last_build_succeeded = last_build_succeeded + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/merge_pull_request_details.py b/src/oci/devops/models/merge_pull_request_details.py new file mode 100644 index 000000000..6d26bdb2c --- /dev/null +++ b/src/oci/devops/models/merge_pull_request_details.py @@ -0,0 +1,109 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class MergePullRequestDetails(object): + """ + determines if this is a merge or a validation. + """ + + #: A constant which can be used with the action_type property of a MergePullRequestDetails. + #: This constant has a value of "EXECUTE" + ACTION_TYPE_EXECUTE = "EXECUTE" + + #: A constant which can be used with the action_type property of a MergePullRequestDetails. + #: This constant has a value of "VALIDATE" + ACTION_TYPE_VALIDATE = "VALIDATE" + + def __init__(self, **kwargs): + """ + Initializes a new MergePullRequestDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.ExecuteMergePullRequestDetails` + * :class:`~oci.devops.models.ValidateMergePullRequestDetails` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param action_type: + The value to assign to the action_type property of this MergePullRequestDetails. + Allowed values for this property are: "EXECUTE", "VALIDATE" + :type action_type: str + + """ + self.swagger_types = { + 'action_type': 'str' + } + + self.attribute_map = { + 'action_type': 'actionType' + } + + self._action_type = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['actionType'] + + if type == 'EXECUTE': + return 'ExecuteMergePullRequestDetails' + + if type == 'VALIDATE': + return 'ValidateMergePullRequestDetails' + else: + return 'MergePullRequestDetails' + + @property + def action_type(self): + """ + **[Required]** Gets the action_type of this MergePullRequestDetails. + the type of action for this merge. + + Allowed values for this property are: "EXECUTE", "VALIDATE" + + + :return: The action_type of this MergePullRequestDetails. + :rtype: str + """ + return self._action_type + + @action_type.setter + def action_type(self, action_type): + """ + Sets the action_type of this MergePullRequestDetails. + the type of action for this merge. + + + :param action_type: The action_type of this MergePullRequestDetails. + :type: str + """ + allowed_values = ["EXECUTE", "VALIDATE"] + if not value_allowed_none_or_none_sentinel(action_type, allowed_values): + raise ValueError( + f"Invalid value for `action_type`, must be None or one of {allowed_values}" + ) + self._action_type = action_type + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/merge_settings.py b/src/oci/devops/models/merge_settings.py new file mode 100644 index 000000000..273f5c81e --- /dev/null +++ b/src/oci/devops/models/merge_settings.py @@ -0,0 +1,139 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class MergeSettings(object): + """ + Enabled and disabled merge strategies for a project or repository, also contains a default strategy. + """ + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "MERGE_COMMIT" + DEFAULT_MERGE_STRATEGY_MERGE_COMMIT = "MERGE_COMMIT" + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "FAST_FORWARD" + DEFAULT_MERGE_STRATEGY_FAST_FORWARD = "FAST_FORWARD" + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "FAST_FORWARD_ONLY" + DEFAULT_MERGE_STRATEGY_FAST_FORWARD_ONLY = "FAST_FORWARD_ONLY" + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "REBASE_AND_MERGE" + DEFAULT_MERGE_STRATEGY_REBASE_AND_MERGE = "REBASE_AND_MERGE" + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "REBASE_AND_FAST_FORWARD" + DEFAULT_MERGE_STRATEGY_REBASE_AND_FAST_FORWARD = "REBASE_AND_FAST_FORWARD" + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "SQUASH" + DEFAULT_MERGE_STRATEGY_SQUASH = "SQUASH" + + #: A constant which can be used with the default_merge_strategy property of a MergeSettings. + #: This constant has a value of "SQUASH_FAST_FORWARD_ONLY" + DEFAULT_MERGE_STRATEGY_SQUASH_FAST_FORWARD_ONLY = "SQUASH_FAST_FORWARD_ONLY" + + def __init__(self, **kwargs): + """ + Initializes a new MergeSettings object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param default_merge_strategy: + The value to assign to the default_merge_strategy property of this MergeSettings. + Allowed values for this property are: "MERGE_COMMIT", "FAST_FORWARD", "FAST_FORWARD_ONLY", "REBASE_AND_MERGE", "REBASE_AND_FAST_FORWARD", "SQUASH", "SQUASH_FAST_FORWARD_ONLY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type default_merge_strategy: str + + :param allowed_merge_strategies: + The value to assign to the allowed_merge_strategies property of this MergeSettings. + :type allowed_merge_strategies: list[oci.devops.models.MergeStrategy] + + """ + self.swagger_types = { + 'default_merge_strategy': 'str', + 'allowed_merge_strategies': 'list[MergeStrategy]' + } + + self.attribute_map = { + 'default_merge_strategy': 'defaultMergeStrategy', + 'allowed_merge_strategies': 'allowedMergeStrategies' + } + + self._default_merge_strategy = None + self._allowed_merge_strategies = None + + @property + def default_merge_strategy(self): + """ + **[Required]** Gets the default_merge_strategy of this MergeSettings. + Default type of merge strategy associated with the a Project or Repository. + + Allowed values for this property are: "MERGE_COMMIT", "FAST_FORWARD", "FAST_FORWARD_ONLY", "REBASE_AND_MERGE", "REBASE_AND_FAST_FORWARD", "SQUASH", "SQUASH_FAST_FORWARD_ONLY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The default_merge_strategy of this MergeSettings. + :rtype: str + """ + return self._default_merge_strategy + + @default_merge_strategy.setter + def default_merge_strategy(self, default_merge_strategy): + """ + Sets the default_merge_strategy of this MergeSettings. + Default type of merge strategy associated with the a Project or Repository. + + + :param default_merge_strategy: The default_merge_strategy of this MergeSettings. + :type: str + """ + allowed_values = ["MERGE_COMMIT", "FAST_FORWARD", "FAST_FORWARD_ONLY", "REBASE_AND_MERGE", "REBASE_AND_FAST_FORWARD", "SQUASH", "SQUASH_FAST_FORWARD_ONLY"] + if not value_allowed_none_or_none_sentinel(default_merge_strategy, allowed_values): + default_merge_strategy = 'UNKNOWN_ENUM_VALUE' + self._default_merge_strategy = default_merge_strategy + + @property + def allowed_merge_strategies(self): + """ + **[Required]** Gets the allowed_merge_strategies of this MergeSettings. + List of merge strategies which are allowed for a Project or Repository. + + + :return: The allowed_merge_strategies of this MergeSettings. + :rtype: list[oci.devops.models.MergeStrategy] + """ + return self._allowed_merge_strategies + + @allowed_merge_strategies.setter + def allowed_merge_strategies(self, allowed_merge_strategies): + """ + Sets the allowed_merge_strategies of this MergeSettings. + List of merge strategies which are allowed for a Project or Repository. + + + :param allowed_merge_strategies: The allowed_merge_strategies of this MergeSettings. + :type: list[oci.devops.models.MergeStrategy] + """ + self._allowed_merge_strategies = allowed_merge_strategies + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/mirror_repository_config.py b/src/oci/devops/models/mirror_repository_config.py index 11eb0d83e..f8bf77c70 100644 --- a/src/oci/devops/models/mirror_repository_config.py +++ b/src/oci/devops/models/mirror_repository_config.py @@ -53,7 +53,7 @@ def __init__(self, **kwargs): def connector_id(self): """ Gets the connector_id of this MirrorRepositoryConfig. - Upstream git repository connection identifer. + Upstream git repository connection identifier. :return: The connector_id of this MirrorRepositoryConfig. @@ -65,7 +65,7 @@ def connector_id(self): def connector_id(self, connector_id): """ Sets the connector_id of this MirrorRepositoryConfig. - Upstream git repository connection identifer. + Upstream git repository connection identifier. :param connector_id: The connector_id of this MirrorRepositoryConfig. diff --git a/src/oci/devops/models/object_storage_generic_artifact_location_details.py b/src/oci/devops/models/object_storage_generic_artifact_location_details.py new file mode 100644 index 000000000..6c367ff88 --- /dev/null +++ b/src/oci/devops/models/object_storage_generic_artifact_location_details.py @@ -0,0 +1,175 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .generic_artifact_location_details import GenericArtifactLocationDetails +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ObjectStorageGenericArtifactLocationDetails(GenericArtifactLocationDetails): + """ + ObjectStorage bucket details where artifact is located. + """ + + def __init__(self, **kwargs): + """ + Initializes a new ObjectStorageGenericArtifactLocationDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ObjectStorageGenericArtifactLocationDetails.storage_type` attribute + of this class is ``OBJECT_STORAGE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param storage_type: + The value to assign to the storage_type property of this ObjectStorageGenericArtifactLocationDetails. + Allowed values for this property are: "OBJECT_STORAGE" + :type storage_type: str + + :param namespace: + The value to assign to the namespace property of this ObjectStorageGenericArtifactLocationDetails. + :type namespace: str + + :param bucket_name: + The value to assign to the bucket_name property of this ObjectStorageGenericArtifactLocationDetails. + :type bucket_name: str + + :param object_name: + The value to assign to the object_name property of this ObjectStorageGenericArtifactLocationDetails. + :type object_name: str + + :param region: + The value to assign to the region property of this ObjectStorageGenericArtifactLocationDetails. + :type region: str + + """ + self.swagger_types = { + 'storage_type': 'str', + 'namespace': 'str', + 'bucket_name': 'str', + 'object_name': 'str', + 'region': 'str' + } + + self.attribute_map = { + 'storage_type': 'storageType', + 'namespace': 'namespace', + 'bucket_name': 'bucketName', + 'object_name': 'objectName', + 'region': 'region' + } + + self._storage_type = None + self._namespace = None + self._bucket_name = None + self._object_name = None + self._region = None + self._storage_type = 'OBJECT_STORAGE' + + @property + def namespace(self): + """ + **[Required]** Gets the namespace of this ObjectStorageGenericArtifactLocationDetails. + Unique namespace in the tenancy which contains the bucket + + + :return: The namespace of this ObjectStorageGenericArtifactLocationDetails. + :rtype: str + """ + return self._namespace + + @namespace.setter + def namespace(self, namespace): + """ + Sets the namespace of this ObjectStorageGenericArtifactLocationDetails. + Unique namespace in the tenancy which contains the bucket + + + :param namespace: The namespace of this ObjectStorageGenericArtifactLocationDetails. + :type: str + """ + self._namespace = namespace + + @property + def bucket_name(self): + """ + **[Required]** Gets the bucket_name of this ObjectStorageGenericArtifactLocationDetails. + Specifies the Object Storage bucket. + + + :return: The bucket_name of this ObjectStorageGenericArtifactLocationDetails. + :rtype: str + """ + return self._bucket_name + + @bucket_name.setter + def bucket_name(self, bucket_name): + """ + Sets the bucket_name of this ObjectStorageGenericArtifactLocationDetails. + Specifies the Object Storage bucket. + + + :param bucket_name: The bucket_name of this ObjectStorageGenericArtifactLocationDetails. + :type: str + """ + self._bucket_name = bucket_name + + @property + def object_name(self): + """ + **[Required]** Gets the object_name of this ObjectStorageGenericArtifactLocationDetails. + Specifies the name of object inside the bucket. + + + :return: The object_name of this ObjectStorageGenericArtifactLocationDetails. + :rtype: str + """ + return self._object_name + + @object_name.setter + def object_name(self, object_name): + """ + Sets the object_name of this ObjectStorageGenericArtifactLocationDetails. + Specifies the name of object inside the bucket. + + + :param object_name: The object_name of this ObjectStorageGenericArtifactLocationDetails. + :type: str + """ + self._object_name = object_name + + @property + def region(self): + """ + **[Required]** Gets the region of this ObjectStorageGenericArtifactLocationDetails. + Region identifier. + + + :return: The region of this ObjectStorageGenericArtifactLocationDetails. + :rtype: str + """ + return self._region + + @region.setter + def region(self, region): + """ + Sets the region of this ObjectStorageGenericArtifactLocationDetails. + Region identifier. + + + :param region: The region of this ObjectStorageGenericArtifactLocationDetails. + :type: str + """ + self._region = region + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/ocir_deploy_artifact_source.py b/src/oci/devops/models/ocir_deploy_artifact_source.py index bfdb108dc..5b1e7861a 100644 --- a/src/oci/devops/models/ocir_deploy_artifact_source.py +++ b/src/oci/devops/models/ocir_deploy_artifact_source.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param deploy_artifact_source_type: The value to assign to the deploy_artifact_source_type property of this OcirDeployArtifactSource. - Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART" + Allowed values for this property are: "INLINE", "OCIR", "GENERIC_ARTIFACT", "HELM_CHART", "HELM_COMMAND_SPEC" :type deploy_artifact_source_type: str :param image_uri: diff --git a/src/oci/devops/models/patch_insert_instruction.py b/src/oci/devops/models/patch_insert_instruction.py new file mode 100644 index 000000000..a3ff4b8e6 --- /dev/null +++ b/src/oci/devops/models/patch_insert_instruction.py @@ -0,0 +1,171 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchInsertInstruction(PatchInstruction): + """ + An operation that inserts a value into an array, shifting array items as necessary and handling NOT_FOUND exceptions by creating the implied containing structure. + """ + + #: A constant which can be used with the position property of a PatchInsertInstruction. + #: This constant has a value of "BEFORE" + POSITION_BEFORE = "BEFORE" + + #: A constant which can be used with the position property of a PatchInsertInstruction. + #: This constant has a value of "AFTER" + POSITION_AFTER = "AFTER" + + def __init__(self, **kwargs): + """ + Initializes a new PatchInsertInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchInsertInstruction.operation` attribute + of this class is ``INSERT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchInsertInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchInsertInstruction. + :type selection: str + + :param value: + The value to assign to the value property of this PatchInsertInstruction. + :type value: object + + :param selected_item: + The value to assign to the selected_item property of this PatchInsertInstruction. + :type selected_item: str + + :param position: + The value to assign to the position property of this PatchInsertInstruction. + Allowed values for this property are: "BEFORE", "AFTER" + :type position: str + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str', + 'value': 'object', + 'selected_item': 'str', + 'position': 'str' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection', + 'value': 'value', + 'selected_item': 'selectedItem', + 'position': 'position' + } + + self._operation = None + self._selection = None + self._value = None + self._selected_item = None + self._position = None + self._operation = 'INSERT' + + @property + def value(self): + """ + **[Required]** Gets the value of this PatchInsertInstruction. + A value to be inserted into the target. + + + :return: The value of this PatchInsertInstruction. + :rtype: object + """ + return self._value + + @value.setter + def value(self, value): + """ + Sets the value of this PatchInsertInstruction. + A value to be inserted into the target. + + + :param value: The value of this PatchInsertInstruction. + :type: object + """ + self._value = value + + @property + def selected_item(self): + """ + Gets the selected_item of this PatchInsertInstruction. + A selection to be evaluated against the array for identifying a particular reference item within it, with the same format and semantics as `selection`. + + + :return: The selected_item of this PatchInsertInstruction. + :rtype: str + """ + return self._selected_item + + @selected_item.setter + def selected_item(self, selected_item): + """ + Sets the selected_item of this PatchInsertInstruction. + A selection to be evaluated against the array for identifying a particular reference item within it, with the same format and semantics as `selection`. + + + :param selected_item: The selected_item of this PatchInsertInstruction. + :type: str + """ + self._selected_item = selected_item + + @property + def position(self): + """ + Gets the position of this PatchInsertInstruction. + Where to insert the value, relative to the first item matched by `selectedItem`. + If `selectedItem` is unspecified, then \"BEFORE\" specifies insertion at the first position in an array and \"AFTER\" specifies insertion at the last position. + If `selectedItem` is specified but results in an empty selection, then both values specify insertion at the last position. + + Allowed values for this property are: "BEFORE", "AFTER" + + + :return: The position of this PatchInsertInstruction. + :rtype: str + """ + return self._position + + @position.setter + def position(self, position): + """ + Sets the position of this PatchInsertInstruction. + Where to insert the value, relative to the first item matched by `selectedItem`. + If `selectedItem` is unspecified, then \"BEFORE\" specifies insertion at the first position in an array and \"AFTER\" specifies insertion at the last position. + If `selectedItem` is specified but results in an empty selection, then both values specify insertion at the last position. + + + :param position: The position of this PatchInsertInstruction. + :type: str + """ + allowed_values = ["BEFORE", "AFTER"] + if not value_allowed_none_or_none_sentinel(position, allowed_values): + raise ValueError( + f"Invalid value for `position`, must be None or one of {allowed_values}" + ) + self._position = position + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_instruction.py b/src/oci/devops/models/patch_instruction.py new file mode 100644 index 000000000..658dbf2b6 --- /dev/null +++ b/src/oci/devops/models/patch_instruction.py @@ -0,0 +1,184 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchInstruction(object): + """ + A single instruction to be included as part of Patch request content. + """ + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "REQUIRE" + OPERATION_REQUIRE = "REQUIRE" + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "PROHIBIT" + OPERATION_PROHIBIT = "PROHIBIT" + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "REPLACE" + OPERATION_REPLACE = "REPLACE" + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "INSERT" + OPERATION_INSERT = "INSERT" + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "REMOVE" + OPERATION_REMOVE = "REMOVE" + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "MOVE" + OPERATION_MOVE = "MOVE" + + #: A constant which can be used with the operation property of a PatchInstruction. + #: This constant has a value of "MERGE" + OPERATION_MERGE = "MERGE" + + def __init__(self, **kwargs): + """ + Initializes a new PatchInstruction object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.PatchMoveInstruction` + * :class:`~oci.devops.models.PatchRemoveInstruction` + * :class:`~oci.devops.models.PatchReplaceInstruction` + * :class:`~oci.devops.models.PatchInsertInstruction` + * :class:`~oci.devops.models.PatchRequireInstruction` + * :class:`~oci.devops.models.PatchMergeInstruction` + * :class:`~oci.devops.models.PatchProhibitInstruction` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchInstruction. + :type selection: str + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection' + } + + self._operation = None + self._selection = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['operation'] + + if type == 'MOVE': + return 'PatchMoveInstruction' + + if type == 'REMOVE': + return 'PatchRemoveInstruction' + + if type == 'REPLACE': + return 'PatchReplaceInstruction' + + if type == 'INSERT': + return 'PatchInsertInstruction' + + if type == 'REQUIRE': + return 'PatchRequireInstruction' + + if type == 'MERGE': + return 'PatchMergeInstruction' + + if type == 'PROHIBIT': + return 'PatchProhibitInstruction' + else: + return 'PatchInstruction' + + @property + def operation(self): + """ + **[Required]** Gets the operation of this PatchInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + + + :return: The operation of this PatchInstruction. + :rtype: str + """ + return self._operation + + @operation.setter + def operation(self, operation): + """ + Sets the operation of this PatchInstruction. + + :param operation: The operation of this PatchInstruction. + :type: str + """ + allowed_values = ["REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE"] + if not value_allowed_none_or_none_sentinel(operation, allowed_values): + raise ValueError( + f"Invalid value for `operation`, must be None or one of {allowed_values}" + ) + self._operation = operation + + @property + def selection(self): + """ + **[Required]** Gets the selection of this PatchInstruction. + The set of values to which the operation applies as a `JMESPath expression`__ for evaluation against the context resource. + An operation fails if the selection yields an exception, except as otherwise specified. + Note that comparisons involving non-primitive values (objects or arrays) are not supported and will always evaluate to false. + + __ https://jmespath.org/specification.html + + + :return: The selection of this PatchInstruction. + :rtype: str + """ + return self._selection + + @selection.setter + def selection(self, selection): + """ + Sets the selection of this PatchInstruction. + The set of values to which the operation applies as a `JMESPath expression`__ for evaluation against the context resource. + An operation fails if the selection yields an exception, except as otherwise specified. + Note that comparisons involving non-primitive values (objects or arrays) are not supported and will always evaluate to false. + + __ https://jmespath.org/specification.html + + + :param selection: The selection of this PatchInstruction. + :type: str + """ + self._selection = selection + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_merge_instruction.py b/src/oci/devops/models/patch_merge_instruction.py new file mode 100644 index 000000000..f10a688a7 --- /dev/null +++ b/src/oci/devops/models/patch_merge_instruction.py @@ -0,0 +1,97 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchMergeInstruction(PatchInstruction): + """ + An operation that recursively updates items of the selection, or adding the value if the selection is empty. + If the value is not an object, it is used directly, otherwise each key-value member is used + to create or update a member of the same name in the target and the same process is applied recursively for each object-typed value + (similar to `RFC 7396`__ JSON Merge Patch, except that null values are copied + rather than transformed into deletions). + NOT_FOUND exceptions are handled by creating the implied containing structure. + To avoid referential errors if an item's descendant is also in the selection, items of the selection are processed in order of decreasing depth. + + __ https://tools.ietf.org/html/rfc7396#section-2 + """ + + def __init__(self, **kwargs): + """ + Initializes a new PatchMergeInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchMergeInstruction.operation` attribute + of this class is ``MERGE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchMergeInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchMergeInstruction. + :type selection: str + + :param value: + The value to assign to the value property of this PatchMergeInstruction. + :type value: object + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str', + 'value': 'object' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection', + 'value': 'value' + } + + self._operation = None + self._selection = None + self._value = None + self._operation = 'MERGE' + + @property + def value(self): + """ + Gets the value of this PatchMergeInstruction. + A value to be merged into the target. + + + :return: The value of this PatchMergeInstruction. + :rtype: object + """ + return self._value + + @value.setter + def value(self, value): + """ + Sets the value of this PatchMergeInstruction. + A value to be merged into the target. + + + :param value: The value of this PatchMergeInstruction. + :type: object + """ + self._value = value + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_move_instruction.py b/src/oci/devops/models/patch_move_instruction.py new file mode 100644 index 000000000..d2920482b --- /dev/null +++ b/src/oci/devops/models/patch_move_instruction.py @@ -0,0 +1,147 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchMoveInstruction(PatchInstruction): + """ + An operation that \"puts\" values from elsewhere in the target, functionally equivalent to a single add and then a remove. + The first item of the selection is replaced, or created if the selection is empty. + NOT_FOUND exceptions in the selection are handled by creating the implied containing structure. + This operation fails if the `from` selection yields any exceptions, or if an item is moved to any of its descendants. + """ + + #: A constant which can be used with the position property of a PatchMoveInstruction. + #: This constant has a value of "AT" + POSITION_AT = "AT" + + #: A constant which can be used with the position property of a PatchMoveInstruction. + #: This constant has a value of "BEFORE" + POSITION_BEFORE = "BEFORE" + + #: A constant which can be used with the position property of a PatchMoveInstruction. + #: This constant has a value of "AFTER" + POSITION_AFTER = "AFTER" + + def __init__(self, **kwargs): + """ + Initializes a new PatchMoveInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchMoveInstruction.operation` attribute + of this class is ``MOVE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchMoveInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchMoveInstruction. + :type selection: str + + :param _from: + The value to assign to the _from property of this PatchMoveInstruction. + :type _from: str + + :param position: + The value to assign to the position property of this PatchMoveInstruction. + Allowed values for this property are: "AT", "BEFORE", "AFTER" + :type position: str + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str', + '_from': 'str', + 'position': 'str' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection', + '_from': 'from', + 'position': 'position' + } + + self._operation = None + self._selection = None + self.__from = None + self._position = None + self._operation = 'MOVE' + + @property + def _from(self): + """ + **[Required]** Gets the _from of this PatchMoveInstruction. + The selection that is to be moved, with the same format and semantics as `selection`. + + + :return: The _from of this PatchMoveInstruction. + :rtype: str + """ + return self.__from + + @_from.setter + def _from(self, _from): + """ + Sets the _from of this PatchMoveInstruction. + The selection that is to be moved, with the same format and semantics as `selection`. + + + :param _from: The _from of this PatchMoveInstruction. + :type: str + """ + self.__from = _from + + @property + def position(self): + """ + Gets the position of this PatchMoveInstruction. + Where to insert the value in an array, relative to the first item in the selection. + If there is no such item, then \"BEFORE\" specifies insertion at the first position in an array and \"AFTER\" specifies insertion at the last position. + If the first item in the selection is not the child of an array, then this field has no effect. + + Allowed values for this property are: "AT", "BEFORE", "AFTER" + + + :return: The position of this PatchMoveInstruction. + :rtype: str + """ + return self._position + + @position.setter + def position(self, position): + """ + Sets the position of this PatchMoveInstruction. + Where to insert the value in an array, relative to the first item in the selection. + If there is no such item, then \"BEFORE\" specifies insertion at the first position in an array and \"AFTER\" specifies insertion at the last position. + If the first item in the selection is not the child of an array, then this field has no effect. + + + :param position: The position of this PatchMoveInstruction. + :type: str + """ + allowed_values = ["AT", "BEFORE", "AFTER"] + if not value_allowed_none_or_none_sentinel(position, allowed_values): + raise ValueError( + f"Invalid value for `position`, must be None or one of {allowed_values}" + ) + self._position = position + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_prohibit_instruction.py b/src/oci/devops/models/patch_prohibit_instruction.py new file mode 100644 index 000000000..e7ea21863 --- /dev/null +++ b/src/oci/devops/models/patch_prohibit_instruction.py @@ -0,0 +1,100 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchProhibitInstruction(PatchInstruction): + """ + A precondition operation that requires a selection to be empty, or optionally to be non-empty but include no item with a specified value + (useful for asserting that a value does not exist before attempting to create it, avoiding accidental update). + It fails if value is provided and the selection includes an item matching it, or if value is not provided and the selection is not empty, + but ignores NOT_FOUND exceptions. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PatchProhibitInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchProhibitInstruction.operation` attribute + of this class is ``PROHIBIT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchProhibitInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchProhibitInstruction. + :type selection: str + + :param value: + The value to assign to the value property of this PatchProhibitInstruction. + :type value: object + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str', + 'value': 'object' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection', + 'value': 'value' + } + + self._operation = None + self._selection = None + self._value = None + self._operation = 'PROHIBIT' + + @property + def value(self): + """ + Gets the value of this PatchProhibitInstruction. + A value to be compared against each item of the selection. + If this value is an object, then it matches any item that would be unaffected by applying this value as a merge operation. + Otherwise, it matches any item to which it is equal according to the rules of `JSON Schema`__. + + __ https://tools.ietf.org/html/draft-handrews-json-schema-00#section-4.2.3 + + + :return: The value of this PatchProhibitInstruction. + :rtype: object + """ + return self._value + + @value.setter + def value(self, value): + """ + Sets the value of this PatchProhibitInstruction. + A value to be compared against each item of the selection. + If this value is an object, then it matches any item that would be unaffected by applying this value as a merge operation. + Otherwise, it matches any item to which it is equal according to the rules of `JSON Schema`__. + + __ https://tools.ietf.org/html/draft-handrews-json-schema-00#section-4.2.3 + + + :param value: The value of this PatchProhibitInstruction. + :type: object + """ + self._value = value + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_pull_request_details.py b/src/oci/devops/models/patch_pull_request_details.py new file mode 100644 index 000000000..9bf66b372 --- /dev/null +++ b/src/oci/devops/models/patch_pull_request_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchPullRequestDetails(object): + """ + Pull request details to patch + """ + + def __init__(self, **kwargs): + """ + Initializes a new PatchPullRequestDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PatchPullRequestDetails. + :type items: list[oci.devops.models.PatchInstruction] + + """ + self.swagger_types = { + 'items': 'list[PatchInstruction]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + Gets the items of this PatchPullRequestDetails. + List of patch instructions + + + :return: The items of this PatchPullRequestDetails. + :rtype: list[oci.devops.models.PatchInstruction] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PatchPullRequestDetails. + List of patch instructions + + + :param items: The items of this PatchPullRequestDetails. + :type: list[oci.devops.models.PatchInstruction] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_remove_instruction.py b/src/oci/devops/models/patch_remove_instruction.py new file mode 100644 index 000000000..d42021c11 --- /dev/null +++ b/src/oci/devops/models/patch_remove_instruction.py @@ -0,0 +1,59 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchRemoveInstruction(PatchInstruction): + """ + An operation that deletes items, ignoring NOT_FOUND exceptions. + To avoid referential errors if an item's descendant is also in the selection, items of the selection are processed in order of decreasing depth. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PatchRemoveInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchRemoveInstruction.operation` attribute + of this class is ``REMOVE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchRemoveInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchRemoveInstruction. + :type selection: str + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection' + } + + self._operation = None + self._selection = None + self._operation = 'REMOVE' + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_replace_instruction.py b/src/oci/devops/models/patch_replace_instruction.py new file mode 100644 index 000000000..44eae9bde --- /dev/null +++ b/src/oci/devops/models/patch_replace_instruction.py @@ -0,0 +1,92 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchReplaceInstruction(PatchInstruction): + """ + An operation that \"puts\" a value, replacing every item of the selection with it, or creating it if the selection is empty. + NOT_FOUND exceptions are handled by creating the implied containing structure (but note that this may put the target in an invalid state, + which can be prevented by use of precondition operations). + To avoid referential errors if an item's descendant is also in the selection, items of the selection are processed in order of decreasing depth. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PatchReplaceInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchReplaceInstruction.operation` attribute + of this class is ``REPLACE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchReplaceInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchReplaceInstruction. + :type selection: str + + :param value: + The value to assign to the value property of this PatchReplaceInstruction. + :type value: object + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str', + 'value': 'object' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection', + 'value': 'value' + } + + self._operation = None + self._selection = None + self._value = None + self._operation = 'REPLACE' + + @property + def value(self): + """ + **[Required]** Gets the value of this PatchReplaceInstruction. + A value to be added into the target. + + + :return: The value of this PatchReplaceInstruction. + :rtype: object + """ + return self._value + + @value.setter + def value(self, value): + """ + Sets the value of this PatchReplaceInstruction. + A value to be added into the target. + + + :param value: The value of this PatchReplaceInstruction. + :type: object + """ + self._value = value + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/patch_require_instruction.py b/src/oci/devops/models/patch_require_instruction.py new file mode 100644 index 000000000..234883670 --- /dev/null +++ b/src/oci/devops/models/patch_require_instruction.py @@ -0,0 +1,99 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .patch_instruction import PatchInstruction +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PatchRequireInstruction(PatchInstruction): + """ + A precondition operation that requires a selection to be non-empty, and optionally to include an item with a specified value + (useful for asserting that a value exists before attempting to update it, avoiding accidental creation). + It fails if the selection is empty, or if value is provided and no item of the selection matches it. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PatchRequireInstruction object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PatchRequireInstruction.operation` attribute + of this class is ``REQUIRE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param operation: + The value to assign to the operation property of this PatchRequireInstruction. + Allowed values for this property are: "REQUIRE", "PROHIBIT", "REPLACE", "INSERT", "REMOVE", "MOVE", "MERGE" + :type operation: str + + :param selection: + The value to assign to the selection property of this PatchRequireInstruction. + :type selection: str + + :param value: + The value to assign to the value property of this PatchRequireInstruction. + :type value: object + + """ + self.swagger_types = { + 'operation': 'str', + 'selection': 'str', + 'value': 'object' + } + + self.attribute_map = { + 'operation': 'operation', + 'selection': 'selection', + 'value': 'value' + } + + self._operation = None + self._selection = None + self._value = None + self._operation = 'REQUIRE' + + @property + def value(self): + """ + Gets the value of this PatchRequireInstruction. + A value to be compared against each item of the selection. + If this value is an object, then it matches any item that would be unaffected by applying this value as a merge operation. + Otherwise, it matches any item to which it is equal according to the rules of `JSON Schema`__. + + __ https://tools.ietf.org/html/draft-handrews-json-schema-00#section-4.2.3 + + + :return: The value of this PatchRequireInstruction. + :rtype: object + """ + return self._value + + @value.setter + def value(self, value): + """ + Sets the value of this PatchRequireInstruction. + A value to be compared against each item of the selection. + If this value is an object, then it matches any item that would be unaffected by applying this value as a merge operation. + Otherwise, it matches any item to which it is equal according to the rules of `JSON Schema`__. + + __ https://tools.ietf.org/html/draft-handrews-json-schema-00#section-4.2.3 + + + :param value: The value of this PatchRequireInstruction. + :type: object + """ + self._value = value + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/principal_details.py b/src/oci/devops/models/principal_details.py new file mode 100644 index 000000000..96c98c58c --- /dev/null +++ b/src/oci/devops/models/principal_details.py @@ -0,0 +1,209 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PrincipalDetails(object): + """ + The principal details + """ + + #: A constant which can be used with the principal_type property of a PrincipalDetails. + #: This constant has a value of "SERVICE" + PRINCIPAL_TYPE_SERVICE = "SERVICE" + + #: A constant which can be used with the principal_type property of a PrincipalDetails. + #: This constant has a value of "USER" + PRINCIPAL_TYPE_USER = "USER" + + #: A constant which can be used with the principal_type property of a PrincipalDetails. + #: This constant has a value of "INSTANCE" + PRINCIPAL_TYPE_INSTANCE = "INSTANCE" + + #: A constant which can be used with the principal_type property of a PrincipalDetails. + #: This constant has a value of "RESOURCE" + PRINCIPAL_TYPE_RESOURCE = "RESOURCE" + + #: A constant which can be used with the principal_state property of a PrincipalDetails. + #: This constant has a value of "ACTIVE" + PRINCIPAL_STATE_ACTIVE = "ACTIVE" + + #: A constant which can be used with the principal_state property of a PrincipalDetails. + #: This constant has a value of "INACTIVE" + PRINCIPAL_STATE_INACTIVE = "INACTIVE" + + #: A constant which can be used with the principal_state property of a PrincipalDetails. + #: This constant has a value of "SUPPRESSED" + PRINCIPAL_STATE_SUPPRESSED = "SUPPRESSED" + + def __init__(self, **kwargs): + """ + Initializes a new PrincipalDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param principal_id: + The value to assign to the principal_id property of this PrincipalDetails. + :type principal_id: str + + :param principal_name: + The value to assign to the principal_name property of this PrincipalDetails. + :type principal_name: str + + :param principal_type: + The value to assign to the principal_type property of this PrincipalDetails. + Allowed values for this property are: "SERVICE", "USER", "INSTANCE", "RESOURCE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type principal_type: str + + :param principal_state: + The value to assign to the principal_state property of this PrincipalDetails. + Allowed values for this property are: "ACTIVE", "INACTIVE", "SUPPRESSED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type principal_state: str + + """ + self.swagger_types = { + 'principal_id': 'str', + 'principal_name': 'str', + 'principal_type': 'str', + 'principal_state': 'str' + } + + self.attribute_map = { + 'principal_id': 'principalId', + 'principal_name': 'principalName', + 'principal_type': 'principalType', + 'principal_state': 'principalState' + } + + self._principal_id = None + self._principal_name = None + self._principal_type = None + self._principal_state = None + + @property + def principal_id(self): + """ + **[Required]** Gets the principal_id of this PrincipalDetails. + the OCID of the principal + + + :return: The principal_id of this PrincipalDetails. + :rtype: str + """ + return self._principal_id + + @principal_id.setter + def principal_id(self, principal_id): + """ + Sets the principal_id of this PrincipalDetails. + the OCID of the principal + + + :param principal_id: The principal_id of this PrincipalDetails. + :type: str + """ + self._principal_id = principal_id + + @property + def principal_name(self): + """ + Gets the principal_name of this PrincipalDetails. + the name of the principal + + + :return: The principal_name of this PrincipalDetails. + :rtype: str + """ + return self._principal_name + + @principal_name.setter + def principal_name(self, principal_name): + """ + Sets the principal_name of this PrincipalDetails. + the name of the principal + + + :param principal_name: The principal_name of this PrincipalDetails. + :type: str + """ + self._principal_name = principal_name + + @property + def principal_type(self): + """ + Gets the principal_type of this PrincipalDetails. + the type of principal + + Allowed values for this property are: "SERVICE", "USER", "INSTANCE", "RESOURCE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The principal_type of this PrincipalDetails. + :rtype: str + """ + return self._principal_type + + @principal_type.setter + def principal_type(self, principal_type): + """ + Sets the principal_type of this PrincipalDetails. + the type of principal + + + :param principal_type: The principal_type of this PrincipalDetails. + :type: str + """ + allowed_values = ["SERVICE", "USER", "INSTANCE", "RESOURCE"] + if not value_allowed_none_or_none_sentinel(principal_type, allowed_values): + principal_type = 'UNKNOWN_ENUM_VALUE' + self._principal_type = principal_type + + @property + def principal_state(self): + """ + Gets the principal_state of this PrincipalDetails. + The state of the principal, it can be active or inactive or suppressed for emails + + Allowed values for this property are: "ACTIVE", "INACTIVE", "SUPPRESSED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The principal_state of this PrincipalDetails. + :rtype: str + """ + return self._principal_state + + @principal_state.setter + def principal_state(self, principal_state): + """ + Sets the principal_state of this PrincipalDetails. + The state of the principal, it can be active or inactive or suppressed for emails + + + :param principal_state: The principal_state of this PrincipalDetails. + :type: str + """ + allowed_values = ["ACTIVE", "INACTIVE", "SUPPRESSED"] + if not value_allowed_none_or_none_sentinel(principal_state, allowed_values): + principal_state = 'UNKNOWN_ENUM_VALUE' + self._principal_state = principal_state + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/project_notification_preference.py b/src/oci/devops/models/project_notification_preference.py new file mode 100644 index 000000000..0ae6d32a2 --- /dev/null +++ b/src/oci/devops/models/project_notification_preference.py @@ -0,0 +1,154 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ProjectNotificationPreference(object): + """ + The notification preference of the project. + """ + + #: A constant which can be used with the notification_preference property of a ProjectNotificationPreference. + #: This constant has a value of "WATCH" + NOTIFICATION_PREFERENCE_WATCH = "WATCH" + + #: A constant which can be used with the notification_preference property of a ProjectNotificationPreference. + #: This constant has a value of "IGNORE" + NOTIFICATION_PREFERENCE_IGNORE = "IGNORE" + + #: A constant which can be used with the notification_preference property of a ProjectNotificationPreference. + #: This constant has a value of "MENTION" + NOTIFICATION_PREFERENCE_MENTION = "MENTION" + + def __init__(self, **kwargs): + """ + Initializes a new ProjectNotificationPreference object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param project_id: + The value to assign to the project_id property of this ProjectNotificationPreference. + :type project_id: str + + :param user_id: + The value to assign to the user_id property of this ProjectNotificationPreference. + :type user_id: str + + :param notification_preference: + The value to assign to the notification_preference property of this ProjectNotificationPreference. + Allowed values for this property are: "WATCH", "IGNORE", "MENTION", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type notification_preference: str + + """ + self.swagger_types = { + 'project_id': 'str', + 'user_id': 'str', + 'notification_preference': 'str' + } + + self.attribute_map = { + 'project_id': 'projectId', + 'user_id': 'userId', + 'notification_preference': 'notificationPreference' + } + + self._project_id = None + self._user_id = None + self._notification_preference = None + + @property + def project_id(self): + """ + **[Required]** Gets the project_id of this ProjectNotificationPreference. + The ocid of project resource + + + :return: The project_id of this ProjectNotificationPreference. + :rtype: str + """ + return self._project_id + + @project_id.setter + def project_id(self, project_id): + """ + Sets the project_id of this ProjectNotificationPreference. + The ocid of project resource + + + :param project_id: The project_id of this ProjectNotificationPreference. + :type: str + """ + self._project_id = project_id + + @property + def user_id(self): + """ + **[Required]** Gets the user_id of this ProjectNotificationPreference. + The ocid of user. + + + :return: The user_id of this ProjectNotificationPreference. + :rtype: str + """ + return self._user_id + + @user_id.setter + def user_id(self, user_id): + """ + Sets the user_id of this ProjectNotificationPreference. + The ocid of user. + + + :param user_id: The user_id of this ProjectNotificationPreference. + :type: str + """ + self._user_id = user_id + + @property + def notification_preference(self): + """ + **[Required]** Gets the notification_preference of this ProjectNotificationPreference. + The override value of project notification preference. + + Allowed values for this property are: "WATCH", "IGNORE", "MENTION", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The notification_preference of this ProjectNotificationPreference. + :rtype: str + """ + return self._notification_preference + + @notification_preference.setter + def notification_preference(self, notification_preference): + """ + Sets the notification_preference of this ProjectNotificationPreference. + The override value of project notification preference. + + + :param notification_preference: The notification_preference of this ProjectNotificationPreference. + :type: str + """ + allowed_values = ["WATCH", "IGNORE", "MENTION"] + if not value_allowed_none_or_none_sentinel(notification_preference, allowed_values): + notification_preference = 'UNKNOWN_ENUM_VALUE' + self._notification_preference = notification_preference + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/project_repository_settings.py b/src/oci/devops/models/project_repository_settings.py new file mode 100644 index 000000000..2aa058611 --- /dev/null +++ b/src/oci/devops/models/project_repository_settings.py @@ -0,0 +1,95 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ProjectRepositorySettings(object): + """ + User configured settings for project resources and their child repositories. + """ + + def __init__(self, **kwargs): + """ + Initializes a new ProjectRepositorySettings object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param merge_settings: + The value to assign to the merge_settings property of this ProjectRepositorySettings. + :type merge_settings: oci.devops.models.MergeSettings + + :param approval_rules: + The value to assign to the approval_rules property of this ProjectRepositorySettings. + :type approval_rules: oci.devops.models.ApprovalRuleCollection + + """ + self.swagger_types = { + 'merge_settings': 'MergeSettings', + 'approval_rules': 'ApprovalRuleCollection' + } + + self.attribute_map = { + 'merge_settings': 'mergeSettings', + 'approval_rules': 'approvalRules' + } + + self._merge_settings = None + self._approval_rules = None + + @property + def merge_settings(self): + """ + **[Required]** Gets the merge_settings of this ProjectRepositorySettings. + + :return: The merge_settings of this ProjectRepositorySettings. + :rtype: oci.devops.models.MergeSettings + """ + return self._merge_settings + + @merge_settings.setter + def merge_settings(self, merge_settings): + """ + Sets the merge_settings of this ProjectRepositorySettings. + + :param merge_settings: The merge_settings of this ProjectRepositorySettings. + :type: oci.devops.models.MergeSettings + """ + self._merge_settings = merge_settings + + @property + def approval_rules(self): + """ + **[Required]** Gets the approval_rules of this ProjectRepositorySettings. + + :return: The approval_rules of this ProjectRepositorySettings. + :rtype: oci.devops.models.ApprovalRuleCollection + """ + return self._approval_rules + + @approval_rules.setter + def approval_rules(self, approval_rules): + """ + Sets the approval_rules of this ProjectRepositorySettings. + + :param approval_rules: The approval_rules of this ProjectRepositorySettings. + :type: oci.devops.models.ApprovalRuleCollection + """ + self._approval_rules = approval_rules + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/protected_branch.py b/src/oci/devops/models/protected_branch.py new file mode 100644 index 000000000..1580a1722 --- /dev/null +++ b/src/oci/devops/models/protected_branch.py @@ -0,0 +1,189 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ProtectedBranch(object): + """ + Holds information used to restrict certain actions on branches + """ + + #: A constant which can be used with the protection_levels property of a ProtectedBranch. + #: This constant has a value of "READ_ONLY" + PROTECTION_LEVELS_READ_ONLY = "READ_ONLY" + + #: A constant which can be used with the protection_levels property of a ProtectedBranch. + #: This constant has a value of "PULL_REQUEST_MERGE_ONLY" + PROTECTION_LEVELS_PULL_REQUEST_MERGE_ONLY = "PULL_REQUEST_MERGE_ONLY" + + def __init__(self, **kwargs): + """ + Initializes a new ProtectedBranch object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param branch_name: + The value to assign to the branch_name property of this ProtectedBranch. + :type branch_name: str + + :param protection_levels: + The value to assign to the protection_levels property of this ProtectedBranch. + Allowed values for items in this list are: "READ_ONLY", "PULL_REQUEST_MERGE_ONLY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type protection_levels: list[str] + + :param freeform_tags: + The value to assign to the freeform_tags property of this ProtectedBranch. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this ProtectedBranch. + :type defined_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'branch_name': 'str', + 'protection_levels': 'list[str]', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'branch_name': 'branchName', + 'protection_levels': 'protectionLevels', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags' + } + + self._branch_name = None + self._protection_levels = None + self._freeform_tags = None + self._defined_tags = None + + @property + def branch_name(self): + """ + **[Required]** Gets the branch_name of this ProtectedBranch. + Branch name inside a repository. + + + :return: The branch_name of this ProtectedBranch. + :rtype: str + """ + return self._branch_name + + @branch_name.setter + def branch_name(self, branch_name): + """ + Sets the branch_name of this ProtectedBranch. + Branch name inside a repository. + + + :param branch_name: The branch_name of this ProtectedBranch. + :type: str + """ + self._branch_name = branch_name + + @property + def protection_levels(self): + """ + **[Required]** Gets the protection_levels of this ProtectedBranch. + Protection levels to be added on the branch. + + Allowed values for items in this list are: "READ_ONLY", "PULL_REQUEST_MERGE_ONLY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The protection_levels of this ProtectedBranch. + :rtype: list[str] + """ + return self._protection_levels + + @protection_levels.setter + def protection_levels(self, protection_levels): + """ + Sets the protection_levels of this ProtectedBranch. + Protection levels to be added on the branch. + + + :param protection_levels: The protection_levels of this ProtectedBranch. + :type: list[str] + """ + allowed_values = ["READ_ONLY", "PULL_REQUEST_MERGE_ONLY"] + if protection_levels: + protection_levels[:] = ['UNKNOWN_ENUM_VALUE' if not value_allowed_none_or_none_sentinel(x, allowed_values) else x for x in protection_levels] + self._protection_levels = protection_levels + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this ProtectedBranch. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this ProtectedBranch. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this ProtectedBranch. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this ProtectedBranch. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + Gets the defined_tags of this ProtectedBranch. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this ProtectedBranch. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this ProtectedBranch. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this ProtectedBranch. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/protected_branch_collection.py b/src/oci/devops/models/protected_branch_collection.py new file mode 100644 index 000000000..7d291019b --- /dev/null +++ b/src/oci/devops/models/protected_branch_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ProtectedBranchCollection(object): + """ + Collection of protected branches + """ + + def __init__(self, **kwargs): + """ + Initializes a new ProtectedBranchCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this ProtectedBranchCollection. + :type items: list[oci.devops.models.ProtectedBranchSummary] + + """ + self.swagger_types = { + 'items': 'list[ProtectedBranchSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this ProtectedBranchCollection. + List of objects describing protected branches + + + :return: The items of this ProtectedBranchCollection. + :rtype: list[oci.devops.models.ProtectedBranchSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this ProtectedBranchCollection. + List of objects describing protected branches + + + :param items: The items of this ProtectedBranchCollection. + :type: list[oci.devops.models.ProtectedBranchSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/protected_branch_summary.py b/src/oci/devops/models/protected_branch_summary.py new file mode 100644 index 000000000..667ac00f9 --- /dev/null +++ b/src/oci/devops/models/protected_branch_summary.py @@ -0,0 +1,224 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ProtectedBranchSummary(object): + """ + Holds information used to restrict certain actions on branches + """ + + #: A constant which can be used with the protection_levels property of a ProtectedBranchSummary. + #: This constant has a value of "READ_ONLY" + PROTECTION_LEVELS_READ_ONLY = "READ_ONLY" + + #: A constant which can be used with the protection_levels property of a ProtectedBranchSummary. + #: This constant has a value of "PULL_REQUEST_MERGE_ONLY" + PROTECTION_LEVELS_PULL_REQUEST_MERGE_ONLY = "PULL_REQUEST_MERGE_ONLY" + + def __init__(self, **kwargs): + """ + Initializes a new ProtectedBranchSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param branch_name: + The value to assign to the branch_name property of this ProtectedBranchSummary. + :type branch_name: str + + :param protection_levels: + The value to assign to the protection_levels property of this ProtectedBranchSummary. + Allowed values for items in this list are: "READ_ONLY", "PULL_REQUEST_MERGE_ONLY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type protection_levels: list[str] + + :param freeform_tags: + The value to assign to the freeform_tags property of this ProtectedBranchSummary. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this ProtectedBranchSummary. + :type defined_tags: dict(str, dict(str, object)) + + :param system_tags: + The value to assign to the system_tags property of this ProtectedBranchSummary. + :type system_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'branch_name': 'str', + 'protection_levels': 'list[str]', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))', + 'system_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'branch_name': 'branchName', + 'protection_levels': 'protectionLevels', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags', + 'system_tags': 'systemTags' + } + + self._branch_name = None + self._protection_levels = None + self._freeform_tags = None + self._defined_tags = None + self._system_tags = None + + @property + def branch_name(self): + """ + **[Required]** Gets the branch_name of this ProtectedBranchSummary. + Branch name inside a repository. + + + :return: The branch_name of this ProtectedBranchSummary. + :rtype: str + """ + return self._branch_name + + @branch_name.setter + def branch_name(self, branch_name): + """ + Sets the branch_name of this ProtectedBranchSummary. + Branch name inside a repository. + + + :param branch_name: The branch_name of this ProtectedBranchSummary. + :type: str + """ + self._branch_name = branch_name + + @property + def protection_levels(self): + """ + **[Required]** Gets the protection_levels of this ProtectedBranchSummary. + Protection level to be added on the branch. + + Allowed values for items in this list are: "READ_ONLY", "PULL_REQUEST_MERGE_ONLY", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The protection_levels of this ProtectedBranchSummary. + :rtype: list[str] + """ + return self._protection_levels + + @protection_levels.setter + def protection_levels(self, protection_levels): + """ + Sets the protection_levels of this ProtectedBranchSummary. + Protection level to be added on the branch. + + + :param protection_levels: The protection_levels of this ProtectedBranchSummary. + :type: list[str] + """ + allowed_values = ["READ_ONLY", "PULL_REQUEST_MERGE_ONLY"] + if protection_levels: + protection_levels[:] = ['UNKNOWN_ENUM_VALUE' if not value_allowed_none_or_none_sentinel(x, allowed_values) else x for x in protection_levels] + self._protection_levels = protection_levels + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this ProtectedBranchSummary. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this ProtectedBranchSummary. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this ProtectedBranchSummary. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this ProtectedBranchSummary. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + Gets the defined_tags of this ProtectedBranchSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this ProtectedBranchSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this ProtectedBranchSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this ProtectedBranchSummary. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def system_tags(self): + """ + Gets the system_tags of this ProtectedBranchSummary. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The system_tags of this ProtectedBranchSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._system_tags + + @system_tags.setter + def system_tags(self, system_tags): + """ + Sets the system_tags of this ProtectedBranchSummary. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param system_tags: The system_tags of this ProtectedBranchSummary. + :type: dict(str, dict(str, object)) + """ + self._system_tags = system_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request.py b/src/oci/devops/models/pull_request.py new file mode 100644 index 000000000..09327afaa --- /dev/null +++ b/src/oci/devops/models/pull_request.py @@ -0,0 +1,814 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequest(object): + """ + Pull Request containing the diff between a review branch and a destination branch + """ + + #: A constant which can be used with the lifecycle_state property of a PullRequest. + #: This constant has a value of "CREATING" + LIFECYCLE_STATE_CREATING = "CREATING" + + #: A constant which can be used with the lifecycle_state property of a PullRequest. + #: This constant has a value of "UPDATING" + LIFECYCLE_STATE_UPDATING = "UPDATING" + + #: A constant which can be used with the lifecycle_state property of a PullRequest. + #: This constant has a value of "ACTIVE" + LIFECYCLE_STATE_ACTIVE = "ACTIVE" + + #: A constant which can be used with the lifecycle_state property of a PullRequest. + #: This constant has a value of "DELETING" + LIFECYCLE_STATE_DELETING = "DELETING" + + #: A constant which can be used with the lifecycle_state property of a PullRequest. + #: This constant has a value of "DELETED" + LIFECYCLE_STATE_DELETED = "DELETED" + + #: A constant which can be used with the lifecycle_state property of a PullRequest. + #: This constant has a value of "FAILED" + LIFECYCLE_STATE_FAILED = "FAILED" + + #: A constant which can be used with the lifecycle_details property of a PullRequest. + #: This constant has a value of "OPEN" + LIFECYCLE_DETAILS_OPEN = "OPEN" + + #: A constant which can be used with the lifecycle_details property of a PullRequest. + #: This constant has a value of "CONFLICT" + LIFECYCLE_DETAILS_CONFLICT = "CONFLICT" + + #: A constant which can be used with the lifecycle_details property of a PullRequest. + #: This constant has a value of "CLOSED" + LIFECYCLE_DETAILS_CLOSED = "CLOSED" + + #: A constant which can be used with the lifecycle_details property of a PullRequest. + #: This constant has a value of "MERGING" + LIFECYCLE_DETAILS_MERGING = "MERGING" + + #: A constant which can be used with the lifecycle_details property of a PullRequest. + #: This constant has a value of "MERGED" + LIFECYCLE_DETAILS_MERGED = "MERGED" + + def __init__(self, **kwargs): + """ + Initializes a new PullRequest object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequest. + :type id: str + + :param display_name: + The value to assign to the display_name property of this PullRequest. + :type display_name: str + + :param description: + The value to assign to the description property of this PullRequest. + :type description: str + + :param compartment_id: + The value to assign to the compartment_id property of this PullRequest. + :type compartment_id: str + + :param repository_id: + The value to assign to the repository_id property of this PullRequest. + :type repository_id: str + + :param source_branch: + The value to assign to the source_branch property of this PullRequest. + :type source_branch: str + + :param destination_branch: + The value to assign to the destination_branch property of this PullRequest. + :type destination_branch: str + + :param source_commit_id_at_termination: + The value to assign to the source_commit_id_at_termination property of this PullRequest. + :type source_commit_id_at_termination: str + + :param merge_base_commit_id_at_termination: + The value to assign to the merge_base_commit_id_at_termination property of this PullRequest. + :type merge_base_commit_id_at_termination: str + + :param time_created: + The value to assign to the time_created property of this PullRequest. + :type time_created: datetime + + :param time_updated: + The value to assign to the time_updated property of this PullRequest. + :type time_updated: datetime + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this PullRequest. + Allowed values for this property are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type lifecycle_state: str + + :param lifecycle_details: + The value to assign to the lifecycle_details property of this PullRequest. + Allowed values for this property are: "OPEN", "CONFLICT", "CLOSED", "MERGING", "MERGED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type lifecycle_details: str + + :param reviewers: + The value to assign to the reviewers property of this PullRequest. + :type reviewers: list[oci.devops.models.Reviewer] + + :param merge_checks: + The value to assign to the merge_checks property of this PullRequest. + :type merge_checks: oci.devops.models.MergeCheckCollection + + :param created_by: + The value to assign to the created_by property of this PullRequest. + :type created_by: oci.devops.models.PrincipalDetails + + :param merged_by: + The value to assign to the merged_by property of this PullRequest. + :type merged_by: oci.devops.models.PrincipalDetails + + :param source_repository_id: + The value to assign to the source_repository_id property of this PullRequest. + :type source_repository_id: str + + :param total_comments: + The value to assign to the total_comments property of this PullRequest. + :type total_comments: int + + :param total_reviewers: + The value to assign to the total_reviewers property of this PullRequest. + :type total_reviewers: int + + :param freeform_tags: + The value to assign to the freeform_tags property of this PullRequest. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this PullRequest. + :type defined_tags: dict(str, dict(str, object)) + + :param system_tags: + The value to assign to the system_tags property of this PullRequest. + :type system_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'id': 'str', + 'display_name': 'str', + 'description': 'str', + 'compartment_id': 'str', + 'repository_id': 'str', + 'source_branch': 'str', + 'destination_branch': 'str', + 'source_commit_id_at_termination': 'str', + 'merge_base_commit_id_at_termination': 'str', + 'time_created': 'datetime', + 'time_updated': 'datetime', + 'lifecycle_state': 'str', + 'lifecycle_details': 'str', + 'reviewers': 'list[Reviewer]', + 'merge_checks': 'MergeCheckCollection', + 'created_by': 'PrincipalDetails', + 'merged_by': 'PrincipalDetails', + 'source_repository_id': 'str', + 'total_comments': 'int', + 'total_reviewers': 'int', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))', + 'system_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'id': 'id', + 'display_name': 'displayName', + 'description': 'description', + 'compartment_id': 'compartmentId', + 'repository_id': 'repositoryId', + 'source_branch': 'sourceBranch', + 'destination_branch': 'destinationBranch', + 'source_commit_id_at_termination': 'sourceCommitIdAtTermination', + 'merge_base_commit_id_at_termination': 'mergeBaseCommitIdAtTermination', + 'time_created': 'timeCreated', + 'time_updated': 'timeUpdated', + 'lifecycle_state': 'lifecycleState', + 'lifecycle_details': 'lifecycleDetails', + 'reviewers': 'reviewers', + 'merge_checks': 'mergeChecks', + 'created_by': 'createdBy', + 'merged_by': 'mergedBy', + 'source_repository_id': 'sourceRepositoryId', + 'total_comments': 'totalComments', + 'total_reviewers': 'totalReviewers', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags', + 'system_tags': 'systemTags' + } + + self._id = None + self._display_name = None + self._description = None + self._compartment_id = None + self._repository_id = None + self._source_branch = None + self._destination_branch = None + self._source_commit_id_at_termination = None + self._merge_base_commit_id_at_termination = None + self._time_created = None + self._time_updated = None + self._lifecycle_state = None + self._lifecycle_details = None + self._reviewers = None + self._merge_checks = None + self._created_by = None + self._merged_by = None + self._source_repository_id = None + self._total_comments = None + self._total_reviewers = None + self._freeform_tags = None + self._defined_tags = None + self._system_tags = None + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequest. + Unique identifier that is immutable on creation + + + :return: The id of this PullRequest. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequest. + Unique identifier that is immutable on creation + + + :param id: The id of this PullRequest. + :type: str + """ + self._id = id + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this PullRequest. + PullRequest title, can be renamed + + + :return: The display_name of this PullRequest. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this PullRequest. + PullRequest title, can be renamed + + + :param display_name: The display_name of this PullRequest. + :type: str + """ + self._display_name = display_name + + @property + def description(self): + """ + Gets the description of this PullRequest. + Details of the pull request. Avoid entering confidential information. + + + :return: The description of this PullRequest. + :rtype: str + """ + return self._description + + @description.setter + def description(self, description): + """ + Sets the description of this PullRequest. + Details of the pull request. Avoid entering confidential information. + + + :param description: The description of this PullRequest. + :type: str + """ + self._description = description + + @property + def compartment_id(self): + """ + **[Required]** Gets the compartment_id of this PullRequest. + Compartment Identifier + + + :return: The compartment_id of this PullRequest. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this PullRequest. + Compartment Identifier + + + :param compartment_id: The compartment_id of this PullRequest. + :type: str + """ + self._compartment_id = compartment_id + + @property + def repository_id(self): + """ + **[Required]** Gets the repository_id of this PullRequest. + DevOps Repository Identifier tells which repository this pull request belongs to + + + :return: The repository_id of this PullRequest. + :rtype: str + """ + return self._repository_id + + @repository_id.setter + def repository_id(self, repository_id): + """ + Sets the repository_id of this PullRequest. + DevOps Repository Identifier tells which repository this pull request belongs to + + + :param repository_id: The repository_id of this PullRequest. + :type: str + """ + self._repository_id = repository_id + + @property + def source_branch(self): + """ + **[Required]** Gets the source_branch of this PullRequest. + The source branch which contains the changes to be reviewed. Example: \"feature/JIRA-123\" + + + :return: The source_branch of this PullRequest. + :rtype: str + """ + return self._source_branch + + @source_branch.setter + def source_branch(self, source_branch): + """ + Sets the source_branch of this PullRequest. + The source branch which contains the changes to be reviewed. Example: \"feature/JIRA-123\" + + + :param source_branch: The source_branch of this PullRequest. + :type: str + """ + self._source_branch = source_branch + + @property + def destination_branch(self): + """ + **[Required]** Gets the destination_branch of this PullRequest. + The destination branch against which the changes are to be reviewed. Example: \"main\". + + + :return: The destination_branch of this PullRequest. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this PullRequest. + The destination branch against which the changes are to be reviewed. Example: \"main\". + + + :param destination_branch: The destination_branch of this PullRequest. + :type: str + """ + self._destination_branch = destination_branch + + @property + def source_commit_id_at_termination(self): + """ + Gets the source_commit_id_at_termination of this PullRequest. + The source branch commit ID when the Pull Request status was last changed to merged or closed + + + :return: The source_commit_id_at_termination of this PullRequest. + :rtype: str + """ + return self._source_commit_id_at_termination + + @source_commit_id_at_termination.setter + def source_commit_id_at_termination(self, source_commit_id_at_termination): + """ + Sets the source_commit_id_at_termination of this PullRequest. + The source branch commit ID when the Pull Request status was last changed to merged or closed + + + :param source_commit_id_at_termination: The source_commit_id_at_termination of this PullRequest. + :type: str + """ + self._source_commit_id_at_termination = source_commit_id_at_termination + + @property + def merge_base_commit_id_at_termination(self): + """ + Gets the merge_base_commit_id_at_termination of this PullRequest. + The merge base commit ID when the Pull Request status was last changed to merged or closed + + + :return: The merge_base_commit_id_at_termination of this PullRequest. + :rtype: str + """ + return self._merge_base_commit_id_at_termination + + @merge_base_commit_id_at_termination.setter + def merge_base_commit_id_at_termination(self, merge_base_commit_id_at_termination): + """ + Sets the merge_base_commit_id_at_termination of this PullRequest. + The merge base commit ID when the Pull Request status was last changed to merged or closed + + + :param merge_base_commit_id_at_termination: The merge_base_commit_id_at_termination of this PullRequest. + :type: str + """ + self._merge_base_commit_id_at_termination = merge_base_commit_id_at_termination + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this PullRequest. + The time the PullRequest was created. An RFC3339 formatted datetime string + + + :return: The time_created of this PullRequest. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this PullRequest. + The time the PullRequest was created. An RFC3339 formatted datetime string + + + :param time_created: The time_created of this PullRequest. + :type: datetime + """ + self._time_created = time_created + + @property + def time_updated(self): + """ + Gets the time_updated of this PullRequest. + The time the PullRequest was updated. An RFC3339 formatted datetime string + + + :return: The time_updated of this PullRequest. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this PullRequest. + The time the PullRequest was updated. An RFC3339 formatted datetime string + + + :param time_updated: The time_updated of this PullRequest. + :type: datetime + """ + self._time_updated = time_updated + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this PullRequest. + The current state of the PullRequest. + + Allowed values for this property are: "CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The lifecycle_state of this PullRequest. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this PullRequest. + The current state of the PullRequest. + + + :param lifecycle_state: The lifecycle_state of this PullRequest. + :type: str + """ + allowed_values = ["CREATING", "UPDATING", "ACTIVE", "DELETING", "DELETED", "FAILED"] + if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): + lifecycle_state = 'UNKNOWN_ENUM_VALUE' + self._lifecycle_state = lifecycle_state + + @property + def lifecycle_details(self): + """ + **[Required]** Gets the lifecycle_details of this PullRequest. + The status of the Pull Request. + + Allowed values for this property are: "OPEN", "CONFLICT", "CLOSED", "MERGING", "MERGED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The lifecycle_details of this PullRequest. + :rtype: str + """ + return self._lifecycle_details + + @lifecycle_details.setter + def lifecycle_details(self, lifecycle_details): + """ + Sets the lifecycle_details of this PullRequest. + The status of the Pull Request. + + + :param lifecycle_details: The lifecycle_details of this PullRequest. + :type: str + """ + allowed_values = ["OPEN", "CONFLICT", "CLOSED", "MERGING", "MERGED"] + if not value_allowed_none_or_none_sentinel(lifecycle_details, allowed_values): + lifecycle_details = 'UNKNOWN_ENUM_VALUE' + self._lifecycle_details = lifecycle_details + + @property + def reviewers(self): + """ + Gets the reviewers of this PullRequest. + List of Reviewers. + + + :return: The reviewers of this PullRequest. + :rtype: list[oci.devops.models.Reviewer] + """ + return self._reviewers + + @reviewers.setter + def reviewers(self, reviewers): + """ + Sets the reviewers of this PullRequest. + List of Reviewers. + + + :param reviewers: The reviewers of this PullRequest. + :type: list[oci.devops.models.Reviewer] + """ + self._reviewers = reviewers + + @property + def merge_checks(self): + """ + Gets the merge_checks of this PullRequest. + + :return: The merge_checks of this PullRequest. + :rtype: oci.devops.models.MergeCheckCollection + """ + return self._merge_checks + + @merge_checks.setter + def merge_checks(self, merge_checks): + """ + Sets the merge_checks of this PullRequest. + + :param merge_checks: The merge_checks of this PullRequest. + :type: oci.devops.models.MergeCheckCollection + """ + self._merge_checks = merge_checks + + @property + def created_by(self): + """ + **[Required]** Gets the created_by of this PullRequest. + + :return: The created_by of this PullRequest. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._created_by + + @created_by.setter + def created_by(self, created_by): + """ + Sets the created_by of this PullRequest. + + :param created_by: The created_by of this PullRequest. + :type: oci.devops.models.PrincipalDetails + """ + self._created_by = created_by + + @property + def merged_by(self): + """ + Gets the merged_by of this PullRequest. + + :return: The merged_by of this PullRequest. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._merged_by + + @merged_by.setter + def merged_by(self, merged_by): + """ + Sets the merged_by of this PullRequest. + + :param merged_by: The merged_by of this PullRequest. + :type: oci.devops.models.PrincipalDetails + """ + self._merged_by = merged_by + + @property + def source_repository_id(self): + """ + Gets the source_repository_id of this PullRequest. + The OCID of the forked repository that will act as the source of the changes to be included in the pull request against the parent repository. + + + :return: The source_repository_id of this PullRequest. + :rtype: str + """ + return self._source_repository_id + + @source_repository_id.setter + def source_repository_id(self, source_repository_id): + """ + Sets the source_repository_id of this PullRequest. + The OCID of the forked repository that will act as the source of the changes to be included in the pull request against the parent repository. + + + :param source_repository_id: The source_repository_id of this PullRequest. + :type: str + """ + self._source_repository_id = source_repository_id + + @property + def total_comments(self): + """ + **[Required]** Gets the total_comments of this PullRequest. + The total number of comments on the pull request. + + + :return: The total_comments of this PullRequest. + :rtype: int + """ + return self._total_comments + + @total_comments.setter + def total_comments(self, total_comments): + """ + Sets the total_comments of this PullRequest. + The total number of comments on the pull request. + + + :param total_comments: The total_comments of this PullRequest. + :type: int + """ + self._total_comments = total_comments + + @property + def total_reviewers(self): + """ + **[Required]** Gets the total_reviewers of this PullRequest. + The total number of reviewers on the pull request. + + + :return: The total_reviewers of this PullRequest. + :rtype: int + """ + return self._total_reviewers + + @total_reviewers.setter + def total_reviewers(self, total_reviewers): + """ + Sets the total_reviewers of this PullRequest. + The total number of reviewers on the pull request. + + + :param total_reviewers: The total_reviewers of this PullRequest. + :type: int + """ + self._total_reviewers = total_reviewers + + @property + def freeform_tags(self): + """ + **[Required]** Gets the freeform_tags of this PullRequest. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this PullRequest. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this PullRequest. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this PullRequest. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + **[Required]** Gets the defined_tags of this PullRequest. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this PullRequest. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this PullRequest. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this PullRequest. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def system_tags(self): + """ + **[Required]** Gets the system_tags of this PullRequest. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The system_tags of this PullRequest. + :rtype: dict(str, dict(str, object)) + """ + return self._system_tags + + @system_tags.setter + def system_tags(self, system_tags): + """ + Sets the system_tags of this PullRequest. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param system_tags: The system_tags of this PullRequest. + :type: dict(str, dict(str, object)) + """ + self._system_tags = system_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_activity_collection.py b/src/oci/devops/models/pull_request_activity_collection.py new file mode 100644 index 000000000..af4222c77 --- /dev/null +++ b/src/oci/devops/models/pull_request_activity_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestActivityCollection(object): + """ + Result of list pullRequest activities. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestActivityCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PullRequestActivityCollection. + :type items: list[oci.devops.models.PullRequestActivitySummary] + + """ + self.swagger_types = { + 'items': 'list[PullRequestActivitySummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this PullRequestActivityCollection. + List of pullRequest activity objects. + + + :return: The items of this PullRequestActivityCollection. + :rtype: list[oci.devops.models.PullRequestActivitySummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PullRequestActivityCollection. + List of pullRequest activity objects. + + + :param items: The items of this PullRequestActivityCollection. + :type: list[oci.devops.models.PullRequestActivitySummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_activity_summary.py b/src/oci/devops/models/pull_request_activity_summary.py new file mode 100644 index 000000000..49d73c85b --- /dev/null +++ b/src/oci/devops/models/pull_request_activity_summary.py @@ -0,0 +1,253 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestActivitySummary(object): + """ + Summary of an activity record in a pull request + """ + + #: A constant which can be used with the activity_type property of a PullRequestActivitySummary. + #: This constant has a value of "LIFECYCLE" + ACTIVITY_TYPE_LIFECYCLE = "LIFECYCLE" + + #: A constant which can be used with the activity_type property of a PullRequestActivitySummary. + #: This constant has a value of "APPROVAL" + ACTIVITY_TYPE_APPROVAL = "APPROVAL" + + #: A constant which can be used with the activity_type property of a PullRequestActivitySummary. + #: This constant has a value of "COMMIT" + ACTIVITY_TYPE_COMMIT = "COMMIT" + + #: A constant which can be used with the activity_type property of a PullRequestActivitySummary. + #: This constant has a value of "REVIEWER" + ACTIVITY_TYPE_REVIEWER = "REVIEWER" + + #: A constant which can be used with the activity_type property of a PullRequestActivitySummary. + #: This constant has a value of "COMMENT" + ACTIVITY_TYPE_COMMENT = "COMMENT" + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestActivitySummary object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.CommitActivitySummary` + * :class:`~oci.devops.models.CommentActivitySummary` + * :class:`~oci.devops.models.ApprovalActivitySummary` + * :class:`~oci.devops.models.ReviewerActivitySummary` + * :class:`~oci.devops.models.PullRequestLifecycleActivitySummary` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestActivitySummary. + :type id: str + + :param principal: + The value to assign to the principal property of this PullRequestActivitySummary. + :type principal: oci.devops.models.PrincipalDetails + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestActivitySummary. + :type pull_request_id: str + + :param time_occurred: + The value to assign to the time_occurred property of this PullRequestActivitySummary. + :type time_occurred: datetime + + :param activity_type: + The value to assign to the activity_type property of this PullRequestActivitySummary. + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type activity_type: str + + """ + self.swagger_types = { + 'id': 'str', + 'principal': 'PrincipalDetails', + 'pull_request_id': 'str', + 'time_occurred': 'datetime', + 'activity_type': 'str' + } + + self.attribute_map = { + 'id': 'id', + 'principal': 'principal', + 'pull_request_id': 'pullRequestId', + 'time_occurred': 'timeOccurred', + 'activity_type': 'activityType' + } + + self._id = None + self._principal = None + self._pull_request_id = None + self._time_occurred = None + self._activity_type = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['activityType'] + + if type == 'COMMIT': + return 'CommitActivitySummary' + + if type == 'COMMENT': + return 'CommentActivitySummary' + + if type == 'APPROVAL': + return 'ApprovalActivitySummary' + + if type == 'REVIEWER': + return 'ReviewerActivitySummary' + + if type == 'LIFECYCLE': + return 'PullRequestLifecycleActivitySummary' + else: + return 'PullRequestActivitySummary' + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequestActivitySummary. + activity identifier + + + :return: The id of this PullRequestActivitySummary. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequestActivitySummary. + activity identifier + + + :param id: The id of this PullRequestActivitySummary. + :type: str + """ + self._id = id + + @property + def principal(self): + """ + **[Required]** Gets the principal of this PullRequestActivitySummary. + + :return: The principal of this PullRequestActivitySummary. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._principal + + @principal.setter + def principal(self, principal): + """ + Sets the principal of this PullRequestActivitySummary. + + :param principal: The principal of this PullRequestActivitySummary. + :type: oci.devops.models.PrincipalDetails + """ + self._principal = principal + + @property + def pull_request_id(self): + """ + **[Required]** Gets the pull_request_id of this PullRequestActivitySummary. + pullRequest OCID + + + :return: The pull_request_id of this PullRequestActivitySummary. + :rtype: str + """ + return self._pull_request_id + + @pull_request_id.setter + def pull_request_id(self, pull_request_id): + """ + Sets the pull_request_id of this PullRequestActivitySummary. + pullRequest OCID + + + :param pull_request_id: The pull_request_id of this PullRequestActivitySummary. + :type: str + """ + self._pull_request_id = pull_request_id + + @property + def time_occurred(self): + """ + **[Required]** Gets the time_occurred of this PullRequestActivitySummary. + The time the action was performed. An RFC3339 formatted datetime string + + + :return: The time_occurred of this PullRequestActivitySummary. + :rtype: datetime + """ + return self._time_occurred + + @time_occurred.setter + def time_occurred(self, time_occurred): + """ + Sets the time_occurred of this PullRequestActivitySummary. + The time the action was performed. An RFC3339 formatted datetime string + + + :param time_occurred: The time_occurred of this PullRequestActivitySummary. + :type: datetime + """ + self._time_occurred = time_occurred + + @property + def activity_type(self): + """ + **[Required]** Gets the activity_type of this PullRequestActivitySummary. + The type of activity performed + + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The activity_type of this PullRequestActivitySummary. + :rtype: str + """ + return self._activity_type + + @activity_type.setter + def activity_type(self, activity_type): + """ + Sets the activity_type of this PullRequestActivitySummary. + The type of activity performed + + + :param activity_type: The activity_type of this PullRequestActivitySummary. + :type: str + """ + allowed_values = ["LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT"] + if not value_allowed_none_or_none_sentinel(activity_type, allowed_values): + activity_type = 'UNKNOWN_ENUM_VALUE' + self._activity_type = activity_type + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_attachment.py b/src/oci/devops/models/pull_request_attachment.py new file mode 100644 index 000000000..a2fddfea7 --- /dev/null +++ b/src/oci/devops/models/pull_request_attachment.py @@ -0,0 +1,196 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestAttachment(object): + """ + Pull Request attachment created by users. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestAttachment object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestAttachment. + :type id: str + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestAttachment. + :type pull_request_id: str + + :param file_name: + The value to assign to the file_name property of this PullRequestAttachment. + :type file_name: str + + :param time_created: + The value to assign to the time_created property of this PullRequestAttachment. + :type time_created: datetime + + :param created_by: + The value to assign to the created_by property of this PullRequestAttachment. + :type created_by: oci.devops.models.PrincipalDetails + + """ + self.swagger_types = { + 'id': 'str', + 'pull_request_id': 'str', + 'file_name': 'str', + 'time_created': 'datetime', + 'created_by': 'PrincipalDetails' + } + + self.attribute_map = { + 'id': 'id', + 'pull_request_id': 'pullRequestId', + 'file_name': 'fileName', + 'time_created': 'timeCreated', + 'created_by': 'createdBy' + } + + self._id = None + self._pull_request_id = None + self._file_name = None + self._time_created = None + self._created_by = None + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequestAttachment. + Unique identifier that is immutable on creation + + + :return: The id of this PullRequestAttachment. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequestAttachment. + Unique identifier that is immutable on creation + + + :param id: The id of this PullRequestAttachment. + :type: str + """ + self._id = id + + @property + def pull_request_id(self): + """ + **[Required]** Gets the pull_request_id of this PullRequestAttachment. + OCID of the pull request that this attachment belongs to + + + :return: The pull_request_id of this PullRequestAttachment. + :rtype: str + """ + return self._pull_request_id + + @pull_request_id.setter + def pull_request_id(self, pull_request_id): + """ + Sets the pull_request_id of this PullRequestAttachment. + OCID of the pull request that this attachment belongs to + + + :param pull_request_id: The pull_request_id of this PullRequestAttachment. + :type: str + """ + self._pull_request_id = pull_request_id + + @property + def file_name(self): + """ + **[Required]** Gets the file_name of this PullRequestAttachment. + name to display in description or comment + + + :return: The file_name of this PullRequestAttachment. + :rtype: str + """ + return self._file_name + + @file_name.setter + def file_name(self, file_name): + """ + Sets the file_name of this PullRequestAttachment. + name to display in description or comment + + + :param file_name: The file_name of this PullRequestAttachment. + :type: str + """ + self._file_name = file_name + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this PullRequestAttachment. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_created of this PullRequestAttachment. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this PullRequestAttachment. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_created: The time_created of this PullRequestAttachment. + :type: datetime + """ + self._time_created = time_created + + @property + def created_by(self): + """ + **[Required]** Gets the created_by of this PullRequestAttachment. + + :return: The created_by of this PullRequestAttachment. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._created_by + + @created_by.setter + def created_by(self, created_by): + """ + Sets the created_by of this PullRequestAttachment. + + :param created_by: The created_by of this PullRequestAttachment. + :type: oci.devops.models.PrincipalDetails + """ + self._created_by = created_by + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_attachment_collection.py b/src/oci/devops/models/pull_request_attachment_collection.py new file mode 100644 index 000000000..bed598dcf --- /dev/null +++ b/src/oci/devops/models/pull_request_attachment_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestAttachmentCollection(object): + """ + Result of list pullRequest attachment. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestAttachmentCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PullRequestAttachmentCollection. + :type items: list[oci.devops.models.PullRequestAttachmentSummary] + + """ + self.swagger_types = { + 'items': 'list[PullRequestAttachmentSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this PullRequestAttachmentCollection. + List of pullRequest attachment objects. + + + :return: The items of this PullRequestAttachmentCollection. + :rtype: list[oci.devops.models.PullRequestAttachmentSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PullRequestAttachmentCollection. + List of pullRequest attachment objects. + + + :param items: The items of this PullRequestAttachmentCollection. + :type: list[oci.devops.models.PullRequestAttachmentSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_attachment_summary.py b/src/oci/devops/models/pull_request_attachment_summary.py new file mode 100644 index 000000000..2485c9039 --- /dev/null +++ b/src/oci/devops/models/pull_request_attachment_summary.py @@ -0,0 +1,196 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestAttachmentSummary(object): + """ + summary of a pullRequest attachment + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestAttachmentSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestAttachmentSummary. + :type id: str + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestAttachmentSummary. + :type pull_request_id: str + + :param file_name: + The value to assign to the file_name property of this PullRequestAttachmentSummary. + :type file_name: str + + :param time_created: + The value to assign to the time_created property of this PullRequestAttachmentSummary. + :type time_created: datetime + + :param created_by: + The value to assign to the created_by property of this PullRequestAttachmentSummary. + :type created_by: oci.devops.models.PrincipalDetails + + """ + self.swagger_types = { + 'id': 'str', + 'pull_request_id': 'str', + 'file_name': 'str', + 'time_created': 'datetime', + 'created_by': 'PrincipalDetails' + } + + self.attribute_map = { + 'id': 'id', + 'pull_request_id': 'pullRequestId', + 'file_name': 'fileName', + 'time_created': 'timeCreated', + 'created_by': 'createdBy' + } + + self._id = None + self._pull_request_id = None + self._file_name = None + self._time_created = None + self._created_by = None + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequestAttachmentSummary. + Unique identifier that is immutable on creation + + + :return: The id of this PullRequestAttachmentSummary. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequestAttachmentSummary. + Unique identifier that is immutable on creation + + + :param id: The id of this PullRequestAttachmentSummary. + :type: str + """ + self._id = id + + @property + def pull_request_id(self): + """ + **[Required]** Gets the pull_request_id of this PullRequestAttachmentSummary. + OCID of the pull request that this attachment belongs to + + + :return: The pull_request_id of this PullRequestAttachmentSummary. + :rtype: str + """ + return self._pull_request_id + + @pull_request_id.setter + def pull_request_id(self, pull_request_id): + """ + Sets the pull_request_id of this PullRequestAttachmentSummary. + OCID of the pull request that this attachment belongs to + + + :param pull_request_id: The pull_request_id of this PullRequestAttachmentSummary. + :type: str + """ + self._pull_request_id = pull_request_id + + @property + def file_name(self): + """ + **[Required]** Gets the file_name of this PullRequestAttachmentSummary. + name to display in description or comment + + + :return: The file_name of this PullRequestAttachmentSummary. + :rtype: str + """ + return self._file_name + + @file_name.setter + def file_name(self, file_name): + """ + Sets the file_name of this PullRequestAttachmentSummary. + name to display in description or comment + + + :param file_name: The file_name of this PullRequestAttachmentSummary. + :type: str + """ + self._file_name = file_name + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this PullRequestAttachmentSummary. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_created of this PullRequestAttachmentSummary. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this PullRequestAttachmentSummary. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_created: The time_created of this PullRequestAttachmentSummary. + :type: datetime + """ + self._time_created = time_created + + @property + def created_by(self): + """ + **[Required]** Gets the created_by of this PullRequestAttachmentSummary. + + :return: The created_by of this PullRequestAttachmentSummary. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._created_by + + @created_by.setter + def created_by(self, created_by): + """ + Sets the created_by of this PullRequestAttachmentSummary. + + :param created_by: The created_by of this PullRequestAttachmentSummary. + :type: oci.devops.models.PrincipalDetails + """ + self._created_by = created_by + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_author_collection.py b/src/oci/devops/models/pull_request_author_collection.py new file mode 100644 index 000000000..57f0e7801 --- /dev/null +++ b/src/oci/devops/models/pull_request_author_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestAuthorCollection(object): + """ + Result of listing PR authors. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestAuthorCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PullRequestAuthorCollection. + :type items: list[oci.devops.models.PullRequestAuthorSummary] + + """ + self.swagger_types = { + 'items': 'list[PullRequestAuthorSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this PullRequestAuthorCollection. + List of authors who has ever created PR before. + + + :return: The items of this PullRequestAuthorCollection. + :rtype: list[oci.devops.models.PullRequestAuthorSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PullRequestAuthorCollection. + List of authors who has ever created PR before. + + + :param items: The items of this PullRequestAuthorCollection. + :type: list[oci.devops.models.PullRequestAuthorSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_author_summary.py b/src/oci/devops/models/pull_request_author_summary.py new file mode 100644 index 000000000..a03bc5778 --- /dev/null +++ b/src/oci/devops/models/pull_request_author_summary.py @@ -0,0 +1,68 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestAuthorSummary(object): + """ + Object containing summary of PR author. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestAuthorSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param principal_details: + The value to assign to the principal_details property of this PullRequestAuthorSummary. + :type principal_details: oci.devops.models.PrincipalDetails + + """ + self.swagger_types = { + 'principal_details': 'PrincipalDetails' + } + + self.attribute_map = { + 'principal_details': 'principalDetails' + } + + self._principal_details = None + + @property + def principal_details(self): + """ + **[Required]** Gets the principal_details of this PullRequestAuthorSummary. + + :return: The principal_details of this PullRequestAuthorSummary. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._principal_details + + @principal_details.setter + def principal_details(self, principal_details): + """ + Sets the principal_details of this PullRequestAuthorSummary. + + :param principal_details: The principal_details of this PullRequestAuthorSummary. + :type: oci.devops.models.PrincipalDetails + """ + self._principal_details = principal_details + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_change_summary_metrics.py b/src/oci/devops/models/pull_request_change_summary_metrics.py new file mode 100644 index 000000000..963f52c19 --- /dev/null +++ b/src/oci/devops/models/pull_request_change_summary_metrics.py @@ -0,0 +1,134 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestChangeSummaryMetrics(object): + """ + Response object for obtaining summary metric of Pull Request changed files. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestChangeSummaryMetrics object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param changed_files_count: + The value to assign to the changed_files_count property of this PullRequestChangeSummaryMetrics. + :type changed_files_count: int + + :param added_lines_count: + The value to assign to the added_lines_count property of this PullRequestChangeSummaryMetrics. + :type added_lines_count: int + + :param deleted_lines_count: + The value to assign to the deleted_lines_count property of this PullRequestChangeSummaryMetrics. + :type deleted_lines_count: int + + """ + self.swagger_types = { + 'changed_files_count': 'int', + 'added_lines_count': 'int', + 'deleted_lines_count': 'int' + } + + self.attribute_map = { + 'changed_files_count': 'changedFilesCount', + 'added_lines_count': 'addedLinesCount', + 'deleted_lines_count': 'deletedLinesCount' + } + + self._changed_files_count = None + self._added_lines_count = None + self._deleted_lines_count = None + + @property + def changed_files_count(self): + """ + **[Required]** Gets the changed_files_count of this PullRequestChangeSummaryMetrics. + The number of lines added in whole difference. + + + :return: The changed_files_count of this PullRequestChangeSummaryMetrics. + :rtype: int + """ + return self._changed_files_count + + @changed_files_count.setter + def changed_files_count(self, changed_files_count): + """ + Sets the changed_files_count of this PullRequestChangeSummaryMetrics. + The number of lines added in whole difference. + + + :param changed_files_count: The changed_files_count of this PullRequestChangeSummaryMetrics. + :type: int + """ + self._changed_files_count = changed_files_count + + @property + def added_lines_count(self): + """ + **[Required]** Gets the added_lines_count of this PullRequestChangeSummaryMetrics. + The number of lines added in whole difference. + + + :return: The added_lines_count of this PullRequestChangeSummaryMetrics. + :rtype: int + """ + return self._added_lines_count + + @added_lines_count.setter + def added_lines_count(self, added_lines_count): + """ + Sets the added_lines_count of this PullRequestChangeSummaryMetrics. + The number of lines added in whole difference. + + + :param added_lines_count: The added_lines_count of this PullRequestChangeSummaryMetrics. + :type: int + """ + self._added_lines_count = added_lines_count + + @property + def deleted_lines_count(self): + """ + **[Required]** Gets the deleted_lines_count of this PullRequestChangeSummaryMetrics. + The number of lines deleted in whole difference. + + + :return: The deleted_lines_count of this PullRequestChangeSummaryMetrics. + :rtype: int + """ + return self._deleted_lines_count + + @deleted_lines_count.setter + def deleted_lines_count(self, deleted_lines_count): + """ + Sets the deleted_lines_count of this PullRequestChangeSummaryMetrics. + The number of lines deleted in whole difference. + + + :param deleted_lines_count: The deleted_lines_count of this PullRequestChangeSummaryMetrics. + :type: int + """ + self._deleted_lines_count = deleted_lines_count + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_collection.py b/src/oci/devops/models/pull_request_collection.py new file mode 100644 index 000000000..3cbd4ae17 --- /dev/null +++ b/src/oci/devops/models/pull_request_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestCollection(object): + """ + Results of a Pull Request search. Contains both PullRequestSummary items and other information, such as metadata. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PullRequestCollection. + :type items: list[oci.devops.models.PullRequestSummary] + + """ + self.swagger_types = { + 'items': 'list[PullRequestSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this PullRequestCollection. + List of Pull Requests. + + + :return: The items of this PullRequestCollection. + :rtype: list[oci.devops.models.PullRequestSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PullRequestCollection. + List of Pull Requests. + + + :param items: The items of this PullRequestCollection. + :type: list[oci.devops.models.PullRequestSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_comment.py b/src/oci/devops/models/pull_request_comment.py new file mode 100644 index 000000000..43a114769 --- /dev/null +++ b/src/oci/devops/models/pull_request_comment.py @@ -0,0 +1,581 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestComment(object): + """ + User comments created by reviewers during the pull request review. + """ + + #: A constant which can be used with the file_type property of a PullRequestComment. + #: This constant has a value of "SOURCE" + FILE_TYPE_SOURCE = "SOURCE" + + #: A constant which can be used with the file_type property of a PullRequestComment. + #: This constant has a value of "DESTINATION" + FILE_TYPE_DESTINATION = "DESTINATION" + + #: A constant which can be used with the status property of a PullRequestComment. + #: This constant has a value of "ACTIVE" + STATUS_ACTIVE = "ACTIVE" + + #: A constant which can be used with the status property of a PullRequestComment. + #: This constant has a value of "OUTDATED" + STATUS_OUTDATED = "OUTDATED" + + #: A constant which can be used with the context_status property of a PullRequestComment. + #: This constant has a value of "PROCESSED" + CONTEXT_STATUS_PROCESSED = "PROCESSED" + + #: A constant which can be used with the context_status property of a PullRequestComment. + #: This constant has a value of "NEEDS_PROCESSING" + CONTEXT_STATUS_NEEDS_PROCESSING = "NEEDS_PROCESSING" + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestComment object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestComment. + :type id: str + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestComment. + :type pull_request_id: str + + :param data: + The value to assign to the data property of this PullRequestComment. + :type data: str + + :param parent_id: + The value to assign to the parent_id property of this PullRequestComment. + :type parent_id: str + + :param file_path: + The value to assign to the file_path property of this PullRequestComment. + :type file_path: str + + :param commit_id: + The value to assign to the commit_id property of this PullRequestComment. + :type commit_id: str + + :param file_type: + The value to assign to the file_type property of this PullRequestComment. + Allowed values for this property are: "SOURCE", "DESTINATION", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type file_type: str + + :param line_number: + The value to assign to the line_number property of this PullRequestComment. + :type line_number: int + + :param likes: + The value to assign to the likes property of this PullRequestComment. + :type likes: oci.devops.models.PullRequestCommentLikeCollection + + :param status: + The value to assign to the status property of this PullRequestComment. + Allowed values for this property are: "ACTIVE", "OUTDATED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type status: str + + :param time_created: + The value to assign to the time_created property of this PullRequestComment. + :type time_created: datetime + + :param created_by: + The value to assign to the created_by property of this PullRequestComment. + :type created_by: oci.devops.models.PrincipalDetails + + :param time_updated: + The value to assign to the time_updated property of this PullRequestComment. + :type time_updated: datetime + + :param updated_by: + The value to assign to the updated_by property of this PullRequestComment. + :type updated_by: oci.devops.models.PrincipalDetails + + :param context_status: + The value to assign to the context_status property of this PullRequestComment. + Allowed values for this property are: "PROCESSED", "NEEDS_PROCESSING", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type context_status: str + + :param comment_context: + The value to assign to the comment_context property of this PullRequestComment. + :type comment_context: list[oci.devops.models.DiffLineDetails] + + """ + self.swagger_types = { + 'id': 'str', + 'pull_request_id': 'str', + 'data': 'str', + 'parent_id': 'str', + 'file_path': 'str', + 'commit_id': 'str', + 'file_type': 'str', + 'line_number': 'int', + 'likes': 'PullRequestCommentLikeCollection', + 'status': 'str', + 'time_created': 'datetime', + 'created_by': 'PrincipalDetails', + 'time_updated': 'datetime', + 'updated_by': 'PrincipalDetails', + 'context_status': 'str', + 'comment_context': 'list[DiffLineDetails]' + } + + self.attribute_map = { + 'id': 'id', + 'pull_request_id': 'pullRequestId', + 'data': 'data', + 'parent_id': 'parentId', + 'file_path': 'filePath', + 'commit_id': 'commitId', + 'file_type': 'fileType', + 'line_number': 'lineNumber', + 'likes': 'likes', + 'status': 'status', + 'time_created': 'timeCreated', + 'created_by': 'createdBy', + 'time_updated': 'timeUpdated', + 'updated_by': 'updatedBy', + 'context_status': 'contextStatus', + 'comment_context': 'commentContext' + } + + self._id = None + self._pull_request_id = None + self._data = None + self._parent_id = None + self._file_path = None + self._commit_id = None + self._file_type = None + self._line_number = None + self._likes = None + self._status = None + self._time_created = None + self._created_by = None + self._time_updated = None + self._updated_by = None + self._context_status = None + self._comment_context = None + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequestComment. + Unique identifier that is immutable on creation + + + :return: The id of this PullRequestComment. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequestComment. + Unique identifier that is immutable on creation + + + :param id: The id of this PullRequestComment. + :type: str + """ + self._id = id + + @property + def pull_request_id(self): + """ + **[Required]** Gets the pull_request_id of this PullRequestComment. + OCID of the pull request that this comment belongs to + + + :return: The pull_request_id of this PullRequestComment. + :rtype: str + """ + return self._pull_request_id + + @pull_request_id.setter + def pull_request_id(self, pull_request_id): + """ + Sets the pull_request_id of this PullRequestComment. + OCID of the pull request that this comment belongs to + + + :param pull_request_id: The pull_request_id of this PullRequestComment. + :type: str + """ + self._pull_request_id = pull_request_id + + @property + def data(self): + """ + **[Required]** Gets the data of this PullRequestComment. + Content of the Comment. + + + :return: The data of this PullRequestComment. + :rtype: str + """ + return self._data + + @data.setter + def data(self, data): + """ + Sets the data of this PullRequestComment. + Content of the Comment. + + + :param data: The data of this PullRequestComment. + :type: str + """ + self._data = data + + @property + def parent_id(self): + """ + Gets the parent_id of this PullRequestComment. + ID of parent Comment + + + :return: The parent_id of this PullRequestComment. + :rtype: str + """ + return self._parent_id + + @parent_id.setter + def parent_id(self, parent_id): + """ + Sets the parent_id of this PullRequestComment. + ID of parent Comment + + + :param parent_id: The parent_id of this PullRequestComment. + :type: str + """ + self._parent_id = parent_id + + @property + def file_path(self): + """ + Gets the file_path of this PullRequestComment. + File path in the commit + + + :return: The file_path of this PullRequestComment. + :rtype: str + """ + return self._file_path + + @file_path.setter + def file_path(self, file_path): + """ + Sets the file_path of this PullRequestComment. + File path in the commit + + + :param file_path: The file_path of this PullRequestComment. + :type: str + """ + self._file_path = file_path + + @property + def commit_id(self): + """ + Gets the commit_id of this PullRequestComment. + Commit SHA + + + :return: The commit_id of this PullRequestComment. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this PullRequestComment. + Commit SHA + + + :param commit_id: The commit_id of this PullRequestComment. + :type: str + """ + self._commit_id = commit_id + + @property + def file_type(self): + """ + Gets the file_type of this PullRequestComment. + File path in the target commit + + Allowed values for this property are: "SOURCE", "DESTINATION", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The file_type of this PullRequestComment. + :rtype: str + """ + return self._file_type + + @file_type.setter + def file_type(self, file_type): + """ + Sets the file_type of this PullRequestComment. + File path in the target commit + + + :param file_type: The file_type of this PullRequestComment. + :type: str + """ + allowed_values = ["SOURCE", "DESTINATION"] + if not value_allowed_none_or_none_sentinel(file_type, allowed_values): + file_type = 'UNKNOWN_ENUM_VALUE' + self._file_type = file_type + + @property + def line_number(self): + """ + Gets the line_number of this PullRequestComment. + Line number in the file + + + :return: The line_number of this PullRequestComment. + :rtype: int + """ + return self._line_number + + @line_number.setter + def line_number(self, line_number): + """ + Sets the line_number of this PullRequestComment. + Line number in the file + + + :param line_number: The line_number of this PullRequestComment. + :type: int + """ + self._line_number = line_number + + @property + def likes(self): + """ + Gets the likes of this PullRequestComment. + + :return: The likes of this PullRequestComment. + :rtype: oci.devops.models.PullRequestCommentLikeCollection + """ + return self._likes + + @likes.setter + def likes(self, likes): + """ + Sets the likes of this PullRequestComment. + + :param likes: The likes of this PullRequestComment. + :type: oci.devops.models.PullRequestCommentLikeCollection + """ + self._likes = likes + + @property + def status(self): + """ + **[Required]** Gets the status of this PullRequestComment. + Status of the Comment + + Allowed values for this property are: "ACTIVE", "OUTDATED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The status of this PullRequestComment. + :rtype: str + """ + return self._status + + @status.setter + def status(self, status): + """ + Sets the status of this PullRequestComment. + Status of the Comment + + + :param status: The status of this PullRequestComment. + :type: str + """ + allowed_values = ["ACTIVE", "OUTDATED"] + if not value_allowed_none_or_none_sentinel(status, allowed_values): + status = 'UNKNOWN_ENUM_VALUE' + self._status = status + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this PullRequestComment. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_created of this PullRequestComment. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this PullRequestComment. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_created: The time_created of this PullRequestComment. + :type: datetime + """ + self._time_created = time_created + + @property + def created_by(self): + """ + **[Required]** Gets the created_by of this PullRequestComment. + + :return: The created_by of this PullRequestComment. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._created_by + + @created_by.setter + def created_by(self, created_by): + """ + Sets the created_by of this PullRequestComment. + + :param created_by: The created_by of this PullRequestComment. + :type: oci.devops.models.PrincipalDetails + """ + self._created_by = created_by + + @property + def time_updated(self): + """ + Gets the time_updated of this PullRequestComment. + Latest update timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_updated of this PullRequestComment. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this PullRequestComment. + Latest update timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_updated: The time_updated of this PullRequestComment. + :type: datetime + """ + self._time_updated = time_updated + + @property + def updated_by(self): + """ + Gets the updated_by of this PullRequestComment. + + :return: The updated_by of this PullRequestComment. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._updated_by + + @updated_by.setter + def updated_by(self, updated_by): + """ + Sets the updated_by of this PullRequestComment. + + :param updated_by: The updated_by of this PullRequestComment. + :type: oci.devops.models.PrincipalDetails + """ + self._updated_by = updated_by + + @property + def context_status(self): + """ + Gets the context_status of this PullRequestComment. + Shows the status of an inline comments context + + Allowed values for this property are: "PROCESSED", "NEEDS_PROCESSING", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The context_status of this PullRequestComment. + :rtype: str + """ + return self._context_status + + @context_status.setter + def context_status(self, context_status): + """ + Sets the context_status of this PullRequestComment. + Shows the status of an inline comments context + + + :param context_status: The context_status of this PullRequestComment. + :type: str + """ + allowed_values = ["PROCESSED", "NEEDS_PROCESSING"] + if not value_allowed_none_or_none_sentinel(context_status, allowed_values): + context_status = 'UNKNOWN_ENUM_VALUE' + self._context_status = context_status + + @property + def comment_context(self): + """ + Gets the comment_context of this PullRequestComment. + 4 line snippet to be displayed as context for inline comments + + + :return: The comment_context of this PullRequestComment. + :rtype: list[oci.devops.models.DiffLineDetails] + """ + return self._comment_context + + @comment_context.setter + def comment_context(self, comment_context): + """ + Sets the comment_context of this PullRequestComment. + 4 line snippet to be displayed as context for inline comments + + + :param comment_context: The comment_context of this PullRequestComment. + :type: list[oci.devops.models.DiffLineDetails] + """ + self._comment_context = comment_context + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_comment_collection.py b/src/oci/devops/models/pull_request_comment_collection.py new file mode 100644 index 000000000..f0cc10bf4 --- /dev/null +++ b/src/oci/devops/models/pull_request_comment_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestCommentCollection(object): + """ + Result of list pullRequest comments. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestCommentCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PullRequestCommentCollection. + :type items: list[oci.devops.models.PullRequestCommentSummary] + + """ + self.swagger_types = { + 'items': 'list[PullRequestCommentSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this PullRequestCommentCollection. + List of pullRequest comment objects. + + + :return: The items of this PullRequestCommentCollection. + :rtype: list[oci.devops.models.PullRequestCommentSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PullRequestCommentCollection. + List of pullRequest comment objects. + + + :param items: The items of this PullRequestCommentCollection. + :type: list[oci.devops.models.PullRequestCommentSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_comment_like_collection.py b/src/oci/devops/models/pull_request_comment_like_collection.py new file mode 100644 index 000000000..88d9a511e --- /dev/null +++ b/src/oci/devops/models/pull_request_comment_like_collection.py @@ -0,0 +1,103 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestCommentLikeCollection(object): + """ + Abstract of Pull Request Comment likes. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestCommentLikeCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param users: + The value to assign to the users property of this PullRequestCommentLikeCollection. + :type users: list[oci.devops.models.PrincipalDetails] + + :param total_likes: + The value to assign to the total_likes property of this PullRequestCommentLikeCollection. + :type total_likes: int + + """ + self.swagger_types = { + 'users': 'list[PrincipalDetails]', + 'total_likes': 'int' + } + + self.attribute_map = { + 'users': 'users', + 'total_likes': 'totalLikes' + } + + self._users = None + self._total_likes = None + + @property + def users(self): + """ + **[Required]** Gets the users of this PullRequestCommentLikeCollection. + List of liked users of whom liked the pull request comment (max size is 50). + + + :return: The users of this PullRequestCommentLikeCollection. + :rtype: list[oci.devops.models.PrincipalDetails] + """ + return self._users + + @users.setter + def users(self, users): + """ + Sets the users of this PullRequestCommentLikeCollection. + List of liked users of whom liked the pull request comment (max size is 50). + + + :param users: The users of this PullRequestCommentLikeCollection. + :type: list[oci.devops.models.PrincipalDetails] + """ + self._users = users + + @property + def total_likes(self): + """ + **[Required]** Gets the total_likes of this PullRequestCommentLikeCollection. + Total like counter + + + :return: The total_likes of this PullRequestCommentLikeCollection. + :rtype: int + """ + return self._total_likes + + @total_likes.setter + def total_likes(self, total_likes): + """ + Sets the total_likes of this PullRequestCommentLikeCollection. + Total like counter + + + :param total_likes: The total_likes of this PullRequestCommentLikeCollection. + :type: int + """ + self._total_likes = total_likes + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_comment_summary.py b/src/oci/devops/models/pull_request_comment_summary.py new file mode 100644 index 000000000..9f8f40d44 --- /dev/null +++ b/src/oci/devops/models/pull_request_comment_summary.py @@ -0,0 +1,533 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestCommentSummary(object): + """ + summary of a pullRequest comment + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestCommentSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestCommentSummary. + :type id: str + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestCommentSummary. + :type pull_request_id: str + + :param data: + The value to assign to the data property of this PullRequestCommentSummary. + :type data: str + + :param parent_id: + The value to assign to the parent_id property of this PullRequestCommentSummary. + :type parent_id: str + + :param file_path: + The value to assign to the file_path property of this PullRequestCommentSummary. + :type file_path: str + + :param commit_id: + The value to assign to the commit_id property of this PullRequestCommentSummary. + :type commit_id: str + + :param file_type: + The value to assign to the file_type property of this PullRequestCommentSummary. + :type file_type: str + + :param line_number: + The value to assign to the line_number property of this PullRequestCommentSummary. + :type line_number: int + + :param likes: + The value to assign to the likes property of this PullRequestCommentSummary. + :type likes: oci.devops.models.PullRequestCommentLikeCollection + + :param status: + The value to assign to the status property of this PullRequestCommentSummary. + :type status: str + + :param time_created: + The value to assign to the time_created property of this PullRequestCommentSummary. + :type time_created: datetime + + :param created_by: + The value to assign to the created_by property of this PullRequestCommentSummary. + :type created_by: oci.devops.models.PrincipalDetails + + :param time_updated: + The value to assign to the time_updated property of this PullRequestCommentSummary. + :type time_updated: datetime + + :param updated_by: + The value to assign to the updated_by property of this PullRequestCommentSummary. + :type updated_by: oci.devops.models.PrincipalDetails + + :param context_status: + The value to assign to the context_status property of this PullRequestCommentSummary. + :type context_status: str + + :param comment_context: + The value to assign to the comment_context property of this PullRequestCommentSummary. + :type comment_context: list[oci.devops.models.DiffLineDetails] + + """ + self.swagger_types = { + 'id': 'str', + 'pull_request_id': 'str', + 'data': 'str', + 'parent_id': 'str', + 'file_path': 'str', + 'commit_id': 'str', + 'file_type': 'str', + 'line_number': 'int', + 'likes': 'PullRequestCommentLikeCollection', + 'status': 'str', + 'time_created': 'datetime', + 'created_by': 'PrincipalDetails', + 'time_updated': 'datetime', + 'updated_by': 'PrincipalDetails', + 'context_status': 'str', + 'comment_context': 'list[DiffLineDetails]' + } + + self.attribute_map = { + 'id': 'id', + 'pull_request_id': 'pullRequestId', + 'data': 'data', + 'parent_id': 'parentId', + 'file_path': 'filePath', + 'commit_id': 'commitId', + 'file_type': 'fileType', + 'line_number': 'lineNumber', + 'likes': 'likes', + 'status': 'status', + 'time_created': 'timeCreated', + 'created_by': 'createdBy', + 'time_updated': 'timeUpdated', + 'updated_by': 'updatedBy', + 'context_status': 'contextStatus', + 'comment_context': 'commentContext' + } + + self._id = None + self._pull_request_id = None + self._data = None + self._parent_id = None + self._file_path = None + self._commit_id = None + self._file_type = None + self._line_number = None + self._likes = None + self._status = None + self._time_created = None + self._created_by = None + self._time_updated = None + self._updated_by = None + self._context_status = None + self._comment_context = None + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequestCommentSummary. + Unique identifier that is immutable on creation + + + :return: The id of this PullRequestCommentSummary. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequestCommentSummary. + Unique identifier that is immutable on creation + + + :param id: The id of this PullRequestCommentSummary. + :type: str + """ + self._id = id + + @property + def pull_request_id(self): + """ + **[Required]** Gets the pull_request_id of this PullRequestCommentSummary. + OCID of the pull request that this comment belongs to + + + :return: The pull_request_id of this PullRequestCommentSummary. + :rtype: str + """ + return self._pull_request_id + + @pull_request_id.setter + def pull_request_id(self, pull_request_id): + """ + Sets the pull_request_id of this PullRequestCommentSummary. + OCID of the pull request that this comment belongs to + + + :param pull_request_id: The pull_request_id of this PullRequestCommentSummary. + :type: str + """ + self._pull_request_id = pull_request_id + + @property + def data(self): + """ + **[Required]** Gets the data of this PullRequestCommentSummary. + Content of the Comment. + + + :return: The data of this PullRequestCommentSummary. + :rtype: str + """ + return self._data + + @data.setter + def data(self, data): + """ + Sets the data of this PullRequestCommentSummary. + Content of the Comment. + + + :param data: The data of this PullRequestCommentSummary. + :type: str + """ + self._data = data + + @property + def parent_id(self): + """ + Gets the parent_id of this PullRequestCommentSummary. + ID of parent Comment + + + :return: The parent_id of this PullRequestCommentSummary. + :rtype: str + """ + return self._parent_id + + @parent_id.setter + def parent_id(self, parent_id): + """ + Sets the parent_id of this PullRequestCommentSummary. + ID of parent Comment + + + :param parent_id: The parent_id of this PullRequestCommentSummary. + :type: str + """ + self._parent_id = parent_id + + @property + def file_path(self): + """ + Gets the file_path of this PullRequestCommentSummary. + File path in the commit + + + :return: The file_path of this PullRequestCommentSummary. + :rtype: str + """ + return self._file_path + + @file_path.setter + def file_path(self, file_path): + """ + Sets the file_path of this PullRequestCommentSummary. + File path in the commit + + + :param file_path: The file_path of this PullRequestCommentSummary. + :type: str + """ + self._file_path = file_path + + @property + def commit_id(self): + """ + Gets the commit_id of this PullRequestCommentSummary. + Commit SHA + + + :return: The commit_id of this PullRequestCommentSummary. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this PullRequestCommentSummary. + Commit SHA + + + :param commit_id: The commit_id of this PullRequestCommentSummary. + :type: str + """ + self._commit_id = commit_id + + @property + def file_type(self): + """ + Gets the file_type of this PullRequestCommentSummary. + File path in the target commit + + + :return: The file_type of this PullRequestCommentSummary. + :rtype: str + """ + return self._file_type + + @file_type.setter + def file_type(self, file_type): + """ + Sets the file_type of this PullRequestCommentSummary. + File path in the target commit + + + :param file_type: The file_type of this PullRequestCommentSummary. + :type: str + """ + self._file_type = file_type + + @property + def line_number(self): + """ + Gets the line_number of this PullRequestCommentSummary. + Line number in the file + + + :return: The line_number of this PullRequestCommentSummary. + :rtype: int + """ + return self._line_number + + @line_number.setter + def line_number(self, line_number): + """ + Sets the line_number of this PullRequestCommentSummary. + Line number in the file + + + :param line_number: The line_number of this PullRequestCommentSummary. + :type: int + """ + self._line_number = line_number + + @property + def likes(self): + """ + Gets the likes of this PullRequestCommentSummary. + + :return: The likes of this PullRequestCommentSummary. + :rtype: oci.devops.models.PullRequestCommentLikeCollection + """ + return self._likes + + @likes.setter + def likes(self, likes): + """ + Sets the likes of this PullRequestCommentSummary. + + :param likes: The likes of this PullRequestCommentSummary. + :type: oci.devops.models.PullRequestCommentLikeCollection + """ + self._likes = likes + + @property + def status(self): + """ + **[Required]** Gets the status of this PullRequestCommentSummary. + Status of the Comment + + + :return: The status of this PullRequestCommentSummary. + :rtype: str + """ + return self._status + + @status.setter + def status(self, status): + """ + Sets the status of this PullRequestCommentSummary. + Status of the Comment + + + :param status: The status of this PullRequestCommentSummary. + :type: str + """ + self._status = status + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this PullRequestCommentSummary. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_created of this PullRequestCommentSummary. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this PullRequestCommentSummary. + Creation timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_created: The time_created of this PullRequestCommentSummary. + :type: datetime + """ + self._time_created = time_created + + @property + def created_by(self): + """ + **[Required]** Gets the created_by of this PullRequestCommentSummary. + + :return: The created_by of this PullRequestCommentSummary. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._created_by + + @created_by.setter + def created_by(self, created_by): + """ + Sets the created_by of this PullRequestCommentSummary. + + :param created_by: The created_by of this PullRequestCommentSummary. + :type: oci.devops.models.PrincipalDetails + """ + self._created_by = created_by + + @property + def time_updated(self): + """ + Gets the time_updated of this PullRequestCommentSummary. + Latest update timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The time_updated of this PullRequestCommentSummary. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this PullRequestCommentSummary. + Latest update timestamp. Format defined by `RFC3339`__. + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param time_updated: The time_updated of this PullRequestCommentSummary. + :type: datetime + """ + self._time_updated = time_updated + + @property + def updated_by(self): + """ + Gets the updated_by of this PullRequestCommentSummary. + + :return: The updated_by of this PullRequestCommentSummary. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._updated_by + + @updated_by.setter + def updated_by(self, updated_by): + """ + Sets the updated_by of this PullRequestCommentSummary. + + :param updated_by: The updated_by of this PullRequestCommentSummary. + :type: oci.devops.models.PrincipalDetails + """ + self._updated_by = updated_by + + @property + def context_status(self): + """ + Gets the context_status of this PullRequestCommentSummary. + Shows the status of an inline comments context + + + :return: The context_status of this PullRequestCommentSummary. + :rtype: str + """ + return self._context_status + + @context_status.setter + def context_status(self, context_status): + """ + Sets the context_status of this PullRequestCommentSummary. + Shows the status of an inline comments context + + + :param context_status: The context_status of this PullRequestCommentSummary. + :type: str + """ + self._context_status = context_status + + @property + def comment_context(self): + """ + Gets the comment_context of this PullRequestCommentSummary. + 4 line snippet to be displayed as context for inline comments + + + :return: The comment_context of this PullRequestCommentSummary. + :rtype: list[oci.devops.models.DiffLineDetails] + """ + return self._comment_context + + @comment_context.setter + def comment_context(self, comment_context): + """ + Sets the comment_context of this PullRequestCommentSummary. + 4 line snippet to be displayed as context for inline comments + + + :param comment_context: The comment_context of this PullRequestCommentSummary. + :type: list[oci.devops.models.DiffLineDetails] + """ + self._comment_context = comment_context + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_file_change_collection.py b/src/oci/devops/models/pull_request_file_change_collection.py new file mode 100644 index 000000000..2cceb0ac3 --- /dev/null +++ b/src/oci/devops/models/pull_request_file_change_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestFileChangeCollection(object): + """ + Result of Pull Request difference. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestFileChangeCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this PullRequestFileChangeCollection. + :type items: list[oci.devops.models.PullRequestFileChangeSummary] + + """ + self.swagger_types = { + 'items': 'list[PullRequestFileChangeSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this PullRequestFileChangeCollection. + List of objects describing Pull Request differences for changed files. + + + :return: The items of this PullRequestFileChangeCollection. + :rtype: list[oci.devops.models.PullRequestFileChangeSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this PullRequestFileChangeCollection. + List of objects describing Pull Request differences for changed files. + + + :param items: The items of this PullRequestFileChangeCollection. + :type: list[oci.devops.models.PullRequestFileChangeSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_file_change_summary.py b/src/oci/devops/models/pull_request_file_change_summary.py new file mode 100644 index 000000000..c73f1048c --- /dev/null +++ b/src/oci/devops/models/pull_request_file_change_summary.py @@ -0,0 +1,456 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestFileChangeSummary(object): + """ + Entry for description of change on a file. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestFileChangeSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param change_type: + The value to assign to the change_type property of this PullRequestFileChangeSummary. + :type change_type: str + + :param object_type: + The value to assign to the object_type property of this PullRequestFileChangeSummary. + :type object_type: str + + :param commit_id: + The value to assign to the commit_id property of this PullRequestFileChangeSummary. + :type commit_id: str + + :param old_path: + The value to assign to the old_path property of this PullRequestFileChangeSummary. + :type old_path: str + + :param new_path: + The value to assign to the new_path property of this PullRequestFileChangeSummary. + :type new_path: str + + :param old_id: + The value to assign to the old_id property of this PullRequestFileChangeSummary. + :type old_id: str + + :param new_id: + The value to assign to the new_id property of this PullRequestFileChangeSummary. + :type new_id: str + + :param added_lines_count: + The value to assign to the added_lines_count property of this PullRequestFileChangeSummary. + :type added_lines_count: int + + :param deleted_lines_count: + The value to assign to the deleted_lines_count property of this PullRequestFileChangeSummary. + :type deleted_lines_count: int + + :param has_conflicts: + The value to assign to the has_conflicts property of this PullRequestFileChangeSummary. + :type has_conflicts: bool + + :param freeform_tags: + The value to assign to the freeform_tags property of this PullRequestFileChangeSummary. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this PullRequestFileChangeSummary. + :type defined_tags: dict(str, dict(str, object)) + + :param system_tags: + The value to assign to the system_tags property of this PullRequestFileChangeSummary. + :type system_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'change_type': 'str', + 'object_type': 'str', + 'commit_id': 'str', + 'old_path': 'str', + 'new_path': 'str', + 'old_id': 'str', + 'new_id': 'str', + 'added_lines_count': 'int', + 'deleted_lines_count': 'int', + 'has_conflicts': 'bool', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))', + 'system_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'change_type': 'changeType', + 'object_type': 'objectType', + 'commit_id': 'commitId', + 'old_path': 'oldPath', + 'new_path': 'newPath', + 'old_id': 'oldId', + 'new_id': 'newId', + 'added_lines_count': 'addedLinesCount', + 'deleted_lines_count': 'deletedLinesCount', + 'has_conflicts': 'hasConflicts', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags', + 'system_tags': 'systemTags' + } + + self._change_type = None + self._object_type = None + self._commit_id = None + self._old_path = None + self._new_path = None + self._old_id = None + self._new_id = None + self._added_lines_count = None + self._deleted_lines_count = None + self._has_conflicts = None + self._freeform_tags = None + self._defined_tags = None + self._system_tags = None + + @property + def change_type(self): + """ + **[Required]** Gets the change_type of this PullRequestFileChangeSummary. + Type of change made to file. + + + :return: The change_type of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._change_type + + @change_type.setter + def change_type(self, change_type): + """ + Sets the change_type of this PullRequestFileChangeSummary. + Type of change made to file. + + + :param change_type: The change_type of this PullRequestFileChangeSummary. + :type: str + """ + self._change_type = change_type + + @property + def object_type(self): + """ + Gets the object_type of this PullRequestFileChangeSummary. + The type of the changed object. + + + :return: The object_type of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._object_type + + @object_type.setter + def object_type(self, object_type): + """ + Sets the object_type of this PullRequestFileChangeSummary. + The type of the changed object. + + + :param object_type: The object_type of this PullRequestFileChangeSummary. + :type: str + """ + self._object_type = object_type + + @property + def commit_id(self): + """ + Gets the commit_id of this PullRequestFileChangeSummary. + The ID of the commit where the change is coming from. + + + :return: The commit_id of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._commit_id + + @commit_id.setter + def commit_id(self, commit_id): + """ + Sets the commit_id of this PullRequestFileChangeSummary. + The ID of the commit where the change is coming from. + + + :param commit_id: The commit_id of this PullRequestFileChangeSummary. + :type: str + """ + self._commit_id = commit_id + + @property + def old_path(self): + """ + Gets the old_path of this PullRequestFileChangeSummary. + The path on the target to the changed object. + + + :return: The old_path of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._old_path + + @old_path.setter + def old_path(self, old_path): + """ + Sets the old_path of this PullRequestFileChangeSummary. + The path on the target to the changed object. + + + :param old_path: The old_path of this PullRequestFileChangeSummary. + :type: str + """ + self._old_path = old_path + + @property + def new_path(self): + """ + Gets the new_path of this PullRequestFileChangeSummary. + The path on the source to the changed object. + + + :return: The new_path of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._new_path + + @new_path.setter + def new_path(self, new_path): + """ + Sets the new_path of this PullRequestFileChangeSummary. + The path on the source to the changed object. + + + :param new_path: The new_path of this PullRequestFileChangeSummary. + :type: str + """ + self._new_path = new_path + + @property + def old_id(self): + """ + Gets the old_id of this PullRequestFileChangeSummary. + The ID of the changed object on the target. + + + :return: The old_id of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._old_id + + @old_id.setter + def old_id(self, old_id): + """ + Sets the old_id of this PullRequestFileChangeSummary. + The ID of the changed object on the target. + + + :param old_id: The old_id of this PullRequestFileChangeSummary. + :type: str + """ + self._old_id = old_id + + @property + def new_id(self): + """ + Gets the new_id of this PullRequestFileChangeSummary. + The ID of the changed object on the source. + + + :return: The new_id of this PullRequestFileChangeSummary. + :rtype: str + """ + return self._new_id + + @new_id.setter + def new_id(self, new_id): + """ + Sets the new_id of this PullRequestFileChangeSummary. + The ID of the changed object on the source. + + + :param new_id: The new_id of this PullRequestFileChangeSummary. + :type: str + """ + self._new_id = new_id + + @property + def added_lines_count(self): + """ + Gets the added_lines_count of this PullRequestFileChangeSummary. + The number of lines added in whole difference. + + + :return: The added_lines_count of this PullRequestFileChangeSummary. + :rtype: int + """ + return self._added_lines_count + + @added_lines_count.setter + def added_lines_count(self, added_lines_count): + """ + Sets the added_lines_count of this PullRequestFileChangeSummary. + The number of lines added in whole difference. + + + :param added_lines_count: The added_lines_count of this PullRequestFileChangeSummary. + :type: int + """ + self._added_lines_count = added_lines_count + + @property + def deleted_lines_count(self): + """ + Gets the deleted_lines_count of this PullRequestFileChangeSummary. + The number of lines deleted in whole difference. + + + :return: The deleted_lines_count of this PullRequestFileChangeSummary. + :rtype: int + """ + return self._deleted_lines_count + + @deleted_lines_count.setter + def deleted_lines_count(self, deleted_lines_count): + """ + Sets the deleted_lines_count of this PullRequestFileChangeSummary. + The number of lines deleted in whole difference. + + + :param deleted_lines_count: The deleted_lines_count of this PullRequestFileChangeSummary. + :type: int + """ + self._deleted_lines_count = deleted_lines_count + + @property + def has_conflicts(self): + """ + Gets the has_conflicts of this PullRequestFileChangeSummary. + Indicates whether the changed file contains conflicts. + + + :return: The has_conflicts of this PullRequestFileChangeSummary. + :rtype: bool + """ + return self._has_conflicts + + @has_conflicts.setter + def has_conflicts(self, has_conflicts): + """ + Sets the has_conflicts of this PullRequestFileChangeSummary. + Indicates whether the changed file contains conflicts. + + + :param has_conflicts: The has_conflicts of this PullRequestFileChangeSummary. + :type: bool + """ + self._has_conflicts = has_conflicts + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this PullRequestFileChangeSummary. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this PullRequestFileChangeSummary. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this PullRequestFileChangeSummary. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this PullRequestFileChangeSummary. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + Gets the defined_tags of this PullRequestFileChangeSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this PullRequestFileChangeSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this PullRequestFileChangeSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this PullRequestFileChangeSummary. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def system_tags(self): + """ + Gets the system_tags of this PullRequestFileChangeSummary. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The system_tags of this PullRequestFileChangeSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._system_tags + + @system_tags.setter + def system_tags(self, system_tags): + """ + Sets the system_tags of this PullRequestFileChangeSummary. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param system_tags: The system_tags of this PullRequestFileChangeSummary. + :type: dict(str, dict(str, object)) + """ + self._system_tags = system_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_lifecycle_activity_summary.py b/src/oci/devops/models/pull_request_lifecycle_activity_summary.py new file mode 100644 index 000000000..067da0834 --- /dev/null +++ b/src/oci/devops/models/pull_request_lifecycle_activity_summary.py @@ -0,0 +1,135 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .pull_request_activity_summary import PullRequestActivitySummary +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestLifecycleActivitySummary(PullRequestActivitySummary): + """ + activity describing a pull request state change + """ + + #: A constant which can be used with the state property of a PullRequestLifecycleActivitySummary. + #: This constant has a value of "OPENED" + STATE_OPENED = "OPENED" + + #: A constant which can be used with the state property of a PullRequestLifecycleActivitySummary. + #: This constant has a value of "CLOSED" + STATE_CLOSED = "CLOSED" + + #: A constant which can be used with the state property of a PullRequestLifecycleActivitySummary. + #: This constant has a value of "MERGED" + STATE_MERGED = "MERGED" + + #: A constant which can be used with the state property of a PullRequestLifecycleActivitySummary. + #: This constant has a value of "REOPENED" + STATE_REOPENED = "REOPENED" + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestLifecycleActivitySummary object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.PullRequestLifecycleActivitySummary.activity_type` attribute + of this class is ``LIFECYCLE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestLifecycleActivitySummary. + :type id: str + + :param principal: + The value to assign to the principal property of this PullRequestLifecycleActivitySummary. + :type principal: oci.devops.models.PrincipalDetails + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestLifecycleActivitySummary. + :type pull_request_id: str + + :param time_occurred: + The value to assign to the time_occurred property of this PullRequestLifecycleActivitySummary. + :type time_occurred: datetime + + :param activity_type: + The value to assign to the activity_type property of this PullRequestLifecycleActivitySummary. + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type activity_type: str + + :param state: + The value to assign to the state property of this PullRequestLifecycleActivitySummary. + Allowed values for this property are: "OPENED", "CLOSED", "MERGED", "REOPENED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type state: str + + """ + self.swagger_types = { + 'id': 'str', + 'principal': 'PrincipalDetails', + 'pull_request_id': 'str', + 'time_occurred': 'datetime', + 'activity_type': 'str', + 'state': 'str' + } + + self.attribute_map = { + 'id': 'id', + 'principal': 'principal', + 'pull_request_id': 'pullRequestId', + 'time_occurred': 'timeOccurred', + 'activity_type': 'activityType', + 'state': 'state' + } + + self._id = None + self._principal = None + self._pull_request_id = None + self._time_occurred = None + self._activity_type = None + self._state = None + self._activity_type = 'LIFECYCLE' + + @property + def state(self): + """ + **[Required]** Gets the state of this PullRequestLifecycleActivitySummary. + The state of a pull request after an action. + + Allowed values for this property are: "OPENED", "CLOSED", "MERGED", "REOPENED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The state of this PullRequestLifecycleActivitySummary. + :rtype: str + """ + return self._state + + @state.setter + def state(self, state): + """ + Sets the state of this PullRequestLifecycleActivitySummary. + The state of a pull request after an action. + + + :param state: The state of this PullRequestLifecycleActivitySummary. + :type: str + """ + allowed_values = ["OPENED", "CLOSED", "MERGED", "REOPENED"] + if not value_allowed_none_or_none_sentinel(state, allowed_values): + state = 'UNKNOWN_ENUM_VALUE' + self._state = state + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_notification_preference.py b/src/oci/devops/models/pull_request_notification_preference.py new file mode 100644 index 000000000..50e2105a2 --- /dev/null +++ b/src/oci/devops/models/pull_request_notification_preference.py @@ -0,0 +1,154 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestNotificationPreference(object): + """ + The notification preference of the pull request. + """ + + #: A constant which can be used with the notification_preference property of a PullRequestNotificationPreference. + #: This constant has a value of "WATCH" + NOTIFICATION_PREFERENCE_WATCH = "WATCH" + + #: A constant which can be used with the notification_preference property of a PullRequestNotificationPreference. + #: This constant has a value of "IGNORE" + NOTIFICATION_PREFERENCE_IGNORE = "IGNORE" + + #: A constant which can be used with the notification_preference property of a PullRequestNotificationPreference. + #: This constant has a value of "MENTION" + NOTIFICATION_PREFERENCE_MENTION = "MENTION" + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestNotificationPreference object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param pull_request_id: + The value to assign to the pull_request_id property of this PullRequestNotificationPreference. + :type pull_request_id: str + + :param user_id: + The value to assign to the user_id property of this PullRequestNotificationPreference. + :type user_id: str + + :param notification_preference: + The value to assign to the notification_preference property of this PullRequestNotificationPreference. + Allowed values for this property are: "WATCH", "IGNORE", "MENTION", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type notification_preference: str + + """ + self.swagger_types = { + 'pull_request_id': 'str', + 'user_id': 'str', + 'notification_preference': 'str' + } + + self.attribute_map = { + 'pull_request_id': 'pullRequestId', + 'user_id': 'userId', + 'notification_preference': 'notificationPreference' + } + + self._pull_request_id = None + self._user_id = None + self._notification_preference = None + + @property + def pull_request_id(self): + """ + **[Required]** Gets the pull_request_id of this PullRequestNotificationPreference. + The ocid of pull request resource + + + :return: The pull_request_id of this PullRequestNotificationPreference. + :rtype: str + """ + return self._pull_request_id + + @pull_request_id.setter + def pull_request_id(self, pull_request_id): + """ + Sets the pull_request_id of this PullRequestNotificationPreference. + The ocid of pull request resource + + + :param pull_request_id: The pull_request_id of this PullRequestNotificationPreference. + :type: str + """ + self._pull_request_id = pull_request_id + + @property + def user_id(self): + """ + **[Required]** Gets the user_id of this PullRequestNotificationPreference. + The ocid of user. + + + :return: The user_id of this PullRequestNotificationPreference. + :rtype: str + """ + return self._user_id + + @user_id.setter + def user_id(self, user_id): + """ + Sets the user_id of this PullRequestNotificationPreference. + The ocid of user. + + + :param user_id: The user_id of this PullRequestNotificationPreference. + :type: str + """ + self._user_id = user_id + + @property + def notification_preference(self): + """ + **[Required]** Gets the notification_preference of this PullRequestNotificationPreference. + The override value of pull request notification preference. + + Allowed values for this property are: "WATCH", "IGNORE", "MENTION", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The notification_preference of this PullRequestNotificationPreference. + :rtype: str + """ + return self._notification_preference + + @notification_preference.setter + def notification_preference(self, notification_preference): + """ + Sets the notification_preference of this PullRequestNotificationPreference. + The override value of pull request notification preference. + + + :param notification_preference: The notification_preference of this PullRequestNotificationPreference. + :type: str + """ + allowed_values = ["WATCH", "IGNORE", "MENTION"] + if not value_allowed_none_or_none_sentinel(notification_preference, allowed_values): + notification_preference = 'UNKNOWN_ENUM_VALUE' + self._notification_preference = notification_preference + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/pull_request_summary.py b/src/oci/devops/models/pull_request_summary.py new file mode 100644 index 000000000..dce8dcb9d --- /dev/null +++ b/src/oci/devops/models/pull_request_summary.py @@ -0,0 +1,669 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class PullRequestSummary(object): + """ + Summary of the Pull Request. + """ + + def __init__(self, **kwargs): + """ + Initializes a new PullRequestSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this PullRequestSummary. + :type id: str + + :param display_name: + The value to assign to the display_name property of this PullRequestSummary. + :type display_name: str + + :param compartment_id: + The value to assign to the compartment_id property of this PullRequestSummary. + :type compartment_id: str + + :param description: + The value to assign to the description property of this PullRequestSummary. + :type description: str + + :param repository_id: + The value to assign to the repository_id property of this PullRequestSummary. + :type repository_id: str + + :param source_repository_id: + The value to assign to the source_repository_id property of this PullRequestSummary. + :type source_repository_id: str + + :param source_branch: + The value to assign to the source_branch property of this PullRequestSummary. + :type source_branch: str + + :param destination_branch: + The value to assign to the destination_branch property of this PullRequestSummary. + :type destination_branch: str + + :param source_commit_id_at_termination: + The value to assign to the source_commit_id_at_termination property of this PullRequestSummary. + :type source_commit_id_at_termination: str + + :param merge_base_commit_id_at_termination: + The value to assign to the merge_base_commit_id_at_termination property of this PullRequestSummary. + :type merge_base_commit_id_at_termination: str + + :param time_created: + The value to assign to the time_created property of this PullRequestSummary. + :type time_created: datetime + + :param time_updated: + The value to assign to the time_updated property of this PullRequestSummary. + :type time_updated: datetime + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this PullRequestSummary. + :type lifecycle_state: str + + :param lifecycle_details: + The value to assign to the lifecycle_details property of this PullRequestSummary. + :type lifecycle_details: str + + :param total_comments: + The value to assign to the total_comments property of this PullRequestSummary. + :type total_comments: int + + :param total_reviewers: + The value to assign to the total_reviewers property of this PullRequestSummary. + :type total_reviewers: int + + :param created_by: + The value to assign to the created_by property of this PullRequestSummary. + :type created_by: oci.devops.models.PrincipalDetails + + :param freeform_tags: + The value to assign to the freeform_tags property of this PullRequestSummary. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this PullRequestSummary. + :type defined_tags: dict(str, dict(str, object)) + + :param system_tags: + The value to assign to the system_tags property of this PullRequestSummary. + :type system_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'id': 'str', + 'display_name': 'str', + 'compartment_id': 'str', + 'description': 'str', + 'repository_id': 'str', + 'source_repository_id': 'str', + 'source_branch': 'str', + 'destination_branch': 'str', + 'source_commit_id_at_termination': 'str', + 'merge_base_commit_id_at_termination': 'str', + 'time_created': 'datetime', + 'time_updated': 'datetime', + 'lifecycle_state': 'str', + 'lifecycle_details': 'str', + 'total_comments': 'int', + 'total_reviewers': 'int', + 'created_by': 'PrincipalDetails', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))', + 'system_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'id': 'id', + 'display_name': 'displayName', + 'compartment_id': 'compartmentId', + 'description': 'description', + 'repository_id': 'repositoryId', + 'source_repository_id': 'sourceRepositoryId', + 'source_branch': 'sourceBranch', + 'destination_branch': 'destinationBranch', + 'source_commit_id_at_termination': 'sourceCommitIdAtTermination', + 'merge_base_commit_id_at_termination': 'mergeBaseCommitIdAtTermination', + 'time_created': 'timeCreated', + 'time_updated': 'timeUpdated', + 'lifecycle_state': 'lifecycleState', + 'lifecycle_details': 'lifecycleDetails', + 'total_comments': 'totalComments', + 'total_reviewers': 'totalReviewers', + 'created_by': 'createdBy', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags', + 'system_tags': 'systemTags' + } + + self._id = None + self._display_name = None + self._compartment_id = None + self._description = None + self._repository_id = None + self._source_repository_id = None + self._source_branch = None + self._destination_branch = None + self._source_commit_id_at_termination = None + self._merge_base_commit_id_at_termination = None + self._time_created = None + self._time_updated = None + self._lifecycle_state = None + self._lifecycle_details = None + self._total_comments = None + self._total_reviewers = None + self._created_by = None + self._freeform_tags = None + self._defined_tags = None + self._system_tags = None + + @property + def id(self): + """ + **[Required]** Gets the id of this PullRequestSummary. + Unique identifier that is immutable on creation + + + :return: The id of this PullRequestSummary. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this PullRequestSummary. + Unique identifier that is immutable on creation + + + :param id: The id of this PullRequestSummary. + :type: str + """ + self._id = id + + @property + def display_name(self): + """ + **[Required]** Gets the display_name of this PullRequestSummary. + Pull Request title, can be renamed + + + :return: The display_name of this PullRequestSummary. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this PullRequestSummary. + Pull Request title, can be renamed + + + :param display_name: The display_name of this PullRequestSummary. + :type: str + """ + self._display_name = display_name + + @property + def compartment_id(self): + """ + **[Required]** Gets the compartment_id of this PullRequestSummary. + Compartment Identifier + + + :return: The compartment_id of this PullRequestSummary. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this PullRequestSummary. + Compartment Identifier + + + :param compartment_id: The compartment_id of this PullRequestSummary. + :type: str + """ + self._compartment_id = compartment_id + + @property + def description(self): + """ + Gets the description of this PullRequestSummary. + Details of the pull request. Avoid entering confidential information. + + + :return: The description of this PullRequestSummary. + :rtype: str + """ + return self._description + + @description.setter + def description(self, description): + """ + Sets the description of this PullRequestSummary. + Details of the pull request. Avoid entering confidential information. + + + :param description: The description of this PullRequestSummary. + :type: str + """ + self._description = description + + @property + def repository_id(self): + """ + **[Required]** Gets the repository_id of this PullRequestSummary. + DevOps Repository Identifier + + + :return: The repository_id of this PullRequestSummary. + :rtype: str + """ + return self._repository_id + + @repository_id.setter + def repository_id(self, repository_id): + """ + Sets the repository_id of this PullRequestSummary. + DevOps Repository Identifier + + + :param repository_id: The repository_id of this PullRequestSummary. + :type: str + """ + self._repository_id = repository_id + + @property + def source_repository_id(self): + """ + Gets the source_repository_id of this PullRequestSummary. + The OCID of the forked repository that will act as the source of the changes to be included in the pull request against the parent repository. + + + :return: The source_repository_id of this PullRequestSummary. + :rtype: str + """ + return self._source_repository_id + + @source_repository_id.setter + def source_repository_id(self, source_repository_id): + """ + Sets the source_repository_id of this PullRequestSummary. + The OCID of the forked repository that will act as the source of the changes to be included in the pull request against the parent repository. + + + :param source_repository_id: The source_repository_id of this PullRequestSummary. + :type: str + """ + self._source_repository_id = source_repository_id + + @property + def source_branch(self): + """ + **[Required]** Gets the source_branch of this PullRequestSummary. + The review branch which contains the changes to be reviewed. + + + :return: The source_branch of this PullRequestSummary. + :rtype: str + """ + return self._source_branch + + @source_branch.setter + def source_branch(self, source_branch): + """ + Sets the source_branch of this PullRequestSummary. + The review branch which contains the changes to be reviewed. + + + :param source_branch: The source_branch of this PullRequestSummary. + :type: str + """ + self._source_branch = source_branch + + @property + def destination_branch(self): + """ + **[Required]** Gets the destination_branch of this PullRequestSummary. + The destination branch against which the changes are to be reviewed. + + + :return: The destination_branch of this PullRequestSummary. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this PullRequestSummary. + The destination branch against which the changes are to be reviewed. + + + :param destination_branch: The destination_branch of this PullRequestSummary. + :type: str + """ + self._destination_branch = destination_branch + + @property + def source_commit_id_at_termination(self): + """ + Gets the source_commit_id_at_termination of this PullRequestSummary. + The source branch commit ID when the Pull Request status was last changed to merged or closed + + + :return: The source_commit_id_at_termination of this PullRequestSummary. + :rtype: str + """ + return self._source_commit_id_at_termination + + @source_commit_id_at_termination.setter + def source_commit_id_at_termination(self, source_commit_id_at_termination): + """ + Sets the source_commit_id_at_termination of this PullRequestSummary. + The source branch commit ID when the Pull Request status was last changed to merged or closed + + + :param source_commit_id_at_termination: The source_commit_id_at_termination of this PullRequestSummary. + :type: str + """ + self._source_commit_id_at_termination = source_commit_id_at_termination + + @property + def merge_base_commit_id_at_termination(self): + """ + Gets the merge_base_commit_id_at_termination of this PullRequestSummary. + The merge base commit ID when the Pull Request status was last changed to merged or closed + + + :return: The merge_base_commit_id_at_termination of this PullRequestSummary. + :rtype: str + """ + return self._merge_base_commit_id_at_termination + + @merge_base_commit_id_at_termination.setter + def merge_base_commit_id_at_termination(self, merge_base_commit_id_at_termination): + """ + Sets the merge_base_commit_id_at_termination of this PullRequestSummary. + The merge base commit ID when the Pull Request status was last changed to merged or closed + + + :param merge_base_commit_id_at_termination: The merge_base_commit_id_at_termination of this PullRequestSummary. + :type: str + """ + self._merge_base_commit_id_at_termination = merge_base_commit_id_at_termination + + @property + def time_created(self): + """ + **[Required]** Gets the time_created of this PullRequestSummary. + The time the the Pull Request was created. An RFC3339 formatted datetime string + + + :return: The time_created of this PullRequestSummary. + :rtype: datetime + """ + return self._time_created + + @time_created.setter + def time_created(self, time_created): + """ + Sets the time_created of this PullRequestSummary. + The time the the Pull Request was created. An RFC3339 formatted datetime string + + + :param time_created: The time_created of this PullRequestSummary. + :type: datetime + """ + self._time_created = time_created + + @property + def time_updated(self): + """ + Gets the time_updated of this PullRequestSummary. + The time the Pull Request was updated. An RFC3339 formatted datetime string + + + :return: The time_updated of this PullRequestSummary. + :rtype: datetime + """ + return self._time_updated + + @time_updated.setter + def time_updated(self, time_updated): + """ + Sets the time_updated of this PullRequestSummary. + The time the Pull Request was updated. An RFC3339 formatted datetime string + + + :param time_updated: The time_updated of this PullRequestSummary. + :type: datetime + """ + self._time_updated = time_updated + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this PullRequestSummary. + The current state of the Pull Request. + + + :return: The lifecycle_state of this PullRequestSummary. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this PullRequestSummary. + The current state of the Pull Request. + + + :param lifecycle_state: The lifecycle_state of this PullRequestSummary. + :type: str + """ + self._lifecycle_state = lifecycle_state + + @property + def lifecycle_details(self): + """ + **[Required]** Gets the lifecycle_details of this PullRequestSummary. + The status of the Pull Request. + + + :return: The lifecycle_details of this PullRequestSummary. + :rtype: str + """ + return self._lifecycle_details + + @lifecycle_details.setter + def lifecycle_details(self, lifecycle_details): + """ + Sets the lifecycle_details of this PullRequestSummary. + The status of the Pull Request. + + + :param lifecycle_details: The lifecycle_details of this PullRequestSummary. + :type: str + """ + self._lifecycle_details = lifecycle_details + + @property + def total_comments(self): + """ + **[Required]** Gets the total_comments of this PullRequestSummary. + The total number of comments on the pull request. + + + :return: The total_comments of this PullRequestSummary. + :rtype: int + """ + return self._total_comments + + @total_comments.setter + def total_comments(self, total_comments): + """ + Sets the total_comments of this PullRequestSummary. + The total number of comments on the pull request. + + + :param total_comments: The total_comments of this PullRequestSummary. + :type: int + """ + self._total_comments = total_comments + + @property + def total_reviewers(self): + """ + **[Required]** Gets the total_reviewers of this PullRequestSummary. + The total number of reviewers on the pull request. + + + :return: The total_reviewers of this PullRequestSummary. + :rtype: int + """ + return self._total_reviewers + + @total_reviewers.setter + def total_reviewers(self, total_reviewers): + """ + Sets the total_reviewers of this PullRequestSummary. + The total number of reviewers on the pull request. + + + :param total_reviewers: The total_reviewers of this PullRequestSummary. + :type: int + """ + self._total_reviewers = total_reviewers + + @property + def created_by(self): + """ + **[Required]** Gets the created_by of this PullRequestSummary. + + :return: The created_by of this PullRequestSummary. + :rtype: oci.devops.models.PrincipalDetails + """ + return self._created_by + + @created_by.setter + def created_by(self, created_by): + """ + Sets the created_by of this PullRequestSummary. + + :param created_by: The created_by of this PullRequestSummary. + :type: oci.devops.models.PrincipalDetails + """ + self._created_by = created_by + + @property + def freeform_tags(self): + """ + **[Required]** Gets the freeform_tags of this PullRequestSummary. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this PullRequestSummary. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this PullRequestSummary. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this PullRequestSummary. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + **[Required]** Gets the defined_tags of this PullRequestSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this PullRequestSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this PullRequestSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this PullRequestSummary. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def system_tags(self): + """ + **[Required]** Gets the system_tags of this PullRequestSummary. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The system_tags of this PullRequestSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._system_tags + + @system_tags.setter + def system_tags(self, system_tags): + """ + Sets the system_tags of this PullRequestSummary. + Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param system_tags: The system_tags of this PullRequestSummary. + :type: dict(str, dict(str, object)) + """ + self._system_tags = system_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/repository.py b/src/oci/devops/models/repository.py index fc378ff0f..d2455ccfb 100644 --- a/src/oci/devops/models/repository.py +++ b/src/oci/devops/models/repository.py @@ -23,6 +23,10 @@ class Repository(object): #: This constant has a value of "HOSTED" REPOSITORY_TYPE_HOSTED = "HOSTED" + #: A constant which can be used with the repository_type property of a Repository. + #: This constant has a value of "FORKED" + REPOSITORY_TYPE_FORKED = "FORKED" + #: A constant which can be used with the lifecycle_state property of a Repository. #: This constant has a value of "ACTIVE" LIFECYCLE_STATE_ACTIVE = "ACTIVE" @@ -35,6 +39,10 @@ class Repository(object): #: This constant has a value of "DELETED" LIFECYCLE_STATE_DELETED = "DELETED" + #: A constant which can be used with the lifecycle_state property of a Repository. + #: This constant has a value of "FAILED" + LIFECYCLE_STATE_FAILED = "FAILED" + #: A constant which can be used with the lifecycle_state property of a Repository. #: This constant has a value of "DELETING" LIFECYCLE_STATE_DELETING = "DELETING" @@ -80,6 +88,10 @@ def __init__(self, **kwargs): The value to assign to the project_id property of this Repository. :type project_id: str + :param parent_repository_id: + The value to assign to the parent_repository_id property of this Repository. + :type parent_repository_id: str + :param project_name: The value to assign to the project_name property of this Repository. :type project_name: str @@ -102,7 +114,7 @@ def __init__(self, **kwargs): :param repository_type: The value to assign to the repository_type property of this Repository. - Allowed values for this property are: "MIRRORED", "HOSTED", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "MIRRORED", "HOSTED", "FORKED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type repository_type: str @@ -120,7 +132,7 @@ def __init__(self, **kwargs): :param lifecycle_state: The value to assign to the lifecycle_state property of this Repository. - Allowed values for this property are: "ACTIVE", "CREATING", "DELETED", "DELETING", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ACTIVE", "CREATING", "DELETED", "FAILED", "DELETING", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type lifecycle_state: str @@ -165,6 +177,7 @@ def __init__(self, **kwargs): 'compartment_id': 'str', 'namespace': 'str', 'project_id': 'str', + 'parent_repository_id': 'str', 'project_name': 'str', 'ssh_url': 'str', 'http_url': 'str', @@ -191,6 +204,7 @@ def __init__(self, **kwargs): 'compartment_id': 'compartmentId', 'namespace': 'namespace', 'project_id': 'projectId', + 'parent_repository_id': 'parentRepositoryId', 'project_name': 'projectName', 'ssh_url': 'sshUrl', 'http_url': 'httpUrl', @@ -216,6 +230,7 @@ def __init__(self, **kwargs): self._compartment_id = None self._namespace = None self._project_id = None + self._parent_repository_id = None self._project_name = None self._ssh_url = None self._http_url = None @@ -355,6 +370,30 @@ def project_id(self, project_id): """ self._project_id = project_id + @property + def parent_repository_id(self): + """ + Gets the parent_repository_id of this Repository. + The OCID of the parent repository. + + + :return: The parent_repository_id of this Repository. + :rtype: str + """ + return self._parent_repository_id + + @parent_repository_id.setter + def parent_repository_id(self, parent_repository_id): + """ + Sets the parent_repository_id of this Repository. + The OCID of the parent repository. + + + :param parent_repository_id: The parent_repository_id of this Repository. + :type: str + """ + self._parent_repository_id = parent_repository_id + @property def project_name(self): """ @@ -482,8 +521,9 @@ def repository_type(self): Type of repository: MIRRORED - Repository created by mirroring an existing repository. HOSTED - Repository created and hosted using OCI DevOps code repository. + FORKED - Repository created by forking an existing repository. - Allowed values for this property are: "MIRRORED", "HOSTED", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "MIRRORED", "HOSTED", "FORKED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -499,12 +539,13 @@ def repository_type(self, repository_type): Type of repository: MIRRORED - Repository created by mirroring an existing repository. HOSTED - Repository created and hosted using OCI DevOps code repository. + FORKED - Repository created by forking an existing repository. :param repository_type: The repository_type of this Repository. :type: str """ - allowed_values = ["MIRRORED", "HOSTED"] + allowed_values = ["MIRRORED", "HOSTED", "FORKED"] if not value_allowed_none_or_none_sentinel(repository_type, allowed_values): repository_type = 'UNKNOWN_ENUM_VALUE' self._repository_type = repository_type @@ -591,7 +632,7 @@ def lifecycle_state(self): Gets the lifecycle_state of this Repository. The current state of the repository. - Allowed values for this property are: "ACTIVE", "CREATING", "DELETED", "DELETING", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ACTIVE", "CREATING", "DELETED", "FAILED", "DELETING", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -610,7 +651,7 @@ def lifecycle_state(self, lifecycle_state): :param lifecycle_state: The lifecycle_state of this Repository. :type: str """ - allowed_values = ["ACTIVE", "CREATING", "DELETED", "DELETING"] + allowed_values = ["ACTIVE", "CREATING", "DELETED", "FAILED", "DELETING"] if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): lifecycle_state = 'UNKNOWN_ENUM_VALUE' self._lifecycle_state = lifecycle_state diff --git a/src/oci/devops/models/repository_analytics_details.py b/src/oci/devops/models/repository_analytics_details.py new file mode 100644 index 000000000..8b01f84d1 --- /dev/null +++ b/src/oci/devops/models/repository_analytics_details.py @@ -0,0 +1,318 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RepositoryAnalyticsDetails(object): + """ + Details of the user configured settings for viewing the metrics. + """ + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "COMMITS" + REPOSITORY_METRICS_COMMITS = "COMMITS" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "LINES_ADDED" + REPOSITORY_METRICS_LINES_ADDED = "LINES_ADDED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "LINES_DELETED" + REPOSITORY_METRICS_LINES_DELETED = "LINES_DELETED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_CREATED" + REPOSITORY_METRICS_PULL_REQUEST_CREATED = "PULL_REQUEST_CREATED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_MERGED" + REPOSITORY_METRICS_PULL_REQUEST_MERGED = "PULL_REQUEST_MERGED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_DECLINED" + REPOSITORY_METRICS_PULL_REQUEST_DECLINED = "PULL_REQUEST_DECLINED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + REPOSITORY_METRICS_PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + REPOSITORY_METRICS_PULL_REQUEST_REVIEW_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_APPROVED" + REPOSITORY_METRICS_PULL_REQUEST_APPROVED = "PULL_REQUEST_APPROVED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEWED" + REPOSITORY_METRICS_PULL_REQUEST_REVIEWED = "PULL_REQUEST_REVIEWED" + + #: A constant which can be used with the repository_metrics property of a RepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_COMMENTS" + REPOSITORY_METRICS_PULL_REQUEST_COMMENTS = "PULL_REQUEST_COMMENTS" + + #: A constant which can be used with the aggregation_duration property of a RepositoryAnalyticsDetails. + #: This constant has a value of "DAILY" + AGGREGATION_DURATION_DAILY = "DAILY" + + #: A constant which can be used with the aggregation_duration property of a RepositoryAnalyticsDetails. + #: This constant has a value of "WEEKLY" + AGGREGATION_DURATION_WEEKLY = "WEEKLY" + + #: A constant which can be used with the aggregation_duration property of a RepositoryAnalyticsDetails. + #: This constant has a value of "MONTHLY" + AGGREGATION_DURATION_MONTHLY = "MONTHLY" + + #: A constant which can be used with the aggregation_duration property of a RepositoryAnalyticsDetails. + #: This constant has a value of "YEARLY" + AGGREGATION_DURATION_YEARLY = "YEARLY" + + #: A constant which can be used with the group_by property of a RepositoryAnalyticsDetails. + #: This constant has a value of "AUTHOR" + GROUP_BY_AUTHOR = "AUTHOR" + + def __init__(self, **kwargs): + """ + Initializes a new RepositoryAnalyticsDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param author_email: + The value to assign to the author_email property of this RepositoryAnalyticsDetails. + :type author_email: str + + :param repository_metrics: + The value to assign to the repository_metrics property of this RepositoryAnalyticsDetails. + Allowed values for items in this list are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS" + :type repository_metrics: list[str] + + :param aggregation_duration: + The value to assign to the aggregation_duration property of this RepositoryAnalyticsDetails. + Allowed values for this property are: "DAILY", "WEEKLY", "MONTHLY", "YEARLY" + :type aggregation_duration: str + + :param start_time: + The value to assign to the start_time property of this RepositoryAnalyticsDetails. + :type start_time: datetime + + :param end_time: + The value to assign to the end_time property of this RepositoryAnalyticsDetails. + :type end_time: datetime + + :param group_by: + The value to assign to the group_by property of this RepositoryAnalyticsDetails. + Allowed values for this property are: "AUTHOR" + :type group_by: str + + """ + self.swagger_types = { + 'author_email': 'str', + 'repository_metrics': 'list[str]', + 'aggregation_duration': 'str', + 'start_time': 'datetime', + 'end_time': 'datetime', + 'group_by': 'str' + } + + self.attribute_map = { + 'author_email': 'authorEmail', + 'repository_metrics': 'repositoryMetrics', + 'aggregation_duration': 'aggregationDuration', + 'start_time': 'startTime', + 'end_time': 'endTime', + 'group_by': 'groupBy' + } + + self._author_email = None + self._repository_metrics = None + self._aggregation_duration = None + self._start_time = None + self._end_time = None + self._group_by = None + + @property + def author_email(self): + """ + Gets the author_email of this RepositoryAnalyticsDetails. + Email address of the author. + + + :return: The author_email of this RepositoryAnalyticsDetails. + :rtype: str + """ + return self._author_email + + @author_email.setter + def author_email(self, author_email): + """ + Sets the author_email of this RepositoryAnalyticsDetails. + Email address of the author. + + + :param author_email: The author_email of this RepositoryAnalyticsDetails. + :type: str + """ + self._author_email = author_email + + @property + def repository_metrics(self): + """ + **[Required]** Gets the repository_metrics of this RepositoryAnalyticsDetails. + The name of the metric to be filtered. + + Allowed values for items in this list are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS" + + + :return: The repository_metrics of this RepositoryAnalyticsDetails. + :rtype: list[str] + """ + return self._repository_metrics + + @repository_metrics.setter + def repository_metrics(self, repository_metrics): + """ + Sets the repository_metrics of this RepositoryAnalyticsDetails. + The name of the metric to be filtered. + + + :param repository_metrics: The repository_metrics of this RepositoryAnalyticsDetails. + :type: list[str] + """ + allowed_values = ["COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS"] + + if repository_metrics and repository_metrics is not NONE_SENTINEL: + for value in repository_metrics: + if not value_allowed_none_or_none_sentinel(value, allowed_values): + raise ValueError( + f"Invalid value for `repository_metrics`, must be None or one of {allowed_values}" + ) + self._repository_metrics = repository_metrics + + @property + def aggregation_duration(self): + """ + Gets the aggregation_duration of this RepositoryAnalyticsDetails. + Metrics aggregated for the defined period. + + Allowed values for this property are: "DAILY", "WEEKLY", "MONTHLY", "YEARLY" + + + :return: The aggregation_duration of this RepositoryAnalyticsDetails. + :rtype: str + """ + return self._aggregation_duration + + @aggregation_duration.setter + def aggregation_duration(self, aggregation_duration): + """ + Sets the aggregation_duration of this RepositoryAnalyticsDetails. + Metrics aggregated for the defined period. + + + :param aggregation_duration: The aggregation_duration of this RepositoryAnalyticsDetails. + :type: str + """ + allowed_values = ["DAILY", "WEEKLY", "MONTHLY", "YEARLY"] + if not value_allowed_none_or_none_sentinel(aggregation_duration, allowed_values): + raise ValueError( + f"Invalid value for `aggregation_duration`, must be None or one of {allowed_values}" + ) + self._aggregation_duration = aggregation_duration + + @property + def start_time(self): + """ + **[Required]** Gets the start_time of this RepositoryAnalyticsDetails. + The beginning of the metric data query time range. + + + :return: The start_time of this RepositoryAnalyticsDetails. + :rtype: datetime + """ + return self._start_time + + @start_time.setter + def start_time(self, start_time): + """ + Sets the start_time of this RepositoryAnalyticsDetails. + The beginning of the metric data query time range. + + + :param start_time: The start_time of this RepositoryAnalyticsDetails. + :type: datetime + """ + self._start_time = start_time + + @property + def end_time(self): + """ + Gets the end_time of this RepositoryAnalyticsDetails. + The end of the metric data query time range. + + + :return: The end_time of this RepositoryAnalyticsDetails. + :rtype: datetime + """ + return self._end_time + + @end_time.setter + def end_time(self, end_time): + """ + Sets the end_time of this RepositoryAnalyticsDetails. + The end of the metric data query time range. + + + :param end_time: The end_time of this RepositoryAnalyticsDetails. + :type: datetime + """ + self._end_time = end_time + + @property + def group_by(self): + """ + Gets the group_by of this RepositoryAnalyticsDetails. + Attribute by which metric data has to be grouped + + Allowed values for this property are: "AUTHOR" + + + :return: The group_by of this RepositoryAnalyticsDetails. + :rtype: str + """ + return self._group_by + + @group_by.setter + def group_by(self, group_by): + """ + Sets the group_by of this RepositoryAnalyticsDetails. + Attribute by which metric data has to be grouped + + + :param group_by: The group_by of this RepositoryAnalyticsDetails. + :type: str + """ + allowed_values = ["AUTHOR"] + if not value_allowed_none_or_none_sentinel(group_by, allowed_values): + raise ValueError( + f"Invalid value for `group_by`, must be None or one of {allowed_values}" + ) + self._group_by = group_by + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/repository_metric_aggregation.py b/src/oci/devops/models/repository_metric_aggregation.py new file mode 100644 index 000000000..5ff1b774e --- /dev/null +++ b/src/oci/devops/models/repository_metric_aggregation.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RepositoryMetricAggregation(object): + """ + The set of aggregated data returned for repository analytics. + """ + + def __init__(self, **kwargs): + """ + Initializes a new RepositoryMetricAggregation object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this RepositoryMetricAggregation. + :type items: list[oci.devops.models.RepositoryMetricSummary] + + """ + self.swagger_types = { + 'items': 'list[RepositoryMetricSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this RepositoryMetricAggregation. + The metric data. + + + :return: The items of this RepositoryMetricAggregation. + :rtype: list[oci.devops.models.RepositoryMetricSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this RepositoryMetricAggregation. + The metric data. + + + :param items: The items of this RepositoryMetricAggregation. + :type: list[oci.devops.models.RepositoryMetricSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/repository_metric_summary.py b/src/oci/devops/models/repository_metric_summary.py new file mode 100644 index 000000000..30a982f88 --- /dev/null +++ b/src/oci/devops/models/repository_metric_summary.py @@ -0,0 +1,281 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RepositoryMetricSummary(object): + """ + The metrics details of a repository resource. + """ + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "COMMITS" + METRIC_NAME_COMMITS = "COMMITS" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "LINES_ADDED" + METRIC_NAME_LINES_ADDED = "LINES_ADDED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "LINES_DELETED" + METRIC_NAME_LINES_DELETED = "LINES_DELETED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_CREATED" + METRIC_NAME_PULL_REQUEST_CREATED = "PULL_REQUEST_CREATED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_MERGED" + METRIC_NAME_PULL_REQUEST_MERGED = "PULL_REQUEST_MERGED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_DECLINED" + METRIC_NAME_PULL_REQUEST_DECLINED = "PULL_REQUEST_DECLINED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + METRIC_NAME_PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + METRIC_NAME_PULL_REQUEST_REVIEW_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_APPROVED" + METRIC_NAME_PULL_REQUEST_APPROVED = "PULL_REQUEST_APPROVED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_REVIEWED" + METRIC_NAME_PULL_REQUEST_REVIEWED = "PULL_REQUEST_REVIEWED" + + #: A constant which can be used with the metric_name property of a RepositoryMetricSummary. + #: This constant has a value of "PULL_REQUEST_COMMENTS" + METRIC_NAME_PULL_REQUEST_COMMENTS = "PULL_REQUEST_COMMENTS" + + def __init__(self, **kwargs): + """ + Initializes a new RepositoryMetricSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param metric_name: + The value to assign to the metric_name property of this RepositoryMetricSummary. + Allowed values for this property are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type metric_name: str + + :param duration_in_seconds: + The value to assign to the duration_in_seconds property of this RepositoryMetricSummary. + :type duration_in_seconds: int + + :param dimensions: + The value to assign to the dimensions property of this RepositoryMetricSummary. + :type dimensions: dict(str, str) + + :param start_timestamp_in_epoch_seconds: + The value to assign to the start_timestamp_in_epoch_seconds property of this RepositoryMetricSummary. + :type start_timestamp_in_epoch_seconds: int + + :param count: + The value to assign to the count property of this RepositoryMetricSummary. + :type count: float + + :param sum: + The value to assign to the sum property of this RepositoryMetricSummary. + :type sum: float + + """ + self.swagger_types = { + 'metric_name': 'str', + 'duration_in_seconds': 'int', + 'dimensions': 'dict(str, str)', + 'start_timestamp_in_epoch_seconds': 'int', + 'count': 'float', + 'sum': 'float' + } + + self.attribute_map = { + 'metric_name': 'metricName', + 'duration_in_seconds': 'durationInSeconds', + 'dimensions': 'dimensions', + 'start_timestamp_in_epoch_seconds': 'startTimestampInEpochSeconds', + 'count': 'count', + 'sum': 'sum' + } + + self._metric_name = None + self._duration_in_seconds = None + self._dimensions = None + self._start_timestamp_in_epoch_seconds = None + self._count = None + self._sum = None + + @property + def metric_name(self): + """ + Gets the metric_name of this RepositoryMetricSummary. + Type of metric + + Allowed values for this property are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The metric_name of this RepositoryMetricSummary. + :rtype: str + """ + return self._metric_name + + @metric_name.setter + def metric_name(self, metric_name): + """ + Sets the metric_name of this RepositoryMetricSummary. + Type of metric + + + :param metric_name: The metric_name of this RepositoryMetricSummary. + :type: str + """ + allowed_values = ["COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS"] + if not value_allowed_none_or_none_sentinel(metric_name, allowed_values): + metric_name = 'UNKNOWN_ENUM_VALUE' + self._metric_name = metric_name + + @property + def duration_in_seconds(self): + """ + Gets the duration_in_seconds of this RepositoryMetricSummary. + The duration of the returned aggregated data in seconds. + + + :return: The duration_in_seconds of this RepositoryMetricSummary. + :rtype: int + """ + return self._duration_in_seconds + + @duration_in_seconds.setter + def duration_in_seconds(self, duration_in_seconds): + """ + Sets the duration_in_seconds of this RepositoryMetricSummary. + The duration of the returned aggregated data in seconds. + + + :param duration_in_seconds: The duration_in_seconds of this RepositoryMetricSummary. + :type: int + """ + self._duration_in_seconds = duration_in_seconds + + @property + def dimensions(self): + """ + Gets the dimensions of this RepositoryMetricSummary. + The qualifiers provided in the definition of the returned metric. + + + :return: The dimensions of this RepositoryMetricSummary. + :rtype: dict(str, str) + """ + return self._dimensions + + @dimensions.setter + def dimensions(self, dimensions): + """ + Sets the dimensions of this RepositoryMetricSummary. + The qualifiers provided in the definition of the returned metric. + + + :param dimensions: The dimensions of this RepositoryMetricSummary. + :type: dict(str, str) + """ + self._dimensions = dimensions + + @property + def start_timestamp_in_epoch_seconds(self): + """ + Gets the start_timestamp_in_epoch_seconds of this RepositoryMetricSummary. + The start time associated with the value of the metric. + + + :return: The start_timestamp_in_epoch_seconds of this RepositoryMetricSummary. + :rtype: int + """ + return self._start_timestamp_in_epoch_seconds + + @start_timestamp_in_epoch_seconds.setter + def start_timestamp_in_epoch_seconds(self, start_timestamp_in_epoch_seconds): + """ + Sets the start_timestamp_in_epoch_seconds of this RepositoryMetricSummary. + The start time associated with the value of the metric. + + + :param start_timestamp_in_epoch_seconds: The start_timestamp_in_epoch_seconds of this RepositoryMetricSummary. + :type: int + """ + self._start_timestamp_in_epoch_seconds = start_timestamp_in_epoch_seconds + + @property + def count(self): + """ + Gets the count of this RepositoryMetricSummary. + Represents the total number of the metric being calculated. + + + :return: The count of this RepositoryMetricSummary. + :rtype: float + """ + return self._count + + @count.setter + def count(self, count): + """ + Sets the count of this RepositoryMetricSummary. + Represents the total number of the metric being calculated. + + + :param count: The count of this RepositoryMetricSummary. + :type: float + """ + self._count = count + + @property + def sum(self): + """ + Gets the sum of this RepositoryMetricSummary. + Represents the total duration in days calculated corresponding to the total no. of PRs. + This is used only for \"PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS\" and \"PULL_REQUEST_REVIEW_DURATION_IN_DAYS\" metrics. + + + :return: The sum of this RepositoryMetricSummary. + :rtype: float + """ + return self._sum + + @sum.setter + def sum(self, sum): + """ + Sets the sum of this RepositoryMetricSummary. + Represents the total duration in days calculated corresponding to the total no. of PRs. + This is used only for \"PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS\" and \"PULL_REQUEST_REVIEW_DURATION_IN_DAYS\" metrics. + + + :param sum: The sum of this RepositoryMetricSummary. + :type: float + """ + self._sum = sum + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/repository_notification_preference.py b/src/oci/devops/models/repository_notification_preference.py new file mode 100644 index 000000000..cd7fe452c --- /dev/null +++ b/src/oci/devops/models/repository_notification_preference.py @@ -0,0 +1,158 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RepositoryNotificationPreference(object): + """ + The notification preference of the repository. + """ + + #: A constant which can be used with the notification_preference property of a RepositoryNotificationPreference. + #: This constant has a value of "WATCH" + NOTIFICATION_PREFERENCE_WATCH = "WATCH" + + #: A constant which can be used with the notification_preference property of a RepositoryNotificationPreference. + #: This constant has a value of "IGNORE" + NOTIFICATION_PREFERENCE_IGNORE = "IGNORE" + + #: A constant which can be used with the notification_preference property of a RepositoryNotificationPreference. + #: This constant has a value of "MENTION" + NOTIFICATION_PREFERENCE_MENTION = "MENTION" + + #: A constant which can be used with the notification_preference property of a RepositoryNotificationPreference. + #: This constant has a value of "INHERITED" + NOTIFICATION_PREFERENCE_INHERITED = "INHERITED" + + def __init__(self, **kwargs): + """ + Initializes a new RepositoryNotificationPreference object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param repository_id: + The value to assign to the repository_id property of this RepositoryNotificationPreference. + :type repository_id: str + + :param user_id: + The value to assign to the user_id property of this RepositoryNotificationPreference. + :type user_id: str + + :param notification_preference: + The value to assign to the notification_preference property of this RepositoryNotificationPreference. + Allowed values for this property are: "WATCH", "IGNORE", "MENTION", "INHERITED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type notification_preference: str + + """ + self.swagger_types = { + 'repository_id': 'str', + 'user_id': 'str', + 'notification_preference': 'str' + } + + self.attribute_map = { + 'repository_id': 'repositoryId', + 'user_id': 'userId', + 'notification_preference': 'notificationPreference' + } + + self._repository_id = None + self._user_id = None + self._notification_preference = None + + @property + def repository_id(self): + """ + **[Required]** Gets the repository_id of this RepositoryNotificationPreference. + The ocid of repository resource + + + :return: The repository_id of this RepositoryNotificationPreference. + :rtype: str + """ + return self._repository_id + + @repository_id.setter + def repository_id(self, repository_id): + """ + Sets the repository_id of this RepositoryNotificationPreference. + The ocid of repository resource + + + :param repository_id: The repository_id of this RepositoryNotificationPreference. + :type: str + """ + self._repository_id = repository_id + + @property + def user_id(self): + """ + **[Required]** Gets the user_id of this RepositoryNotificationPreference. + The ocid of user. + + + :return: The user_id of this RepositoryNotificationPreference. + :rtype: str + """ + return self._user_id + + @user_id.setter + def user_id(self, user_id): + """ + Sets the user_id of this RepositoryNotificationPreference. + The ocid of user. + + + :param user_id: The user_id of this RepositoryNotificationPreference. + :type: str + """ + self._user_id = user_id + + @property + def notification_preference(self): + """ + **[Required]** Gets the notification_preference of this RepositoryNotificationPreference. + The override value of repository notification preference. + + Allowed values for this property are: "WATCH", "IGNORE", "MENTION", "INHERITED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The notification_preference of this RepositoryNotificationPreference. + :rtype: str + """ + return self._notification_preference + + @notification_preference.setter + def notification_preference(self, notification_preference): + """ + Sets the notification_preference of this RepositoryNotificationPreference. + The override value of repository notification preference. + + + :param notification_preference: The notification_preference of this RepositoryNotificationPreference. + :type: str + """ + allowed_values = ["WATCH", "IGNORE", "MENTION", "INHERITED"] + if not value_allowed_none_or_none_sentinel(notification_preference, allowed_values): + notification_preference = 'UNKNOWN_ENUM_VALUE' + self._notification_preference = notification_preference + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/repository_settings.py b/src/oci/devops/models/repository_settings.py new file mode 100644 index 000000000..52a38da66 --- /dev/null +++ b/src/oci/devops/models/repository_settings.py @@ -0,0 +1,122 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RepositorySettings(object): + """ + User configured settings for repository resources + """ + + def __init__(self, **kwargs): + """ + Initializes a new RepositorySettings object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param merge_checks: + The value to assign to the merge_checks property of this RepositorySettings. + :type merge_checks: oci.devops.models.MergeChecks + + :param merge_settings: + The value to assign to the merge_settings property of this RepositorySettings. + :type merge_settings: oci.devops.models.MergeSettings + + :param approval_rules: + The value to assign to the approval_rules property of this RepositorySettings. + :type approval_rules: oci.devops.models.ApprovalRuleCollection + + """ + self.swagger_types = { + 'merge_checks': 'MergeChecks', + 'merge_settings': 'MergeSettings', + 'approval_rules': 'ApprovalRuleCollection' + } + + self.attribute_map = { + 'merge_checks': 'mergeChecks', + 'merge_settings': 'mergeSettings', + 'approval_rules': 'approvalRules' + } + + self._merge_checks = None + self._merge_settings = None + self._approval_rules = None + + @property + def merge_checks(self): + """ + **[Required]** Gets the merge_checks of this RepositorySettings. + + :return: The merge_checks of this RepositorySettings. + :rtype: oci.devops.models.MergeChecks + """ + return self._merge_checks + + @merge_checks.setter + def merge_checks(self, merge_checks): + """ + Sets the merge_checks of this RepositorySettings. + + :param merge_checks: The merge_checks of this RepositorySettings. + :type: oci.devops.models.MergeChecks + """ + self._merge_checks = merge_checks + + @property + def merge_settings(self): + """ + **[Required]** Gets the merge_settings of this RepositorySettings. + + :return: The merge_settings of this RepositorySettings. + :rtype: oci.devops.models.MergeSettings + """ + return self._merge_settings + + @merge_settings.setter + def merge_settings(self, merge_settings): + """ + Sets the merge_settings of this RepositorySettings. + + :param merge_settings: The merge_settings of this RepositorySettings. + :type: oci.devops.models.MergeSettings + """ + self._merge_settings = merge_settings + + @property + def approval_rules(self): + """ + **[Required]** Gets the approval_rules of this RepositorySettings. + + :return: The approval_rules of this RepositorySettings. + :rtype: oci.devops.models.ApprovalRuleCollection + """ + return self._approval_rules + + @approval_rules.setter + def approval_rules(self, approval_rules): + """ + Sets the approval_rules of this RepositorySettings. + + :param approval_rules: The approval_rules of this RepositorySettings. + :type: oci.devops.models.ApprovalRuleCollection + """ + self._approval_rules = approval_rules + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/repository_summary.py b/src/oci/devops/models/repository_summary.py index 4e62644b7..9c395092f 100644 --- a/src/oci/devops/models/repository_summary.py +++ b/src/oci/devops/models/repository_summary.py @@ -36,6 +36,10 @@ def __init__(self, **kwargs): The value to assign to the project_id property of this RepositorySummary. :type project_id: str + :param parent_repository_id: + The value to assign to the parent_repository_id property of this RepositorySummary. + :type parent_repository_id: str + :param namespace: The value to assign to the namespace property of this RepositorySummary. :type namespace: str @@ -102,6 +106,7 @@ def __init__(self, **kwargs): 'name': 'str', 'compartment_id': 'str', 'project_id': 'str', + 'parent_repository_id': 'str', 'namespace': 'str', 'project_name': 'str', 'description': 'str', @@ -124,6 +129,7 @@ def __init__(self, **kwargs): 'name': 'name', 'compartment_id': 'compartmentId', 'project_id': 'projectId', + 'parent_repository_id': 'parentRepositoryId', 'namespace': 'namespace', 'project_name': 'projectName', 'description': 'description', @@ -145,6 +151,7 @@ def __init__(self, **kwargs): self._name = None self._compartment_id = None self._project_id = None + self._parent_repository_id = None self._namespace = None self._project_name = None self._description = None @@ -257,6 +264,30 @@ def project_id(self, project_id): """ self._project_id = project_id + @property + def parent_repository_id(self): + """ + Gets the parent_repository_id of this RepositorySummary. + The OCID of the parent repository. + + + :return: The parent_repository_id of this RepositorySummary. + :rtype: str + """ + return self._parent_repository_id + + @parent_repository_id.setter + def parent_repository_id(self, parent_repository_id): + """ + Sets the parent_repository_id of this RepositorySummary. + The OCID of the parent repository. + + + :param parent_repository_id: The parent_repository_id of this RepositorySummary. + :type: str + """ + self._parent_repository_id = parent_repository_id + @property def namespace(self): """ @@ -360,6 +391,7 @@ def repository_type(self): Type of repository. Allowed values: `MIRRORED` `HOSTED` + `FORKED` :return: The repository_type of this RepositorySummary. @@ -374,6 +406,7 @@ def repository_type(self, repository_type): Type of repository. Allowed values: `MIRRORED` `HOSTED` + `FORKED` :param repository_type: The repository_type of this RepositorySummary. diff --git a/src/oci/devops/models/review_pull_request_details.py b/src/oci/devops/models/review_pull_request_details.py new file mode 100644 index 000000000..2db607839 --- /dev/null +++ b/src/oci/devops/models/review_pull_request_details.py @@ -0,0 +1,88 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ReviewPullRequestDetails(object): + """ + Details to submit pull request review + """ + + #: A constant which can be used with the action property of a ReviewPullRequestDetails. + #: This constant has a value of "APPROVE" + ACTION_APPROVE = "APPROVE" + + #: A constant which can be used with the action property of a ReviewPullRequestDetails. + #: This constant has a value of "UNAPPROVE" + ACTION_UNAPPROVE = "UNAPPROVE" + + def __init__(self, **kwargs): + """ + Initializes a new ReviewPullRequestDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param action: + The value to assign to the action property of this ReviewPullRequestDetails. + Allowed values for this property are: "APPROVE", "UNAPPROVE" + :type action: str + + """ + self.swagger_types = { + 'action': 'str' + } + + self.attribute_map = { + 'action': 'action' + } + + self._action = None + + @property + def action(self): + """ + **[Required]** Gets the action of this ReviewPullRequestDetails. + The review action taken + + Allowed values for this property are: "APPROVE", "UNAPPROVE" + + + :return: The action of this ReviewPullRequestDetails. + :rtype: str + """ + return self._action + + @action.setter + def action(self, action): + """ + Sets the action of this ReviewPullRequestDetails. + The review action taken + + + :param action: The action of this ReviewPullRequestDetails. + :type: str + """ + allowed_values = ["APPROVE", "UNAPPROVE"] + if not value_allowed_none_or_none_sentinel(action, allowed_values): + raise ValueError( + f"Invalid value for `action`, must be None or one of {allowed_values}" + ) + self._action = action + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/reviewer.py b/src/oci/devops/models/reviewer.py new file mode 100644 index 000000000..94f7cac35 --- /dev/null +++ b/src/oci/devops/models/reviewer.py @@ -0,0 +1,256 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class Reviewer(object): + """ + Reviewer information. + """ + + #: A constant which can be used with the principal_type property of a Reviewer. + #: This constant has a value of "SERVICE" + PRINCIPAL_TYPE_SERVICE = "SERVICE" + + #: A constant which can be used with the principal_type property of a Reviewer. + #: This constant has a value of "USER" + PRINCIPAL_TYPE_USER = "USER" + + #: A constant which can be used with the principal_type property of a Reviewer. + #: This constant has a value of "INSTANCE" + PRINCIPAL_TYPE_INSTANCE = "INSTANCE" + + #: A constant which can be used with the principal_type property of a Reviewer. + #: This constant has a value of "RESOURCE" + PRINCIPAL_TYPE_RESOURCE = "RESOURCE" + + #: A constant which can be used with the principal_state property of a Reviewer. + #: This constant has a value of "ACTIVE" + PRINCIPAL_STATE_ACTIVE = "ACTIVE" + + #: A constant which can be used with the principal_state property of a Reviewer. + #: This constant has a value of "INACTIVE" + PRINCIPAL_STATE_INACTIVE = "INACTIVE" + + #: A constant which can be used with the principal_state property of a Reviewer. + #: This constant has a value of "SUPPRESSED" + PRINCIPAL_STATE_SUPPRESSED = "SUPPRESSED" + + #: A constant which can be used with the status property of a Reviewer. + #: This constant has a value of "APPROVED" + STATUS_APPROVED = "APPROVED" + + #: A constant which can be used with the status property of a Reviewer. + #: This constant has a value of "REVIEW_PENDING" + STATUS_REVIEW_PENDING = "REVIEW_PENDING" + + def __init__(self, **kwargs): + """ + Initializes a new Reviewer object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param principal_id: + The value to assign to the principal_id property of this Reviewer. + :type principal_id: str + + :param principal_name: + The value to assign to the principal_name property of this Reviewer. + :type principal_name: str + + :param principal_type: + The value to assign to the principal_type property of this Reviewer. + Allowed values for this property are: "SERVICE", "USER", "INSTANCE", "RESOURCE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type principal_type: str + + :param principal_state: + The value to assign to the principal_state property of this Reviewer. + Allowed values for this property are: "ACTIVE", "INACTIVE", "SUPPRESSED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type principal_state: str + + :param status: + The value to assign to the status property of this Reviewer. + Allowed values for this property are: "APPROVED", "REVIEW_PENDING", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type status: str + + """ + self.swagger_types = { + 'principal_id': 'str', + 'principal_name': 'str', + 'principal_type': 'str', + 'principal_state': 'str', + 'status': 'str' + } + + self.attribute_map = { + 'principal_id': 'principalId', + 'principal_name': 'principalName', + 'principal_type': 'principalType', + 'principal_state': 'principalState', + 'status': 'status' + } + + self._principal_id = None + self._principal_name = None + self._principal_type = None + self._principal_state = None + self._status = None + + @property + def principal_id(self): + """ + **[Required]** Gets the principal_id of this Reviewer. + Pull Request reviewer id + + + :return: The principal_id of this Reviewer. + :rtype: str + """ + return self._principal_id + + @principal_id.setter + def principal_id(self, principal_id): + """ + Sets the principal_id of this Reviewer. + Pull Request reviewer id + + + :param principal_id: The principal_id of this Reviewer. + :type: str + """ + self._principal_id = principal_id + + @property + def principal_name(self): + """ + Gets the principal_name of this Reviewer. + the name of the principal + + + :return: The principal_name of this Reviewer. + :rtype: str + """ + return self._principal_name + + @principal_name.setter + def principal_name(self, principal_name): + """ + Sets the principal_name of this Reviewer. + the name of the principal + + + :param principal_name: The principal_name of this Reviewer. + :type: str + """ + self._principal_name = principal_name + + @property + def principal_type(self): + """ + Gets the principal_type of this Reviewer. + the type of principal + + Allowed values for this property are: "SERVICE", "USER", "INSTANCE", "RESOURCE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The principal_type of this Reviewer. + :rtype: str + """ + return self._principal_type + + @principal_type.setter + def principal_type(self, principal_type): + """ + Sets the principal_type of this Reviewer. + the type of principal + + + :param principal_type: The principal_type of this Reviewer. + :type: str + """ + allowed_values = ["SERVICE", "USER", "INSTANCE", "RESOURCE"] + if not value_allowed_none_or_none_sentinel(principal_type, allowed_values): + principal_type = 'UNKNOWN_ENUM_VALUE' + self._principal_type = principal_type + + @property + def principal_state(self): + """ + Gets the principal_state of this Reviewer. + The state of the principal, it can be active or inactive or suppressed for emails + + Allowed values for this property are: "ACTIVE", "INACTIVE", "SUPPRESSED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The principal_state of this Reviewer. + :rtype: str + """ + return self._principal_state + + @principal_state.setter + def principal_state(self, principal_state): + """ + Sets the principal_state of this Reviewer. + The state of the principal, it can be active or inactive or suppressed for emails + + + :param principal_state: The principal_state of this Reviewer. + :type: str + """ + allowed_values = ["ACTIVE", "INACTIVE", "SUPPRESSED"] + if not value_allowed_none_or_none_sentinel(principal_state, allowed_values): + principal_state = 'UNKNOWN_ENUM_VALUE' + self._principal_state = principal_state + + @property + def status(self): + """ + Gets the status of this Reviewer. + The current state of the Review. + + Allowed values for this property are: "APPROVED", "REVIEW_PENDING", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The status of this Reviewer. + :rtype: str + """ + return self._status + + @status.setter + def status(self, status): + """ + Sets the status of this Reviewer. + The current state of the Review. + + + :param status: The status of this Reviewer. + :type: str + """ + allowed_values = ["APPROVED", "REVIEW_PENDING"] + if not value_allowed_none_or_none_sentinel(status, allowed_values): + status = 'UNKNOWN_ENUM_VALUE' + self._status = status + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/reviewer_activity_summary.py b/src/oci/devops/models/reviewer_activity_summary.py new file mode 100644 index 000000000..24e6312d9 --- /dev/null +++ b/src/oci/devops/models/reviewer_activity_summary.py @@ -0,0 +1,141 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .pull_request_activity_summary import PullRequestActivitySummary +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ReviewerActivitySummary(PullRequestActivitySummary): + """ + activity describing reviewer updates to a pull request + """ + + def __init__(self, **kwargs): + """ + Initializes a new ReviewerActivitySummary object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ReviewerActivitySummary.activity_type` attribute + of this class is ``REVIEWER`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this ReviewerActivitySummary. + :type id: str + + :param principal: + The value to assign to the principal property of this ReviewerActivitySummary. + :type principal: oci.devops.models.PrincipalDetails + + :param pull_request_id: + The value to assign to the pull_request_id property of this ReviewerActivitySummary. + :type pull_request_id: str + + :param time_occurred: + The value to assign to the time_occurred property of this ReviewerActivitySummary. + :type time_occurred: datetime + + :param activity_type: + The value to assign to the activity_type property of this ReviewerActivitySummary. + Allowed values for this property are: "LIFECYCLE", "APPROVAL", "COMMIT", "REVIEWER", "COMMENT" + :type activity_type: str + + :param reviewers_added: + The value to assign to the reviewers_added property of this ReviewerActivitySummary. + :type reviewers_added: list[oci.devops.models.PrincipalDetails] + + :param reviewers_removed: + The value to assign to the reviewers_removed property of this ReviewerActivitySummary. + :type reviewers_removed: list[oci.devops.models.PrincipalDetails] + + """ + self.swagger_types = { + 'id': 'str', + 'principal': 'PrincipalDetails', + 'pull_request_id': 'str', + 'time_occurred': 'datetime', + 'activity_type': 'str', + 'reviewers_added': 'list[PrincipalDetails]', + 'reviewers_removed': 'list[PrincipalDetails]' + } + + self.attribute_map = { + 'id': 'id', + 'principal': 'principal', + 'pull_request_id': 'pullRequestId', + 'time_occurred': 'timeOccurred', + 'activity_type': 'activityType', + 'reviewers_added': 'reviewersAdded', + 'reviewers_removed': 'reviewersRemoved' + } + + self._id = None + self._principal = None + self._pull_request_id = None + self._time_occurred = None + self._activity_type = None + self._reviewers_added = None + self._reviewers_removed = None + self._activity_type = 'REVIEWER' + + @property + def reviewers_added(self): + """ + **[Required]** Gets the reviewers_added of this ReviewerActivitySummary. + list of reviewers added to a pull request + + + :return: The reviewers_added of this ReviewerActivitySummary. + :rtype: list[oci.devops.models.PrincipalDetails] + """ + return self._reviewers_added + + @reviewers_added.setter + def reviewers_added(self, reviewers_added): + """ + Sets the reviewers_added of this ReviewerActivitySummary. + list of reviewers added to a pull request + + + :param reviewers_added: The reviewers_added of this ReviewerActivitySummary. + :type: list[oci.devops.models.PrincipalDetails] + """ + self._reviewers_added = reviewers_added + + @property + def reviewers_removed(self): + """ + **[Required]** Gets the reviewers_removed of this ReviewerActivitySummary. + list of reviewers removed from a pull request + + + :return: The reviewers_removed of this ReviewerActivitySummary. + :rtype: list[oci.devops.models.PrincipalDetails] + """ + return self._reviewers_removed + + @reviewers_removed.setter + def reviewers_removed(self, reviewers_removed): + """ + Sets the reviewers_removed of this ReviewerActivitySummary. + list of reviewers removed from a pull request + + + :param reviewers_removed: The reviewers_removed of this ReviewerActivitySummary. + :type: list[oci.devops.models.PrincipalDetails] + """ + self._reviewers_removed = reviewers_removed + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/stage_output.py b/src/oci/devops/models/stage_output.py new file mode 100644 index 000000000..43910b4be --- /dev/null +++ b/src/oci/devops/models/stage_output.py @@ -0,0 +1,140 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class StageOutput(object): + """ + Details of the generated artifact or report. + """ + + #: A constant which can be used with the output_type property of a StageOutput. + #: This constant has a value of "ARTIFACT" + OUTPUT_TYPE_ARTIFACT = "ARTIFACT" + + #: A constant which can be used with the output_type property of a StageOutput. + #: This constant has a value of "TEST_REPORT" + OUTPUT_TYPE_TEST_REPORT = "TEST_REPORT" + + def __init__(self, **kwargs): + """ + Initializes a new StageOutput object with values from keyword arguments. This class has the following subclasses and if you are using this class as input + to a service operations then you should favor using a subclass over the base class: + + * :class:`~oci.devops.models.TestReportOutput` + * :class:`~oci.devops.models.GenericArtifacts` + + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param output_type: + The value to assign to the output_type property of this StageOutput. + Allowed values for this property are: "ARTIFACT", "TEST_REPORT" + :type output_type: str + + :param step_name: + The value to assign to the step_name property of this StageOutput. + :type step_name: str + + """ + self.swagger_types = { + 'output_type': 'str', + 'step_name': 'str' + } + + self.attribute_map = { + 'output_type': 'outputType', + 'step_name': 'stepName' + } + + self._output_type = None + self._step_name = None + + @staticmethod + def get_subtype(object_dictionary): + """ + Given the hash representation of a subtype of this class, + use the info in the hash to return the class of the subtype. + """ + type = object_dictionary['outputType'] + + if type == 'TEST_REPORT': + return 'TestReportOutput' + + if type == 'ARTIFACT': + return 'GenericArtifacts' + else: + return 'StageOutput' + + @property + def output_type(self): + """ + **[Required]** Gets the output_type of this StageOutput. + Type of output generated. + + Allowed values for this property are: "ARTIFACT", "TEST_REPORT" + + + :return: The output_type of this StageOutput. + :rtype: str + """ + return self._output_type + + @output_type.setter + def output_type(self, output_type): + """ + Sets the output_type of this StageOutput. + Type of output generated. + + + :param output_type: The output_type of this StageOutput. + :type: str + """ + allowed_values = ["ARTIFACT", "TEST_REPORT"] + if not value_allowed_none_or_none_sentinel(output_type, allowed_values): + raise ValueError( + f"Invalid value for `output_type`, must be None or one of {allowed_values}" + ) + self._output_type = output_type + + @property + def step_name(self): + """ + **[Required]** Gets the step_name of this StageOutput. + Name of stage step at which this output is generated. + + + :return: The step_name of this StageOutput. + :rtype: str + """ + return self._step_name + + @step_name.setter + def step_name(self, step_name): + """ + Sets the step_name of this StageOutput. + Name of stage step at which this output is generated. + + + :param step_name: The step_name of this StageOutput. + :type: str + """ + self._step_name = step_name + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/summarize_project_repository_analytics_details.py b/src/oci/devops/models/summarize_project_repository_analytics_details.py new file mode 100644 index 000000000..a4ac59599 --- /dev/null +++ b/src/oci/devops/models/summarize_project_repository_analytics_details.py @@ -0,0 +1,318 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class SummarizeProjectRepositoryAnalyticsDetails(object): + """ + Details of the user configured settings for viewing the metrics at project level. + """ + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "COMMITS" + REPOSITORY_METRICS_COMMITS = "COMMITS" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "LINES_ADDED" + REPOSITORY_METRICS_LINES_ADDED = "LINES_ADDED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "LINES_DELETED" + REPOSITORY_METRICS_LINES_DELETED = "LINES_DELETED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_CREATED" + REPOSITORY_METRICS_PULL_REQUEST_CREATED = "PULL_REQUEST_CREATED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_MERGED" + REPOSITORY_METRICS_PULL_REQUEST_MERGED = "PULL_REQUEST_MERGED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_DECLINED" + REPOSITORY_METRICS_PULL_REQUEST_DECLINED = "PULL_REQUEST_DECLINED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + REPOSITORY_METRICS_PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + REPOSITORY_METRICS_PULL_REQUEST_REVIEW_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_APPROVED" + REPOSITORY_METRICS_PULL_REQUEST_APPROVED = "PULL_REQUEST_APPROVED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEWED" + REPOSITORY_METRICS_PULL_REQUEST_REVIEWED = "PULL_REQUEST_REVIEWED" + + #: A constant which can be used with the repository_metrics property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_COMMENTS" + REPOSITORY_METRICS_PULL_REQUEST_COMMENTS = "PULL_REQUEST_COMMENTS" + + #: A constant which can be used with the aggregation_duration property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "DAILY" + AGGREGATION_DURATION_DAILY = "DAILY" + + #: A constant which can be used with the aggregation_duration property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "WEEKLY" + AGGREGATION_DURATION_WEEKLY = "WEEKLY" + + #: A constant which can be used with the aggregation_duration property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "MONTHLY" + AGGREGATION_DURATION_MONTHLY = "MONTHLY" + + #: A constant which can be used with the aggregation_duration property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "YEARLY" + AGGREGATION_DURATION_YEARLY = "YEARLY" + + #: A constant which can be used with the group_by property of a SummarizeProjectRepositoryAnalyticsDetails. + #: This constant has a value of "AUTHOR" + GROUP_BY_AUTHOR = "AUTHOR" + + def __init__(self, **kwargs): + """ + Initializes a new SummarizeProjectRepositoryAnalyticsDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param author_email: + The value to assign to the author_email property of this SummarizeProjectRepositoryAnalyticsDetails. + :type author_email: str + + :param repository_metrics: + The value to assign to the repository_metrics property of this SummarizeProjectRepositoryAnalyticsDetails. + Allowed values for items in this list are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS" + :type repository_metrics: list[str] + + :param aggregation_duration: + The value to assign to the aggregation_duration property of this SummarizeProjectRepositoryAnalyticsDetails. + Allowed values for this property are: "DAILY", "WEEKLY", "MONTHLY", "YEARLY" + :type aggregation_duration: str + + :param start_time: + The value to assign to the start_time property of this SummarizeProjectRepositoryAnalyticsDetails. + :type start_time: datetime + + :param end_time: + The value to assign to the end_time property of this SummarizeProjectRepositoryAnalyticsDetails. + :type end_time: datetime + + :param group_by: + The value to assign to the group_by property of this SummarizeProjectRepositoryAnalyticsDetails. + Allowed values for this property are: "AUTHOR" + :type group_by: str + + """ + self.swagger_types = { + 'author_email': 'str', + 'repository_metrics': 'list[str]', + 'aggregation_duration': 'str', + 'start_time': 'datetime', + 'end_time': 'datetime', + 'group_by': 'str' + } + + self.attribute_map = { + 'author_email': 'authorEmail', + 'repository_metrics': 'repositoryMetrics', + 'aggregation_duration': 'aggregationDuration', + 'start_time': 'startTime', + 'end_time': 'endTime', + 'group_by': 'groupBy' + } + + self._author_email = None + self._repository_metrics = None + self._aggregation_duration = None + self._start_time = None + self._end_time = None + self._group_by = None + + @property + def author_email(self): + """ + Gets the author_email of this SummarizeProjectRepositoryAnalyticsDetails. + Email address of the author. + + + :return: The author_email of this SummarizeProjectRepositoryAnalyticsDetails. + :rtype: str + """ + return self._author_email + + @author_email.setter + def author_email(self, author_email): + """ + Sets the author_email of this SummarizeProjectRepositoryAnalyticsDetails. + Email address of the author. + + + :param author_email: The author_email of this SummarizeProjectRepositoryAnalyticsDetails. + :type: str + """ + self._author_email = author_email + + @property + def repository_metrics(self): + """ + **[Required]** Gets the repository_metrics of this SummarizeProjectRepositoryAnalyticsDetails. + The name of the metric to be filtered. + + Allowed values for items in this list are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS" + + + :return: The repository_metrics of this SummarizeProjectRepositoryAnalyticsDetails. + :rtype: list[str] + """ + return self._repository_metrics + + @repository_metrics.setter + def repository_metrics(self, repository_metrics): + """ + Sets the repository_metrics of this SummarizeProjectRepositoryAnalyticsDetails. + The name of the metric to be filtered. + + + :param repository_metrics: The repository_metrics of this SummarizeProjectRepositoryAnalyticsDetails. + :type: list[str] + """ + allowed_values = ["COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS"] + + if repository_metrics and repository_metrics is not NONE_SENTINEL: + for value in repository_metrics: + if not value_allowed_none_or_none_sentinel(value, allowed_values): + raise ValueError( + f"Invalid value for `repository_metrics`, must be None or one of {allowed_values}" + ) + self._repository_metrics = repository_metrics + + @property + def aggregation_duration(self): + """ + Gets the aggregation_duration of this SummarizeProjectRepositoryAnalyticsDetails. + Metrics aggregated for the defined period. + + Allowed values for this property are: "DAILY", "WEEKLY", "MONTHLY", "YEARLY" + + + :return: The aggregation_duration of this SummarizeProjectRepositoryAnalyticsDetails. + :rtype: str + """ + return self._aggregation_duration + + @aggregation_duration.setter + def aggregation_duration(self, aggregation_duration): + """ + Sets the aggregation_duration of this SummarizeProjectRepositoryAnalyticsDetails. + Metrics aggregated for the defined period. + + + :param aggregation_duration: The aggregation_duration of this SummarizeProjectRepositoryAnalyticsDetails. + :type: str + """ + allowed_values = ["DAILY", "WEEKLY", "MONTHLY", "YEARLY"] + if not value_allowed_none_or_none_sentinel(aggregation_duration, allowed_values): + raise ValueError( + f"Invalid value for `aggregation_duration`, must be None or one of {allowed_values}" + ) + self._aggregation_duration = aggregation_duration + + @property + def start_time(self): + """ + **[Required]** Gets the start_time of this SummarizeProjectRepositoryAnalyticsDetails. + The beginning of the metric data query time range. + + + :return: The start_time of this SummarizeProjectRepositoryAnalyticsDetails. + :rtype: datetime + """ + return self._start_time + + @start_time.setter + def start_time(self, start_time): + """ + Sets the start_time of this SummarizeProjectRepositoryAnalyticsDetails. + The beginning of the metric data query time range. + + + :param start_time: The start_time of this SummarizeProjectRepositoryAnalyticsDetails. + :type: datetime + """ + self._start_time = start_time + + @property + def end_time(self): + """ + Gets the end_time of this SummarizeProjectRepositoryAnalyticsDetails. + The end of the metric data query time range. + + + :return: The end_time of this SummarizeProjectRepositoryAnalyticsDetails. + :rtype: datetime + """ + return self._end_time + + @end_time.setter + def end_time(self, end_time): + """ + Sets the end_time of this SummarizeProjectRepositoryAnalyticsDetails. + The end of the metric data query time range. + + + :param end_time: The end_time of this SummarizeProjectRepositoryAnalyticsDetails. + :type: datetime + """ + self._end_time = end_time + + @property + def group_by(self): + """ + Gets the group_by of this SummarizeProjectRepositoryAnalyticsDetails. + Attribute by which metric data has to be grouped + + Allowed values for this property are: "AUTHOR" + + + :return: The group_by of this SummarizeProjectRepositoryAnalyticsDetails. + :rtype: str + """ + return self._group_by + + @group_by.setter + def group_by(self, group_by): + """ + Sets the group_by of this SummarizeProjectRepositoryAnalyticsDetails. + Attribute by which metric data has to be grouped + + + :param group_by: The group_by of this SummarizeProjectRepositoryAnalyticsDetails. + :type: str + """ + allowed_values = ["AUTHOR"] + if not value_allowed_none_or_none_sentinel(group_by, allowed_values): + raise ValueError( + f"Invalid value for `group_by`, must be None or one of {allowed_values}" + ) + self._group_by = group_by + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/summarize_repository_analytics_details.py b/src/oci/devops/models/summarize_repository_analytics_details.py new file mode 100644 index 000000000..4b861239b --- /dev/null +++ b/src/oci/devops/models/summarize_repository_analytics_details.py @@ -0,0 +1,318 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class SummarizeRepositoryAnalyticsDetails(object): + """ + Details of the user configured settings for viewing the metrics at repository level. + """ + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "COMMITS" + REPOSITORY_METRICS_COMMITS = "COMMITS" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "LINES_ADDED" + REPOSITORY_METRICS_LINES_ADDED = "LINES_ADDED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "LINES_DELETED" + REPOSITORY_METRICS_LINES_DELETED = "LINES_DELETED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_CREATED" + REPOSITORY_METRICS_PULL_REQUEST_CREATED = "PULL_REQUEST_CREATED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_MERGED" + REPOSITORY_METRICS_PULL_REQUEST_MERGED = "PULL_REQUEST_MERGED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_DECLINED" + REPOSITORY_METRICS_PULL_REQUEST_DECLINED = "PULL_REQUEST_DECLINED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + REPOSITORY_METRICS_PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + REPOSITORY_METRICS_PULL_REQUEST_REVIEW_DURATION_IN_DAYS = "PULL_REQUEST_REVIEW_DURATION_IN_DAYS" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_APPROVED" + REPOSITORY_METRICS_PULL_REQUEST_APPROVED = "PULL_REQUEST_APPROVED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_REVIEWED" + REPOSITORY_METRICS_PULL_REQUEST_REVIEWED = "PULL_REQUEST_REVIEWED" + + #: A constant which can be used with the repository_metrics property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "PULL_REQUEST_COMMENTS" + REPOSITORY_METRICS_PULL_REQUEST_COMMENTS = "PULL_REQUEST_COMMENTS" + + #: A constant which can be used with the aggregation_duration property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "DAILY" + AGGREGATION_DURATION_DAILY = "DAILY" + + #: A constant which can be used with the aggregation_duration property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "WEEKLY" + AGGREGATION_DURATION_WEEKLY = "WEEKLY" + + #: A constant which can be used with the aggregation_duration property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "MONTHLY" + AGGREGATION_DURATION_MONTHLY = "MONTHLY" + + #: A constant which can be used with the aggregation_duration property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "YEARLY" + AGGREGATION_DURATION_YEARLY = "YEARLY" + + #: A constant which can be used with the group_by property of a SummarizeRepositoryAnalyticsDetails. + #: This constant has a value of "AUTHOR" + GROUP_BY_AUTHOR = "AUTHOR" + + def __init__(self, **kwargs): + """ + Initializes a new SummarizeRepositoryAnalyticsDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param author_email: + The value to assign to the author_email property of this SummarizeRepositoryAnalyticsDetails. + :type author_email: str + + :param repository_metrics: + The value to assign to the repository_metrics property of this SummarizeRepositoryAnalyticsDetails. + Allowed values for items in this list are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS" + :type repository_metrics: list[str] + + :param aggregation_duration: + The value to assign to the aggregation_duration property of this SummarizeRepositoryAnalyticsDetails. + Allowed values for this property are: "DAILY", "WEEKLY", "MONTHLY", "YEARLY" + :type aggregation_duration: str + + :param start_time: + The value to assign to the start_time property of this SummarizeRepositoryAnalyticsDetails. + :type start_time: datetime + + :param end_time: + The value to assign to the end_time property of this SummarizeRepositoryAnalyticsDetails. + :type end_time: datetime + + :param group_by: + The value to assign to the group_by property of this SummarizeRepositoryAnalyticsDetails. + Allowed values for this property are: "AUTHOR" + :type group_by: str + + """ + self.swagger_types = { + 'author_email': 'str', + 'repository_metrics': 'list[str]', + 'aggregation_duration': 'str', + 'start_time': 'datetime', + 'end_time': 'datetime', + 'group_by': 'str' + } + + self.attribute_map = { + 'author_email': 'authorEmail', + 'repository_metrics': 'repositoryMetrics', + 'aggregation_duration': 'aggregationDuration', + 'start_time': 'startTime', + 'end_time': 'endTime', + 'group_by': 'groupBy' + } + + self._author_email = None + self._repository_metrics = None + self._aggregation_duration = None + self._start_time = None + self._end_time = None + self._group_by = None + + @property + def author_email(self): + """ + Gets the author_email of this SummarizeRepositoryAnalyticsDetails. + Email address of the author. + + + :return: The author_email of this SummarizeRepositoryAnalyticsDetails. + :rtype: str + """ + return self._author_email + + @author_email.setter + def author_email(self, author_email): + """ + Sets the author_email of this SummarizeRepositoryAnalyticsDetails. + Email address of the author. + + + :param author_email: The author_email of this SummarizeRepositoryAnalyticsDetails. + :type: str + """ + self._author_email = author_email + + @property + def repository_metrics(self): + """ + **[Required]** Gets the repository_metrics of this SummarizeRepositoryAnalyticsDetails. + The name of the metric to be filtered. + + Allowed values for items in this list are: "COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS" + + + :return: The repository_metrics of this SummarizeRepositoryAnalyticsDetails. + :rtype: list[str] + """ + return self._repository_metrics + + @repository_metrics.setter + def repository_metrics(self, repository_metrics): + """ + Sets the repository_metrics of this SummarizeRepositoryAnalyticsDetails. + The name of the metric to be filtered. + + + :param repository_metrics: The repository_metrics of this SummarizeRepositoryAnalyticsDetails. + :type: list[str] + """ + allowed_values = ["COMMITS", "LINES_ADDED", "LINES_DELETED", "PULL_REQUEST_CREATED", "PULL_REQUEST_MERGED", "PULL_REQUEST_DECLINED", "PULL_REQUEST_REVIEW_START_DURATION_IN_DAYS", "PULL_REQUEST_REVIEW_DURATION_IN_DAYS", "PULL_REQUEST_APPROVED", "PULL_REQUEST_REVIEWED", "PULL_REQUEST_COMMENTS"] + + if repository_metrics and repository_metrics is not NONE_SENTINEL: + for value in repository_metrics: + if not value_allowed_none_or_none_sentinel(value, allowed_values): + raise ValueError( + f"Invalid value for `repository_metrics`, must be None or one of {allowed_values}" + ) + self._repository_metrics = repository_metrics + + @property + def aggregation_duration(self): + """ + Gets the aggregation_duration of this SummarizeRepositoryAnalyticsDetails. + Metrics aggregated for the defined period. + + Allowed values for this property are: "DAILY", "WEEKLY", "MONTHLY", "YEARLY" + + + :return: The aggregation_duration of this SummarizeRepositoryAnalyticsDetails. + :rtype: str + """ + return self._aggregation_duration + + @aggregation_duration.setter + def aggregation_duration(self, aggregation_duration): + """ + Sets the aggregation_duration of this SummarizeRepositoryAnalyticsDetails. + Metrics aggregated for the defined period. + + + :param aggregation_duration: The aggregation_duration of this SummarizeRepositoryAnalyticsDetails. + :type: str + """ + allowed_values = ["DAILY", "WEEKLY", "MONTHLY", "YEARLY"] + if not value_allowed_none_or_none_sentinel(aggregation_duration, allowed_values): + raise ValueError( + f"Invalid value for `aggregation_duration`, must be None or one of {allowed_values}" + ) + self._aggregation_duration = aggregation_duration + + @property + def start_time(self): + """ + **[Required]** Gets the start_time of this SummarizeRepositoryAnalyticsDetails. + The beginning of the metric data query time range. + + + :return: The start_time of this SummarizeRepositoryAnalyticsDetails. + :rtype: datetime + """ + return self._start_time + + @start_time.setter + def start_time(self, start_time): + """ + Sets the start_time of this SummarizeRepositoryAnalyticsDetails. + The beginning of the metric data query time range. + + + :param start_time: The start_time of this SummarizeRepositoryAnalyticsDetails. + :type: datetime + """ + self._start_time = start_time + + @property + def end_time(self): + """ + Gets the end_time of this SummarizeRepositoryAnalyticsDetails. + The end of the metric data query time range. + + + :return: The end_time of this SummarizeRepositoryAnalyticsDetails. + :rtype: datetime + """ + return self._end_time + + @end_time.setter + def end_time(self, end_time): + """ + Sets the end_time of this SummarizeRepositoryAnalyticsDetails. + The end of the metric data query time range. + + + :param end_time: The end_time of this SummarizeRepositoryAnalyticsDetails. + :type: datetime + """ + self._end_time = end_time + + @property + def group_by(self): + """ + Gets the group_by of this SummarizeRepositoryAnalyticsDetails. + Attribute by which metric data has to be grouped + + Allowed values for this property are: "AUTHOR" + + + :return: The group_by of this SummarizeRepositoryAnalyticsDetails. + :rtype: str + """ + return self._group_by + + @group_by.setter + def group_by(self, group_by): + """ + Sets the group_by of this SummarizeRepositoryAnalyticsDetails. + Attribute by which metric data has to be grouped + + + :param group_by: The group_by of this SummarizeRepositoryAnalyticsDetails. + :type: str + """ + allowed_values = ["AUTHOR"] + if not value_allowed_none_or_none_sentinel(group_by, allowed_values): + raise ValueError( + f"Invalid value for `group_by`, must be None or one of {allowed_values}" + ) + self._group_by = group_by + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/sync_repository_details.py b/src/oci/devops/models/sync_repository_details.py new file mode 100644 index 000000000..82747a2a7 --- /dev/null +++ b/src/oci/devops/models/sync_repository_details.py @@ -0,0 +1,103 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class SyncRepositoryDetails(object): + """ + Details required for syncing a repository with its upstream. + """ + + def __init__(self, **kwargs): + """ + Initializes a new SyncRepositoryDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param source_branch: + The value to assign to the source_branch property of this SyncRepositoryDetails. + :type source_branch: str + + :param destination_branch: + The value to assign to the destination_branch property of this SyncRepositoryDetails. + :type destination_branch: str + + """ + self.swagger_types = { + 'source_branch': 'str', + 'destination_branch': 'str' + } + + self.attribute_map = { + 'source_branch': 'sourceBranch', + 'destination_branch': 'destinationBranch' + } + + self._source_branch = None + self._destination_branch = None + + @property + def source_branch(self): + """ + **[Required]** Gets the source_branch of this SyncRepositoryDetails. + The branch in the upstream repository we want to sync from. + + + :return: The source_branch of this SyncRepositoryDetails. + :rtype: str + """ + return self._source_branch + + @source_branch.setter + def source_branch(self, source_branch): + """ + Sets the source_branch of this SyncRepositoryDetails. + The branch in the upstream repository we want to sync from. + + + :param source_branch: The source_branch of this SyncRepositoryDetails. + :type: str + """ + self._source_branch = source_branch + + @property + def destination_branch(self): + """ + **[Required]** Gets the destination_branch of this SyncRepositoryDetails. + The branch in the repository we want to be updated with changes from the upstream. + + + :return: The destination_branch of this SyncRepositoryDetails. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this SyncRepositoryDetails. + The branch in the repository we want to be updated with changes from the upstream. + + + :param destination_branch: The destination_branch of this SyncRepositoryDetails. + :type: str + """ + self._destination_branch = destination_branch + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/test_report_output.py b/src/oci/devops/models/test_report_output.py new file mode 100644 index 000000000..ea4dbbfd0 --- /dev/null +++ b/src/oci/devops/models/test_report_output.py @@ -0,0 +1,89 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .stage_output import StageOutput +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class TestReportOutput(StageOutput): + """ + Details of test report generated via pipeline run + """ + + def __init__(self, **kwargs): + """ + Initializes a new TestReportOutput object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.TestReportOutput.output_type` attribute + of this class is ``TEST_REPORT`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param output_type: + The value to assign to the output_type property of this TestReportOutput. + Allowed values for this property are: "ARTIFACT", "TEST_REPORT" + :type output_type: str + + :param step_name: + The value to assign to the step_name property of this TestReportOutput. + :type step_name: str + + :param id: + The value to assign to the id property of this TestReportOutput. + :type id: str + + """ + self.swagger_types = { + 'output_type': 'str', + 'step_name': 'str', + 'id': 'str' + } + + self.attribute_map = { + 'output_type': 'outputType', + 'step_name': 'stepName', + 'id': 'id' + } + + self._output_type = None + self._step_name = None + self._id = None + self._output_type = 'TEST_REPORT' + + @property + def id(self): + """ + **[Required]** Gets the id of this TestReportOutput. + The OCID of the test report. + + + :return: The id of this TestReportOutput. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this TestReportOutput. + The OCID of the test report. + + + :param id: The id of this TestReportOutput. + :type: str + """ + self._id = id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_approval_rule_details.py b/src/oci/devops/models/update_approval_rule_details.py new file mode 100644 index 000000000..4939395b3 --- /dev/null +++ b/src/oci/devops/models/update_approval_rule_details.py @@ -0,0 +1,165 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateApprovalRuleDetails(object): + """ + A rule which must be satisfied for matching pull requests before the pull request can be merged + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateApprovalRuleDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param name: + The value to assign to the name property of this UpdateApprovalRuleDetails. + :type name: str + + :param destination_branch: + The value to assign to the destination_branch property of this UpdateApprovalRuleDetails. + :type destination_branch: str + + :param reviewers: + The value to assign to the reviewers property of this UpdateApprovalRuleDetails. + :type reviewers: list[oci.devops.models.UpdateReviewerDetails] + + :param min_approvals_count: + The value to assign to the min_approvals_count property of this UpdateApprovalRuleDetails. + :type min_approvals_count: int + + """ + self.swagger_types = { + 'name': 'str', + 'destination_branch': 'str', + 'reviewers': 'list[UpdateReviewerDetails]', + 'min_approvals_count': 'int' + } + + self.attribute_map = { + 'name': 'name', + 'destination_branch': 'destinationBranch', + 'reviewers': 'reviewers', + 'min_approvals_count': 'minApprovalsCount' + } + + self._name = None + self._destination_branch = None + self._reviewers = None + self._min_approvals_count = None + + @property + def name(self): + """ + **[Required]** Gets the name of this UpdateApprovalRuleDetails. + Name which is used to uniquely identify an approval rule. + + + :return: The name of this UpdateApprovalRuleDetails. + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """ + Sets the name of this UpdateApprovalRuleDetails. + Name which is used to uniquely identify an approval rule. + + + :param name: The name of this UpdateApprovalRuleDetails. + :type: str + """ + self._name = name + + @property + def destination_branch(self): + """ + Gets the destination_branch of this UpdateApprovalRuleDetails. + Branch name where pull requests targeting the branch must satisfy the approval rule. This value being null means the rule applies to all pull requests + + + :return: The destination_branch of this UpdateApprovalRuleDetails. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this UpdateApprovalRuleDetails. + Branch name where pull requests targeting the branch must satisfy the approval rule. This value being null means the rule applies to all pull requests + + + :param destination_branch: The destination_branch of this UpdateApprovalRuleDetails. + :type: str + """ + self._destination_branch = destination_branch + + @property + def reviewers(self): + """ + Gets the reviewers of this UpdateApprovalRuleDetails. + List of users who must provide approvals up to the minApprovalsCount specified in the rule. An empty list means the approvals can come from any user. + + + :return: The reviewers of this UpdateApprovalRuleDetails. + :rtype: list[oci.devops.models.UpdateReviewerDetails] + """ + return self._reviewers + + @reviewers.setter + def reviewers(self, reviewers): + """ + Sets the reviewers of this UpdateApprovalRuleDetails. + List of users who must provide approvals up to the minApprovalsCount specified in the rule. An empty list means the approvals can come from any user. + + + :param reviewers: The reviewers of this UpdateApprovalRuleDetails. + :type: list[oci.devops.models.UpdateReviewerDetails] + """ + self._reviewers = reviewers + + @property + def min_approvals_count(self): + """ + **[Required]** Gets the min_approvals_count of this UpdateApprovalRuleDetails. + Minimum number of approvals which must be provided by the reviewers specified in the list before the rule can be satisfied + + + :return: The min_approvals_count of this UpdateApprovalRuleDetails. + :rtype: int + """ + return self._min_approvals_count + + @min_approvals_count.setter + def min_approvals_count(self, min_approvals_count): + """ + Sets the min_approvals_count of this UpdateApprovalRuleDetails. + Minimum number of approvals which must be provided by the reviewers specified in the list before the rule can be satisfied + + + :param min_approvals_count: The min_approvals_count of this UpdateApprovalRuleDetails. + :type: int + """ + self._min_approvals_count = min_approvals_count + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_approval_rule_details_collection.py b/src/oci/devops/models/update_approval_rule_details_collection.py new file mode 100644 index 000000000..8ff4849aa --- /dev/null +++ b/src/oci/devops/models/update_approval_rule_details_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateApprovalRuleDetailsCollection(object): + """ + List of approval rules which must be statisfied before pull requests which match the rules can be merged + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateApprovalRuleDetailsCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this UpdateApprovalRuleDetailsCollection. + :type items: list[oci.devops.models.UpdateApprovalRuleDetails] + + """ + self.swagger_types = { + 'items': 'list[UpdateApprovalRuleDetails]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this UpdateApprovalRuleDetailsCollection. + List of approval rules. + + + :return: The items of this UpdateApprovalRuleDetailsCollection. + :rtype: list[oci.devops.models.UpdateApprovalRuleDetails] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this UpdateApprovalRuleDetailsCollection. + List of approval rules. + + + :param items: The items of this UpdateApprovalRuleDetailsCollection. + :type: list[oci.devops.models.UpdateApprovalRuleDetails] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_project_notification_preference_details.py b/src/oci/devops/models/update_project_notification_preference_details.py new file mode 100644 index 000000000..d213063db --- /dev/null +++ b/src/oci/devops/models/update_project_notification_preference_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateProjectNotificationPreferenceDetails(object): + """ + Information to update notification preference settings on project resource + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateProjectNotificationPreferenceDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param notification_preference: + The value to assign to the notification_preference property of this UpdateProjectNotificationPreferenceDetails. + :type notification_preference: str + + """ + self.swagger_types = { + 'notification_preference': 'str' + } + + self.attribute_map = { + 'notification_preference': 'notificationPreference' + } + + self._notification_preference = None + + @property + def notification_preference(self): + """ + **[Required]** Gets the notification_preference of this UpdateProjectNotificationPreferenceDetails. + The override value of project notification preference. + + + :return: The notification_preference of this UpdateProjectNotificationPreferenceDetails. + :rtype: str + """ + return self._notification_preference + + @notification_preference.setter + def notification_preference(self, notification_preference): + """ + Sets the notification_preference of this UpdateProjectNotificationPreferenceDetails. + The override value of project notification preference. + + + :param notification_preference: The notification_preference of this UpdateProjectNotificationPreferenceDetails. + :type: str + """ + self._notification_preference = notification_preference + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_project_repository_settings_details.py b/src/oci/devops/models/update_project_repository_settings_details.py new file mode 100644 index 000000000..e6b899eb4 --- /dev/null +++ b/src/oci/devops/models/update_project_repository_settings_details.py @@ -0,0 +1,95 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateProjectRepositorySettingsDetails(object): + """ + Information to update custom project repository settings. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateProjectRepositorySettingsDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param merge_settings: + The value to assign to the merge_settings property of this UpdateProjectRepositorySettingsDetails. + :type merge_settings: oci.devops.models.MergeSettings + + :param approval_rules: + The value to assign to the approval_rules property of this UpdateProjectRepositorySettingsDetails. + :type approval_rules: oci.devops.models.UpdateApprovalRuleDetailsCollection + + """ + self.swagger_types = { + 'merge_settings': 'MergeSettings', + 'approval_rules': 'UpdateApprovalRuleDetailsCollection' + } + + self.attribute_map = { + 'merge_settings': 'mergeSettings', + 'approval_rules': 'approvalRules' + } + + self._merge_settings = None + self._approval_rules = None + + @property + def merge_settings(self): + """ + Gets the merge_settings of this UpdateProjectRepositorySettingsDetails. + + :return: The merge_settings of this UpdateProjectRepositorySettingsDetails. + :rtype: oci.devops.models.MergeSettings + """ + return self._merge_settings + + @merge_settings.setter + def merge_settings(self, merge_settings): + """ + Sets the merge_settings of this UpdateProjectRepositorySettingsDetails. + + :param merge_settings: The merge_settings of this UpdateProjectRepositorySettingsDetails. + :type: oci.devops.models.MergeSettings + """ + self._merge_settings = merge_settings + + @property + def approval_rules(self): + """ + Gets the approval_rules of this UpdateProjectRepositorySettingsDetails. + + :return: The approval_rules of this UpdateProjectRepositorySettingsDetails. + :rtype: oci.devops.models.UpdateApprovalRuleDetailsCollection + """ + return self._approval_rules + + @approval_rules.setter + def approval_rules(self, approval_rules): + """ + Sets the approval_rules of this UpdateProjectRepositorySettingsDetails. + + :param approval_rules: The approval_rules of this UpdateProjectRepositorySettingsDetails. + :type: oci.devops.models.UpdateApprovalRuleDetailsCollection + """ + self._approval_rules = approval_rules + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_pull_request_comment_details.py b/src/oci/devops/models/update_pull_request_comment_details.py new file mode 100644 index 000000000..294d80735 --- /dev/null +++ b/src/oci/devops/models/update_pull_request_comment_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdatePullRequestCommentDetails(object): + """ + The new comment content to be updated. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdatePullRequestCommentDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param data: + The value to assign to the data property of this UpdatePullRequestCommentDetails. + :type data: str + + """ + self.swagger_types = { + 'data': 'str' + } + + self.attribute_map = { + 'data': 'data' + } + + self._data = None + + @property + def data(self): + """ + Gets the data of this UpdatePullRequestCommentDetails. + Pull Request comment content + + + :return: The data of this UpdatePullRequestCommentDetails. + :rtype: str + """ + return self._data + + @data.setter + def data(self, data): + """ + Sets the data of this UpdatePullRequestCommentDetails. + Pull Request comment content + + + :param data: The data of this UpdatePullRequestCommentDetails. + :type: str + """ + self._data = data + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_pull_request_details.py b/src/oci/devops/models/update_pull_request_details.py new file mode 100644 index 000000000..93172e000 --- /dev/null +++ b/src/oci/devops/models/update_pull_request_details.py @@ -0,0 +1,235 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdatePullRequestDetails(object): + """ + The information to be updated. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdatePullRequestDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param display_name: + The value to assign to the display_name property of this UpdatePullRequestDetails. + :type display_name: str + + :param description: + The value to assign to the description property of this UpdatePullRequestDetails. + :type description: str + + :param destination_branch: + The value to assign to the destination_branch property of this UpdatePullRequestDetails. + :type destination_branch: str + + :param reviewers: + The value to assign to the reviewers property of this UpdatePullRequestDetails. + :type reviewers: list[oci.devops.models.UpdateReviewerDetails] + + :param freeform_tags: + The value to assign to the freeform_tags property of this UpdatePullRequestDetails. + :type freeform_tags: dict(str, str) + + :param defined_tags: + The value to assign to the defined_tags property of this UpdatePullRequestDetails. + :type defined_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'display_name': 'str', + 'description': 'str', + 'destination_branch': 'str', + 'reviewers': 'list[UpdateReviewerDetails]', + 'freeform_tags': 'dict(str, str)', + 'defined_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'display_name': 'displayName', + 'description': 'description', + 'destination_branch': 'destinationBranch', + 'reviewers': 'reviewers', + 'freeform_tags': 'freeformTags', + 'defined_tags': 'definedTags' + } + + self._display_name = None + self._description = None + self._destination_branch = None + self._reviewers = None + self._freeform_tags = None + self._defined_tags = None + + @property + def display_name(self): + """ + Gets the display_name of this UpdatePullRequestDetails. + Pull Request title + + + :return: The display_name of this UpdatePullRequestDetails. + :rtype: str + """ + return self._display_name + + @display_name.setter + def display_name(self, display_name): + """ + Sets the display_name of this UpdatePullRequestDetails. + Pull Request title + + + :param display_name: The display_name of this UpdatePullRequestDetails. + :type: str + """ + self._display_name = display_name + + @property + def description(self): + """ + Gets the description of this UpdatePullRequestDetails. + Details of the pull request. Avoid entering confidential information. + + + :return: The description of this UpdatePullRequestDetails. + :rtype: str + """ + return self._description + + @description.setter + def description(self, description): + """ + Sets the description of this UpdatePullRequestDetails. + Details of the pull request. Avoid entering confidential information. + + + :param description: The description of this UpdatePullRequestDetails. + :type: str + """ + self._description = description + + @property + def destination_branch(self): + """ + Gets the destination_branch of this UpdatePullRequestDetails. + The destination branch against which the changes are to be reviewed. Example: \"main\" + + + :return: The destination_branch of this UpdatePullRequestDetails. + :rtype: str + """ + return self._destination_branch + + @destination_branch.setter + def destination_branch(self, destination_branch): + """ + Sets the destination_branch of this UpdatePullRequestDetails. + The destination branch against which the changes are to be reviewed. Example: \"main\" + + + :param destination_branch: The destination_branch of this UpdatePullRequestDetails. + :type: str + """ + self._destination_branch = destination_branch + + @property + def reviewers(self): + """ + Gets the reviewers of this UpdatePullRequestDetails. + Reviewers for this Review. + + + :return: The reviewers of this UpdatePullRequestDetails. + :rtype: list[oci.devops.models.UpdateReviewerDetails] + """ + return self._reviewers + + @reviewers.setter + def reviewers(self, reviewers): + """ + Sets the reviewers of this UpdatePullRequestDetails. + Reviewers for this Review. + + + :param reviewers: The reviewers of this UpdatePullRequestDetails. + :type: list[oci.devops.models.UpdateReviewerDetails] + """ + self._reviewers = reviewers + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this UpdatePullRequestDetails. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The freeform_tags of this UpdatePullRequestDetails. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this UpdatePullRequestDetails. + Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param freeform_tags: The freeform_tags of this UpdatePullRequestDetails. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def defined_tags(self): + """ + Gets the defined_tags of this UpdatePullRequestDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The defined_tags of this UpdatePullRequestDetails. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this UpdatePullRequestDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param defined_tags: The defined_tags of this UpdatePullRequestDetails. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_pull_request_notification_preference_details.py b/src/oci/devops/models/update_pull_request_notification_preference_details.py new file mode 100644 index 000000000..b85a94f96 --- /dev/null +++ b/src/oci/devops/models/update_pull_request_notification_preference_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdatePullRequestNotificationPreferenceDetails(object): + """ + Information to update notification preference settings on pull request resource + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdatePullRequestNotificationPreferenceDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param notification_preference: + The value to assign to the notification_preference property of this UpdatePullRequestNotificationPreferenceDetails. + :type notification_preference: str + + """ + self.swagger_types = { + 'notification_preference': 'str' + } + + self.attribute_map = { + 'notification_preference': 'notificationPreference' + } + + self._notification_preference = None + + @property + def notification_preference(self): + """ + **[Required]** Gets the notification_preference of this UpdatePullRequestNotificationPreferenceDetails. + The override value of pull request notification preference. + + + :return: The notification_preference of this UpdatePullRequestNotificationPreferenceDetails. + :rtype: str + """ + return self._notification_preference + + @notification_preference.setter + def notification_preference(self, notification_preference): + """ + Sets the notification_preference of this UpdatePullRequestNotificationPreferenceDetails. + The override value of pull request notification preference. + + + :param notification_preference: The notification_preference of this UpdatePullRequestNotificationPreferenceDetails. + :type: str + """ + self._notification_preference = notification_preference + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_repository_details.py b/src/oci/devops/models/update_repository_details.py index eedc75b57..5e2004519 100644 --- a/src/oci/devops/models/update_repository_details.py +++ b/src/oci/devops/models/update_repository_details.py @@ -156,6 +156,7 @@ def repository_type(self): Type of repository. Allowed values: `MIRRORED` `HOSTED` + `FORKED` :return: The repository_type of this UpdateRepositoryDetails. @@ -170,6 +171,7 @@ def repository_type(self, repository_type): Type of repository. Allowed values: `MIRRORED` `HOSTED` + `FORKED` :param repository_type: The repository_type of this UpdateRepositoryDetails. diff --git a/src/oci/devops/models/update_repository_notification_preference_details.py b/src/oci/devops/models/update_repository_notification_preference_details.py new file mode 100644 index 000000000..ba659be85 --- /dev/null +++ b/src/oci/devops/models/update_repository_notification_preference_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateRepositoryNotificationPreferenceDetails(object): + """ + Information to update notification preference settings on repository resource + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateRepositoryNotificationPreferenceDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param notification_preference: + The value to assign to the notification_preference property of this UpdateRepositoryNotificationPreferenceDetails. + :type notification_preference: str + + """ + self.swagger_types = { + 'notification_preference': 'str' + } + + self.attribute_map = { + 'notification_preference': 'notificationPreference' + } + + self._notification_preference = None + + @property + def notification_preference(self): + """ + **[Required]** Gets the notification_preference of this UpdateRepositoryNotificationPreferenceDetails. + The override value of repository notification preference. + + + :return: The notification_preference of this UpdateRepositoryNotificationPreferenceDetails. + :rtype: str + """ + return self._notification_preference + + @notification_preference.setter + def notification_preference(self, notification_preference): + """ + Sets the notification_preference of this UpdateRepositoryNotificationPreferenceDetails. + The override value of repository notification preference. + + + :param notification_preference: The notification_preference of this UpdateRepositoryNotificationPreferenceDetails. + :type: str + """ + self._notification_preference = notification_preference + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_repository_settings_details.py b/src/oci/devops/models/update_repository_settings_details.py new file mode 100644 index 000000000..4f000bbcc --- /dev/null +++ b/src/oci/devops/models/update_repository_settings_details.py @@ -0,0 +1,122 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateRepositorySettingsDetails(object): + """ + Information to update custom repository settings + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateRepositorySettingsDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param merge_checks: + The value to assign to the merge_checks property of this UpdateRepositorySettingsDetails. + :type merge_checks: oci.devops.models.MergeChecks + + :param merge_settings: + The value to assign to the merge_settings property of this UpdateRepositorySettingsDetails. + :type merge_settings: oci.devops.models.MergeSettings + + :param approval_rules: + The value to assign to the approval_rules property of this UpdateRepositorySettingsDetails. + :type approval_rules: oci.devops.models.UpdateApprovalRuleDetailsCollection + + """ + self.swagger_types = { + 'merge_checks': 'MergeChecks', + 'merge_settings': 'MergeSettings', + 'approval_rules': 'UpdateApprovalRuleDetailsCollection' + } + + self.attribute_map = { + 'merge_checks': 'mergeChecks', + 'merge_settings': 'mergeSettings', + 'approval_rules': 'approvalRules' + } + + self._merge_checks = None + self._merge_settings = None + self._approval_rules = None + + @property + def merge_checks(self): + """ + Gets the merge_checks of this UpdateRepositorySettingsDetails. + + :return: The merge_checks of this UpdateRepositorySettingsDetails. + :rtype: oci.devops.models.MergeChecks + """ + return self._merge_checks + + @merge_checks.setter + def merge_checks(self, merge_checks): + """ + Sets the merge_checks of this UpdateRepositorySettingsDetails. + + :param merge_checks: The merge_checks of this UpdateRepositorySettingsDetails. + :type: oci.devops.models.MergeChecks + """ + self._merge_checks = merge_checks + + @property + def merge_settings(self): + """ + Gets the merge_settings of this UpdateRepositorySettingsDetails. + + :return: The merge_settings of this UpdateRepositorySettingsDetails. + :rtype: oci.devops.models.MergeSettings + """ + return self._merge_settings + + @merge_settings.setter + def merge_settings(self, merge_settings): + """ + Sets the merge_settings of this UpdateRepositorySettingsDetails. + + :param merge_settings: The merge_settings of this UpdateRepositorySettingsDetails. + :type: oci.devops.models.MergeSettings + """ + self._merge_settings = merge_settings + + @property + def approval_rules(self): + """ + Gets the approval_rules of this UpdateRepositorySettingsDetails. + + :return: The approval_rules of this UpdateRepositorySettingsDetails. + :rtype: oci.devops.models.UpdateApprovalRuleDetailsCollection + """ + return self._approval_rules + + @approval_rules.setter + def approval_rules(self, approval_rules): + """ + Sets the approval_rules of this UpdateRepositorySettingsDetails. + + :param approval_rules: The approval_rules of this UpdateRepositorySettingsDetails. + :type: oci.devops.models.UpdateApprovalRuleDetailsCollection + """ + self._approval_rules = approval_rules + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/update_reviewer_details.py b/src/oci/devops/models/update_reviewer_details.py new file mode 100644 index 000000000..c7950aed0 --- /dev/null +++ b/src/oci/devops/models/update_reviewer_details.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateReviewerDetails(object): + """ + The reviewer to be updated. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateReviewerDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param principal_id: + The value to assign to the principal_id property of this UpdateReviewerDetails. + :type principal_id: str + + """ + self.swagger_types = { + 'principal_id': 'str' + } + + self.attribute_map = { + 'principal_id': 'principalId' + } + + self._principal_id = None + + @property + def principal_id(self): + """ + **[Required]** Gets the principal_id of this UpdateReviewerDetails. + Pull Request reviewer id + + + :return: The principal_id of this UpdateReviewerDetails. + :rtype: str + """ + return self._principal_id + + @principal_id.setter + def principal_id(self, principal_id): + """ + Sets the principal_id of this UpdateReviewerDetails. + Pull Request reviewer id + + + :param principal_id: The principal_id of this UpdateReviewerDetails. + :type: str + """ + self._principal_id = principal_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/validate_merge_pull_request_details.py b/src/oci/devops/models/validate_merge_pull_request_details.py new file mode 100644 index 000000000..776c2d740 --- /dev/null +++ b/src/oci/devops/models/validate_merge_pull_request_details.py @@ -0,0 +1,51 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210630 + +from .merge_pull_request_details import MergePullRequestDetails +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ValidateMergePullRequestDetails(MergePullRequestDetails): + """ + The information about the merge validation. + """ + + def __init__(self, **kwargs): + """ + Initializes a new ValidateMergePullRequestDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.devops.models.ValidateMergePullRequestDetails.action_type` attribute + of this class is ``VALIDATE`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param action_type: + The value to assign to the action_type property of this ValidateMergePullRequestDetails. + Allowed values for this property are: "EXECUTE", "VALIDATE" + :type action_type: str + + """ + self.swagger_types = { + 'action_type': 'str' + } + + self.attribute_map = { + 'action_type': 'actionType' + } + + self._action_type = None + self._action_type = 'VALIDATE' + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/devops/models/work_request.py b/src/oci/devops/models/work_request.py index d38556330..fa840b751 100644 --- a/src/oci/devops/models/work_request.py +++ b/src/oci/devops/models/work_request.py @@ -159,6 +159,14 @@ class WorkRequest(object): #: This constant has a value of "MIRROR_REPOSITORY" OPERATION_TYPE_MIRROR_REPOSITORY = "MIRROR_REPOSITORY" + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "FORK_REPOSITORY" + OPERATION_TYPE_FORK_REPOSITORY = "FORK_REPOSITORY" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "SYNC_FORK_REPOSITORY" + OPERATION_TYPE_SYNC_FORK_REPOSITORY = "SYNC_FORK_REPOSITORY" + #: A constant which can be used with the operation_type property of a WorkRequest. #: This constant has a value of "SCHEDULE_CASCADING_PROJECT_DELETION" OPERATION_TYPE_SCHEDULE_CASCADING_PROJECT_DELETION = "SCHEDULE_CASCADING_PROJECT_DELETION" @@ -167,6 +175,26 @@ class WorkRequest(object): #: This constant has a value of "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION" OPERATION_TYPE_CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION = "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION" + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "CREATE_PULL_REQUEST" + OPERATION_TYPE_CREATE_PULL_REQUEST = "CREATE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "UPDATE_PULL_REQUEST" + OPERATION_TYPE_UPDATE_PULL_REQUEST = "UPDATE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "DELETE_PULL_REQUEST" + OPERATION_TYPE_DELETE_PULL_REQUEST = "DELETE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "MOVE_PULL_REQUEST" + OPERATION_TYPE_MOVE_PULL_REQUEST = "MOVE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequest. + #: This constant has a value of "MERGE_PULL_REQUEST" + OPERATION_TYPE_MERGE_PULL_REQUEST = "MERGE_PULL_REQUEST" + #: A constant which can be used with the status property of a WorkRequest. #: This constant has a value of "ACCEPTED" STATUS_ACCEPTED = "ACCEPTED" @@ -206,7 +234,7 @@ def __init__(self, **kwargs): :param operation_type: The value to assign to the operation_type property of this WorkRequest. - Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "FORK_REPOSITORY", "SYNC_FORK_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", "CREATE_PULL_REQUEST", "UPDATE_PULL_REQUEST", "DELETE_PULL_REQUEST", "MOVE_PULL_REQUEST", "MERGE_PULL_REQUEST", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type operation_type: str @@ -285,7 +313,7 @@ def operation_type(self): **[Required]** Gets the operation_type of this WorkRequest. Type of the work request. - Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "FORK_REPOSITORY", "SYNC_FORK_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", "CREATE_PULL_REQUEST", "UPDATE_PULL_REQUEST", "DELETE_PULL_REQUEST", "MOVE_PULL_REQUEST", "MERGE_PULL_REQUEST", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -304,7 +332,7 @@ def operation_type(self, operation_type): :param operation_type: The operation_type of this WorkRequest. :type: str """ - allowed_values = ["CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION"] + allowed_values = ["CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "FORK_REPOSITORY", "SYNC_FORK_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", "CREATE_PULL_REQUEST", "UPDATE_PULL_REQUEST", "DELETE_PULL_REQUEST", "MOVE_PULL_REQUEST", "MERGE_PULL_REQUEST"] if not value_allowed_none_or_none_sentinel(operation_type, allowed_values): operation_type = 'UNKNOWN_ENUM_VALUE' self._operation_type = operation_type diff --git a/src/oci/devops/models/work_request_summary.py b/src/oci/devops/models/work_request_summary.py index 403c9464c..e0cad26f3 100644 --- a/src/oci/devops/models/work_request_summary.py +++ b/src/oci/devops/models/work_request_summary.py @@ -159,6 +159,14 @@ class WorkRequestSummary(object): #: This constant has a value of "MIRROR_REPOSITORY" OPERATION_TYPE_MIRROR_REPOSITORY = "MIRROR_REPOSITORY" + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "FORK_REPOSITORY" + OPERATION_TYPE_FORK_REPOSITORY = "FORK_REPOSITORY" + + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "SYNC_FORK_REPOSITORY" + OPERATION_TYPE_SYNC_FORK_REPOSITORY = "SYNC_FORK_REPOSITORY" + #: A constant which can be used with the operation_type property of a WorkRequestSummary. #: This constant has a value of "SCHEDULE_CASCADING_PROJECT_DELETION" OPERATION_TYPE_SCHEDULE_CASCADING_PROJECT_DELETION = "SCHEDULE_CASCADING_PROJECT_DELETION" @@ -167,6 +175,26 @@ class WorkRequestSummary(object): #: This constant has a value of "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION" OPERATION_TYPE_CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION = "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION" + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "CREATE_PULL_REQUEST" + OPERATION_TYPE_CREATE_PULL_REQUEST = "CREATE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "UPDATE_PULL_REQUEST" + OPERATION_TYPE_UPDATE_PULL_REQUEST = "UPDATE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "DELETE_PULL_REQUEST" + OPERATION_TYPE_DELETE_PULL_REQUEST = "DELETE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "MOVE_PULL_REQUEST" + OPERATION_TYPE_MOVE_PULL_REQUEST = "MOVE_PULL_REQUEST" + + #: A constant which can be used with the operation_type property of a WorkRequestSummary. + #: This constant has a value of "MERGE_PULL_REQUEST" + OPERATION_TYPE_MERGE_PULL_REQUEST = "MERGE_PULL_REQUEST" + #: A constant which can be used with the status property of a WorkRequestSummary. #: This constant has a value of "ACCEPTED" STATUS_ACCEPTED = "ACCEPTED" @@ -206,7 +234,7 @@ def __init__(self, **kwargs): :param operation_type: The value to assign to the operation_type property of this WorkRequestSummary. - Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "FORK_REPOSITORY", "SYNC_FORK_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", "CREATE_PULL_REQUEST", "UPDATE_PULL_REQUEST", "DELETE_PULL_REQUEST", "MOVE_PULL_REQUEST", "MERGE_PULL_REQUEST", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type operation_type: str @@ -285,7 +313,7 @@ def operation_type(self): **[Required]** Gets the operation_type of this WorkRequestSummary. Type of the work request. - Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "FORK_REPOSITORY", "SYNC_FORK_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", "CREATE_PULL_REQUEST", "UPDATE_PULL_REQUEST", "DELETE_PULL_REQUEST", "MOVE_PULL_REQUEST", "MERGE_PULL_REQUEST", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -304,7 +332,7 @@ def operation_type(self, operation_type): :param operation_type: The operation_type of this WorkRequestSummary. :type: str """ - allowed_values = ["CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION"] + allowed_values = ["CREATE_PROJECT", "UPDATE_PROJECT", "DELETE_PROJECT", "MOVE_PROJECT", "CREATE_DEPLOY_PIPELINE", "UPDATE_DEPLOY_PIPELINE", "DELETE_DEPLOY_PIPELINE", "CREATE_DEPLOY_STAGE", "UPDATE_DEPLOY_STAGE", "DELETE_DEPLOY_STAGE", "CREATE_DEPLOY_ARTIFACT", "UPDATE_DEPLOY_ARTIFACT", "DELETE_DEPLOY_ARTIFACT", "CREATE_DEPLOY_ENVIRONMENT", "UPDATE_DEPLOY_ENVIRONMENT", "DELETE_DEPLOY_ENVIRONMENT", "CREATE_DEPLOYMENT", "UPDATE_DEPLOYMENT", "DELETE_DEPLOYMENT", "CREATE_BUILD_PIPELINE", "UPDATE_BUILD_PIPELINE", "DELETE_BUILD_PIPELINE", "CREATE_BUILD_PIPELINE_STAGE", "UPDATE_BUILD_PIPELINE_STAGE", "DELETE_BUILD_PIPELINE_STAGE", "CREATE_CONNECTION", "UPDATE_CONNECTION", "DELETE_CONNECTION", "CREATE_TRIGGER", "UPDATE_TRIGGER", "DELETE_TRIGGER", "EXECUTE_TRIGGER", "CREATE_REPOSITORY", "UPDATE_REPOSITORY", "DELETE_REPOSITORY", "MIRROR_REPOSITORY", "FORK_REPOSITORY", "SYNC_FORK_REPOSITORY", "SCHEDULE_CASCADING_PROJECT_DELETION", "CANCEL_SCHEDULED_CASCADING_PROJECT_DELETION", "CREATE_PULL_REQUEST", "UPDATE_PULL_REQUEST", "DELETE_PULL_REQUEST", "MOVE_PULL_REQUEST", "MERGE_PULL_REQUEST"] if not value_allowed_none_or_none_sentinel(operation_type, allowed_values): operation_type = 'UNKNOWN_ENUM_VALUE' self._operation_type = operation_type diff --git a/src/oci/em_warehouse/em_warehouse_client.py b/src/oci/em_warehouse/em_warehouse_client.py index 356ebcecf..24c1e4de3 100644 --- a/src/oci/em_warehouse/em_warehouse_client.py +++ b/src/oci/em_warehouse/em_warehouse_client.py @@ -157,7 +157,7 @@ def cancel_work_request(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}" method = "DELETE" operation_name = "cancel_work_request" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/WorkRequest/CancelWorkRequest" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -270,7 +270,7 @@ def change_em_warehouse_compartment(self, em_warehouse_id, change_em_warehouse_c resource_path = "/emWarehouses/{emWarehouseId}/actions/changeCompartment" method = "POST" operation_name = "change_em_warehouse_compartment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EmWarehouse/ChangeEmWarehouseCompartment" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -378,7 +378,7 @@ def create_em_warehouse(self, create_em_warehouse_details, **kwargs): resource_path = "/emWarehouses" method = "POST" operation_name = "create_em_warehouse" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EmWarehouse/CreateEmWarehouse" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -472,7 +472,7 @@ def delete_em_warehouse(self, em_warehouse_id, **kwargs): resource_path = "/emWarehouses/{emWarehouseId}" method = "DELETE" operation_name = "delete_em_warehouse" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EmWarehouse/DeleteEmWarehouse" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -568,7 +568,7 @@ def get_em_warehouse(self, em_warehouse_id, **kwargs): resource_path = "/emWarehouses/{emWarehouseId}" method = "GET" operation_name = "get_em_warehouse" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EmWarehouse/GetEmWarehouse" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -664,7 +664,7 @@ def get_em_warehouse_resource_usage(self, em_warehouse_id, **kwargs): resource_path = "/emWarehouses/{emWarehouseId}/resourceUsage" method = "GET" operation_name = "get_em_warehouse_resource_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/ResourceUsage/GetEmWarehouseResourceUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -760,7 +760,7 @@ def get_work_request(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}" method = "GET" operation_name = "get_work_request" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/WorkRequest/GetWorkRequest" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -886,7 +886,7 @@ def list_em_warehouses(self, **kwargs): resource_path = "/emWarehouses" method = "GET" operation_name = "list_em_warehouses" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EmWarehouseCollection/ListEmWarehouses" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1037,7 +1037,7 @@ def list_etl_runs(self, em_warehouse_id, **kwargs): resource_path = "/emWarehouses/{emWarehouseId}/etlRuns" method = "GET" operation_name = "list_etl_runs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EtlRunCollection/ListEtlRuns" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1181,7 +1181,7 @@ def list_work_request_errors(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}/errors" method = "GET" operation_name = "list_work_request_errors" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/WorkRequestError/ListWorkRequestErrors" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1321,7 +1321,7 @@ def list_work_request_logs(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}/logs" method = "GET" operation_name = "list_work_request_logs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/WorkRequestLogEntry/ListWorkRequestLogs" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1472,7 +1472,7 @@ def list_work_requests(self, **kwargs): resource_path = "/workRequests" method = "GET" operation_name = "list_work_requests" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/WorkRequest/ListWorkRequests" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1609,7 +1609,7 @@ def update_em_warehouse(self, em_warehouse_id, update_em_warehouse_details, **kw resource_path = "/emWarehouses/{emWarehouseId}" method = "PUT" operation_name = "update_em_warehouse" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/em-warehouse/20180828/EmWarehouse/UpdateEmWarehouse" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ diff --git a/src/oci/jms/java_management_service_client.py b/src/oci/jms/java_management_service_client.py index 64a02d4d6..cf5b93fdd 100644 --- a/src/oci/jms/java_management_service_client.py +++ b/src/oci/jms/java_management_service_client.py @@ -22,7 +22,7 @@ class JavaManagementServiceClient(object): """ - API for the Java Management Service. Use this API to view, create, and manage Fleets. + The APIs for the [Fleet Management](https://docs.oracle.com/en-us/iaas/jms/doc/fleet-management.html) feature of Java Management Service to monitor and manage the usage of Java in your enterprise. Use these APIs to manage fleets, configure managed instances to report to fleets, and gain insights into the Java workloads running on these instances by carrying out basic and advanced features. """ def __init__(self, config, **kwargs): @@ -169,7 +169,7 @@ def add_fleet_installation_sites(self, fleet_id, add_fleet_installation_sites_de resource_path = "/fleets/{fleetId}/actions/addInstallationSites" method = "POST" operation_name = "add_fleet_installation_sites" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/InstallationSiteSummary/AddFleetInstallationSites" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -281,7 +281,7 @@ def cancel_work_request(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}" method = "DELETE" operation_name = "cancel_work_request" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/WorkRequest/CancelWorkRequest" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -398,7 +398,7 @@ def change_fleet_compartment(self, fleet_id, change_fleet_compartment_details, * resource_path = "/fleets/{fleetId}/actions/changeCompartment" method = "POST" operation_name = "change_fleet_compartment" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/ChangeFleetCompartment" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -513,7 +513,7 @@ def create_blocklist(self, fleet_id, create_blocklist_details, **kwargs): resource_path = "/fleets/{fleetId}/blocklists" method = "POST" operation_name = "create_blocklist" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Blocklist/CreateBlocklist" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -584,7 +584,7 @@ def create_blocklist(self, fleet_id, create_blocklist_details, **kwargs): def create_drs_file(self, fleet_id, create_drs_file_details, **kwargs): """ - Request to perform validaition of the DRS file and create the file to the Object Storage. + Request to perform validation of the DRS file and create the file to the Object Storage. :param str fleet_id: (required) @@ -635,7 +635,7 @@ def create_drs_file(self, fleet_id, create_drs_file_details, **kwargs): resource_path = "/fleets/{fleetId}/drsFiles" method = "POST" operation_name = "create_drs_file" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/CreateDrsFile" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -753,7 +753,7 @@ def create_fleet(self, create_fleet_details, **kwargs): resource_path = "/fleets" method = "POST" operation_name = "create_fleet" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/CreateFleet" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -808,6 +808,106 @@ def create_fleet(self, create_fleet_details, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) + def create_jms_plugin(self, create_jms_plugin_details, **kwargs): + """ + Registers an agent's JmsPlugin, optionally attaching to an existing fleet of the tenancy. + JmsPlugins registered fleet-less are created with lifecycle state INACTIVE. + For the operation to be authorized, the agent must exist, and the authorized user requires JMS_PLUGIN_CREATE permission for the agent's compartment. + + + :param oci.jms.models.CreateJmsPluginDetails create_jms_plugin_details: (required) + Details for the new JmsPlugin. + + :param str opc_retry_token: (optional) + A token that uniquely identifies a request so it can be retried in case of a timeout or + server error without risk of executing that same action again. Retry tokens expire after 24 + hours, but can be invalidated before then due to conflicting operations. For example, if a resource + has been deleted and purged from the system, then a retry of the original creation request + might be rejected. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.jms.models.JmsPlugin` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use create_jms_plugin API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/jmsPlugins" + method = "POST" + operation_name = "create_jms_plugin" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_retry_token", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"create_jms_plugin got unknown kwargs: {extra_kwargs!r}") + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-retry-token": kwargs.get("opc_retry_token", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + header_params=header_params, + body=create_jms_plugin_details, + response_type="JmsPlugin", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + header_params=header_params, + body=create_jms_plugin_details, + response_type="JmsPlugin", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def delete_blocklist(self, fleet_id, blocklist_key, **kwargs): """ Deletes the blocklist record specified by an identifier. @@ -854,7 +954,7 @@ def delete_blocklist(self, fleet_id, blocklist_key, **kwargs): resource_path = "/fleets/{fleetId}/blocklists/{blocklistKey}" method = "DELETE" operation_name = "delete_blocklist" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Blocklist/DeleteBlocklist" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -965,7 +1065,7 @@ def delete_crypto_analysis_result(self, fleet_id, crypto_analysis_result_id, **k resource_path = "/fleets/{fleetId}/cryptoAnalysisResults/{cryptoAnalysisResultId}" method = "DELETE" operation_name = "delete_crypto_analysis_result" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/CryptoAnalysisResult/DeleteCryptoAnalysisResult" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1076,7 +1176,7 @@ def delete_drs_file(self, fleet_id, drs_file_key, **kwargs): resource_path = "/fleets/{fleetId}/drsFiles/{drsFileKey}" method = "DELETE" operation_name = "delete_drs_file" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/DrsFile/DeleteDrsFile" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1184,7 +1284,7 @@ def delete_fleet(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}" method = "DELETE" operation_name = "delete_fleet" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/DeleteFleet" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1294,7 +1394,7 @@ def delete_java_migration_analysis_result(self, fleet_id, java_migration_analysi resource_path = "/fleets/{fleetId}/javaMigrationAnalysisResults/{javaMigrationAnalysisResultId}" method = "DELETE" operation_name = "delete_java_migration_analysis_result" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaMigrationAnalysisResult/DeleteJavaMigrationAnalysisResult" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1359,6 +1459,114 @@ def delete_java_migration_analysis_result(self, fleet_id, java_migration_analysi api_reference_link=api_reference_link, required_arguments=required_arguments) + def delete_jms_plugin(self, jms_plugin_id, **kwargs): + """ + Deletes a JmsPlugin. The JmsPlugin may be visible for some time with state DELETED. + Deleted plugins will not be able to communicate with the JMS service. + + + :param str jms_plugin_id: (required) + The `OCID`__ of the JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call + for a resource, set the `if-match` parameter to the value of the + ETag from a previous GET or POST response for that resource. + The resource will be updated or deleted only if the ETag you + provide matches the resource's current ETag value. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use delete_jms_plugin API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['jmsPluginId'] + resource_path = "/jmsPlugins/{jmsPluginId}" + method = "DELETE" + operation_name = "delete_jms_plugin" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id", + "if_match" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"delete_jms_plugin got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "jmsPluginId": jms_plugin_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing), + "if-match": kwargs.get("if_match", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def delete_performance_tuning_analysis_result(self, fleet_id, performance_tuning_analysis_result_id, **kwargs): """ Deletes only the metadata of the Performance Tuning Analysis result, but the file remains in the object storage. @@ -1405,7 +1613,7 @@ def delete_performance_tuning_analysis_result(self, fleet_id, performance_tuning resource_path = "/fleets/{fleetId}/performanceTuningAnalysisResults/{performanceTuningAnalysisResultId}" method = "DELETE" operation_name = "delete_performance_tuning_analysis_result" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/PerformanceTuningAnalysisResult/DeletePerformanceTuningAnalysisResult" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1523,7 +1731,7 @@ def disable_drs(self, fleet_id, disable_drs_details, **kwargs): resource_path = "/fleets/{fleetId}/actions/disableDrs" method = "POST" operation_name = "disable_drs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/DisableDrs" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1645,7 +1853,7 @@ def enable_drs(self, fleet_id, enable_drs_details, **kwargs): resource_path = "/fleets/{fleetId}/actions/enableDrs" method = "POST" operation_name = "enable_drs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/EnableDrs" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1671,11 +1879,205 @@ def enable_drs(self, fleet_id, enable_drs_details, **kwargs): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') header_params = { - "accept": "application/json", + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing), + "if-match": kwargs.get("if_match", missing), + "opc-retry-token": kwargs.get("opc_retry_token", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_retry_token_if_needed(header_params) + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=enable_drs_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=enable_drs_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_details, **kwargs): + """ + Generates Agent Deploy Script for Fleet using the information provided. + + + :param str fleet_id: (required) + The `OCID`__ of the Fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param oci.jms.models.GenerateAgentDeployScriptDetails generate_agent_deploy_script_details: (required) + Attributes to generate the agent deploy script for a Fleet. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type stream + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use generate_agent_deploy_script API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['fleetId'] + resource_path = "/fleets/{fleetId}/actions/generateAgentDeployScript" + method = "POST" + operation_name = "generate_agent_deploy_script" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"generate_agent_deploy_script got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "fleetId": fleet_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "text/plain", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=generate_agent_deploy_script_details, + response_type="stream", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=generate_agent_deploy_script_details, + response_type="stream", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def generate_agent_installer_configuration(self, generate_agent_installer_configuration_details, **kwargs): + """ + Generates the agent installer configuration using the information provided. + + + :param oci.jms.models.GenerateAgentInstallerConfigurationDetails generate_agent_installer_configuration_details: (required) + Details that are used to generate the installer configuration for a fleet. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type stream + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use generate_agent_installer_configuration API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/agentInstallers/actions/generateAgentInstallerConfiguration" + method = "POST" + operation_name = "generate_agent_installer_configuration" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"generate_agent_installer_configuration got unknown kwargs: {extra_kwargs!r}") + + header_params = { + "accept": "text/plain", "content-type": "application/json", - "opc-request-id": kwargs.get("opc_request_id", missing), - "if-match": kwargs.get("if_match", missing), - "opc-retry-token": kwargs.get("opc_retry_token", missing) + "opc-request-id": kwargs.get("opc_request_id", missing) } header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} @@ -1688,16 +2090,15 @@ def enable_drs(self, fleet_id, enable_drs_details, **kwargs): if retry_strategy: if not isinstance(retry_strategy, retry.NoneRetryStrategy): - self.base_client.add_opc_retry_token_if_needed(header_params) self.base_client.add_opc_client_retries_header(header_params) retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) return retry_strategy.make_retrying_call( self.base_client.call_api, resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, - body=enable_drs_details, + body=generate_agent_installer_configuration_details, + response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -1706,17 +2107,17 @@ def enable_drs(self, fleet_id, enable_drs_details, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - path_params=path_params, header_params=header_params, - body=enable_drs_details, + body=generate_agent_installer_configuration_details, + response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) - def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_details, **kwargs): + def generate_load_pipeline_script(self, fleet_id, generate_load_pipeline_script_details, **kwargs): """ - Generates Agent Deploy Script for Fleet using the information provided. + Generates Load Pipeline Script :param str fleet_id: (required) @@ -1724,8 +2125,8 @@ def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_de __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm - :param oci.jms.models.GenerateAgentDeployScriptDetails generate_agent_deploy_script_details: (required) - Attributes to generate the agent deploy script for a Fleet. + :param oci.jms.models.GenerateLoadPipelineScriptDetails generate_load_pipeline_script_details: (required) + Attributes to generate the load pipeline script. :param str opc_request_id: (optional) The client request ID for tracing. @@ -1746,14 +2147,14 @@ def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_de :rtype: :class:`~oci.response.Response` :example: - Click `here `__ to see an example of how to use generate_agent_deploy_script API. + Click `here `__ to see an example of how to use generate_load_pipeline_script API. """ # Required path and query arguments. These are in camelCase to replace values in service endpoints. required_arguments = ['fleetId'] - resource_path = "/fleets/{fleetId}/actions/generateAgentDeployScript" + resource_path = "/fleets/{fleetId}/actions/generateLoadPipelineScript" method = "POST" - operation_name = "generate_agent_deploy_script" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/GenerateAgentDeployScript" + operation_name = "generate_load_pipeline_script" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1764,7 +2165,7 @@ def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_de extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( - f"generate_agent_deploy_script got unknown kwargs: {extra_kwargs!r}") + f"generate_load_pipeline_script got unknown kwargs: {extra_kwargs!r}") path_params = { "fleetId": fleet_id @@ -1800,7 +2201,7 @@ def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_de method=method, path_params=path_params, header_params=header_params, - body=generate_agent_deploy_script_details, + body=generate_load_pipeline_script_details, response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, @@ -1812,7 +2213,7 @@ def generate_agent_deploy_script(self, fleet_id, generate_agent_deploy_script_de method=method, path_params=path_params, header_params=header_params, - body=generate_agent_deploy_script_details, + body=generate_load_pipeline_script_details, response_type="stream", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, @@ -1858,7 +2259,7 @@ def get_crypto_analysis_result(self, fleet_id, crypto_analysis_result_id, **kwar resource_path = "/fleets/{fleetId}/cryptoAnalysisResults/{cryptoAnalysisResultId}" method = "GET" operation_name = "get_crypto_analysis_result" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/CryptoAnalysisResult/GetCryptoAnalysisResult" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -1965,7 +2366,7 @@ def get_drs_file(self, fleet_id, drs_file_key, **kwargs): resource_path = "/fleets/{fleetId}/drsFiles/{drsFileKey}" method = "GET" operation_name = "get_drs_file" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/DrsFile/GetDrsFile" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2040,7 +2441,7 @@ def get_drs_file(self, fleet_id, drs_file_key, **kwargs): def get_export_setting(self, fleet_id, **kwargs): """ - Returns export setting for the specified Fleet. + Returns export setting for the specified fleet. :param str fleet_id: (required) @@ -2074,7 +2475,7 @@ def get_export_setting(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/exportSetting" method = "GET" operation_name = "get_export_setting" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/ExportSetting/GetExportSetting" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2140,7 +2541,7 @@ def get_export_setting(self, fleet_id, **kwargs): def get_export_status(self, fleet_id, **kwargs): """ - Returns last export status for the specified Fleet. + Returns last export status for the specified fleet. :param str fleet_id: (required) @@ -2174,7 +2575,7 @@ def get_export_status(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/exportStatus" method = "GET" operation_name = "get_export_status" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/ExportStatus/GetExportStatus" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2274,7 +2675,7 @@ def get_fleet(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}" method = "GET" operation_name = "get_fleet" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/GetFleet" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2381,7 +2782,7 @@ def get_fleet_advanced_feature_configuration(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/advancedFeatureConfiguration" method = "GET" operation_name = "get_fleet_advanced_feature_configuration" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/FleetAdvancedFeatureConfiguration/GetFleetAdvancedFeatureConfiguration" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2483,7 +2884,7 @@ def get_fleet_agent_configuration(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/agentConfiguration" method = "GET" operation_name = "get_fleet_agent_configuration" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/FleetAgentConfiguration/GetFleetAgentConfiguration" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2581,7 +2982,7 @@ def get_java_family(self, family_version, **kwargs): resource_path = "/javaFamilies/{familyVersion}" method = "GET" operation_name = "get_java_family" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaFamily/GetJavaFamily" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2684,7 +3085,7 @@ def get_java_migration_analysis_result(self, fleet_id, java_migration_analysis_r resource_path = "/fleets/{fleetId}/javaMigrationAnalysisResults/{javaMigrationAnalysisResultId}" method = "GET" operation_name = "get_java_migration_analysis_result" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaMigrationAnalysisResult/GetJavaMigrationAnalysisResult" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2783,7 +3184,7 @@ def get_java_release(self, release_version, **kwargs): resource_path = "/javaReleases/{releaseVersion}" method = "GET" operation_name = "get_java_release" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaRelease/GetJavaRelease" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2847,6 +3248,106 @@ def get_java_release(self, release_version, **kwargs): api_reference_link=api_reference_link, required_arguments=required_arguments) + def get_jms_plugin(self, jms_plugin_id, **kwargs): + """ + Returns the JmsPlugin. + + + :param str jms_plugin_id: (required) + The `OCID`__ of the JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.jms.models.JmsPlugin` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use get_jms_plugin API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['jmsPluginId'] + resource_path = "/jmsPlugins/{jmsPluginId}" + method = "GET" + operation_name = "get_jms_plugin" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"get_jms_plugin got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "jmsPluginId": jms_plugin_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="JmsPlugin", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="JmsPlugin", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def get_performance_tuning_analysis_result(self, fleet_id, performance_tuning_analysis_result_id, **kwargs): """ Retrieve metadata of the Performance Tuning Analysis result. @@ -2886,7 +3387,7 @@ def get_performance_tuning_analysis_result(self, fleet_id, performance_tuning_an resource_path = "/fleets/{fleetId}/performanceTuningAnalysisResults/{performanceTuningAnalysisResultId}" method = "GET" operation_name = "get_performance_tuning_analysis_result" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/PerformanceTuningAnalysisResult/GetPerformanceTuningAnalysisResult" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -2987,7 +3488,7 @@ def get_work_request(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}" method = "GET" operation_name = "get_work_request" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/WorkRequest/GetWorkRequest" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -3032,9 +3533,178 @@ def get_work_request(self, work_request_id, **kwargs): self.base_client.call_api, resource_path=resource_path, method=method, - path_params=path_params, + path_params=path_params, + header_params=header_params, + response_type="WorkRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + response_type="WorkRequest", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_agent_installers(self, **kwargs): + """ + Returns a list of the agent installer information. + + + :param str compartment_id: (optional) + The `OCID`__ of the compartment in which to list resources. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param str fleet_id: (optional) + The ID of the Fleet. + + :param str platform_architecture: (optional) + The platform architecture for the agent installer. + + Allowed values are: "X86_64", "X86", "AARCH64" + + :param str os_family: (optional) + The OS family for the agent installer. + + Allowed values are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN" + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. The token is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order, either 'asc' or 'desc'. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort the agent installer. Only one sort order can be provided. + Default order for _agentInstallerId_, _osFamily_, _platformArchitecture_ is **ascending**. + If no value is specified _agentInstallerId_ is default. + + Allowed values are: "agentInstallerId", "osFamily", "platformArchitecture" + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.jms.models.AgentInstallerCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_agent_installers API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/agentInstallers" + method = "GET" + operation_name = "list_agent_installers" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "fleet_id", + "platform_architecture", + "os_family", + "limit", + "page", + "sort_order", + "sort_by", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_agent_installers got unknown kwargs: {extra_kwargs!r}") + + if 'platform_architecture' in kwargs: + platform_architecture_allowed_values = ["X86_64", "X86", "AARCH64"] + if kwargs['platform_architecture'] not in platform_architecture_allowed_values: + raise ValueError( + f"Invalid value for `platform_architecture`, must be one of { platform_architecture_allowed_values }" + ) + + if 'os_family' in kwargs: + os_family_allowed_values = ["LINUX", "WINDOWS", "MACOS", "UNKNOWN"] + if kwargs['os_family'] not in os_family_allowed_values: + raise ValueError( + f"Invalid value for `os_family`, must be one of { os_family_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["agentInstallerId", "osFamily", "platformArchitecture"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "compartmentId": kwargs.get("compartment_id", missing), + "fleetId": kwargs.get("fleet_id", missing), + "platformArchitecture": kwargs.get("platform_architecture", missing), + "osFamily": kwargs.get("os_family", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, header_params=header_params, - response_type="WorkRequest", + response_type="AgentInstallerCollection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3043,9 +3713,9 @@ def get_work_request(self, work_request_id, **kwargs): return self.base_client.call_api( resource_path=resource_path, method=method, - path_params=path_params, + query_params=query_params, header_params=header_params, - response_type="WorkRequest", + response_type="AgentInstallerCollection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -3112,7 +3782,7 @@ def list_announcements(self, **kwargs): resource_path = "/announcements" method = "GET" operation_name = "list_announcements" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/AnnouncementCollection/ListAnnouncements" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -3260,7 +3930,7 @@ def list_blocklists(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/blocklists" method = "GET" operation_name = "list_blocklists" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Blocklist/ListBlocklists" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -3381,6 +4051,33 @@ def list_crypto_analysis_results(self, fleet_id, **kwargs): :param str managed_instance_id: (optional) The Fleet-unique identifier of the related managed instance. + :param str host_name: (optional) + The host `OCID`__ of the managed instance. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param int non_compliant_finding_count: (optional) + Non Compliant Finding Count of CryptoAnalysis Report. + + :param int non_compliant_finding_count_greater_than: (optional) + Non Compliant Finding Count of CryptoAnalysis Report. + + :param int finding_count: (optional) + FindingCount of CryptoAnalysis Report. + + :param int finding_count_greater_than: (optional) + FindingCount of CryptoAnalysis Report. + + :param datetime time_start: (optional) + The start of the time period during which resources are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param datetime time_end: (optional) + The end of the time period during which resources are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + :param int limit: (optional) The maximum number of items to return. @@ -3403,16 +4100,6 @@ def list_crypto_analysis_results(self, fleet_id, **kwargs): :param str opc_request_id: (optional) The client request ID for tracing. - :param datetime time_start: (optional) - The start of the time period during which resources are searched (formatted according to `RFC3339`__). - - __ https://datatracker.ietf.org/doc/html/rfc3339 - - :param datetime time_end: (optional) - The end of the time period during which resources are searched (formatted according to `RFC3339`__). - - __ https://datatracker.ietf.org/doc/html/rfc3339 - :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -3436,7 +4123,7 @@ def list_crypto_analysis_results(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/cryptoAnalysisResults" method = "GET" operation_name = "list_crypto_analysis_results" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/CryptoAnalysisResult/ListCryptoAnalysisResults" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -3444,13 +4131,18 @@ def list_crypto_analysis_results(self, fleet_id, **kwargs): "retry_strategy", "aggregation_mode", "managed_instance_id", + "host_name", + "non_compliant_finding_count", + "non_compliant_finding_count_greater_than", + "finding_count", + "finding_count_greater_than", + "time_start", + "time_end", "limit", "page", "sort_order", "sort_by", - "opc_request_id", - "time_start", - "time_end" + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: @@ -3491,12 +4183,17 @@ def list_crypto_analysis_results(self, fleet_id, **kwargs): query_params = { "aggregationMode": kwargs.get("aggregation_mode", missing), "managedInstanceId": kwargs.get("managed_instance_id", missing), + "hostName": kwargs.get("host_name", missing), + "nonCompliantFindingCount": kwargs.get("non_compliant_finding_count", missing), + "nonCompliantFindingCountGreaterThan": kwargs.get("non_compliant_finding_count_greater_than", missing), + "findingCount": kwargs.get("finding_count", missing), + "findingCountGreaterThan": kwargs.get("finding_count_greater_than", missing), + "timeStart": kwargs.get("time_start", missing), + "timeEnd": kwargs.get("time_end", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing), - "timeStart": kwargs.get("time_start", missing), - "timeEnd": kwargs.get("time_end", missing) + "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -3597,7 +4294,7 @@ def list_drs_files(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/drsFiles" method = "GET" operation_name = "list_drs_files" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/DrsFileCollection/ListDrsFiles" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -3731,7 +4428,7 @@ def list_fleet_diagnoses(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/diagnoses" method = "GET" operation_name = "list_fleet_diagnoses" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/FleetDiagnosisSummary/ListFleetDiagnoses" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -3817,7 +4514,7 @@ def list_fleets(self, **kwargs): __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm :param str id: (optional) - The ID of the Fleet. + The ID. :param str lifecycle_state: (optional) The state of the lifecycle. @@ -3876,7 +4573,7 @@ def list_fleets(self, **kwargs): resource_path = "/fleets" method = "GET" operation_name = "list_fleets" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/ListFleets" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -4069,7 +4766,7 @@ def list_installation_sites(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/installationSites" method = "GET" operation_name = "list_installation_sites" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/InstallationSiteSummary/ListInstallationSites" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -4255,7 +4952,7 @@ def list_java_families(self, **kwargs): resource_path = "/javaFamilies" method = "GET" operation_name = "list_java_families" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaFamily/ListJavaFamilies" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -4354,6 +5051,24 @@ def list_java_migration_analysis_results(self, fleet_id, **kwargs): :param str managed_instance_id: (optional) The Fleet-unique identifier of the related managed instance. + :param str host_name: (optional) + The host `OCID`__ of the managed instance. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param str application_name: (optional) + The name of the application. + + :param datetime time_start: (optional) + The start of the time period during which resources are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param datetime time_end: (optional) + The end of the time period during which resources are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + :param int limit: (optional) The maximum number of items to return. @@ -4375,16 +5090,6 @@ def list_java_migration_analysis_results(self, fleet_id, **kwargs): :param str opc_request_id: (optional) The client request ID for tracing. - :param datetime time_start: (optional) - The start of the time period during which resources are searched (formatted according to `RFC3339`__). - - __ https://datatracker.ietf.org/doc/html/rfc3339 - - :param datetime time_end: (optional) - The end of the time period during which resources are searched (formatted according to `RFC3339`__). - - __ https://datatracker.ietf.org/doc/html/rfc3339 - :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -4408,20 +5113,22 @@ def list_java_migration_analysis_results(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/javaMigrationAnalysisResults" method = "GET" operation_name = "list_java_migration_analysis_results" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaMigrationAnalysisResult/ListJavaMigrationAnalysisResults" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ "allow_control_chars", "retry_strategy", "managed_instance_id", + "host_name", + "application_name", + "time_start", + "time_end", "limit", "page", "sort_order", "sort_by", - "opc_request_id", - "time_start", - "time_end" + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: @@ -4454,12 +5161,14 @@ def list_java_migration_analysis_results(self, fleet_id, **kwargs): query_params = { "managedInstanceId": kwargs.get("managed_instance_id", missing), + "hostName": kwargs.get("host_name", missing), + "applicationName": kwargs.get("application_name", missing), + "timeStart": kwargs.get("time_start", missing), + "timeEnd": kwargs.get("time_end", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing), - "timeStart": kwargs.get("time_start", missing), - "timeEnd": kwargs.get("time_end", missing) + "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -4574,7 +5283,7 @@ def list_java_releases(self, **kwargs): resource_path = "/javaReleases" method = "GET" operation_name = "list_java_releases" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaRelease/ListJavaReleases" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -4614,7 +5323,209 @@ def list_java_releases(self, **kwargs): license_type_allowed_values = ["OTN", "NFTC", "RESTRICTED"] if kwargs['license_type'] not in license_type_allowed_values: raise ValueError( - f"Invalid value for `license_type`, must be one of { license_type_allowed_values }" + f"Invalid value for `license_type`, must be one of { license_type_allowed_values }" + ) + + if 'sort_order' in kwargs: + sort_order_allowed_values = ["ASC", "DESC"] + if kwargs['sort_order'] not in sort_order_allowed_values: + raise ValueError( + f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }" + ) + + if 'sort_by' in kwargs: + sort_by_allowed_values = ["releaseDate", "releaseVersion", "familyVersion", "licenseType"] + if kwargs['sort_by'] not in sort_by_allowed_values: + raise ValueError( + f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" + ) + + query_params = { + "releaseVersion": kwargs.get("release_version", missing), + "familyVersion": kwargs.get("family_version", missing), + "releaseType": kwargs.get("release_type", missing), + "jreSecurityStatus": kwargs.get("jre_security_status", missing), + "licenseType": kwargs.get("license_type", missing), + "limit": kwargs.get("limit", missing), + "page": kwargs.get("page", missing), + "sortOrder": kwargs.get("sort_order", missing), + "sortBy": kwargs.get("sort_by", missing) + } + query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="JavaReleaseCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + query_params=query_params, + header_params=header_params, + response_type="JavaReleaseCollection", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + + def list_jms_plugins(self, **kwargs): + """ + Lists the JmsPlugins. + + + :param str compartment_id: (optional) + The `OCID`__ of the compartment in which to list resources. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param bool compartment_id_in_subtree: (optional) + Flag to determine whether the info should be gathered only in the compartment or in the compartment and its subcompartments. + + :param str id: (optional) + The `OCID`__ of the JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param str fleet_id: (optional) + The ID of the Fleet. + + :param str agent_id: (optional) + The ManagementAgent (OMA) or Instance (OCA) `OCID`__ that identifies the Agent. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param str lifecycle_state: (optional) + Filter JmsPlugin with its lifecycle state. + + Allowed values are: "ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED" + + :param str availability_status: (optional) + Filter JmsPlugin with its availability status. + + Allowed values are: "ACTIVE", "SILENT", "NOT_AVAILABLE" + + :param datetime time_registered_less_than_or_equal_to: (optional) + If present, only plugins with a registration time before this parameter are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param datetime time_last_seen_less_than_or_equal_to: (optional) + If present, only plugins with a last seen time before this parameter are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param int limit: (optional) + The maximum number of items to return. + + :param str page: (optional) + The page token representing the page at which to start retrieving results. The token is usually retrieved from a previous list call. + + :param str sort_order: (optional) + The sort order, either 'asc' or 'desc'. + + Allowed values are: "ASC", "DESC" + + :param str sort_by: (optional) + The field to sort JmsPlugin. Only one sort order may be provided. + Default order is **descending**. + If no value is specified _timeLastSeen_ is default. + + Allowed values are: "id", "timeLastSeen", "timeRegistered", "hostname", "agentId", "agentType", "lifecycleState", "availabilityStatus", "fleetId", "compartmentId", "osFamily", "osArchitecture", "osDistribution", "pluginVersion" + + :param str hostname_contains: (optional) + Filter the list with hostname contains the given value. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.jms.models.JmsPluginCollection` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use list_jms_plugins API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = [] + resource_path = "/jmsPlugins" + method = "GET" + operation_name = "list_jms_plugins" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "compartment_id", + "compartment_id_in_subtree", + "id", + "fleet_id", + "agent_id", + "lifecycle_state", + "availability_status", + "time_registered_less_than_or_equal_to", + "time_last_seen_less_than_or_equal_to", + "limit", + "page", + "sort_order", + "sort_by", + "hostname_contains", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"list_jms_plugins got unknown kwargs: {extra_kwargs!r}") + + if 'lifecycle_state' in kwargs: + lifecycle_state_allowed_values = ["ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED"] + if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values: + raise ValueError( + f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }" + ) + + if 'availability_status' in kwargs: + availability_status_allowed_values = ["ACTIVE", "SILENT", "NOT_AVAILABLE"] + if kwargs['availability_status'] not in availability_status_allowed_values: + raise ValueError( + f"Invalid value for `availability_status`, must be one of { availability_status_allowed_values }" ) if 'sort_order' in kwargs: @@ -4625,22 +5536,27 @@ def list_java_releases(self, **kwargs): ) if 'sort_by' in kwargs: - sort_by_allowed_values = ["releaseDate", "releaseVersion", "familyVersion", "licenseType"] + sort_by_allowed_values = ["id", "timeLastSeen", "timeRegistered", "hostname", "agentId", "agentType", "lifecycleState", "availabilityStatus", "fleetId", "compartmentId", "osFamily", "osArchitecture", "osDistribution", "pluginVersion"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" ) query_params = { - "releaseVersion": kwargs.get("release_version", missing), - "familyVersion": kwargs.get("family_version", missing), - "releaseType": kwargs.get("release_type", missing), - "jreSecurityStatus": kwargs.get("jre_security_status", missing), - "licenseType": kwargs.get("license_type", missing), + "compartmentId": kwargs.get("compartment_id", missing), + "compartmentIdInSubtree": kwargs.get("compartment_id_in_subtree", missing), + "id": kwargs.get("id", missing), + "fleetId": kwargs.get("fleet_id", missing), + "agentId": kwargs.get("agent_id", missing), + "lifecycleState": kwargs.get("lifecycle_state", missing), + "availabilityStatus": kwargs.get("availability_status", missing), + "timeRegisteredLessThanOrEqualTo": kwargs.get("time_registered_less_than_or_equal_to", missing), + "timeLastSeenLessThanOrEqualTo": kwargs.get("time_last_seen_less_than_or_equal_to", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing) + "sortBy": kwargs.get("sort_by", missing), + "hostnameContains": kwargs.get("hostname_contains", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -4668,7 +5584,7 @@ def list_java_releases(self, **kwargs): method=method, query_params=query_params, header_params=header_params, - response_type="JavaReleaseCollection", + response_type="JmsPluginCollection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4679,7 +5595,7 @@ def list_java_releases(self, **kwargs): method=method, query_params=query_params, header_params=header_params, - response_type="JavaReleaseCollection", + response_type="JmsPluginCollection", allow_control_chars=kwargs.get('allow_control_chars'), operation_name=operation_name, api_reference_link=api_reference_link, @@ -4763,7 +5679,7 @@ def list_jre_usage(self, **kwargs): resource_path = "/listJreUsage" method = "GET" operation_name = "list_jre_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JreUsage/ListJreUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -4871,6 +5787,21 @@ def list_performance_tuning_analysis_results(self, fleet_id, **kwargs): :param str application_id: (optional) The Fleet-unique identifier of the related application. + :param str host_name: (optional) + The host `OCID`__ of the managed instance. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param datetime time_start: (optional) + The start of the time period during which resources are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + :param datetime time_end: (optional) + The end of the time period during which resources are searched (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + :param int limit: (optional) The maximum number of items to return. @@ -4888,21 +5819,11 @@ def list_performance_tuning_analysis_results(self, fleet_id, **kwargs): Default order for _managedInstanceId_, _jreDistribution_, _jreVendor_ and _osName_ is **ascending**. If no value is specified _timeCreated_ is default. - Allowed values are: "timeCreated", "managedInstanceId", "workRequestId" + Allowed values are: "timeCreated", "managedInstanceId", "workRequestId", "warningCount" :param str opc_request_id: (optional) The client request ID for tracing. - :param datetime time_start: (optional) - The start of the time period during which resources are searched (formatted according to `RFC3339`__). - - __ https://datatracker.ietf.org/doc/html/rfc3339 - - :param datetime time_end: (optional) - The end of the time period during which resources are searched (formatted according to `RFC3339`__). - - __ https://datatracker.ietf.org/doc/html/rfc3339 - :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -4926,7 +5847,7 @@ def list_performance_tuning_analysis_results(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/performanceTuningAnalysisResults" method = "GET" operation_name = "list_performance_tuning_analysis_results" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/PerformanceTuningAnalysisResult/ListPerformanceTuningAnalysisResults" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -4934,13 +5855,14 @@ def list_performance_tuning_analysis_results(self, fleet_id, **kwargs): "retry_strategy", "managed_instance_id", "application_id", + "host_name", + "time_start", + "time_end", "limit", "page", "sort_order", "sort_by", - "opc_request_id", - "time_start", - "time_end" + "opc_request_id" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: @@ -4965,7 +5887,7 @@ def list_performance_tuning_analysis_results(self, fleet_id, **kwargs): ) if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeCreated", "managedInstanceId", "workRequestId"] + sort_by_allowed_values = ["timeCreated", "managedInstanceId", "workRequestId", "warningCount"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" @@ -4974,12 +5896,13 @@ def list_performance_tuning_analysis_results(self, fleet_id, **kwargs): query_params = { "managedInstanceId": kwargs.get("managed_instance_id", missing), "applicationId": kwargs.get("application_id", missing), + "hostName": kwargs.get("host_name", missing), + "timeStart": kwargs.get("time_start", missing), + "timeEnd": kwargs.get("time_end", missing), "limit": kwargs.get("limit", missing), "page": kwargs.get("page", missing), "sortOrder": kwargs.get("sort_order", missing), - "sortBy": kwargs.get("sort_by", missing), - "timeStart": kwargs.get("time_start", missing), - "timeEnd": kwargs.get("time_end", missing) + "sortBy": kwargs.get("sort_by", missing) } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -5068,7 +5991,7 @@ def list_work_items(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}/workItems" method = "GET" operation_name = "list_work_items" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/WorkItemSummary/ListWorkItems" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5184,7 +6107,7 @@ def list_work_request_errors(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}/errors" method = "GET" operation_name = "list_work_request_errors" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/WorkRequestError/ListWorkRequestErrors" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5300,7 +6223,7 @@ def list_work_request_logs(self, work_request_id, **kwargs): resource_path = "/workRequests/{workRequestId}/logs" method = "GET" operation_name = "list_work_request_logs" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/WorkRequestLogEntry/ListWorkRequestLogs" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5404,6 +6327,16 @@ def list_work_requests(self, **kwargs): :param str managed_instance_id: (optional) The Fleet-unique identifier of the managed instance. + :param str operation_type: (optional) + The operation type of the work request. + + Allowed values are: "CREATE_FLEET", "DELETE_FLEET", "MOVE_FLEET", "UPDATE_FLEET", "UPDATE_FLEET_AGENT_CONFIGURATION", "DELETE_JAVA_INSTALLATION", "CREATE_JAVA_INSTALLATION", "COLLECT_JFR", "REQUEST_CRYPTO_EVENT_ANALYSIS", "REQUEST_PERFORMANCE_TUNING_ANALYSIS", "REQUEST_JAVA_MIGRATION_ANALYSIS", "DELETE_JMS_REPORT", "SCAN_JAVA_SERVER_USAGE", "SCAN_LIBRARY_USAGE", "EXPORT_DATA_CSV", "CREATE_DRS_FILE", "UPDATE_DRS_FILE", "DELETE_DRS_FILE", "ENABLE_DRS", "DISABLE_DRS" + + :param list[str] status: (optional) + The status of the work request. + + Allowed values are: "ACCEPTED", "CANCELED", "CANCELING", "FAILED", "IN_PROGRESS", "SUCCEEDED" + :param obj retry_strategy: (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. @@ -5427,7 +6360,7 @@ def list_work_requests(self, **kwargs): resource_path = "/workRequests" method = "GET" operation_name = "list_work_requests" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/WorkRequest/ListWorkRequests" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5439,20 +6372,39 @@ def list_work_requests(self, **kwargs): "opc_request_id", "page", "limit", - "managed_instance_id" + "managed_instance_id", + "operation_type", + "status" ] extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] if extra_kwargs: raise ValueError( f"list_work_requests got unknown kwargs: {extra_kwargs!r}") + if 'operation_type' in kwargs: + operation_type_allowed_values = ["CREATE_FLEET", "DELETE_FLEET", "MOVE_FLEET", "UPDATE_FLEET", "UPDATE_FLEET_AGENT_CONFIGURATION", "DELETE_JAVA_INSTALLATION", "CREATE_JAVA_INSTALLATION", "COLLECT_JFR", "REQUEST_CRYPTO_EVENT_ANALYSIS", "REQUEST_PERFORMANCE_TUNING_ANALYSIS", "REQUEST_JAVA_MIGRATION_ANALYSIS", "DELETE_JMS_REPORT", "SCAN_JAVA_SERVER_USAGE", "SCAN_LIBRARY_USAGE", "EXPORT_DATA_CSV", "CREATE_DRS_FILE", "UPDATE_DRS_FILE", "DELETE_DRS_FILE", "ENABLE_DRS", "DISABLE_DRS"] + if kwargs['operation_type'] not in operation_type_allowed_values: + raise ValueError( + f"Invalid value for `operation_type`, must be one of { operation_type_allowed_values }" + ) + + if 'status' in kwargs: + status_allowed_values = ["ACCEPTED", "CANCELED", "CANCELING", "FAILED", "IN_PROGRESS", "SUCCEEDED"] + for status_item in kwargs['status']: + if status_item not in status_allowed_values: + raise ValueError( + f"Invalid value for `status`, must be one of { status_allowed_values }" + ) + query_params = { "compartmentId": kwargs.get("compartment_id", missing), "id": kwargs.get("id", missing), "fleetId": kwargs.get("fleet_id", missing), "page": kwargs.get("page", missing), "limit": kwargs.get("limit", missing), - "managedInstanceId": kwargs.get("managed_instance_id", missing) + "managedInstanceId": kwargs.get("managed_instance_id", missing), + "operationType": kwargs.get("operation_type", missing), + "status": self.base_client.generate_collection_format_param(kwargs.get("status", missing), 'multi') } query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None} @@ -5550,7 +6502,7 @@ def remove_fleet_installation_sites(self, fleet_id, remove_fleet_installation_si resource_path = "/fleets/{fleetId}/actions/removeInstallationSites" method = "POST" operation_name = "remove_fleet_installation_sites" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/InstallationSiteSummary/RemoveFleetInstallationSites" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5658,7 +6610,7 @@ def request_crypto_analyses(self, fleet_id, request_crypto_analyses_details, **k resource_path = "/fleets/{fleetId}/actions/requestCryptoAnalyses" method = "POST" operation_name = "request_crypto_analyses" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/RequestCryptoAnalyses" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5722,6 +6674,110 @@ def request_crypto_analyses(self, fleet_id, request_crypto_analyses_details, **k api_reference_link=api_reference_link, required_arguments=required_arguments) + def request_deployed_application_migration_analyses(self, fleet_id, request_deployed_application_migration_analyses_details, **kwargs): + """ + Request to perform a deployed Java migration analyses. The results of the deployed Java migration analyses will be uploaded to the + Object Storage bucket that you designate when you enable the Java Migration Analyses feature. + + + :param str fleet_id: (required) + The `OCID`__ of the Fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails request_deployed_application_migration_analyses_details: (required) + Detail information that starts the deployed Java migration analyses + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type None + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use request_deployed_application_migration_analyses API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['fleetId'] + resource_path = "/fleets/{fleetId}/actions/requestDeployedApplicationMigrationAnalyses" + method = "POST" + operation_name = "request_deployed_application_migration_analyses" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"request_deployed_application_migration_analyses got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "fleetId": fleet_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=request_deployed_application_migration_analyses_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=request_deployed_application_migration_analyses_details, + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + def request_java_migration_analyses(self, fleet_id, request_java_migration_analyses_details, **kwargs): """ Request to perform a Java migration analysis. The results of the Java migration analysis will be uploaded to the @@ -5762,7 +6818,7 @@ def request_java_migration_analyses(self, fleet_id, request_java_migration_analy resource_path = "/fleets/{fleetId}/actions/requestJavaMigrationAnalyses" method = "POST" operation_name = "request_java_migration_analyses" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/RequestJavaMigrationAnalyses" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5865,7 +6921,7 @@ def request_jfr_recordings(self, fleet_id, request_jfr_recordings_details, **kwa resource_path = "/fleets/{fleetId}/actions/requestJfrRecordings" method = "POST" operation_name = "request_jfr_recordings" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/RequestJfrRecordings" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -5969,7 +7025,7 @@ def request_performance_tuning_analyses(self, fleet_id, request_performance_tuni resource_path = "/fleets/{fleetId}/actions/requestPerformanceTuningAnalyses" method = "POST" operation_name = "request_performance_tuning_analyses" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/RequestPerformanceTuningAnalyses" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -6086,7 +7142,7 @@ def scan_java_server_usage(self, fleet_id, scan_java_server_usage_details, **kwa resource_path = "/fleets/{fleetId}/actions/scanJavaServerUsage" method = "POST" operation_name = "scan_java_server_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaServerUsage/ScanJavaServerUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -6208,7 +7264,7 @@ def scan_library_usage(self, fleet_id, scan_library_usage_details, **kwargs): resource_path = "/fleets/{fleetId}/actions/scanLibraryUsage" method = "POST" operation_name = "scan_library_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/LibraryUsage/ScanLibraryUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -6356,7 +7412,7 @@ def summarize_application_installation_usage(self, fleet_id, **kwargs): Default order for _displayName_, _installationPath_ and _osName_ is **ascending**. If no value is specified _timeLastSeen_ is default. - Allowed values are: "timeFirstSeen", "timeLastSeen", "displayName", "installationPath", "osName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount" + Allowed values are: "timeFirstSeen", "timeLastSeen", "displayName", "installationPath", "osName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount", "approximateLibraryCount" :param str opc_request_id: (optional) The client request ID for tracing. @@ -6384,7 +7440,7 @@ def summarize_application_installation_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeApplicationInstallationUsage" method = "GET" operation_name = "summarize_application_installation_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/ApplicationInstallationUsageSummary/SummarizeApplicationInstallationUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -6442,7 +7498,7 @@ def summarize_application_installation_usage(self, fleet_id, **kwargs): ) if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeFirstSeen", "timeLastSeen", "displayName", "installationPath", "osName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount"] + sort_by_allowed_values = ["timeFirstSeen", "timeLastSeen", "displayName", "installationPath", "osName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount", "approximateLibraryCount"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" @@ -6583,7 +7639,7 @@ def summarize_application_usage(self, fleet_id, **kwargs): Default order for _displayName_ and _osName_ is **ascending**. If no value is specified _timeLastSeen_ is default. - Allowed values are: "timeFirstSeen", "timeLastSeen", "displayName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount", "osName" + Allowed values are: "timeFirstSeen", "timeLastSeen", "displayName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount", "approximateLibraryCount", "osName" :param str opc_request_id: (optional) The client request ID for tracing. @@ -6622,7 +7678,7 @@ def summarize_application_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeApplicationUsage" method = "GET" operation_name = "summarize_application_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/ApplicationUsage/SummarizeApplicationUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -6679,7 +7735,7 @@ def summarize_application_usage(self, fleet_id, **kwargs): ) if 'sort_by' in kwargs: - sort_by_allowed_values = ["timeFirstSeen", "timeLastSeen", "displayName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount", "osName"] + sort_by_allowed_values = ["timeFirstSeen", "timeLastSeen", "displayName", "approximateJreCount", "approximateInstallationCount", "approximateManagedInstanceCount", "approximateLibraryCount", "osName"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" @@ -6820,7 +7876,7 @@ def summarize_deployed_application_installation_usage(self, fleet_id, **kwargs): The field to sort the deployed application installations. Only one sort order can be provided. If no value is specified _timeLastSeen_ is default. - Allowed values are: "applicationName", "applicationType", "applicationSourcePath", "isClustered", "javaServerInstanceCount", "timeFirstSeen", "timeLastSeen" + Allowed values are: "applicationName", "applicationType", "applicationSourcePath", "isClustered", "javaServerInstanceCount", "approximateJavaServerInstanceCount", "approximateLibraryCount", "timeFirstSeen", "timeLastSeen" :param str opc_request_id: (optional) The client request ID for tracing. @@ -6848,7 +7904,7 @@ def summarize_deployed_application_installation_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeDeployedApplicationInstallationUsage" method = "GET" operation_name = "summarize_deployed_application_installation_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/DeployedApplicationInstallationUsageSummary/SummarizeDeployedApplicationInstallationUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -6894,7 +7950,7 @@ def summarize_deployed_application_installation_usage(self, fleet_id, **kwargs): ) if 'sort_by' in kwargs: - sort_by_allowed_values = ["applicationName", "applicationType", "applicationSourcePath", "isClustered", "javaServerInstanceCount", "timeFirstSeen", "timeLastSeen"] + sort_by_allowed_values = ["applicationName", "applicationType", "applicationSourcePath", "isClustered", "javaServerInstanceCount", "approximateJavaServerInstanceCount", "approximateLibraryCount", "timeFirstSeen", "timeLastSeen"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" @@ -7018,7 +8074,7 @@ def summarize_deployed_application_usage(self, fleet_id, **kwargs): The field to sort the deployed applications. Only one sort order can be provided. If no value is specified _timeLastSeen_ is default. - Allowed values are: "applicationName", "applicationType", "isClustered", "javaServerInstanceCount", "timeFirstSeen", "timeLastSeen" + Allowed values are: "applicationName", "applicationType", "isClustered", "javaServerInstanceCount", "approximateJavaServerInstanceCount", "approximateLibraryCount", "timeFirstSeen", "timeLastSeen" :param str opc_request_id: (optional) The client request ID for tracing. @@ -7046,7 +8102,7 @@ def summarize_deployed_application_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeDeployedApplicationUsage" method = "GET" operation_name = "summarize_deployed_application_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/DeployedApplicationUsage/SummarizeDeployedApplicationUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -7090,7 +8146,7 @@ def summarize_deployed_application_usage(self, fleet_id, **kwargs): ) if 'sort_by' in kwargs: - sort_by_allowed_values = ["applicationName", "applicationType", "isClustered", "javaServerInstanceCount", "timeFirstSeen", "timeLastSeen"] + sort_by_allowed_values = ["applicationName", "applicationType", "isClustered", "javaServerInstanceCount", "approximateJavaServerInstanceCount", "approximateLibraryCount", "timeFirstSeen", "timeLastSeen"] if kwargs['sort_by'] not in sort_by_allowed_values: raise ValueError( f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }" @@ -7254,7 +8310,7 @@ def summarize_installation_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeInstallationUsage" method = "GET" operation_name = "summarize_installation_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/InstallationUsage/SummarizeInstallationUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -7468,7 +8524,7 @@ def summarize_java_server_instance_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeJavaServerInstanceUsage" method = "GET" operation_name = "summarize_java_server_instance_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaServerInstanceUsage/SummarizeJavaServerInstanceUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -7653,7 +8709,7 @@ def summarize_java_server_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeJavaServerUsage" method = "GET" operation_name = "summarize_java_server_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JavaServerUsage/SummarizeJavaServerUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -7859,7 +8915,7 @@ def summarize_jre_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeJreUsage" method = "GET" operation_name = "summarize_jre_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/JreUsage/SummarizeJreUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8024,6 +9080,12 @@ def summarize_library_usage(self, fleet_id, **kwargs): :param str library_name: (optional) The library name. + :param int cvss_score_greater_than: (optional) + Total Common Vulnerability Scoring System (CVSS) Score reported by the analysis. + + :param int cvss_score_less_than: (optional) + Total Common Vulnerability Scoring System (CVSS) Score reported by the analysis. + :param datetime time_start: (optional) The start of the time period during which resources are searched (formatted according to `RFC3339`__). @@ -8077,7 +9139,7 @@ def summarize_library_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeLibraryUsage" method = "GET" operation_name = "summarize_library_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/LibraryUsage/SummarizeLibraryUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8089,6 +9151,8 @@ def summarize_library_usage(self, fleet_id, **kwargs): "library_key", "library_name_contains", "library_name", + "cvss_score_greater_than", + "cvss_score_less_than", "time_start", "time_end", "limit", @@ -8133,6 +9197,8 @@ def summarize_library_usage(self, fleet_id, **kwargs): "libraryKey": kwargs.get("library_key", missing), "libraryNameContains": kwargs.get("library_name_contains", missing), "libraryName": kwargs.get("library_name", missing), + "cvssScoreGreaterThan": kwargs.get("cvss_score_greater_than", missing), + "cvssScoreLessThan": kwargs.get("cvss_score_less_than", missing), "timeStart": kwargs.get("time_start", missing), "timeEnd": kwargs.get("time_end", missing), "limit": kwargs.get("limit", missing), @@ -8201,7 +9267,7 @@ def summarize_managed_instance_usage(self, fleet_id, **kwargs): :param str managed_instance_type: (optional) The type of the managed instance. - Allowed values are: "ORACLE_MANAGEMENT_AGENT" + Allowed values are: "ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT" :param str jre_vendor: (optional) The vendor of the related Java Runtime. @@ -8292,7 +9358,7 @@ def summarize_managed_instance_usage(self, fleet_id, **kwargs): resource_path = "/fleets/{fleetId}/actions/summarizeManagedInstanceUsage" method = "GET" operation_name = "summarize_managed_instance_usage" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/ManagedInstanceUsage/SummarizeManagedInstanceUsage" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8333,7 +9399,7 @@ def summarize_managed_instance_usage(self, fleet_id, **kwargs): raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') if 'managed_instance_type' in kwargs: - managed_instance_type_allowed_values = ["ORACLE_MANAGEMENT_AGENT"] + managed_instance_type_allowed_values = ["ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT"] if kwargs['managed_instance_type'] not in managed_instance_type_allowed_values: raise ValueError( f"Invalid value for `managed_instance_type`, must be one of { managed_instance_type_allowed_values }" @@ -8479,7 +9545,7 @@ def summarize_resource_inventory(self, **kwargs): resource_path = "/summarizeResourceInventory" method = "GET" operation_name = "summarize_resource_inventory" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/SummarizeResourceInventory" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8545,7 +9611,7 @@ def summarize_resource_inventory(self, **kwargs): def update_drs_file(self, fleet_id, update_drs_file_details, drs_file_key, **kwargs): """ - Request to perform validaition of the DRS file and update the existing file in the Object Storage. + Request to perform validation of the DRS file and update the existing file in the Object Storage. :param str fleet_id: (required) @@ -8599,7 +9665,7 @@ def update_drs_file(self, fleet_id, update_drs_file_details, drs_file_key, **kwa resource_path = "/fleets/{fleetId}/drsFiles/{drsFileKey}" method = "PUT" operation_name = "update_drs_file" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/UpdateDrsFile" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8671,7 +9737,7 @@ def update_drs_file(self, fleet_id, update_drs_file_details, drs_file_key, **kwa def update_export_setting(self, fleet_id, update_export_setting_details, **kwargs): """ - Updates existing export setting for the specified Fleet. + Updates existing export setting for the specified fleet. :param str fleet_id: (required) @@ -8680,7 +9746,7 @@ def update_export_setting(self, fleet_id, update_export_setting_details, **kwarg __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm :param oci.jms.models.UpdateExportSettingDetails update_export_setting_details: (required) - The new details for the Export setting. + The new details for the export setting. :param str if_match: (optional) For optimistic concurrency control. In the PUT or DELETE call @@ -8715,7 +9781,7 @@ def update_export_setting(self, fleet_id, update_export_setting_details, **kwarg resource_path = "/fleets/{fleetId}/exportSetting" method = "PUT" operation_name = "update_export_setting" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/ExportSetting/UpdateExportSetting" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8829,7 +9895,7 @@ def update_fleet(self, fleet_id, update_fleet_details, **kwargs): resource_path = "/fleets/{fleetId}" method = "PUT" operation_name = "update_fleet" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/Fleet/UpdateFleet" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -8949,7 +10015,7 @@ def update_fleet_advanced_feature_configuration(self, fleet_id, update_fleet_adv resource_path = "/fleets/{fleetId}/advancedFeatureConfiguration" method = "PUT" operation_name = "update_fleet_advanced_feature_configuration" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/FleetAdvancedFeatureConfiguration/UpdateFleetAdvancedFeatureConfiguration" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -9066,7 +10132,7 @@ def update_fleet_agent_configuration(self, fleet_id, update_fleet_agent_configur resource_path = "/fleets/{fleetId}/agentConfiguration" method = "PUT" operation_name = "update_fleet_agent_configuration" - api_reference_link = "https://docs.oracle.com/iaas/api/#/en/jms/20210610/FleetAgentConfiguration/UpdateFleetAgentConfiguration" + api_reference_link = "" # Don't accept unknown kwargs expected_kwargs = [ @@ -9131,3 +10197,117 @@ def update_fleet_agent_configuration(self, fleet_id, update_fleet_agent_configur operation_name=operation_name, api_reference_link=api_reference_link, required_arguments=required_arguments) + + def update_jms_plugin(self, jms_plugin_id, update_jms_plugin_details, **kwargs): + """ + Updates the Fleet of a JmsPlugin. + + + :param str jms_plugin_id: (required) + The `OCID`__ of the JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param oci.jms.models.UpdateJmsPluginDetails update_jms_plugin_details: (required) + The new details for the JmsPlugin. + + :param str if_match: (optional) + For optimistic concurrency control. In the PUT or DELETE call + for a resource, set the `if-match` parameter to the value of the + ETag from a previous GET or POST response for that resource. + The resource will be updated or deleted only if the ETag you + provide matches the resource's current ETag value. + + :param str opc_request_id: (optional) + The client request ID for tracing. + + :param obj retry_strategy: (optional) + A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level. + + This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided. + The specifics of the default retry strategy are described `here `__. + + To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`. + + :param bool allow_control_chars: (optional) + allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object. + By default, the response will not allow control characters in strings + + :return: A :class:`~oci.response.Response` object with data of type :class:`~oci.jms.models.JmsPlugin` + :rtype: :class:`~oci.response.Response` + + :example: + Click `here `__ to see an example of how to use update_jms_plugin API. + """ + # Required path and query arguments. These are in camelCase to replace values in service endpoints. + required_arguments = ['jmsPluginId'] + resource_path = "/jmsPlugins/{jmsPluginId}" + method = "PUT" + operation_name = "update_jms_plugin" + api_reference_link = "" + + # Don't accept unknown kwargs + expected_kwargs = [ + "allow_control_chars", + "retry_strategy", + "if_match", + "opc_request_id" + ] + extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs] + if extra_kwargs: + raise ValueError( + f"update_jms_plugin got unknown kwargs: {extra_kwargs!r}") + + path_params = { + "jmsPluginId": jms_plugin_id + } + + path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing} + + for (k, v) in six.iteritems(path_params): + if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0): + raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string') + + header_params = { + "accept": "application/json", + "content-type": "application/json", + "if-match": kwargs.get("if_match", missing), + "opc-request-id": kwargs.get("opc_request_id", missing) + } + header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None} + + retry_strategy = self.base_client.get_preferred_retry_strategy( + operation_retry_strategy=kwargs.get('retry_strategy'), + client_retry_strategy=self.retry_strategy + ) + if retry_strategy is None: + retry_strategy = retry.DEFAULT_RETRY_STRATEGY + + if retry_strategy: + if not isinstance(retry_strategy, retry.NoneRetryStrategy): + self.base_client.add_opc_client_retries_header(header_params) + retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback) + return retry_strategy.make_retrying_call( + self.base_client.call_api, + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=update_jms_plugin_details, + response_type="JmsPlugin", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) + else: + return self.base_client.call_api( + resource_path=resource_path, + method=method, + path_params=path_params, + header_params=header_params, + body=update_jms_plugin_details, + response_type="JmsPlugin", + allow_control_chars=kwargs.get('allow_control_chars'), + operation_name=operation_name, + api_reference_link=api_reference_link, + required_arguments=required_arguments) diff --git a/src/oci/jms/java_management_service_client_composite_operations.py b/src/oci/jms/java_management_service_client_composite_operations.py index acefd4b1f..b8530c1e9 100644 --- a/src/oci/jms/java_management_service_client_composite_operations.py +++ b/src/oci/jms/java_management_service_client_composite_operations.py @@ -196,6 +196,48 @@ def create_fleet_and_wait_for_state(self, create_fleet_details, wait_for_states= except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def create_jms_plugin_and_wait_for_state(self, create_jms_plugin_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.jms.JavaManagementServiceClient.create_jms_plugin` and waits for the :py:class:`~oci.jms.models.JmsPlugin` acted upon + to enter the given state(s). + + :param oci.jms.models.CreateJmsPluginDetails create_jms_plugin_details: (required) + Details for the new JmsPlugin. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.jms.models.JmsPlugin.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.jms.JavaManagementServiceClient.create_jms_plugin` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.create_jms_plugin(create_jms_plugin_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + jms_plugin_id = operation_result.data.id + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_jms_plugin(jms_plugin_id), # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_crypto_analysis_result_and_wait_for_state(self, fleet_id, crypto_analysis_result_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.jms.JavaManagementServiceClient.delete_crypto_analysis_result` and waits for the :py:class:`~oci.jms.models.WorkRequest` @@ -401,6 +443,67 @@ def delete_java_migration_analysis_result_and_wait_for_state(self, fleet_id, jav except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_jms_plugin_and_wait_for_state(self, jms_plugin_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.jms.JavaManagementServiceClient.delete_jms_plugin` and waits for the :py:class:`~oci.jms.models.JmsPlugin` acted upon + to enter the given state(s). + + :param str jms_plugin_id: (required) + The `OCID`__ of the JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.jms.models.JmsPlugin.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.jms.JavaManagementServiceClient.delete_jms_plugin` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + initial_get_result = self.client.get_jms_plugin(jms_plugin_id) + operation_result = None + try: + operation_result = self.client.delete_jms_plugin(jms_plugin_id, **operation_kwargs) + except oci.exceptions.ServiceError as e: + if e.status == 404: + return WAIT_RESOURCE_NOT_FOUND + else: + raise e + + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + + try: + if ("succeed_on_not_found" in waiter_kwargs) and (waiter_kwargs["succeed_on_not_found"] is False): + self.client.base_client.logger.warning("The waiter kwarg succeed_on_not_found was passed as False for the delete composite operation delete_jms_plugin, this would result in the operation to fail if the resource is not found! Please, do not pass this kwarg if this was not intended") + else: + """ + If the user does not send in this value, we set it to True by default. + We are doing this because during a delete resource scenario and waiting on its state, the service can + return a 404 NOT FOUND exception as the resource was deleted and a get on its state would fail + """ + waiter_kwargs["succeed_on_not_found"] = True + waiter_result = oci.wait_until( + self.client, + initial_get_result, # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def delete_performance_tuning_analysis_result_and_wait_for_state(self, fleet_id, performance_tuning_analysis_result_id, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.jms.JavaManagementServiceClient.delete_performance_tuning_analysis_result` and waits for the :py:class:`~oci.jms.models.WorkRequest` @@ -629,6 +732,50 @@ def request_crypto_analyses_and_wait_for_state(self, fleet_id, request_crypto_an except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def request_deployed_application_migration_analyses_and_wait_for_state(self, fleet_id, request_deployed_application_migration_analyses_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.jms.JavaManagementServiceClient.request_deployed_application_migration_analyses` and waits for the :py:class:`~oci.jms.models.WorkRequest` + to enter the given state(s). + + :param str fleet_id: (required) + The `OCID`__ of the Fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param oci.jms.models.RequestDeployedApplicationMigrationAnalysesDetails request_deployed_application_migration_analyses_details: (required) + Detail information that starts the deployed Java migration analyses + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.jms.models.WorkRequest.status` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.jms.JavaManagementServiceClient.request_deployed_application_migration_analyses` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.request_deployed_application_migration_analyses(fleet_id, request_deployed_application_migration_analyses_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + if 'opc-work-request-id' not in operation_result.headers: + return operation_result + wait_for_resource_id = operation_result.headers['opc-work-request-id'] + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_work_request(wait_for_resource_id), + evaluate_response=lambda r: getattr(r.data, 'status') and getattr(r.data, 'status').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + def request_java_migration_analyses_and_wait_for_state(self, fleet_id, request_java_migration_analyses_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): """ Calls :py:func:`~oci.jms.JavaManagementServiceClient.request_java_migration_analyses` and waits for the :py:class:`~oci.jms.models.WorkRequest` @@ -983,3 +1130,50 @@ def update_fleet_agent_configuration_and_wait_for_state(self, fleet_id, update_f return result_to_return except Exception as e: raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + + def update_jms_plugin_and_wait_for_state(self, jms_plugin_id, update_jms_plugin_details, wait_for_states=[], operation_kwargs={}, waiter_kwargs={}): + """ + Calls :py:func:`~oci.jms.JavaManagementServiceClient.update_jms_plugin` and waits for the :py:class:`~oci.jms.models.JmsPlugin` acted upon + to enter the given state(s). + + :param str jms_plugin_id: (required) + The `OCID`__ of the JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + :param oci.jms.models.UpdateJmsPluginDetails update_jms_plugin_details: (required) + The new details for the JmsPlugin. + + :param list[str] wait_for_states: + An array of states to wait on. These should be valid values for :py:attr:`~oci.jms.models.JmsPlugin.lifecycle_state` + + :param dict operation_kwargs: + A dictionary of keyword arguments to pass to :py:func:`~oci.jms.JavaManagementServiceClient.update_jms_plugin` + + :param dict waiter_kwargs: + A dictionary of keyword arguments to pass to the :py:func:`oci.wait_until` function. For example, you could pass ``max_interval_seconds`` or ``max_interval_seconds`` + as dictionary keys to modify how long the waiter function will wait between retries and the maximum amount of time it will wait + """ + operation_result = self.client.update_jms_plugin(jms_plugin_id, update_jms_plugin_details, **operation_kwargs) + if not wait_for_states: + return operation_result + lowered_wait_for_states = [w.lower() for w in wait_for_states] + jms_plugin_id = operation_result.data.id + + try: + waiter_result = oci.wait_until( + self.client, + self.client.get_jms_plugin(jms_plugin_id), # noqa: F821 + evaluate_response=lambda r: getattr(r.data, 'lifecycle_state') and getattr(r.data, 'lifecycle_state').lower() in lowered_wait_for_states, + **waiter_kwargs + ) + result_to_return = waiter_result + + return result_to_return + except (NameError, TypeError) as e: + if not e.args: + e.args = ('',) + e.args = e.args + ('This composite operation is currently not supported in the SDK. Please use the operation from the service client and use waiters as an alternative. For more information on waiters, visit: "https://docs.oracle.com/en-us/iaas/tools/python/latest/api/waiters.html"', ) + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) + except Exception as e: + raise oci.exceptions.CompositeOperationError(partial_results=[operation_result], cause=e) diff --git a/src/oci/jms/models/__init__.py b/src/oci/jms/models/__init__.py index e3b4ffe23..2f408936b 100644 --- a/src/oci/jms/models/__init__.py +++ b/src/oci/jms/models/__init__.py @@ -9,6 +9,8 @@ from .add_fleet_installation_sites_details import AddFleetInstallationSitesDetails from .advanced_usage_tracking import AdvancedUsageTracking from .agent import Agent +from .agent_installer_collection import AgentInstallerCollection +from .agent_installer_summary import AgentInstallerSummary from .announcement_collection import AnnouncementCollection from .announcement_summary import AnnouncementSummary from .application_installation_usage_summary import ApplicationInstallationUsageSummary @@ -25,6 +27,7 @@ from .create_blocklist_details import CreateBlocklistDetails from .create_drs_file_details import CreateDrsFileDetails from .create_fleet_details import CreateFleetDetails +from .create_jms_plugin_details import CreateJmsPluginDetails from .crypto_analysis_result import CryptoAnalysisResult from .crypto_analysis_result_collection import CryptoAnalysisResultCollection from .crypto_analysis_result_summary import CryptoAnalysisResultSummary @@ -32,8 +35,10 @@ from .custom_log import CustomLog from .deployed_application_installation_usage_summary import DeployedApplicationInstallationUsageSummary from .deployed_application_installation_usage_summary_collection import DeployedApplicationInstallationUsageSummaryCollection +from .deployed_application_migration_analyses_target import DeployedApplicationMigrationAnalysesTarget from .deployed_application_usage import DeployedApplicationUsage from .deployed_application_usage_collection import DeployedApplicationUsageCollection +from .deployed_application_work_item_details import DeployedApplicationWorkItemDetails from .disable_drs_details import DisableDrsDetails from .drs_file import DrsFile from .drs_file_collection import DrsFileCollection @@ -52,6 +57,8 @@ from .fleet_diagnosis_summary import FleetDiagnosisSummary from .fleet_summary import FleetSummary from .generate_agent_deploy_script_details import GenerateAgentDeployScriptDetails +from .generate_agent_installer_configuration_details import GenerateAgentInstallerConfigurationDetails +from .generate_load_pipeline_script_details import GenerateLoadPipelineScriptDetails from .installation_site import InstallationSite from .installation_site_collection import InstallationSiteCollection from .installation_site_summary import InstallationSiteSummary @@ -77,6 +84,9 @@ from .java_server_usage_collection import JavaServerUsageCollection from .jfr_attachment_target import JfrAttachmentTarget from .jfr_recording import JfrRecording +from .jms_plugin import JmsPlugin +from .jms_plugin_collection import JmsPluginCollection +from .jms_plugin_summary import JmsPluginSummary from .jre_usage import JreUsage from .jre_usage_collection import JreUsageCollection from .key_size_algorithm import KeySizeAlgorithm @@ -101,6 +111,7 @@ from .proxies import Proxies from .remove_fleet_installation_sites_details import RemoveFleetInstallationSitesDetails from .request_crypto_analyses_details import RequestCryptoAnalysesDetails +from .request_deployed_application_migration_analyses_details import RequestDeployedApplicationMigrationAnalysesDetails from .request_java_migration_analyses_details import RequestJavaMigrationAnalysesDetails from .request_jfr_recordings_details import RequestJfrRecordingsDetails from .request_performance_tuning_analyses_details import RequestPerformanceTuningAnalysesDetails @@ -113,6 +124,7 @@ from .update_fleet_advanced_feature_configuration_details import UpdateFleetAdvancedFeatureConfigurationDetails from .update_fleet_agent_configuration_details import UpdateFleetAgentConfigurationDetails from .update_fleet_details import UpdateFleetDetails +from .update_jms_plugin_details import UpdateJmsPluginDetails from .work_item_collection import WorkItemCollection from .work_item_details import WorkItemDetails from .work_item_summary import WorkItemSummary @@ -129,6 +141,8 @@ "AddFleetInstallationSitesDetails": AddFleetInstallationSitesDetails, "AdvancedUsageTracking": AdvancedUsageTracking, "Agent": Agent, + "AgentInstallerCollection": AgentInstallerCollection, + "AgentInstallerSummary": AgentInstallerSummary, "AnnouncementCollection": AnnouncementCollection, "AnnouncementSummary": AnnouncementSummary, "ApplicationInstallationUsageSummary": ApplicationInstallationUsageSummary, @@ -145,6 +159,7 @@ "CreateBlocklistDetails": CreateBlocklistDetails, "CreateDrsFileDetails": CreateDrsFileDetails, "CreateFleetDetails": CreateFleetDetails, + "CreateJmsPluginDetails": CreateJmsPluginDetails, "CryptoAnalysisResult": CryptoAnalysisResult, "CryptoAnalysisResultCollection": CryptoAnalysisResultCollection, "CryptoAnalysisResultSummary": CryptoAnalysisResultSummary, @@ -152,8 +167,10 @@ "CustomLog": CustomLog, "DeployedApplicationInstallationUsageSummary": DeployedApplicationInstallationUsageSummary, "DeployedApplicationInstallationUsageSummaryCollection": DeployedApplicationInstallationUsageSummaryCollection, + "DeployedApplicationMigrationAnalysesTarget": DeployedApplicationMigrationAnalysesTarget, "DeployedApplicationUsage": DeployedApplicationUsage, "DeployedApplicationUsageCollection": DeployedApplicationUsageCollection, + "DeployedApplicationWorkItemDetails": DeployedApplicationWorkItemDetails, "DisableDrsDetails": DisableDrsDetails, "DrsFile": DrsFile, "DrsFileCollection": DrsFileCollection, @@ -172,6 +189,8 @@ "FleetDiagnosisSummary": FleetDiagnosisSummary, "FleetSummary": FleetSummary, "GenerateAgentDeployScriptDetails": GenerateAgentDeployScriptDetails, + "GenerateAgentInstallerConfigurationDetails": GenerateAgentInstallerConfigurationDetails, + "GenerateLoadPipelineScriptDetails": GenerateLoadPipelineScriptDetails, "InstallationSite": InstallationSite, "InstallationSiteCollection": InstallationSiteCollection, "InstallationSiteSummary": InstallationSiteSummary, @@ -197,6 +216,9 @@ "JavaServerUsageCollection": JavaServerUsageCollection, "JfrAttachmentTarget": JfrAttachmentTarget, "JfrRecording": JfrRecording, + "JmsPlugin": JmsPlugin, + "JmsPluginCollection": JmsPluginCollection, + "JmsPluginSummary": JmsPluginSummary, "JreUsage": JreUsage, "JreUsageCollection": JreUsageCollection, "KeySizeAlgorithm": KeySizeAlgorithm, @@ -221,6 +243,7 @@ "Proxies": Proxies, "RemoveFleetInstallationSitesDetails": RemoveFleetInstallationSitesDetails, "RequestCryptoAnalysesDetails": RequestCryptoAnalysesDetails, + "RequestDeployedApplicationMigrationAnalysesDetails": RequestDeployedApplicationMigrationAnalysesDetails, "RequestJavaMigrationAnalysesDetails": RequestJavaMigrationAnalysesDetails, "RequestJfrRecordingsDetails": RequestJfrRecordingsDetails, "RequestPerformanceTuningAnalysesDetails": RequestPerformanceTuningAnalysesDetails, @@ -233,6 +256,7 @@ "UpdateFleetAdvancedFeatureConfigurationDetails": UpdateFleetAdvancedFeatureConfigurationDetails, "UpdateFleetAgentConfigurationDetails": UpdateFleetAgentConfigurationDetails, "UpdateFleetDetails": UpdateFleetDetails, + "UpdateJmsPluginDetails": UpdateJmsPluginDetails, "WorkItemCollection": WorkItemCollection, "WorkItemDetails": WorkItemDetails, "WorkItemSummary": WorkItemSummary, diff --git a/src/oci/jms/models/agent_installer_collection.py b/src/oci/jms/models/agent_installer_collection.py new file mode 100644 index 000000000..21dcd0e01 --- /dev/null +++ b/src/oci/jms/models/agent_installer_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class AgentInstallerCollection(object): + """ + Collection of the agent installer summary. + """ + + def __init__(self, **kwargs): + """ + Initializes a new AgentInstallerCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this AgentInstallerCollection. + :type items: list[oci.jms.models.AgentInstallerSummary] + + """ + self.swagger_types = { + 'items': 'list[AgentInstallerSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this AgentInstallerCollection. + A list of the agent installer summaries. + + + :return: The items of this AgentInstallerCollection. + :rtype: list[oci.jms.models.AgentInstallerSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this AgentInstallerCollection. + A list of the agent installer summaries. + + + :param items: The items of this AgentInstallerCollection. + :type: list[oci.jms.models.AgentInstallerSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/agent_installer_summary.py b/src/oci/jms/models/agent_installer_summary.py new file mode 100644 index 000000000..47461d697 --- /dev/null +++ b/src/oci/jms/models/agent_installer_summary.py @@ -0,0 +1,411 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class AgentInstallerSummary(object): + """ + Supported agent installer downloads. + """ + + #: A constant which can be used with the os_family property of a AgentInstallerSummary. + #: This constant has a value of "LINUX" + OS_FAMILY_LINUX = "LINUX" + + #: A constant which can be used with the os_family property of a AgentInstallerSummary. + #: This constant has a value of "WINDOWS" + OS_FAMILY_WINDOWS = "WINDOWS" + + #: A constant which can be used with the os_family property of a AgentInstallerSummary. + #: This constant has a value of "MACOS" + OS_FAMILY_MACOS = "MACOS" + + #: A constant which can be used with the os_family property of a AgentInstallerSummary. + #: This constant has a value of "UNKNOWN" + OS_FAMILY_UNKNOWN = "UNKNOWN" + + #: A constant which can be used with the platform_architecture property of a AgentInstallerSummary. + #: This constant has a value of "X86_64" + PLATFORM_ARCHITECTURE_X86_64 = "X86_64" + + #: A constant which can be used with the platform_architecture property of a AgentInstallerSummary. + #: This constant has a value of "X86" + PLATFORM_ARCHITECTURE_X86 = "X86" + + #: A constant which can be used with the platform_architecture property of a AgentInstallerSummary. + #: This constant has a value of "AARCH64" + PLATFORM_ARCHITECTURE_AARCH64 = "AARCH64" + + #: A constant which can be used with the package_type property of a AgentInstallerSummary. + #: This constant has a value of "RPM" + PACKAGE_TYPE_RPM = "RPM" + + #: A constant which can be used with the package_type property of a AgentInstallerSummary. + #: This constant has a value of "ZIP" + PACKAGE_TYPE_ZIP = "ZIP" + + def __init__(self, **kwargs): + """ + Initializes a new AgentInstallerSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param agent_installer_id: + The value to assign to the agent_installer_id property of this AgentInstallerSummary. + :type agent_installer_id: int + + :param agent_installer_description: + The value to assign to the agent_installer_description property of this AgentInstallerSummary. + :type agent_installer_description: str + + :param approximate_file_size_in_bytes: + The value to assign to the approximate_file_size_in_bytes property of this AgentInstallerSummary. + :type approximate_file_size_in_bytes: int + + :param sha256: + The value to assign to the sha256 property of this AgentInstallerSummary. + :type sha256: str + + :param os_family: + The value to assign to the os_family property of this AgentInstallerSummary. + Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type os_family: str + + :param platform_architecture: + The value to assign to the platform_architecture property of this AgentInstallerSummary. + Allowed values for this property are: "X86_64", "X86", "AARCH64", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type platform_architecture: str + + :param package_type: + The value to assign to the package_type property of this AgentInstallerSummary. + Allowed values for this property are: "RPM", "ZIP", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type package_type: str + + :param agent_version: + The value to assign to the agent_version property of this AgentInstallerSummary. + :type agent_version: str + + :param java_version: + The value to assign to the java_version property of this AgentInstallerSummary. + :type java_version: str + + :param agent_installer_version: + The value to assign to the agent_installer_version property of this AgentInstallerSummary. + :type agent_installer_version: str + + """ + self.swagger_types = { + 'agent_installer_id': 'int', + 'agent_installer_description': 'str', + 'approximate_file_size_in_bytes': 'int', + 'sha256': 'str', + 'os_family': 'str', + 'platform_architecture': 'str', + 'package_type': 'str', + 'agent_version': 'str', + 'java_version': 'str', + 'agent_installer_version': 'str' + } + + self.attribute_map = { + 'agent_installer_id': 'agentInstallerId', + 'agent_installer_description': 'agentInstallerDescription', + 'approximate_file_size_in_bytes': 'approximateFileSizeInBytes', + 'sha256': 'sha256', + 'os_family': 'osFamily', + 'platform_architecture': 'platformArchitecture', + 'package_type': 'packageType', + 'agent_version': 'agentVersion', + 'java_version': 'javaVersion', + 'agent_installer_version': 'agentInstallerVersion' + } + + self._agent_installer_id = None + self._agent_installer_description = None + self._approximate_file_size_in_bytes = None + self._sha256 = None + self._os_family = None + self._platform_architecture = None + self._package_type = None + self._agent_version = None + self._java_version = None + self._agent_installer_version = None + + @property + def agent_installer_id(self): + """ + **[Required]** Gets the agent_installer_id of this AgentInstallerSummary. + Unique identifier for the agent installer. + + + :return: The agent_installer_id of this AgentInstallerSummary. + :rtype: int + """ + return self._agent_installer_id + + @agent_installer_id.setter + def agent_installer_id(self, agent_installer_id): + """ + Sets the agent_installer_id of this AgentInstallerSummary. + Unique identifier for the agent installer. + + + :param agent_installer_id: The agent_installer_id of this AgentInstallerSummary. + :type: int + """ + self._agent_installer_id = agent_installer_id + + @property + def agent_installer_description(self): + """ + **[Required]** Gets the agent_installer_description of this AgentInstallerSummary. + Description of the agent installer artifact. The description typically includes the OS, architecture, and agent installer type. + + + :return: The agent_installer_description of this AgentInstallerSummary. + :rtype: str + """ + return self._agent_installer_description + + @agent_installer_description.setter + def agent_installer_description(self, agent_installer_description): + """ + Sets the agent_installer_description of this AgentInstallerSummary. + Description of the agent installer artifact. The description typically includes the OS, architecture, and agent installer type. + + + :param agent_installer_description: The agent_installer_description of this AgentInstallerSummary. + :type: str + """ + self._agent_installer_description = agent_installer_description + + @property + def approximate_file_size_in_bytes(self): + """ + **[Required]** Gets the approximate_file_size_in_bytes of this AgentInstallerSummary. + Approximate compressed file size in bytes. + + + :return: The approximate_file_size_in_bytes of this AgentInstallerSummary. + :rtype: int + """ + return self._approximate_file_size_in_bytes + + @approximate_file_size_in_bytes.setter + def approximate_file_size_in_bytes(self, approximate_file_size_in_bytes): + """ + Sets the approximate_file_size_in_bytes of this AgentInstallerSummary. + Approximate compressed file size in bytes. + + + :param approximate_file_size_in_bytes: The approximate_file_size_in_bytes of this AgentInstallerSummary. + :type: int + """ + self._approximate_file_size_in_bytes = approximate_file_size_in_bytes + + @property + def sha256(self): + """ + **[Required]** Gets the sha256 of this AgentInstallerSummary. + SHA256 checksum of the agent installer. + + + :return: The sha256 of this AgentInstallerSummary. + :rtype: str + """ + return self._sha256 + + @sha256.setter + def sha256(self, sha256): + """ + Sets the sha256 of this AgentInstallerSummary. + SHA256 checksum of the agent installer. + + + :param sha256: The sha256 of this AgentInstallerSummary. + :type: str + """ + self._sha256 = sha256 + + @property + def os_family(self): + """ + **[Required]** Gets the os_family of this AgentInstallerSummary. + The target operating system family for the agent installer. + + Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The os_family of this AgentInstallerSummary. + :rtype: str + """ + return self._os_family + + @os_family.setter + def os_family(self, os_family): + """ + Sets the os_family of this AgentInstallerSummary. + The target operating system family for the agent installer. + + + :param os_family: The os_family of this AgentInstallerSummary. + :type: str + """ + allowed_values = ["LINUX", "WINDOWS", "MACOS", "UNKNOWN"] + if not value_allowed_none_or_none_sentinel(os_family, allowed_values): + os_family = 'UNKNOWN_ENUM_VALUE' + self._os_family = os_family + + @property + def platform_architecture(self): + """ + **[Required]** Gets the platform_architecture of this AgentInstallerSummary. + The target operating system architecture for the installer. + + Allowed values for this property are: "X86_64", "X86", "AARCH64", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The platform_architecture of this AgentInstallerSummary. + :rtype: str + """ + return self._platform_architecture + + @platform_architecture.setter + def platform_architecture(self, platform_architecture): + """ + Sets the platform_architecture of this AgentInstallerSummary. + The target operating system architecture for the installer. + + + :param platform_architecture: The platform_architecture of this AgentInstallerSummary. + :type: str + """ + allowed_values = ["X86_64", "X86", "AARCH64"] + if not value_allowed_none_or_none_sentinel(platform_architecture, allowed_values): + platform_architecture = 'UNKNOWN_ENUM_VALUE' + self._platform_architecture = platform_architecture + + @property + def package_type(self): + """ + **[Required]** Gets the package_type of this AgentInstallerSummary. + The package type (typically the file extension) of the agent software included in the installer. + + Allowed values for this property are: "RPM", "ZIP", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The package_type of this AgentInstallerSummary. + :rtype: str + """ + return self._package_type + + @package_type.setter + def package_type(self, package_type): + """ + Sets the package_type of this AgentInstallerSummary. + The package type (typically the file extension) of the agent software included in the installer. + + + :param package_type: The package_type of this AgentInstallerSummary. + :type: str + """ + allowed_values = ["RPM", "ZIP"] + if not value_allowed_none_or_none_sentinel(package_type, allowed_values): + package_type = 'UNKNOWN_ENUM_VALUE' + self._package_type = package_type + + @property + def agent_version(self): + """ + **[Required]** Gets the agent_version of this AgentInstallerSummary. + Agent image version. + + + :return: The agent_version of this AgentInstallerSummary. + :rtype: str + """ + return self._agent_version + + @agent_version.setter + def agent_version(self, agent_version): + """ + Sets the agent_version of this AgentInstallerSummary. + Agent image version. + + + :param agent_version: The agent_version of this AgentInstallerSummary. + :type: str + """ + self._agent_version = agent_version + + @property + def java_version(self): + """ + **[Required]** Gets the java_version of this AgentInstallerSummary. + Java version. + + + :return: The java_version of this AgentInstallerSummary. + :rtype: str + """ + return self._java_version + + @java_version.setter + def java_version(self, java_version): + """ + Sets the java_version of this AgentInstallerSummary. + Java version. + + + :param java_version: The java_version of this AgentInstallerSummary. + :type: str + """ + self._java_version = java_version + + @property + def agent_installer_version(self): + """ + **[Required]** Gets the agent_installer_version of this AgentInstallerSummary. + Agent installer version. + + + :return: The agent_installer_version of this AgentInstallerSummary. + :rtype: str + """ + return self._agent_installer_version + + @agent_installer_version.setter + def agent_installer_version(self, agent_installer_version): + """ + Sets the agent_installer_version of this AgentInstallerSummary. + Agent installer version. + + + :param agent_installer_version: The agent_installer_version of this AgentInstallerSummary. + :type: str + """ + self._agent_installer_version = agent_installer_version + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/application_installation_usage_summary.py b/src/oci/jms/models/application_installation_usage_summary.py index 8f11b1c06..32be2e957 100644 --- a/src/oci/jms/models/application_installation_usage_summary.py +++ b/src/oci/jms/models/application_installation_usage_summary.py @@ -61,6 +61,14 @@ def __init__(self, **kwargs): The value to assign to the approximate_managed_instance_count property of this ApplicationInstallationUsageSummary. :type approximate_managed_instance_count: int + :param approximate_library_count: + The value to assign to the approximate_library_count property of this ApplicationInstallationUsageSummary. + :type approximate_library_count: int + + :param application_invoked_by: + The value to assign to the application_invoked_by property of this ApplicationInstallationUsageSummary. + :type application_invoked_by: str + :param time_start: The value to assign to the time_start property of this ApplicationInstallationUsageSummary. :type time_start: datetime @@ -89,6 +97,8 @@ def __init__(self, **kwargs): 'approximate_installation_count': 'int', 'approximate_jre_count': 'int', 'approximate_managed_instance_count': 'int', + 'approximate_library_count': 'int', + 'application_invoked_by': 'str', 'time_start': 'datetime', 'time_end': 'datetime', 'time_first_seen': 'datetime', @@ -106,6 +116,8 @@ def __init__(self, **kwargs): 'approximate_installation_count': 'approximateInstallationCount', 'approximate_jre_count': 'approximateJreCount', 'approximate_managed_instance_count': 'approximateManagedInstanceCount', + 'approximate_library_count': 'approximateLibraryCount', + 'application_invoked_by': 'applicationInvokedBy', 'time_start': 'timeStart', 'time_end': 'timeEnd', 'time_first_seen': 'timeFirstSeen', @@ -122,6 +134,8 @@ def __init__(self, **kwargs): self._approximate_installation_count = None self._approximate_jre_count = None self._approximate_managed_instance_count = None + self._approximate_library_count = None + self._application_invoked_by = None self._time_start = None self._time_end = None self._time_first_seen = None @@ -371,6 +385,54 @@ def approximate_managed_instance_count(self, approximate_managed_instance_count) """ self._approximate_managed_instance_count = approximate_managed_instance_count + @property + def approximate_library_count(self): + """ + Gets the approximate_library_count of this ApplicationInstallationUsageSummary. + The approximate count of libraries in this application. + + + :return: The approximate_library_count of this ApplicationInstallationUsageSummary. + :rtype: int + """ + return self._approximate_library_count + + @approximate_library_count.setter + def approximate_library_count(self, approximate_library_count): + """ + Sets the approximate_library_count of this ApplicationInstallationUsageSummary. + The approximate count of libraries in this application. + + + :param approximate_library_count: The approximate_library_count of this ApplicationInstallationUsageSummary. + :type: int + """ + self._approximate_library_count = approximate_library_count + + @property + def application_invoked_by(self): + """ + Gets the application_invoked_by of this ApplicationInstallationUsageSummary. + Comma separated list of user names that invoked application installations. + + + :return: The application_invoked_by of this ApplicationInstallationUsageSummary. + :rtype: str + """ + return self._application_invoked_by + + @application_invoked_by.setter + def application_invoked_by(self, application_invoked_by): + """ + Sets the application_invoked_by of this ApplicationInstallationUsageSummary. + Comma separated list of user names that invoked application installations. + + + :param application_invoked_by: The application_invoked_by of this ApplicationInstallationUsageSummary. + :type: str + """ + self._application_invoked_by = application_invoked_by + @property def time_start(self): """ diff --git a/src/oci/jms/models/application_usage.py b/src/oci/jms/models/application_usage.py index d3e5d5828..e0a6414b0 100644 --- a/src/oci/jms/models/application_usage.py +++ b/src/oci/jms/models/application_usage.py @@ -50,6 +50,10 @@ def __init__(self, **kwargs): The value to assign to the approximate_managed_instance_count property of this ApplicationUsage. :type approximate_managed_instance_count: int + :param approximate_library_count: + The value to assign to the approximate_library_count property of this ApplicationUsage. + :type approximate_library_count: int + :param time_start: The value to assign to the time_start property of this ApplicationUsage. :type time_start: datetime @@ -75,6 +79,7 @@ def __init__(self, **kwargs): 'approximate_installation_count': 'int', 'approximate_jre_count': 'int', 'approximate_managed_instance_count': 'int', + 'approximate_library_count': 'int', 'time_start': 'datetime', 'time_end': 'datetime', 'time_first_seen': 'datetime', @@ -89,6 +94,7 @@ def __init__(self, **kwargs): 'approximate_installation_count': 'approximateInstallationCount', 'approximate_jre_count': 'approximateJreCount', 'approximate_managed_instance_count': 'approximateManagedInstanceCount', + 'approximate_library_count': 'approximateLibraryCount', 'time_start': 'timeStart', 'time_end': 'timeEnd', 'time_first_seen': 'timeFirstSeen', @@ -102,6 +108,7 @@ def __init__(self, **kwargs): self._approximate_installation_count = None self._approximate_jre_count = None self._approximate_managed_instance_count = None + self._approximate_library_count = None self._time_start = None self._time_end = None self._time_first_seen = None @@ -111,7 +118,7 @@ def __init__(self, **kwargs): def application_id(self): """ **[Required]** Gets the application_id of this ApplicationUsage. - An internal identifier for the application that is unique to a Fleet. + An internal identifier for the application that is unique to a fleet. :return: The application_id of this ApplicationUsage. @@ -123,7 +130,7 @@ def application_id(self): def application_id(self, application_id): """ Sets the application_id of this ApplicationUsage. - An internal identifier for the application that is unique to a Fleet. + An internal identifier for the application that is unique to a fleet. :param application_id: The application_id of this ApplicationUsage. @@ -159,7 +166,7 @@ def display_name(self, display_name): def application_type(self): """ **[Required]** Gets the application_type of this ApplicationUsage. - The type of the application, denoted by how the application was started. + The type of the application denoted by how the application was started. :return: The application_type of this ApplicationUsage. @@ -171,7 +178,7 @@ def application_type(self): def application_type(self, application_type): """ Sets the application_type of this ApplicationUsage. - The type of the application, denoted by how the application was started. + The type of the application denoted by how the application was started. :param application_type: The application_type of this ApplicationUsage. @@ -275,6 +282,30 @@ def approximate_managed_instance_count(self, approximate_managed_instance_count) """ self._approximate_managed_instance_count = approximate_managed_instance_count + @property + def approximate_library_count(self): + """ + Gets the approximate_library_count of this ApplicationUsage. + The approximate count of libraries in this application. + + + :return: The approximate_library_count of this ApplicationUsage. + :rtype: int + """ + return self._approximate_library_count + + @approximate_library_count.setter + def approximate_library_count(self, approximate_library_count): + """ + Sets the approximate_library_count of this ApplicationUsage. + The approximate count of libraries in this application. + + + :param approximate_library_count: The approximate_library_count of this ApplicationUsage. + :type: int + """ + self._approximate_library_count = approximate_library_count + @property def time_start(self): """ diff --git a/src/oci/jms/models/application_work_item_details.py b/src/oci/jms/models/application_work_item_details.py index 68aabbc04..7b1d20d05 100644 --- a/src/oci/jms/models/application_work_item_details.py +++ b/src/oci/jms/models/application_work_item_details.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param kind: The value to assign to the kind property of this ApplicationWorkItemDetails. - Allowed values for this property are: "BASIC", "APPLICATION", "LCM" + Allowed values for this property are: "BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION" :type kind: str :param work_item_type: diff --git a/src/oci/jms/models/basic_work_item_details.py b/src/oci/jms/models/basic_work_item_details.py index a2e127cdf..8b2c810d4 100644 --- a/src/oci/jms/models/basic_work_item_details.py +++ b/src/oci/jms/models/basic_work_item_details.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param kind: The value to assign to the kind property of this BasicWorkItemDetails. - Allowed values for this property are: "BASIC", "APPLICATION", "LCM" + Allowed values for this property are: "BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION" :type kind: str :param work_item_type: diff --git a/src/oci/jms/models/create_jms_plugin_details.py b/src/oci/jms/models/create_jms_plugin_details.py new file mode 100644 index 000000000..d87f1699e --- /dev/null +++ b/src/oci/jms/models/create_jms_plugin_details.py @@ -0,0 +1,220 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class CreateJmsPluginDetails(object): + """ + The details for creating a JmsPlugin. + """ + + def __init__(self, **kwargs): + """ + Initializes a new CreateJmsPluginDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param agent_id: + The value to assign to the agent_id property of this CreateJmsPluginDetails. + :type agent_id: str + + :param compartment_id: + The value to assign to the compartment_id property of this CreateJmsPluginDetails. + :type compartment_id: str + + :param fleet_id: + The value to assign to the fleet_id property of this CreateJmsPluginDetails. + :type fleet_id: str + + :param defined_tags: + The value to assign to the defined_tags property of this CreateJmsPluginDetails. + :type defined_tags: dict(str, dict(str, object)) + + :param freeform_tags: + The value to assign to the freeform_tags property of this CreateJmsPluginDetails. + :type freeform_tags: dict(str, str) + + """ + self.swagger_types = { + 'agent_id': 'str', + 'compartment_id': 'str', + 'fleet_id': 'str', + 'defined_tags': 'dict(str, dict(str, object))', + 'freeform_tags': 'dict(str, str)' + } + + self.attribute_map = { + 'agent_id': 'agentId', + 'compartment_id': 'compartmentId', + 'fleet_id': 'fleetId', + 'defined_tags': 'definedTags', + 'freeform_tags': 'freeformTags' + } + + self._agent_id = None + self._compartment_id = None + self._fleet_id = None + self._defined_tags = None + self._freeform_tags = None + + @property + def agent_id(self): + """ + **[Required]** Gets the agent_id of this CreateJmsPluginDetails. + The `OCID`__ of the Management Agent (OMA) or the Oracle Cloud Agent (OCA) instance where the JMS plugin is deployed. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The agent_id of this CreateJmsPluginDetails. + :rtype: str + """ + return self._agent_id + + @agent_id.setter + def agent_id(self, agent_id): + """ + Sets the agent_id of this CreateJmsPluginDetails. + The `OCID`__ of the Management Agent (OMA) or the Oracle Cloud Agent (OCA) instance where the JMS plugin is deployed. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param agent_id: The agent_id of this CreateJmsPluginDetails. + :type: str + """ + self._agent_id = agent_id + + @property + def compartment_id(self): + """ + **[Required]** Gets the compartment_id of this CreateJmsPluginDetails. + The OMA/OCA agent's compartment `OCID`__. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The compartment_id of this CreateJmsPluginDetails. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this CreateJmsPluginDetails. + The OMA/OCA agent's compartment `OCID`__. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param compartment_id: The compartment_id of this CreateJmsPluginDetails. + :type: str + """ + self._compartment_id = compartment_id + + @property + def fleet_id(self): + """ + Gets the fleet_id of this CreateJmsPluginDetails. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The fleet_id of this CreateJmsPluginDetails. + :rtype: str + """ + return self._fleet_id + + @fleet_id.setter + def fleet_id(self, fleet_id): + """ + Sets the fleet_id of this CreateJmsPluginDetails. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param fleet_id: The fleet_id of this CreateJmsPluginDetails. + :type: str + """ + self._fleet_id = fleet_id + + @property + def defined_tags(self): + """ + Gets the defined_tags of this CreateJmsPluginDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :return: The defined_tags of this CreateJmsPluginDetails. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this CreateJmsPluginDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :param defined_tags: The defined_tags of this CreateJmsPluginDetails. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this CreateJmsPluginDetails. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :return: The freeform_tags of this CreateJmsPluginDetails. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this CreateJmsPluginDetails. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :param freeform_tags: The freeform_tags of this CreateJmsPluginDetails. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/crypto_analysis_result.py b/src/oci/jms/models/crypto_analysis_result.py index 59cba4554..35f765ebf 100644 --- a/src/oci/jms/models/crypto_analysis_result.py +++ b/src/oci/jms/models/crypto_analysis_result.py @@ -82,6 +82,14 @@ def __init__(self, **kwargs): The value to assign to the time_created property of this CryptoAnalysisResult. :type time_created: datetime + :param time_started: + The value to assign to the time_started property of this CryptoAnalysisResult. + :type time_started: datetime + + :param time_finished: + The value to assign to the time_finished property of this CryptoAnalysisResult. + :type time_finished: datetime + :param crypto_roadmap_version: The value to assign to the crypto_roadmap_version property of this CryptoAnalysisResult. :type crypto_roadmap_version: str @@ -113,6 +121,8 @@ def __init__(self, **kwargs): 'finding_count': 'int', 'non_compliant_finding_count': 'int', 'time_created': 'datetime', + 'time_started': 'datetime', + 'time_finished': 'datetime', 'crypto_roadmap_version': 'str', 'namespace': 'str', 'bucket_name': 'str', @@ -133,6 +143,8 @@ def __init__(self, **kwargs): 'finding_count': 'findingCount', 'non_compliant_finding_count': 'nonCompliantFindingCount', 'time_created': 'timeCreated', + 'time_started': 'timeStarted', + 'time_finished': 'timeFinished', 'crypto_roadmap_version': 'cryptoRoadmapVersion', 'namespace': 'namespace', 'bucket_name': 'bucketName', @@ -152,6 +164,8 @@ def __init__(self, **kwargs): self._finding_count = None self._non_compliant_finding_count = None self._time_created = None + self._time_started = None + self._time_finished = None self._crypto_roadmap_version = None self._namespace = None self._bucket_name = None @@ -479,6 +493,54 @@ def time_created(self, time_created): """ self._time_created = time_created + @property + def time_started(self): + """ + Gets the time_started of this CryptoAnalysisResult. + The time the JFR recording has started. + + + :return: The time_started of this CryptoAnalysisResult. + :rtype: datetime + """ + return self._time_started + + @time_started.setter + def time_started(self, time_started): + """ + Sets the time_started of this CryptoAnalysisResult. + The time the JFR recording has started. + + + :param time_started: The time_started of this CryptoAnalysisResult. + :type: datetime + """ + self._time_started = time_started + + @property + def time_finished(self): + """ + Gets the time_finished of this CryptoAnalysisResult. + The time the JFR recording has finished. + + + :return: The time_finished of this CryptoAnalysisResult. + :rtype: datetime + """ + return self._time_finished + + @time_finished.setter + def time_finished(self, time_finished): + """ + Sets the time_finished of this CryptoAnalysisResult. + The time the JFR recording has finished. + + + :param time_finished: The time_finished of this CryptoAnalysisResult. + :type: datetime + """ + self._time_finished = time_finished + @property def crypto_roadmap_version(self): """ diff --git a/src/oci/jms/models/crypto_analysis_result_summary.py b/src/oci/jms/models/crypto_analysis_result_summary.py index 5c361feef..08480ffc5 100644 --- a/src/oci/jms/models/crypto_analysis_result_summary.py +++ b/src/oci/jms/models/crypto_analysis_result_summary.py @@ -82,6 +82,14 @@ def __init__(self, **kwargs): The value to assign to the time_created property of this CryptoAnalysisResultSummary. :type time_created: datetime + :param time_started: + The value to assign to the time_started property of this CryptoAnalysisResultSummary. + :type time_started: datetime + + :param time_finished: + The value to assign to the time_finished property of this CryptoAnalysisResultSummary. + :type time_finished: datetime + :param crypto_roadmap_version: The value to assign to the crypto_roadmap_version property of this CryptoAnalysisResultSummary. :type crypto_roadmap_version: str @@ -113,6 +121,8 @@ def __init__(self, **kwargs): 'finding_count': 'int', 'non_compliant_finding_count': 'int', 'time_created': 'datetime', + 'time_started': 'datetime', + 'time_finished': 'datetime', 'crypto_roadmap_version': 'str', 'namespace': 'str', 'bucket_name': 'str', @@ -133,6 +143,8 @@ def __init__(self, **kwargs): 'finding_count': 'findingCount', 'non_compliant_finding_count': 'nonCompliantFindingCount', 'time_created': 'timeCreated', + 'time_started': 'timeStarted', + 'time_finished': 'timeFinished', 'crypto_roadmap_version': 'cryptoRoadmapVersion', 'namespace': 'namespace', 'bucket_name': 'bucketName', @@ -152,6 +164,8 @@ def __init__(self, **kwargs): self._finding_count = None self._non_compliant_finding_count = None self._time_created = None + self._time_started = None + self._time_finished = None self._crypto_roadmap_version = None self._namespace = None self._bucket_name = None @@ -479,6 +493,54 @@ def time_created(self, time_created): """ self._time_created = time_created + @property + def time_started(self): + """ + Gets the time_started of this CryptoAnalysisResultSummary. + The time the JFR recording has started. + + + :return: The time_started of this CryptoAnalysisResultSummary. + :rtype: datetime + """ + return self._time_started + + @time_started.setter + def time_started(self, time_started): + """ + Sets the time_started of this CryptoAnalysisResultSummary. + The time the JFR recording has started. + + + :param time_started: The time_started of this CryptoAnalysisResultSummary. + :type: datetime + """ + self._time_started = time_started + + @property + def time_finished(self): + """ + Gets the time_finished of this CryptoAnalysisResultSummary. + The time the JFR recording has finished. + + + :return: The time_finished of this CryptoAnalysisResultSummary. + :rtype: datetime + """ + return self._time_finished + + @time_finished.setter + def time_finished(self, time_finished): + """ + Sets the time_finished of this CryptoAnalysisResultSummary. + The time the JFR recording has finished. + + + :param time_finished: The time_finished of this CryptoAnalysisResultSummary. + :type: datetime + """ + self._time_finished = time_finished + @property def crypto_roadmap_version(self): """ diff --git a/src/oci/jms/models/deployed_application_installation_usage_summary.py b/src/oci/jms/models/deployed_application_installation_usage_summary.py index 947f326aa..06b896e3b 100644 --- a/src/oci/jms/models/deployed_application_installation_usage_summary.py +++ b/src/oci/jms/models/deployed_application_installation_usage_summary.py @@ -12,7 +12,7 @@ @init_model_state_from_kwargs class DeployedApplicationInstallationUsageSummary(object): """ - Summarize usage information about an application deployed on Java servers including installation information during a specified time period. The main difference between DeployedApplicationInstallationUsageSummary and DeployedApplicationUsage is the presence of the applicationSourcePath. DeployedApplicationUsage provides only an aggregated view to the deployed applications without installation information. It therefore doesn\u2019t distinguish between applications with the identical deployment information deployed to different paths. DeployedApplicationInstallationUsageSummary contains installation information, and it\u2019s therefore possible to target actions. + Summarize usage information about an application deployed on Java servers including installation information during a specified time period. The main difference between DeployedApplicationInstallationUsageSummary and DeployedApplicationUsage is the presence of the applicationSourcePath. DeployedApplicationUsage provides only an aggregated view to the deployed applications without installation information. DeployedApplicationUsage does not distinguish between applications with the identical deployment information deployed to different paths. DeployedApplicationInstallationUsageSummary contains installation information used to select target actions. """ def __init__(self, **kwargs): @@ -52,6 +52,10 @@ def __init__(self, **kwargs): The value to assign to the approximate_java_server_instance_count property of this DeployedApplicationInstallationUsageSummary. :type approximate_java_server_instance_count: int + :param approximate_library_count: + The value to assign to the approximate_library_count property of this DeployedApplicationInstallationUsageSummary. + :type approximate_library_count: int + :param time_start: The value to assign to the time_start property of this DeployedApplicationInstallationUsageSummary. :type time_start: datetime @@ -78,6 +82,7 @@ def __init__(self, **kwargs): 'application_source_path': 'str', 'is_clustered': 'bool', 'approximate_java_server_instance_count': 'int', + 'approximate_library_count': 'int', 'time_start': 'datetime', 'time_end': 'datetime', 'time_first_seen': 'datetime', @@ -93,6 +98,7 @@ def __init__(self, **kwargs): 'application_source_path': 'applicationSourcePath', 'is_clustered': 'isClustered', 'approximate_java_server_instance_count': 'approximateJavaServerInstanceCount', + 'approximate_library_count': 'approximateLibraryCount', 'time_start': 'timeStart', 'time_end': 'timeEnd', 'time_first_seen': 'timeFirstSeen', @@ -107,6 +113,7 @@ def __init__(self, **kwargs): self._application_source_path = None self._is_clustered = None self._approximate_java_server_instance_count = None + self._approximate_library_count = None self._time_start = None self._time_end = None self._time_first_seen = None @@ -310,6 +317,30 @@ def approximate_java_server_instance_count(self, approximate_java_server_instanc """ self._approximate_java_server_instance_count = approximate_java_server_instance_count + @property + def approximate_library_count(self): + """ + Gets the approximate_library_count of this DeployedApplicationInstallationUsageSummary. + The approximate count of libraries in the deployed application. + + + :return: The approximate_library_count of this DeployedApplicationInstallationUsageSummary. + :rtype: int + """ + return self._approximate_library_count + + @approximate_library_count.setter + def approximate_library_count(self, approximate_library_count): + """ + Sets the approximate_library_count of this DeployedApplicationInstallationUsageSummary. + The approximate count of libraries in the deployed application. + + + :param approximate_library_count: The approximate_library_count of this DeployedApplicationInstallationUsageSummary. + :type: int + """ + self._approximate_library_count = approximate_library_count + @property def time_start(self): """ diff --git a/src/oci/jms/models/deployed_application_migration_analyses_target.py b/src/oci/jms/models/deployed_application_migration_analyses_target.py new file mode 100644 index 000000000..c6f62c8d2 --- /dev/null +++ b/src/oci/jms/models/deployed_application_migration_analyses_target.py @@ -0,0 +1,197 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DeployedApplicationMigrationAnalysesTarget(object): + """ + The target describes the input data for deployed Java migration analyses. + A target contains a managed instance, deployed application installation Key, sourceJdkVersion, targetJdkVersion and optional excludePackagePrefixes. + """ + + def __init__(self, **kwargs): + """ + Initializes a new DeployedApplicationMigrationAnalysesTarget object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param managed_instance_id: + The value to assign to the managed_instance_id property of this DeployedApplicationMigrationAnalysesTarget. + :type managed_instance_id: str + + :param deployed_application_installation_key: + The value to assign to the deployed_application_installation_key property of this DeployedApplicationMigrationAnalysesTarget. + :type deployed_application_installation_key: str + + :param source_jdk_version: + The value to assign to the source_jdk_version property of this DeployedApplicationMigrationAnalysesTarget. + :type source_jdk_version: str + + :param target_jdk_version: + The value to assign to the target_jdk_version property of this DeployedApplicationMigrationAnalysesTarget. + :type target_jdk_version: str + + :param exclude_package_prefixes: + The value to assign to the exclude_package_prefixes property of this DeployedApplicationMigrationAnalysesTarget. + :type exclude_package_prefixes: list[str] + + """ + self.swagger_types = { + 'managed_instance_id': 'str', + 'deployed_application_installation_key': 'str', + 'source_jdk_version': 'str', + 'target_jdk_version': 'str', + 'exclude_package_prefixes': 'list[str]' + } + + self.attribute_map = { + 'managed_instance_id': 'managedInstanceId', + 'deployed_application_installation_key': 'deployedApplicationInstallationKey', + 'source_jdk_version': 'sourceJdkVersion', + 'target_jdk_version': 'targetJdkVersion', + 'exclude_package_prefixes': 'excludePackagePrefixes' + } + + self._managed_instance_id = None + self._deployed_application_installation_key = None + self._source_jdk_version = None + self._target_jdk_version = None + self._exclude_package_prefixes = None + + @property + def managed_instance_id(self): + """ + **[Required]** Gets the managed_instance_id of this DeployedApplicationMigrationAnalysesTarget. + The OCID of the managed instance that hosts the application for which the Java migration analyses was performed. + + + :return: The managed_instance_id of this DeployedApplicationMigrationAnalysesTarget. + :rtype: str + """ + return self._managed_instance_id + + @managed_instance_id.setter + def managed_instance_id(self, managed_instance_id): + """ + Sets the managed_instance_id of this DeployedApplicationMigrationAnalysesTarget. + The OCID of the managed instance that hosts the application for which the Java migration analyses was performed. + + + :param managed_instance_id: The managed_instance_id of this DeployedApplicationMigrationAnalysesTarget. + :type: str + """ + self._managed_instance_id = managed_instance_id + + @property + def deployed_application_installation_key(self): + """ + **[Required]** Gets the deployed_application_installation_key of this DeployedApplicationMigrationAnalysesTarget. + The unique key that identifies the deployed application's installation path that is to be used for the Java migration analyses. + + + :return: The deployed_application_installation_key of this DeployedApplicationMigrationAnalysesTarget. + :rtype: str + """ + return self._deployed_application_installation_key + + @deployed_application_installation_key.setter + def deployed_application_installation_key(self, deployed_application_installation_key): + """ + Sets the deployed_application_installation_key of this DeployedApplicationMigrationAnalysesTarget. + The unique key that identifies the deployed application's installation path that is to be used for the Java migration analyses. + + + :param deployed_application_installation_key: The deployed_application_installation_key of this DeployedApplicationMigrationAnalysesTarget. + :type: str + """ + self._deployed_application_installation_key = deployed_application_installation_key + + @property + def source_jdk_version(self): + """ + **[Required]** Gets the source_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + The JDK version the application is currently running on. + + + :return: The source_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + :rtype: str + """ + return self._source_jdk_version + + @source_jdk_version.setter + def source_jdk_version(self, source_jdk_version): + """ + Sets the source_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + The JDK version the application is currently running on. + + + :param source_jdk_version: The source_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + :type: str + """ + self._source_jdk_version = source_jdk_version + + @property + def target_jdk_version(self): + """ + **[Required]** Gets the target_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + The JDK version against which the migration analyses was performed to identify effort required to move from source JDK. + + + :return: The target_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + :rtype: str + """ + return self._target_jdk_version + + @target_jdk_version.setter + def target_jdk_version(self, target_jdk_version): + """ + Sets the target_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + The JDK version against which the migration analyses was performed to identify effort required to move from source JDK. + + + :param target_jdk_version: The target_jdk_version of this DeployedApplicationMigrationAnalysesTarget. + :type: str + """ + self._target_jdk_version = target_jdk_version + + @property + def exclude_package_prefixes(self): + """ + Gets the exclude_package_prefixes of this DeployedApplicationMigrationAnalysesTarget. + Excludes the packages that starts with the prefix from the migration analyses result. + + + :return: The exclude_package_prefixes of this DeployedApplicationMigrationAnalysesTarget. + :rtype: list[str] + """ + return self._exclude_package_prefixes + + @exclude_package_prefixes.setter + def exclude_package_prefixes(self, exclude_package_prefixes): + """ + Sets the exclude_package_prefixes of this DeployedApplicationMigrationAnalysesTarget. + Excludes the packages that starts with the prefix from the migration analyses result. + + + :param exclude_package_prefixes: The exclude_package_prefixes of this DeployedApplicationMigrationAnalysesTarget. + :type: list[str] + """ + self._exclude_package_prefixes = exclude_package_prefixes + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/deployed_application_usage.py b/src/oci/jms/models/deployed_application_usage.py index ebdb43c0e..2c91f1f8f 100644 --- a/src/oci/jms/models/deployed_application_usage.py +++ b/src/oci/jms/models/deployed_application_usage.py @@ -44,6 +44,10 @@ def __init__(self, **kwargs): The value to assign to the approximate_java_server_instance_count property of this DeployedApplicationUsage. :type approximate_java_server_instance_count: int + :param approximate_library_count: + The value to assign to the approximate_library_count property of this DeployedApplicationUsage. + :type approximate_library_count: int + :param time_start: The value to assign to the time_start property of this DeployedApplicationUsage. :type time_start: datetime @@ -68,6 +72,7 @@ def __init__(self, **kwargs): 'application_type': 'str', 'is_clustered': 'bool', 'approximate_java_server_instance_count': 'int', + 'approximate_library_count': 'int', 'time_start': 'datetime', 'time_end': 'datetime', 'time_first_seen': 'datetime', @@ -81,6 +86,7 @@ def __init__(self, **kwargs): 'application_type': 'applicationType', 'is_clustered': 'isClustered', 'approximate_java_server_instance_count': 'approximateJavaServerInstanceCount', + 'approximate_library_count': 'approximateLibraryCount', 'time_start': 'timeStart', 'time_end': 'timeEnd', 'time_first_seen': 'timeFirstSeen', @@ -93,6 +99,7 @@ def __init__(self, **kwargs): self._application_type = None self._is_clustered = None self._approximate_java_server_instance_count = None + self._approximate_library_count = None self._time_start = None self._time_end = None self._time_first_seen = None @@ -246,6 +253,30 @@ def approximate_java_server_instance_count(self, approximate_java_server_instanc """ self._approximate_java_server_instance_count = approximate_java_server_instance_count + @property + def approximate_library_count(self): + """ + Gets the approximate_library_count of this DeployedApplicationUsage. + The approximate count of libraries in the deployed application. + + + :return: The approximate_library_count of this DeployedApplicationUsage. + :rtype: int + """ + return self._approximate_library_count + + @approximate_library_count.setter + def approximate_library_count(self, approximate_library_count): + """ + Sets the approximate_library_count of this DeployedApplicationUsage. + The approximate count of libraries in the deployed application. + + + :param approximate_library_count: The approximate_library_count of this DeployedApplicationUsage. + :type: int + """ + self._approximate_library_count = approximate_library_count + @property def time_start(self): """ diff --git a/src/oci/jms/models/deployed_application_work_item_details.py b/src/oci/jms/models/deployed_application_work_item_details.py new file mode 100644 index 000000000..1ec88f5c1 --- /dev/null +++ b/src/oci/jms/models/deployed_application_work_item_details.py @@ -0,0 +1,183 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + +from .work_item_details import WorkItemDetails +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class DeployedApplicationWorkItemDetails(WorkItemDetails): + """ + The work item details for deployed application related information. + """ + + def __init__(self, **kwargs): + """ + Initializes a new DeployedApplicationWorkItemDetails object with values from keyword arguments. The default value of the :py:attr:`~oci.jms.models.DeployedApplicationWorkItemDetails.kind` attribute + of this class is ``DEPLOYED_APPLICATION`` and it should not be changed. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param kind: + The value to assign to the kind property of this DeployedApplicationWorkItemDetails. + Allowed values for this property are: "BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION" + :type kind: str + + :param work_item_type: + The value to assign to the work_item_type property of this DeployedApplicationWorkItemDetails. + Allowed values for this property are: "LCM", "JFR_CAPTURE", "JFR_UPLOAD", "CRYPTO_ANALYSIS", "CRYPTO_ANALYSIS_MERGE", "ADVANCED_USAGE_TRACKING", "ADV_USAGE_SERVER_METADATA", "ADV_USAGE_SERVER_LIBRARIES", "ADV_USAGE_JAVA_LIBRARIES", "PERFORMANCE_TUNING", "JMIGRATE_ANALYSIS", "JMIGRATE_CREATE_REPORT", "DRS" + :type work_item_type: str + + :param deployed_application_key: + The value to assign to the deployed_application_key property of this DeployedApplicationWorkItemDetails. + :type deployed_application_key: str + + :param deployed_application_installation_key: + The value to assign to the deployed_application_installation_key property of this DeployedApplicationWorkItemDetails. + :type deployed_application_installation_key: str + + :param deployed_application_name: + The value to assign to the deployed_application_name property of this DeployedApplicationWorkItemDetails. + :type deployed_application_name: str + + :param deployed_application_installation_path: + The value to assign to the deployed_application_installation_path property of this DeployedApplicationWorkItemDetails. + :type deployed_application_installation_path: str + + """ + self.swagger_types = { + 'kind': 'str', + 'work_item_type': 'str', + 'deployed_application_key': 'str', + 'deployed_application_installation_key': 'str', + 'deployed_application_name': 'str', + 'deployed_application_installation_path': 'str' + } + + self.attribute_map = { + 'kind': 'kind', + 'work_item_type': 'workItemType', + 'deployed_application_key': 'deployedApplicationKey', + 'deployed_application_installation_key': 'deployedApplicationInstallationKey', + 'deployed_application_name': 'deployedApplicationName', + 'deployed_application_installation_path': 'deployedApplicationInstallationPath' + } + + self._kind = None + self._work_item_type = None + self._deployed_application_key = None + self._deployed_application_installation_key = None + self._deployed_application_name = None + self._deployed_application_installation_path = None + self._kind = 'DEPLOYED_APPLICATION' + + @property + def deployed_application_key(self): + """ + **[Required]** Gets the deployed_application_key of this DeployedApplicationWorkItemDetails. + The unique key of the deployed application. + + + :return: The deployed_application_key of this DeployedApplicationWorkItemDetails. + :rtype: str + """ + return self._deployed_application_key + + @deployed_application_key.setter + def deployed_application_key(self, deployed_application_key): + """ + Sets the deployed_application_key of this DeployedApplicationWorkItemDetails. + The unique key of the deployed application. + + + :param deployed_application_key: The deployed_application_key of this DeployedApplicationWorkItemDetails. + :type: str + """ + self._deployed_application_key = deployed_application_key + + @property + def deployed_application_installation_key(self): + """ + Gets the deployed_application_installation_key of this DeployedApplicationWorkItemDetails. + The unique key of the deployed application installation. + + + :return: The deployed_application_installation_key of this DeployedApplicationWorkItemDetails. + :rtype: str + """ + return self._deployed_application_installation_key + + @deployed_application_installation_key.setter + def deployed_application_installation_key(self, deployed_application_installation_key): + """ + Sets the deployed_application_installation_key of this DeployedApplicationWorkItemDetails. + The unique key of the deployed application installation. + + + :param deployed_application_installation_key: The deployed_application_installation_key of this DeployedApplicationWorkItemDetails. + :type: str + """ + self._deployed_application_installation_key = deployed_application_installation_key + + @property + def deployed_application_name(self): + """ + **[Required]** Gets the deployed_application_name of this DeployedApplicationWorkItemDetails. + The deployed application name. + + + :return: The deployed_application_name of this DeployedApplicationWorkItemDetails. + :rtype: str + """ + return self._deployed_application_name + + @deployed_application_name.setter + def deployed_application_name(self, deployed_application_name): + """ + Sets the deployed_application_name of this DeployedApplicationWorkItemDetails. + The deployed application name. + + + :param deployed_application_name: The deployed_application_name of this DeployedApplicationWorkItemDetails. + :type: str + """ + self._deployed_application_name = deployed_application_name + + @property + def deployed_application_installation_path(self): + """ + Gets the deployed_application_installation_path of this DeployedApplicationWorkItemDetails. + The full path on which deployed application installation was detected. + + + :return: The deployed_application_installation_path of this DeployedApplicationWorkItemDetails. + :rtype: str + """ + return self._deployed_application_installation_path + + @deployed_application_installation_path.setter + def deployed_application_installation_path(self, deployed_application_installation_path): + """ + Sets the deployed_application_installation_path of this DeployedApplicationWorkItemDetails. + The full path on which deployed application installation was detected. + + + :param deployed_application_installation_path: The deployed_application_installation_path of this DeployedApplicationWorkItemDetails. + :type: str + """ + self._deployed_application_installation_path = deployed_application_installation_path + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/export_setting.py b/src/oci/jms/models/export_setting.py index 819377aee..c9ab8638c 100644 --- a/src/oci/jms/models/export_setting.py +++ b/src/oci/jms/models/export_setting.py @@ -12,7 +12,7 @@ @init_model_state_from_kwargs class ExportSetting(object): """ - An export settings for JMS fleets. + Export settings of a fleet. """ #: A constant which can be used with the export_duration property of a ExportSetting. @@ -342,7 +342,7 @@ def target_bucket_namespace(self, target_bucket_namespace): def target_bucket_region(self): """ Gets the target_bucket_region of this ExportSetting. - The namespace of the bucket where data will be exported. + The id of the region of the target bucket. :return: The target_bucket_region of this ExportSetting. @@ -354,7 +354,7 @@ def target_bucket_region(self): def target_bucket_region(self, target_bucket_region): """ Sets the target_bucket_region of this ExportSetting. - The namespace of the bucket where data will be exported. + The id of the region of the target bucket. :param target_bucket_region: The target_bucket_region of this ExportSetting. diff --git a/src/oci/jms/models/fleet_agent_configuration.py b/src/oci/jms/models/fleet_agent_configuration.py index 74cf9d0a1..0875f4648 100644 --- a/src/oci/jms/models/fleet_agent_configuration.py +++ b/src/oci/jms/models/fleet_agent_configuration.py @@ -36,6 +36,14 @@ def __init__(self, **kwargs): The value to assign to the agent_polling_interval_in_minutes property of this FleetAgentConfiguration. :type agent_polling_interval_in_minutes: int + :param is_collecting_managed_instance_metrics_enabled: + The value to assign to the is_collecting_managed_instance_metrics_enabled property of this FleetAgentConfiguration. + :type is_collecting_managed_instance_metrics_enabled: bool + + :param is_collecting_usernames_enabled: + The value to assign to the is_collecting_usernames_enabled property of this FleetAgentConfiguration. + :type is_collecting_usernames_enabled: bool + :param linux_configuration: The value to assign to the linux_configuration property of this FleetAgentConfiguration. :type linux_configuration: oci.jms.models.FleetAgentOsConfiguration @@ -58,6 +66,8 @@ def __init__(self, **kwargs): 'java_usage_tracker_processing_frequency_in_minutes': 'int', 'work_request_validity_period_in_days': 'int', 'agent_polling_interval_in_minutes': 'int', + 'is_collecting_managed_instance_metrics_enabled': 'bool', + 'is_collecting_usernames_enabled': 'bool', 'linux_configuration': 'FleetAgentOsConfiguration', 'windows_configuration': 'FleetAgentOsConfiguration', 'mac_os_configuration': 'FleetAgentOsConfiguration', @@ -69,6 +79,8 @@ def __init__(self, **kwargs): 'java_usage_tracker_processing_frequency_in_minutes': 'javaUsageTrackerProcessingFrequencyInMinutes', 'work_request_validity_period_in_days': 'workRequestValidityPeriodInDays', 'agent_polling_interval_in_minutes': 'agentPollingIntervalInMinutes', + 'is_collecting_managed_instance_metrics_enabled': 'isCollectingManagedInstanceMetricsEnabled', + 'is_collecting_usernames_enabled': 'isCollectingUsernamesEnabled', 'linux_configuration': 'linuxConfiguration', 'windows_configuration': 'windowsConfiguration', 'mac_os_configuration': 'macOsConfiguration', @@ -79,6 +91,8 @@ def __init__(self, **kwargs): self._java_usage_tracker_processing_frequency_in_minutes = None self._work_request_validity_period_in_days = None self._agent_polling_interval_in_minutes = None + self._is_collecting_managed_instance_metrics_enabled = None + self._is_collecting_usernames_enabled = None self._linux_configuration = None self._windows_configuration = None self._mac_os_configuration = None @@ -180,6 +194,54 @@ def agent_polling_interval_in_minutes(self, agent_polling_interval_in_minutes): """ self._agent_polling_interval_in_minutes = agent_polling_interval_in_minutes + @property + def is_collecting_managed_instance_metrics_enabled(self): + """ + Gets the is_collecting_managed_instance_metrics_enabled of this FleetAgentConfiguration. + Collect JMS agent metrics on all managed instances in the fleet. + + + :return: The is_collecting_managed_instance_metrics_enabled of this FleetAgentConfiguration. + :rtype: bool + """ + return self._is_collecting_managed_instance_metrics_enabled + + @is_collecting_managed_instance_metrics_enabled.setter + def is_collecting_managed_instance_metrics_enabled(self, is_collecting_managed_instance_metrics_enabled): + """ + Sets the is_collecting_managed_instance_metrics_enabled of this FleetAgentConfiguration. + Collect JMS agent metrics on all managed instances in the fleet. + + + :param is_collecting_managed_instance_metrics_enabled: The is_collecting_managed_instance_metrics_enabled of this FleetAgentConfiguration. + :type: bool + """ + self._is_collecting_managed_instance_metrics_enabled = is_collecting_managed_instance_metrics_enabled + + @property + def is_collecting_usernames_enabled(self): + """ + Gets the is_collecting_usernames_enabled of this FleetAgentConfiguration. + Collect username for application invocations for all managed instances in the fleet. + + + :return: The is_collecting_usernames_enabled of this FleetAgentConfiguration. + :rtype: bool + """ + return self._is_collecting_usernames_enabled + + @is_collecting_usernames_enabled.setter + def is_collecting_usernames_enabled(self, is_collecting_usernames_enabled): + """ + Sets the is_collecting_usernames_enabled of this FleetAgentConfiguration. + Collect username for application invocations for all managed instances in the fleet. + + + :param is_collecting_usernames_enabled: The is_collecting_usernames_enabled of this FleetAgentConfiguration. + :type: bool + """ + self._is_collecting_usernames_enabled = is_collecting_usernames_enabled + @property def linux_configuration(self): """ diff --git a/src/oci/jms/models/generate_agent_installer_configuration_details.py b/src/oci/jms/models/generate_agent_installer_configuration_details.py new file mode 100644 index 000000000..eba0135b5 --- /dev/null +++ b/src/oci/jms/models/generate_agent_installer_configuration_details.py @@ -0,0 +1,111 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class GenerateAgentInstallerConfigurationDetails(object): + """ + Attributes to generate agent installer parameters for a fleet. + """ + + def __init__(self, **kwargs): + """ + Initializes a new GenerateAgentInstallerConfigurationDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param install_key_id: + The value to assign to the install_key_id property of this GenerateAgentInstallerConfigurationDetails. + :type install_key_id: str + + :param fleet_id: + The value to assign to the fleet_id property of this GenerateAgentInstallerConfigurationDetails. + :type fleet_id: str + + """ + self.swagger_types = { + 'install_key_id': 'str', + 'fleet_id': 'str' + } + + self.attribute_map = { + 'install_key_id': 'installKeyId', + 'fleet_id': 'fleetId' + } + + self._install_key_id = None + self._fleet_id = None + + @property + def install_key_id(self): + """ + **[Required]** Gets the install_key_id of this GenerateAgentInstallerConfigurationDetails. + The `OCID`__ of the install key for which to generate the configuration file. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The install_key_id of this GenerateAgentInstallerConfigurationDetails. + :rtype: str + """ + return self._install_key_id + + @install_key_id.setter + def install_key_id(self, install_key_id): + """ + Sets the install_key_id of this GenerateAgentInstallerConfigurationDetails. + The `OCID`__ of the install key for which to generate the configuration file. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param install_key_id: The install_key_id of this GenerateAgentInstallerConfigurationDetails. + :type: str + """ + self._install_key_id = install_key_id + + @property + def fleet_id(self): + """ + **[Required]** Gets the fleet_id of this GenerateAgentInstallerConfigurationDetails. + The `OCID`__ of the fleet for which to generate the configuration file. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The fleet_id of this GenerateAgentInstallerConfigurationDetails. + :rtype: str + """ + return self._fleet_id + + @fleet_id.setter + def fleet_id(self, fleet_id): + """ + Sets the fleet_id of this GenerateAgentInstallerConfigurationDetails. + The `OCID`__ of the fleet for which to generate the configuration file. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param fleet_id: The fleet_id of this GenerateAgentInstallerConfigurationDetails. + :type: str + """ + self._fleet_id = fleet_id + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/generate_load_pipeline_script_details.py b/src/oci/jms/models/generate_load_pipeline_script_details.py new file mode 100644 index 000000000..b1a44a285 --- /dev/null +++ b/src/oci/jms/models/generate_load_pipeline_script_details.py @@ -0,0 +1,165 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class GenerateLoadPipelineScriptDetails(object): + """ + Attributes to generate load pipeline script. + """ + + def __init__(self, **kwargs): + """ + Initializes a new GenerateLoadPipelineScriptDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param target_bucket_name: + The value to assign to the target_bucket_name property of this GenerateLoadPipelineScriptDetails. + :type target_bucket_name: str + + :param target_bucket_namespace: + The value to assign to the target_bucket_namespace property of this GenerateLoadPipelineScriptDetails. + :type target_bucket_namespace: str + + :param target_bucket_region: + The value to assign to the target_bucket_region property of this GenerateLoadPipelineScriptDetails. + :type target_bucket_region: str + + :param interval_minutes: + The value to assign to the interval_minutes property of this GenerateLoadPipelineScriptDetails. + :type interval_minutes: int + + """ + self.swagger_types = { + 'target_bucket_name': 'str', + 'target_bucket_namespace': 'str', + 'target_bucket_region': 'str', + 'interval_minutes': 'int' + } + + self.attribute_map = { + 'target_bucket_name': 'targetBucketName', + 'target_bucket_namespace': 'targetBucketNamespace', + 'target_bucket_region': 'targetBucketRegion', + 'interval_minutes': 'intervalMinutes' + } + + self._target_bucket_name = None + self._target_bucket_namespace = None + self._target_bucket_region = None + self._interval_minutes = None + + @property + def target_bucket_name(self): + """ + **[Required]** Gets the target_bucket_name of this GenerateLoadPipelineScriptDetails. + The name of the bucket where data will be exported. + + + :return: The target_bucket_name of this GenerateLoadPipelineScriptDetails. + :rtype: str + """ + return self._target_bucket_name + + @target_bucket_name.setter + def target_bucket_name(self, target_bucket_name): + """ + Sets the target_bucket_name of this GenerateLoadPipelineScriptDetails. + The name of the bucket where data will be exported. + + + :param target_bucket_name: The target_bucket_name of this GenerateLoadPipelineScriptDetails. + :type: str + """ + self._target_bucket_name = target_bucket_name + + @property + def target_bucket_namespace(self): + """ + **[Required]** Gets the target_bucket_namespace of this GenerateLoadPipelineScriptDetails. + The namespace of the bucket where data will be exported. + + + :return: The target_bucket_namespace of this GenerateLoadPipelineScriptDetails. + :rtype: str + """ + return self._target_bucket_namespace + + @target_bucket_namespace.setter + def target_bucket_namespace(self, target_bucket_namespace): + """ + Sets the target_bucket_namespace of this GenerateLoadPipelineScriptDetails. + The namespace of the bucket where data will be exported. + + + :param target_bucket_namespace: The target_bucket_namespace of this GenerateLoadPipelineScriptDetails. + :type: str + """ + self._target_bucket_namespace = target_bucket_namespace + + @property + def target_bucket_region(self): + """ + **[Required]** Gets the target_bucket_region of this GenerateLoadPipelineScriptDetails. + The id of the region of the target bucket. + + + :return: The target_bucket_region of this GenerateLoadPipelineScriptDetails. + :rtype: str + """ + return self._target_bucket_region + + @target_bucket_region.setter + def target_bucket_region(self, target_bucket_region): + """ + Sets the target_bucket_region of this GenerateLoadPipelineScriptDetails. + The id of the region of the target bucket. + + + :param target_bucket_region: The target_bucket_region of this GenerateLoadPipelineScriptDetails. + :type: str + """ + self._target_bucket_region = target_bucket_region + + @property + def interval_minutes(self): + """ + Gets the interval_minutes of this GenerateLoadPipelineScriptDetails. + The time internal in minutes between consecutive executions of scheduled pipeline job. + + + :return: The interval_minutes of this GenerateLoadPipelineScriptDetails. + :rtype: int + """ + return self._interval_minutes + + @interval_minutes.setter + def interval_minutes(self, interval_minutes): + """ + Sets the interval_minutes of this GenerateLoadPipelineScriptDetails. + The time internal in minutes between consecutive executions of scheduled pipeline job. + + + :param interval_minutes: The interval_minutes of this GenerateLoadPipelineScriptDetails. + :type: int + """ + self._interval_minutes = interval_minutes + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/installation_site.py b/src/oci/jms/models/installation_site.py index 487a8d54c..8783f9d90 100644 --- a/src/oci/jms/models/installation_site.py +++ b/src/oci/jms/models/installation_site.py @@ -48,6 +48,10 @@ class InstallationSite(object): #: This constant has a value of "ORACLE_MANAGEMENT_AGENT" MANAGED_INSTANCE_TYPE_ORACLE_MANAGEMENT_AGENT = "ORACLE_MANAGEMENT_AGENT" + #: A constant which can be used with the managed_instance_type property of a InstallationSite. + #: This constant has a value of "ORACLE_CLOUD_AGENT" + MANAGED_INSTANCE_TYPE_ORACLE_CLOUD_AGENT = "ORACLE_CLOUD_AGENT" + def __init__(self, **kwargs): """ Initializes a new InstallationSite object with values from keyword arguments. @@ -93,7 +97,7 @@ def __init__(self, **kwargs): :param managed_instance_type: The value to assign to the managed_instance_type property of this InstallationSite. - Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type managed_instance_type: str @@ -372,7 +376,7 @@ def managed_instance_type(self): Gets the managed_instance_type of this InstallationSite. The type of the source of events. - Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -391,7 +395,7 @@ def managed_instance_type(self, managed_instance_type): :param managed_instance_type: The managed_instance_type of this InstallationSite. :type: str """ - allowed_values = ["ORACLE_MANAGEMENT_AGENT"] + allowed_values = ["ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT"] if not value_allowed_none_or_none_sentinel(managed_instance_type, allowed_values): managed_instance_type = 'UNKNOWN_ENUM_VALUE' self._managed_instance_type = managed_instance_type diff --git a/src/oci/jms/models/java_artifact.py b/src/oci/jms/models/java_artifact.py index 8241663a0..9a48766b2 100644 --- a/src/oci/jms/models/java_artifact.py +++ b/src/oci/jms/models/java_artifact.py @@ -387,7 +387,7 @@ def download_url(self): This download url can then be used for downloading the artifact. See this `API`__ for more details. - __ https://docs.oracle.com/en-us/iaas/api/#/en/jms/20230601/JavaArtifact/GenerateArtifactDownloadUrl + __ https://docs.oracle.com/en-us/iaas/api/#/en/jms-java-download/20230601/DownloadUrl/GenerateArtifactDownloadUrl :return: The download_url of this JavaArtifact. @@ -403,7 +403,7 @@ def download_url(self, download_url): This download url can then be used for downloading the artifact. See this `API`__ for more details. - __ https://docs.oracle.com/en-us/iaas/api/#/en/jms/20230601/JavaArtifact/GenerateArtifactDownloadUrl + __ https://docs.oracle.com/en-us/iaas/api/#/en/jms-java-download/20230601/DownloadUrl/GenerateArtifactDownloadUrl :param download_url: The download_url of this JavaArtifact. diff --git a/src/oci/jms/models/java_family.py b/src/oci/jms/models/java_family.py index ddabdb1c1..c41e904d2 100644 --- a/src/oci/jms/models/java_family.py +++ b/src/oci/jms/models/java_family.py @@ -63,6 +63,10 @@ def __init__(self, **kwargs): The value to assign to the is_supported_version property of this JavaFamily. :type is_supported_version: bool + :param release_date: + The value to assign to the release_date property of this JavaFamily. + :type release_date: datetime + """ self.swagger_types = { 'latest_release_artifacts': 'list[JavaArtifact]', @@ -72,7 +76,8 @@ def __init__(self, **kwargs): 'end_of_support_life_date': 'datetime', 'doc_url': 'str', 'latest_release_version': 'str', - 'is_supported_version': 'bool' + 'is_supported_version': 'bool', + 'release_date': 'datetime' } self.attribute_map = { @@ -83,7 +88,8 @@ def __init__(self, **kwargs): 'end_of_support_life_date': 'endOfSupportLifeDate', 'doc_url': 'docUrl', 'latest_release_version': 'latestReleaseVersion', - 'is_supported_version': 'isSupportedVersion' + 'is_supported_version': 'isSupportedVersion', + 'release_date': 'releaseDate' } self._latest_release_artifacts = None @@ -94,6 +100,7 @@ def __init__(self, **kwargs): self._doc_url = None self._latest_release_version = None self._is_supported_version = None + self._release_date = None @property def latest_release_artifacts(self): @@ -305,6 +312,34 @@ def is_supported_version(self, is_supported_version): """ self._is_supported_version = is_supported_version + @property + def release_date(self): + """ + Gets the release_date of this JavaFamily. + The date on which the Java release family was first made available (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The release_date of this JavaFamily. + :rtype: datetime + """ + return self._release_date + + @release_date.setter + def release_date(self, release_date): + """ + Sets the release_date of this JavaFamily. + The date on which the Java release family was first made available (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param release_date: The release_date of this JavaFamily. + :type: datetime + """ + self._release_date = release_date + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/jms/models/java_family_summary.py b/src/oci/jms/models/java_family_summary.py index eff65f8c3..80e3700d4 100644 --- a/src/oci/jms/models/java_family_summary.py +++ b/src/oci/jms/models/java_family_summary.py @@ -59,6 +59,10 @@ def __init__(self, **kwargs): The value to assign to the is_supported_version property of this JavaFamilySummary. :type is_supported_version: bool + :param release_date: + The value to assign to the release_date property of this JavaFamilySummary. + :type release_date: datetime + """ self.swagger_types = { 'family_version': 'str', @@ -67,7 +71,8 @@ def __init__(self, **kwargs): 'end_of_support_life_date': 'datetime', 'doc_url': 'str', 'latest_release_version': 'str', - 'is_supported_version': 'bool' + 'is_supported_version': 'bool', + 'release_date': 'datetime' } self.attribute_map = { @@ -77,7 +82,8 @@ def __init__(self, **kwargs): 'end_of_support_life_date': 'endOfSupportLifeDate', 'doc_url': 'docUrl', 'latest_release_version': 'latestReleaseVersion', - 'is_supported_version': 'isSupportedVersion' + 'is_supported_version': 'isSupportedVersion', + 'release_date': 'releaseDate' } self._family_version = None @@ -87,6 +93,7 @@ def __init__(self, **kwargs): self._doc_url = None self._latest_release_version = None self._is_supported_version = None + self._release_date = None @property def family_version(self): @@ -272,6 +279,34 @@ def is_supported_version(self, is_supported_version): """ self._is_supported_version = is_supported_version + @property + def release_date(self): + """ + Gets the release_date of this JavaFamilySummary. + The date on which the Java release family was first made available (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :return: The release_date of this JavaFamilySummary. + :rtype: datetime + """ + return self._release_date + + @release_date.setter + def release_date(self, release_date): + """ + Sets the release_date of this JavaFamilySummary. + The date on which the Java release family was first made available (formatted according to `RFC3339`__). + + __ https://datatracker.ietf.org/doc/html/rfc3339 + + + :param release_date: The release_date of this JavaFamilySummary. + :type: datetime + """ + self._release_date = release_date + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/jms/models/java_migration_analysis_target.py b/src/oci/jms/models/java_migration_analysis_target.py index 69d8ab693..6c7ef9ab0 100644 --- a/src/oci/jms/models/java_migration_analysis_target.py +++ b/src/oci/jms/models/java_migration_analysis_target.py @@ -13,7 +13,7 @@ class JavaMigrationAnalysisTarget(object): """ The target describes the input data for Java migration analysis. - A target contains a managed instance, application Installation Key, sourceJdkVersion, and targetJdkVersion. + A target contains a managed instance, application Installation Key, sourceJdkVersion, targetJdkVersion and optional excludePackagePrefixes. """ def __init__(self, **kwargs): @@ -37,25 +37,32 @@ def __init__(self, **kwargs): The value to assign to the target_jdk_version property of this JavaMigrationAnalysisTarget. :type target_jdk_version: str + :param exclude_package_prefixes: + The value to assign to the exclude_package_prefixes property of this JavaMigrationAnalysisTarget. + :type exclude_package_prefixes: list[str] + """ self.swagger_types = { 'managed_instance_id': 'str', 'application_installation_key': 'str', 'source_jdk_version': 'str', - 'target_jdk_version': 'str' + 'target_jdk_version': 'str', + 'exclude_package_prefixes': 'list[str]' } self.attribute_map = { 'managed_instance_id': 'managedInstanceId', 'application_installation_key': 'applicationInstallationKey', 'source_jdk_version': 'sourceJdkVersion', - 'target_jdk_version': 'targetJdkVersion' + 'target_jdk_version': 'targetJdkVersion', + 'exclude_package_prefixes': 'excludePackagePrefixes' } self._managed_instance_id = None self._application_installation_key = None self._source_jdk_version = None self._target_jdk_version = None + self._exclude_package_prefixes = None @property def managed_instance_id(self): @@ -153,6 +160,30 @@ def target_jdk_version(self, target_jdk_version): """ self._target_jdk_version = target_jdk_version + @property + def exclude_package_prefixes(self): + """ + Gets the exclude_package_prefixes of this JavaMigrationAnalysisTarget. + Excludes the packages that starts with the prefix from the migration analysis result. + + + :return: The exclude_package_prefixes of this JavaMigrationAnalysisTarget. + :rtype: list[str] + """ + return self._exclude_package_prefixes + + @exclude_package_prefixes.setter + def exclude_package_prefixes(self, exclude_package_prefixes): + """ + Sets the exclude_package_prefixes of this JavaMigrationAnalysisTarget. + Excludes the packages that starts with the prefix from the migration analysis result. + + + :param exclude_package_prefixes: The exclude_package_prefixes of this JavaMigrationAnalysisTarget. + :type: list[str] + """ + self._exclude_package_prefixes = exclude_package_prefixes + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/jms/models/java_server_instance_usage.py b/src/oci/jms/models/java_server_instance_usage.py index f30e88914..6a466f5e4 100644 --- a/src/oci/jms/models/java_server_instance_usage.py +++ b/src/oci/jms/models/java_server_instance_usage.py @@ -52,6 +52,10 @@ def __init__(self, **kwargs): The value to assign to the server_instance_name property of this JavaServerInstanceUsage. :type server_instance_name: str + :param server_instance_port: + The value to assign to the server_instance_port property of this JavaServerInstanceUsage. + :type server_instance_port: int + :param server_key: The value to assign to the server_key property of this JavaServerInstanceUsage. :type server_key: str @@ -119,6 +123,7 @@ def __init__(self, **kwargs): 'server_instance_key': 'str', 'fleet_id': 'str', 'server_instance_name': 'str', + 'server_instance_port': 'int', 'server_key': 'str', 'server_name': 'str', 'server_version': 'str', @@ -140,6 +145,7 @@ def __init__(self, **kwargs): 'server_instance_key': 'serverInstanceKey', 'fleet_id': 'fleetId', 'server_instance_name': 'serverInstanceName', + 'server_instance_port': 'serverInstancePort', 'server_key': 'serverKey', 'server_name': 'serverName', 'server_version': 'serverVersion', @@ -160,6 +166,7 @@ def __init__(self, **kwargs): self._server_instance_key = None self._fleet_id = None self._server_instance_name = None + self._server_instance_port = None self._server_key = None self._server_name = None self._server_version = None @@ -252,6 +259,30 @@ def server_instance_name(self, server_instance_name): """ self._server_instance_name = server_instance_name + @property + def server_instance_port(self): + """ + Gets the server_instance_port of this JavaServerInstanceUsage. + The port of the Java Server instance. + + + :return: The server_instance_port of this JavaServerInstanceUsage. + :rtype: int + """ + return self._server_instance_port + + @server_instance_port.setter + def server_instance_port(self, server_instance_port): + """ + Sets the server_instance_port of this JavaServerInstanceUsage. + The port of the Java Server instance. + + + :param server_instance_port: The server_instance_port of this JavaServerInstanceUsage. + :type: int + """ + self._server_instance_port = server_instance_port + @property def server_key(self): """ diff --git a/src/oci/jms/models/jms_plugin.py b/src/oci/jms/models/jms_plugin.py new file mode 100644 index 000000000..35e070fdb --- /dev/null +++ b/src/oci/jms/models/jms_plugin.py @@ -0,0 +1,698 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class JmsPlugin(object): + """ + Information about a JmsPlugin that has been registered. + """ + + #: A constant which can be used with the agent_type property of a JmsPlugin. + #: This constant has a value of "OMA" + AGENT_TYPE_OMA = "OMA" + + #: A constant which can be used with the agent_type property of a JmsPlugin. + #: This constant has a value of "OCA" + AGENT_TYPE_OCA = "OCA" + + #: A constant which can be used with the lifecycle_state property of a JmsPlugin. + #: This constant has a value of "ACTIVE" + LIFECYCLE_STATE_ACTIVE = "ACTIVE" + + #: A constant which can be used with the lifecycle_state property of a JmsPlugin. + #: This constant has a value of "INACTIVE" + LIFECYCLE_STATE_INACTIVE = "INACTIVE" + + #: A constant which can be used with the lifecycle_state property of a JmsPlugin. + #: This constant has a value of "NEEDS_ATTENTION" + LIFECYCLE_STATE_NEEDS_ATTENTION = "NEEDS_ATTENTION" + + #: A constant which can be used with the lifecycle_state property of a JmsPlugin. + #: This constant has a value of "DELETED" + LIFECYCLE_STATE_DELETED = "DELETED" + + #: A constant which can be used with the availability_status property of a JmsPlugin. + #: This constant has a value of "ACTIVE" + AVAILABILITY_STATUS_ACTIVE = "ACTIVE" + + #: A constant which can be used with the availability_status property of a JmsPlugin. + #: This constant has a value of "SILENT" + AVAILABILITY_STATUS_SILENT = "SILENT" + + #: A constant which can be used with the availability_status property of a JmsPlugin. + #: This constant has a value of "NOT_AVAILABLE" + AVAILABILITY_STATUS_NOT_AVAILABLE = "NOT_AVAILABLE" + + #: A constant which can be used with the os_family property of a JmsPlugin. + #: This constant has a value of "LINUX" + OS_FAMILY_LINUX = "LINUX" + + #: A constant which can be used with the os_family property of a JmsPlugin. + #: This constant has a value of "WINDOWS" + OS_FAMILY_WINDOWS = "WINDOWS" + + #: A constant which can be used with the os_family property of a JmsPlugin. + #: This constant has a value of "MACOS" + OS_FAMILY_MACOS = "MACOS" + + #: A constant which can be used with the os_family property of a JmsPlugin. + #: This constant has a value of "UNKNOWN" + OS_FAMILY_UNKNOWN = "UNKNOWN" + + def __init__(self, **kwargs): + """ + Initializes a new JmsPlugin object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this JmsPlugin. + :type id: str + + :param agent_id: + The value to assign to the agent_id property of this JmsPlugin. + :type agent_id: str + + :param agent_type: + The value to assign to the agent_type property of this JmsPlugin. + Allowed values for this property are: "OMA", "OCA", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type agent_type: str + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this JmsPlugin. + Allowed values for this property are: "ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type lifecycle_state: str + + :param availability_status: + The value to assign to the availability_status property of this JmsPlugin. + Allowed values for this property are: "ACTIVE", "SILENT", "NOT_AVAILABLE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type availability_status: str + + :param fleet_id: + The value to assign to the fleet_id property of this JmsPlugin. + :type fleet_id: str + + :param compartment_id: + The value to assign to the compartment_id property of this JmsPlugin. + :type compartment_id: str + + :param hostname: + The value to assign to the hostname property of this JmsPlugin. + :type hostname: str + + :param os_family: + The value to assign to the os_family property of this JmsPlugin. + Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type os_family: str + + :param os_architecture: + The value to assign to the os_architecture property of this JmsPlugin. + :type os_architecture: str + + :param os_distribution: + The value to assign to the os_distribution property of this JmsPlugin. + :type os_distribution: str + + :param plugin_version: + The value to assign to the plugin_version property of this JmsPlugin. + :type plugin_version: str + + :param time_registered: + The value to assign to the time_registered property of this JmsPlugin. + :type time_registered: datetime + + :param time_last_seen: + The value to assign to the time_last_seen property of this JmsPlugin. + :type time_last_seen: datetime + + :param defined_tags: + The value to assign to the defined_tags property of this JmsPlugin. + :type defined_tags: dict(str, dict(str, object)) + + :param freeform_tags: + The value to assign to the freeform_tags property of this JmsPlugin. + :type freeform_tags: dict(str, str) + + :param system_tags: + The value to assign to the system_tags property of this JmsPlugin. + :type system_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'id': 'str', + 'agent_id': 'str', + 'agent_type': 'str', + 'lifecycle_state': 'str', + 'availability_status': 'str', + 'fleet_id': 'str', + 'compartment_id': 'str', + 'hostname': 'str', + 'os_family': 'str', + 'os_architecture': 'str', + 'os_distribution': 'str', + 'plugin_version': 'str', + 'time_registered': 'datetime', + 'time_last_seen': 'datetime', + 'defined_tags': 'dict(str, dict(str, object))', + 'freeform_tags': 'dict(str, str)', + 'system_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'id': 'id', + 'agent_id': 'agentId', + 'agent_type': 'agentType', + 'lifecycle_state': 'lifecycleState', + 'availability_status': 'availabilityStatus', + 'fleet_id': 'fleetId', + 'compartment_id': 'compartmentId', + 'hostname': 'hostname', + 'os_family': 'osFamily', + 'os_architecture': 'osArchitecture', + 'os_distribution': 'osDistribution', + 'plugin_version': 'pluginVersion', + 'time_registered': 'timeRegistered', + 'time_last_seen': 'timeLastSeen', + 'defined_tags': 'definedTags', + 'freeform_tags': 'freeformTags', + 'system_tags': 'systemTags' + } + + self._id = None + self._agent_id = None + self._agent_type = None + self._lifecycle_state = None + self._availability_status = None + self._fleet_id = None + self._compartment_id = None + self._hostname = None + self._os_family = None + self._os_architecture = None + self._os_distribution = None + self._plugin_version = None + self._time_registered = None + self._time_last_seen = None + self._defined_tags = None + self._freeform_tags = None + self._system_tags = None + + @property + def id(self): + """ + **[Required]** Gets the id of this JmsPlugin. + The `OCID`__ to identify this JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The id of this JmsPlugin. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this JmsPlugin. + The `OCID`__ to identify this JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param id: The id of this JmsPlugin. + :type: str + """ + self._id = id + + @property + def agent_id(self): + """ + **[Required]** Gets the agent_id of this JmsPlugin. + The `OCID`__ of the Management Agent (OMA) or the Oracle Cloud Agent (OCA) instance where the JMS plugin is deployed. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The agent_id of this JmsPlugin. + :rtype: str + """ + return self._agent_id + + @agent_id.setter + def agent_id(self, agent_id): + """ + Sets the agent_id of this JmsPlugin. + The `OCID`__ of the Management Agent (OMA) or the Oracle Cloud Agent (OCA) instance where the JMS plugin is deployed. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param agent_id: The agent_id of this JmsPlugin. + :type: str + """ + self._agent_id = agent_id + + @property + def agent_type(self): + """ + **[Required]** Gets the agent_type of this JmsPlugin. + The agent type. + + Allowed values for this property are: "OMA", "OCA", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The agent_type of this JmsPlugin. + :rtype: str + """ + return self._agent_type + + @agent_type.setter + def agent_type(self, agent_type): + """ + Sets the agent_type of this JmsPlugin. + The agent type. + + + :param agent_type: The agent_type of this JmsPlugin. + :type: str + """ + allowed_values = ["OMA", "OCA"] + if not value_allowed_none_or_none_sentinel(agent_type, allowed_values): + agent_type = 'UNKNOWN_ENUM_VALUE' + self._agent_type = agent_type + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this JmsPlugin. + The lifecycle state. + + Allowed values for this property are: "ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The lifecycle_state of this JmsPlugin. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this JmsPlugin. + The lifecycle state. + + + :param lifecycle_state: The lifecycle_state of this JmsPlugin. + :type: str + """ + allowed_values = ["ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED"] + if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): + lifecycle_state = 'UNKNOWN_ENUM_VALUE' + self._lifecycle_state = lifecycle_state + + @property + def availability_status(self): + """ + **[Required]** Gets the availability_status of this JmsPlugin. + The availability status. + + Allowed values for this property are: "ACTIVE", "SILENT", "NOT_AVAILABLE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The availability_status of this JmsPlugin. + :rtype: str + """ + return self._availability_status + + @availability_status.setter + def availability_status(self, availability_status): + """ + Sets the availability_status of this JmsPlugin. + The availability status. + + + :param availability_status: The availability_status of this JmsPlugin. + :type: str + """ + allowed_values = ["ACTIVE", "SILENT", "NOT_AVAILABLE"] + if not value_allowed_none_or_none_sentinel(availability_status, allowed_values): + availability_status = 'UNKNOWN_ENUM_VALUE' + self._availability_status = availability_status + + @property + def fleet_id(self): + """ + Gets the fleet_id of this JmsPlugin. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The fleet_id of this JmsPlugin. + :rtype: str + """ + return self._fleet_id + + @fleet_id.setter + def fleet_id(self, fleet_id): + """ + Sets the fleet_id of this JmsPlugin. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param fleet_id: The fleet_id of this JmsPlugin. + :type: str + """ + self._fleet_id = fleet_id + + @property + def compartment_id(self): + """ + Gets the compartment_id of this JmsPlugin. + The OMA/OCA agent's compartment `OCID`__. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The compartment_id of this JmsPlugin. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this JmsPlugin. + The OMA/OCA agent's compartment `OCID`__. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param compartment_id: The compartment_id of this JmsPlugin. + :type: str + """ + self._compartment_id = compartment_id + + @property + def hostname(self): + """ + Gets the hostname of this JmsPlugin. + The hostname of the agent. + + + :return: The hostname of this JmsPlugin. + :rtype: str + """ + return self._hostname + + @hostname.setter + def hostname(self, hostname): + """ + Sets the hostname of this JmsPlugin. + The hostname of the agent. + + + :param hostname: The hostname of this JmsPlugin. + :type: str + """ + self._hostname = hostname + + @property + def os_family(self): + """ + Gets the os_family of this JmsPlugin. + The operating system family for the plugin. + + Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The os_family of this JmsPlugin. + :rtype: str + """ + return self._os_family + + @os_family.setter + def os_family(self, os_family): + """ + Sets the os_family of this JmsPlugin. + The operating system family for the plugin. + + + :param os_family: The os_family of this JmsPlugin. + :type: str + """ + allowed_values = ["LINUX", "WINDOWS", "MACOS", "UNKNOWN"] + if not value_allowed_none_or_none_sentinel(os_family, allowed_values): + os_family = 'UNKNOWN_ENUM_VALUE' + self._os_family = os_family + + @property + def os_architecture(self): + """ + Gets the os_architecture of this JmsPlugin. + The architecture of the operating system of the plugin. + + + :return: The os_architecture of this JmsPlugin. + :rtype: str + """ + return self._os_architecture + + @os_architecture.setter + def os_architecture(self, os_architecture): + """ + Sets the os_architecture of this JmsPlugin. + The architecture of the operating system of the plugin. + + + :param os_architecture: The os_architecture of this JmsPlugin. + :type: str + """ + self._os_architecture = os_architecture + + @property + def os_distribution(self): + """ + Gets the os_distribution of this JmsPlugin. + The distribution of the operating system of the plugin. + + + :return: The os_distribution of this JmsPlugin. + :rtype: str + """ + return self._os_distribution + + @os_distribution.setter + def os_distribution(self, os_distribution): + """ + Sets the os_distribution of this JmsPlugin. + The distribution of the operating system of the plugin. + + + :param os_distribution: The os_distribution of this JmsPlugin. + :type: str + """ + self._os_distribution = os_distribution + + @property + def plugin_version(self): + """ + Gets the plugin_version of this JmsPlugin. + The version of the plugin. + + + :return: The plugin_version of this JmsPlugin. + :rtype: str + """ + return self._plugin_version + + @plugin_version.setter + def plugin_version(self, plugin_version): + """ + Sets the plugin_version of this JmsPlugin. + The version of the plugin. + + + :param plugin_version: The plugin_version of this JmsPlugin. + :type: str + """ + self._plugin_version = plugin_version + + @property + def time_registered(self): + """ + **[Required]** Gets the time_registered of this JmsPlugin. + The date and time the plugin was registered. + + + :return: The time_registered of this JmsPlugin. + :rtype: datetime + """ + return self._time_registered + + @time_registered.setter + def time_registered(self, time_registered): + """ + Sets the time_registered of this JmsPlugin. + The date and time the plugin was registered. + + + :param time_registered: The time_registered of this JmsPlugin. + :type: datetime + """ + self._time_registered = time_registered + + @property + def time_last_seen(self): + """ + Gets the time_last_seen of this JmsPlugin. + The date and time the resource was _last_ reported to JMS. + This is potentially _after_ the specified time period provided by the filters. + For example, a resource can be last reported to JMS before the start of a specified time period, + if it is also reported during the time period. + + + :return: The time_last_seen of this JmsPlugin. + :rtype: datetime + """ + return self._time_last_seen + + @time_last_seen.setter + def time_last_seen(self, time_last_seen): + """ + Sets the time_last_seen of this JmsPlugin. + The date and time the resource was _last_ reported to JMS. + This is potentially _after_ the specified time period provided by the filters. + For example, a resource can be last reported to JMS before the start of a specified time period, + if it is also reported during the time period. + + + :param time_last_seen: The time_last_seen of this JmsPlugin. + :type: datetime + """ + self._time_last_seen = time_last_seen + + @property + def defined_tags(self): + """ + Gets the defined_tags of this JmsPlugin. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :return: The defined_tags of this JmsPlugin. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this JmsPlugin. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :param defined_tags: The defined_tags of this JmsPlugin. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this JmsPlugin. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :return: The freeform_tags of this JmsPlugin. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this JmsPlugin. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :param freeform_tags: The freeform_tags of this JmsPlugin. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def system_tags(self): + """ + Gets the system_tags of this JmsPlugin. + System tags for this resource. Each key is predefined and scoped to a namespace. + For more information, see `Resource Tags`__. + System tags can be viewed by users, but can only be created by the system. + + Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The system_tags of this JmsPlugin. + :rtype: dict(str, dict(str, object)) + """ + return self._system_tags + + @system_tags.setter + def system_tags(self, system_tags): + """ + Sets the system_tags of this JmsPlugin. + System tags for this resource. Each key is predefined and scoped to a namespace. + For more information, see `Resource Tags`__. + System tags can be viewed by users, but can only be created by the system. + + Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param system_tags: The system_tags of this JmsPlugin. + :type: dict(str, dict(str, object)) + """ + self._system_tags = system_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/jms_plugin_collection.py b/src/oci/jms/models/jms_plugin_collection.py new file mode 100644 index 000000000..32c4a9099 --- /dev/null +++ b/src/oci/jms/models/jms_plugin_collection.py @@ -0,0 +1,72 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class JmsPluginCollection(object): + """ + Results of a JmsPlugin search. Contains JmsPluginSummary items. + """ + + def __init__(self, **kwargs): + """ + Initializes a new JmsPluginCollection object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param items: + The value to assign to the items property of this JmsPluginCollection. + :type items: list[oci.jms.models.JmsPluginSummary] + + """ + self.swagger_types = { + 'items': 'list[JmsPluginSummary]' + } + + self.attribute_map = { + 'items': 'items' + } + + self._items = None + + @property + def items(self): + """ + **[Required]** Gets the items of this JmsPluginCollection. + A list of JmsPlugins. + + + :return: The items of this JmsPluginCollection. + :rtype: list[oci.jms.models.JmsPluginSummary] + """ + return self._items + + @items.setter + def items(self, items): + """ + Sets the items of this JmsPluginCollection. + A list of JmsPlugins. + + + :param items: The items of this JmsPluginCollection. + :type: list[oci.jms.models.JmsPluginSummary] + """ + self._items = items + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/jms_plugin_summary.py b/src/oci/jms/models/jms_plugin_summary.py new file mode 100644 index 000000000..79adccf98 --- /dev/null +++ b/src/oci/jms/models/jms_plugin_summary.py @@ -0,0 +1,698 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class JmsPluginSummary(object): + """ + Summary of the JmsPlugin. + """ + + #: A constant which can be used with the agent_type property of a JmsPluginSummary. + #: This constant has a value of "OMA" + AGENT_TYPE_OMA = "OMA" + + #: A constant which can be used with the agent_type property of a JmsPluginSummary. + #: This constant has a value of "OCA" + AGENT_TYPE_OCA = "OCA" + + #: A constant which can be used with the lifecycle_state property of a JmsPluginSummary. + #: This constant has a value of "ACTIVE" + LIFECYCLE_STATE_ACTIVE = "ACTIVE" + + #: A constant which can be used with the lifecycle_state property of a JmsPluginSummary. + #: This constant has a value of "INACTIVE" + LIFECYCLE_STATE_INACTIVE = "INACTIVE" + + #: A constant which can be used with the lifecycle_state property of a JmsPluginSummary. + #: This constant has a value of "NEEDS_ATTENTION" + LIFECYCLE_STATE_NEEDS_ATTENTION = "NEEDS_ATTENTION" + + #: A constant which can be used with the lifecycle_state property of a JmsPluginSummary. + #: This constant has a value of "DELETED" + LIFECYCLE_STATE_DELETED = "DELETED" + + #: A constant which can be used with the availability_status property of a JmsPluginSummary. + #: This constant has a value of "ACTIVE" + AVAILABILITY_STATUS_ACTIVE = "ACTIVE" + + #: A constant which can be used with the availability_status property of a JmsPluginSummary. + #: This constant has a value of "SILENT" + AVAILABILITY_STATUS_SILENT = "SILENT" + + #: A constant which can be used with the availability_status property of a JmsPluginSummary. + #: This constant has a value of "NOT_AVAILABLE" + AVAILABILITY_STATUS_NOT_AVAILABLE = "NOT_AVAILABLE" + + #: A constant which can be used with the os_family property of a JmsPluginSummary. + #: This constant has a value of "LINUX" + OS_FAMILY_LINUX = "LINUX" + + #: A constant which can be used with the os_family property of a JmsPluginSummary. + #: This constant has a value of "WINDOWS" + OS_FAMILY_WINDOWS = "WINDOWS" + + #: A constant which can be used with the os_family property of a JmsPluginSummary. + #: This constant has a value of "MACOS" + OS_FAMILY_MACOS = "MACOS" + + #: A constant which can be used with the os_family property of a JmsPluginSummary. + #: This constant has a value of "UNKNOWN" + OS_FAMILY_UNKNOWN = "UNKNOWN" + + def __init__(self, **kwargs): + """ + Initializes a new JmsPluginSummary object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param id: + The value to assign to the id property of this JmsPluginSummary. + :type id: str + + :param agent_id: + The value to assign to the agent_id property of this JmsPluginSummary. + :type agent_id: str + + :param agent_type: + The value to assign to the agent_type property of this JmsPluginSummary. + Allowed values for this property are: "OMA", "OCA", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type agent_type: str + + :param lifecycle_state: + The value to assign to the lifecycle_state property of this JmsPluginSummary. + Allowed values for this property are: "ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type lifecycle_state: str + + :param availability_status: + The value to assign to the availability_status property of this JmsPluginSummary. + Allowed values for this property are: "ACTIVE", "SILENT", "NOT_AVAILABLE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type availability_status: str + + :param fleet_id: + The value to assign to the fleet_id property of this JmsPluginSummary. + :type fleet_id: str + + :param compartment_id: + The value to assign to the compartment_id property of this JmsPluginSummary. + :type compartment_id: str + + :param hostname: + The value to assign to the hostname property of this JmsPluginSummary. + :type hostname: str + + :param os_family: + The value to assign to the os_family property of this JmsPluginSummary. + Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type os_family: str + + :param os_architecture: + The value to assign to the os_architecture property of this JmsPluginSummary. + :type os_architecture: str + + :param os_distribution: + The value to assign to the os_distribution property of this JmsPluginSummary. + :type os_distribution: str + + :param plugin_version: + The value to assign to the plugin_version property of this JmsPluginSummary. + :type plugin_version: str + + :param time_registered: + The value to assign to the time_registered property of this JmsPluginSummary. + :type time_registered: datetime + + :param time_last_seen: + The value to assign to the time_last_seen property of this JmsPluginSummary. + :type time_last_seen: datetime + + :param defined_tags: + The value to assign to the defined_tags property of this JmsPluginSummary. + :type defined_tags: dict(str, dict(str, object)) + + :param freeform_tags: + The value to assign to the freeform_tags property of this JmsPluginSummary. + :type freeform_tags: dict(str, str) + + :param system_tags: + The value to assign to the system_tags property of this JmsPluginSummary. + :type system_tags: dict(str, dict(str, object)) + + """ + self.swagger_types = { + 'id': 'str', + 'agent_id': 'str', + 'agent_type': 'str', + 'lifecycle_state': 'str', + 'availability_status': 'str', + 'fleet_id': 'str', + 'compartment_id': 'str', + 'hostname': 'str', + 'os_family': 'str', + 'os_architecture': 'str', + 'os_distribution': 'str', + 'plugin_version': 'str', + 'time_registered': 'datetime', + 'time_last_seen': 'datetime', + 'defined_tags': 'dict(str, dict(str, object))', + 'freeform_tags': 'dict(str, str)', + 'system_tags': 'dict(str, dict(str, object))' + } + + self.attribute_map = { + 'id': 'id', + 'agent_id': 'agentId', + 'agent_type': 'agentType', + 'lifecycle_state': 'lifecycleState', + 'availability_status': 'availabilityStatus', + 'fleet_id': 'fleetId', + 'compartment_id': 'compartmentId', + 'hostname': 'hostname', + 'os_family': 'osFamily', + 'os_architecture': 'osArchitecture', + 'os_distribution': 'osDistribution', + 'plugin_version': 'pluginVersion', + 'time_registered': 'timeRegistered', + 'time_last_seen': 'timeLastSeen', + 'defined_tags': 'definedTags', + 'freeform_tags': 'freeformTags', + 'system_tags': 'systemTags' + } + + self._id = None + self._agent_id = None + self._agent_type = None + self._lifecycle_state = None + self._availability_status = None + self._fleet_id = None + self._compartment_id = None + self._hostname = None + self._os_family = None + self._os_architecture = None + self._os_distribution = None + self._plugin_version = None + self._time_registered = None + self._time_last_seen = None + self._defined_tags = None + self._freeform_tags = None + self._system_tags = None + + @property + def id(self): + """ + **[Required]** Gets the id of this JmsPluginSummary. + The `OCID`__ to identify this JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The id of this JmsPluginSummary. + :rtype: str + """ + return self._id + + @id.setter + def id(self, id): + """ + Sets the id of this JmsPluginSummary. + The `OCID`__ to identify this JmsPlugin. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param id: The id of this JmsPluginSummary. + :type: str + """ + self._id = id + + @property + def agent_id(self): + """ + **[Required]** Gets the agent_id of this JmsPluginSummary. + The `OCID`__ of the Management Agent (OMA) or the Oracle Cloud Agent (OCA) instance where the JMS plugin is deployed. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The agent_id of this JmsPluginSummary. + :rtype: str + """ + return self._agent_id + + @agent_id.setter + def agent_id(self, agent_id): + """ + Sets the agent_id of this JmsPluginSummary. + The `OCID`__ of the Management Agent (OMA) or the Oracle Cloud Agent (OCA) instance where the JMS plugin is deployed. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param agent_id: The agent_id of this JmsPluginSummary. + :type: str + """ + self._agent_id = agent_id + + @property + def agent_type(self): + """ + **[Required]** Gets the agent_type of this JmsPluginSummary. + The agent type. + + Allowed values for this property are: "OMA", "OCA", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The agent_type of this JmsPluginSummary. + :rtype: str + """ + return self._agent_type + + @agent_type.setter + def agent_type(self, agent_type): + """ + Sets the agent_type of this JmsPluginSummary. + The agent type. + + + :param agent_type: The agent_type of this JmsPluginSummary. + :type: str + """ + allowed_values = ["OMA", "OCA"] + if not value_allowed_none_or_none_sentinel(agent_type, allowed_values): + agent_type = 'UNKNOWN_ENUM_VALUE' + self._agent_type = agent_type + + @property + def lifecycle_state(self): + """ + **[Required]** Gets the lifecycle_state of this JmsPluginSummary. + The lifecycle state. + + Allowed values for this property are: "ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The lifecycle_state of this JmsPluginSummary. + :rtype: str + """ + return self._lifecycle_state + + @lifecycle_state.setter + def lifecycle_state(self, lifecycle_state): + """ + Sets the lifecycle_state of this JmsPluginSummary. + The lifecycle state. + + + :param lifecycle_state: The lifecycle_state of this JmsPluginSummary. + :type: str + """ + allowed_values = ["ACTIVE", "INACTIVE", "NEEDS_ATTENTION", "DELETED"] + if not value_allowed_none_or_none_sentinel(lifecycle_state, allowed_values): + lifecycle_state = 'UNKNOWN_ENUM_VALUE' + self._lifecycle_state = lifecycle_state + + @property + def availability_status(self): + """ + **[Required]** Gets the availability_status of this JmsPluginSummary. + The availability status. + + Allowed values for this property are: "ACTIVE", "SILENT", "NOT_AVAILABLE", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The availability_status of this JmsPluginSummary. + :rtype: str + """ + return self._availability_status + + @availability_status.setter + def availability_status(self, availability_status): + """ + Sets the availability_status of this JmsPluginSummary. + The availability status. + + + :param availability_status: The availability_status of this JmsPluginSummary. + :type: str + """ + allowed_values = ["ACTIVE", "SILENT", "NOT_AVAILABLE"] + if not value_allowed_none_or_none_sentinel(availability_status, allowed_values): + availability_status = 'UNKNOWN_ENUM_VALUE' + self._availability_status = availability_status + + @property + def fleet_id(self): + """ + Gets the fleet_id of this JmsPluginSummary. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The fleet_id of this JmsPluginSummary. + :rtype: str + """ + return self._fleet_id + + @fleet_id.setter + def fleet_id(self, fleet_id): + """ + Sets the fleet_id of this JmsPluginSummary. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param fleet_id: The fleet_id of this JmsPluginSummary. + :type: str + """ + self._fleet_id = fleet_id + + @property + def compartment_id(self): + """ + Gets the compartment_id of this JmsPluginSummary. + The OMA/OCA agent's compartment `OCID`__. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The compartment_id of this JmsPluginSummary. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this JmsPluginSummary. + The OMA/OCA agent's compartment `OCID`__. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param compartment_id: The compartment_id of this JmsPluginSummary. + :type: str + """ + self._compartment_id = compartment_id + + @property + def hostname(self): + """ + Gets the hostname of this JmsPluginSummary. + The hostname of the agent. + + + :return: The hostname of this JmsPluginSummary. + :rtype: str + """ + return self._hostname + + @hostname.setter + def hostname(self, hostname): + """ + Sets the hostname of this JmsPluginSummary. + The hostname of the agent. + + + :param hostname: The hostname of this JmsPluginSummary. + :type: str + """ + self._hostname = hostname + + @property + def os_family(self): + """ + Gets the os_family of this JmsPluginSummary. + The operating system family for the plugin. + + Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The os_family of this JmsPluginSummary. + :rtype: str + """ + return self._os_family + + @os_family.setter + def os_family(self, os_family): + """ + Sets the os_family of this JmsPluginSummary. + The operating system family for the plugin. + + + :param os_family: The os_family of this JmsPluginSummary. + :type: str + """ + allowed_values = ["LINUX", "WINDOWS", "MACOS", "UNKNOWN"] + if not value_allowed_none_or_none_sentinel(os_family, allowed_values): + os_family = 'UNKNOWN_ENUM_VALUE' + self._os_family = os_family + + @property + def os_architecture(self): + """ + Gets the os_architecture of this JmsPluginSummary. + The architecture of the operating system of the plugin. + + + :return: The os_architecture of this JmsPluginSummary. + :rtype: str + """ + return self._os_architecture + + @os_architecture.setter + def os_architecture(self, os_architecture): + """ + Sets the os_architecture of this JmsPluginSummary. + The architecture of the operating system of the plugin. + + + :param os_architecture: The os_architecture of this JmsPluginSummary. + :type: str + """ + self._os_architecture = os_architecture + + @property + def os_distribution(self): + """ + Gets the os_distribution of this JmsPluginSummary. + The distribution of the operating system of the plugin. + + + :return: The os_distribution of this JmsPluginSummary. + :rtype: str + """ + return self._os_distribution + + @os_distribution.setter + def os_distribution(self, os_distribution): + """ + Sets the os_distribution of this JmsPluginSummary. + The distribution of the operating system of the plugin. + + + :param os_distribution: The os_distribution of this JmsPluginSummary. + :type: str + """ + self._os_distribution = os_distribution + + @property + def plugin_version(self): + """ + Gets the plugin_version of this JmsPluginSummary. + The version of the plugin. + + + :return: The plugin_version of this JmsPluginSummary. + :rtype: str + """ + return self._plugin_version + + @plugin_version.setter + def plugin_version(self, plugin_version): + """ + Sets the plugin_version of this JmsPluginSummary. + The version of the plugin. + + + :param plugin_version: The plugin_version of this JmsPluginSummary. + :type: str + """ + self._plugin_version = plugin_version + + @property + def time_registered(self): + """ + **[Required]** Gets the time_registered of this JmsPluginSummary. + The date and time the plugin was registered. + + + :return: The time_registered of this JmsPluginSummary. + :rtype: datetime + """ + return self._time_registered + + @time_registered.setter + def time_registered(self, time_registered): + """ + Sets the time_registered of this JmsPluginSummary. + The date and time the plugin was registered. + + + :param time_registered: The time_registered of this JmsPluginSummary. + :type: datetime + """ + self._time_registered = time_registered + + @property + def time_last_seen(self): + """ + Gets the time_last_seen of this JmsPluginSummary. + The date and time the resource was _last_ reported to JMS. + This is potentially _after_ the specified time period provided by the filters. + For example, a resource can be last reported to JMS before the start of a specified time period, + if it is also reported during the time period. + + + :return: The time_last_seen of this JmsPluginSummary. + :rtype: datetime + """ + return self._time_last_seen + + @time_last_seen.setter + def time_last_seen(self, time_last_seen): + """ + Sets the time_last_seen of this JmsPluginSummary. + The date and time the resource was _last_ reported to JMS. + This is potentially _after_ the specified time period provided by the filters. + For example, a resource can be last reported to JMS before the start of a specified time period, + if it is also reported during the time period. + + + :param time_last_seen: The time_last_seen of this JmsPluginSummary. + :type: datetime + """ + self._time_last_seen = time_last_seen + + @property + def defined_tags(self): + """ + Gets the defined_tags of this JmsPluginSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :return: The defined_tags of this JmsPluginSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this JmsPluginSummary. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :param defined_tags: The defined_tags of this JmsPluginSummary. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this JmsPluginSummary. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :return: The freeform_tags of this JmsPluginSummary. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this JmsPluginSummary. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :param freeform_tags: The freeform_tags of this JmsPluginSummary. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + @property + def system_tags(self): + """ + Gets the system_tags of this JmsPluginSummary. + System tags for this resource. Each key is predefined and scoped to a namespace. + For more information, see `Resource Tags`__. + System tags can be viewed by users, but can only be created by the system. + + Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :return: The system_tags of this JmsPluginSummary. + :rtype: dict(str, dict(str, object)) + """ + return self._system_tags + + @system_tags.setter + def system_tags(self, system_tags): + """ + Sets the system_tags of this JmsPluginSummary. + System tags for this resource. Each key is predefined and scoped to a namespace. + For more information, see `Resource Tags`__. + System tags can be viewed by users, but can only be created by the system. + + Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` + + __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm + + + :param system_tags: The system_tags of this JmsPluginSummary. + :type: dict(str, dict(str, object)) + """ + self._system_tags = system_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/lcm_work_item_details.py b/src/oci/jms/models/lcm_work_item_details.py index ddc15ec3c..8c83c99b8 100644 --- a/src/oci/jms/models/lcm_work_item_details.py +++ b/src/oci/jms/models/lcm_work_item_details.py @@ -23,7 +23,7 @@ def __init__(self, **kwargs): :param kind: The value to assign to the kind property of this LcmWorkItemDetails. - Allowed values for this property are: "BASIC", "APPLICATION", "LCM" + Allowed values for this property are: "BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION" :type kind: str :param work_item_type: diff --git a/src/oci/jms/models/library_usage.py b/src/oci/jms/models/library_usage.py index b8dbac5d0..680cfae42 100644 --- a/src/oci/jms/models/library_usage.py +++ b/src/oci/jms/models/library_usage.py @@ -36,6 +36,10 @@ def __init__(self, **kwargs): The value to assign to the library_version property of this LibraryUsage. :type library_version: str + :param cve_id: + The value to assign to the cve_id property of this LibraryUsage. + :type cve_id: str + :param cvss_score: The value to assign to the cvss_score property of this LibraryUsage. :type cvss_score: float @@ -72,12 +76,17 @@ def __init__(self, **kwargs): The value to assign to the time_last_seen property of this LibraryUsage. :type time_last_seen: datetime + :param time_last_cve_refreshed: + The value to assign to the time_last_cve_refreshed property of this LibraryUsage. + :type time_last_cve_refreshed: datetime + """ self.swagger_types = { 'library_key': 'str', 'fleet_id': 'str', 'library_name': 'str', 'library_version': 'str', + 'cve_id': 'str', 'cvss_score': 'float', 'approximate_application_count': 'int', 'approximate_java_server_instance_count': 'int', @@ -86,7 +95,8 @@ def __init__(self, **kwargs): 'time_start': 'datetime', 'time_end': 'datetime', 'time_first_seen': 'datetime', - 'time_last_seen': 'datetime' + 'time_last_seen': 'datetime', + 'time_last_cve_refreshed': 'datetime' } self.attribute_map = { @@ -94,6 +104,7 @@ def __init__(self, **kwargs): 'fleet_id': 'fleetId', 'library_name': 'libraryName', 'library_version': 'libraryVersion', + 'cve_id': 'cveId', 'cvss_score': 'cvssScore', 'approximate_application_count': 'approximateApplicationCount', 'approximate_java_server_instance_count': 'approximateJavaServerInstanceCount', @@ -102,13 +113,15 @@ def __init__(self, **kwargs): 'time_start': 'timeStart', 'time_end': 'timeEnd', 'time_first_seen': 'timeFirstSeen', - 'time_last_seen': 'timeLastSeen' + 'time_last_seen': 'timeLastSeen', + 'time_last_cve_refreshed': 'timeLastCveRefreshed' } self._library_key = None self._fleet_id = None self._library_name = None self._library_version = None + self._cve_id = None self._cvss_score = None self._approximate_application_count = None self._approximate_java_server_instance_count = None @@ -118,6 +131,7 @@ def __init__(self, **kwargs): self._time_end = None self._time_first_seen = None self._time_last_seen = None + self._time_last_cve_refreshed = None @property def library_key(self): @@ -219,6 +233,30 @@ def library_version(self, library_version): """ self._library_version = library_version + @property + def cve_id(self): + """ + Gets the cve_id of this LibraryUsage. + The Common Vulnerabilities and Exposures (CVE) ID. + + + :return: The cve_id of this LibraryUsage. + :rtype: str + """ + return self._cve_id + + @cve_id.setter + def cve_id(self, cve_id): + """ + Sets the cve_id of this LibraryUsage. + The Common Vulnerabilities and Exposures (CVE) ID. + + + :param cve_id: The cve_id of this LibraryUsage. + :type: str + """ + self._cve_id = cve_id + @property def cvss_score(self): """ @@ -447,6 +485,30 @@ def time_last_seen(self, time_last_seen): """ self._time_last_seen = time_last_seen + @property + def time_last_cve_refreshed(self): + """ + Gets the time_last_cve_refreshed of this LibraryUsage. + The date and time of the last CVEs refresh was completed. + + + :return: The time_last_cve_refreshed of this LibraryUsage. + :rtype: datetime + """ + return self._time_last_cve_refreshed + + @time_last_cve_refreshed.setter + def time_last_cve_refreshed(self, time_last_cve_refreshed): + """ + Sets the time_last_cve_refreshed of this LibraryUsage. + The date and time of the last CVEs refresh was completed. + + + :param time_last_cve_refreshed: The time_last_cve_refreshed of this LibraryUsage. + :type: datetime + """ + self._time_last_cve_refreshed = time_last_cve_refreshed + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/jms/models/managed_instance_usage.py b/src/oci/jms/models/managed_instance_usage.py index 0aa46c560..90559378d 100644 --- a/src/oci/jms/models/managed_instance_usage.py +++ b/src/oci/jms/models/managed_instance_usage.py @@ -22,6 +22,10 @@ class ManagedInstanceUsage(object): #: This constant has a value of "ORACLE_MANAGEMENT_AGENT" MANAGED_INSTANCE_TYPE_ORACLE_MANAGEMENT_AGENT = "ORACLE_MANAGEMENT_AGENT" + #: A constant which can be used with the managed_instance_type property of a ManagedInstanceUsage. + #: This constant has a value of "ORACLE_CLOUD_AGENT" + MANAGED_INSTANCE_TYPE_ORACLE_CLOUD_AGENT = "ORACLE_CLOUD_AGENT" + #: A constant which can be used with the drs_file_status property of a ManagedInstanceUsage. #: This constant has a value of "PRESENT" DRS_FILE_STATUS_PRESENT = "PRESENT" @@ -49,7 +53,7 @@ def __init__(self, **kwargs): :param managed_instance_type: The value to assign to the managed_instance_type property of this ManagedInstanceUsage. - Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type managed_instance_type: str @@ -87,6 +91,10 @@ def __init__(self, **kwargs): Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type drs_file_status: str + :param application_invoked_by: + The value to assign to the application_invoked_by property of this ManagedInstanceUsage. + :type application_invoked_by: str + :param time_start: The value to assign to the time_start property of this ManagedInstanceUsage. :type time_start: datetime @@ -115,6 +123,7 @@ def __init__(self, **kwargs): 'approximate_installation_count': 'int', 'approximate_jre_count': 'int', 'drs_file_status': 'str', + 'application_invoked_by': 'str', 'time_start': 'datetime', 'time_end': 'datetime', 'time_first_seen': 'datetime', @@ -132,6 +141,7 @@ def __init__(self, **kwargs): 'approximate_installation_count': 'approximateInstallationCount', 'approximate_jre_count': 'approximateJreCount', 'drs_file_status': 'drsFileStatus', + 'application_invoked_by': 'applicationInvokedBy', 'time_start': 'timeStart', 'time_end': 'timeEnd', 'time_first_seen': 'timeFirstSeen', @@ -148,6 +158,7 @@ def __init__(self, **kwargs): self._approximate_installation_count = None self._approximate_jre_count = None self._drs_file_status = None + self._application_invoked_by = None self._time_start = None self._time_end = None self._time_first_seen = None @@ -187,7 +198,7 @@ def managed_instance_type(self): **[Required]** Gets the managed_instance_type of this ManagedInstanceUsage. The type of the source of events. - Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -206,7 +217,7 @@ def managed_instance_type(self, managed_instance_type): :param managed_instance_type: The managed_instance_type of this ManagedInstanceUsage. :type: str """ - allowed_values = ["ORACLE_MANAGEMENT_AGENT"] + allowed_values = ["ORACLE_MANAGEMENT_AGENT", "ORACLE_CLOUD_AGENT"] if not value_allowed_none_or_none_sentinel(managed_instance_type, allowed_values): managed_instance_type = 'UNKNOWN_ENUM_VALUE' self._managed_instance_type = managed_instance_type @@ -405,6 +416,30 @@ def drs_file_status(self, drs_file_status): drs_file_status = 'UNKNOWN_ENUM_VALUE' self._drs_file_status = drs_file_status + @property + def application_invoked_by(self): + """ + Gets the application_invoked_by of this ManagedInstanceUsage. + Comma separated list of user names that invoked applications within this managed instance. + + + :return: The application_invoked_by of this ManagedInstanceUsage. + :rtype: str + """ + return self._application_invoked_by + + @application_invoked_by.setter + def application_invoked_by(self, application_invoked_by): + """ + Sets the application_invoked_by of this ManagedInstanceUsage. + Comma separated list of user names that invoked applications within this managed instance. + + + :param application_invoked_by: The application_invoked_by of this ManagedInstanceUsage. + :type: str + """ + self._application_invoked_by = application_invoked_by + @property def time_start(self): """ diff --git a/src/oci/jms/models/operating_system.py b/src/oci/jms/models/operating_system.py index fef17e186..9f1149aa9 100644 --- a/src/oci/jms/models/operating_system.py +++ b/src/oci/jms/models/operating_system.py @@ -85,7 +85,7 @@ def __init__(self, **kwargs): def family(self): """ **[Required]** Gets the family of this OperatingSystem. - The operating system type, such as Windows or Linux + The operating system type, such as Windows, Linux or macOS Allowed values for this property are: "LINUX", "WINDOWS", "MACOS", "UNKNOWN", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -100,7 +100,7 @@ def family(self): def family(self, family): """ Sets the family of this OperatingSystem. - The operating system type, such as Windows or Linux + The operating system type, such as Windows, Linux or macOS :param family: The family of this OperatingSystem. diff --git a/src/oci/jms/models/performance_tuning_analysis_result.py b/src/oci/jms/models/performance_tuning_analysis_result.py index e37713d29..e6ef7274c 100644 --- a/src/oci/jms/models/performance_tuning_analysis_result.py +++ b/src/oci/jms/models/performance_tuning_analysis_result.py @@ -527,7 +527,7 @@ def time_created(self, time_created): def time_started(self): """ **[Required]** Gets the time_started of this PerformanceTuningAnalysisResult. - The time the JFR capture started. + The time the JFR recording has started. :return: The time_started of this PerformanceTuningAnalysisResult. @@ -539,7 +539,7 @@ def time_started(self): def time_started(self, time_started): """ Sets the time_started of this PerformanceTuningAnalysisResult. - The time the JFR capture started. + The time the JFR recording has started. :param time_started: The time_started of this PerformanceTuningAnalysisResult. @@ -551,7 +551,7 @@ def time_started(self, time_started): def time_finished(self): """ **[Required]** Gets the time_finished of this PerformanceTuningAnalysisResult. - The time the JFR capture finished. + The time the JFR recording has finished. :return: The time_finished of this PerformanceTuningAnalysisResult. @@ -563,7 +563,7 @@ def time_finished(self): def time_finished(self, time_finished): """ Sets the time_finished of this PerformanceTuningAnalysisResult. - The time the JFR capture finished. + The time the JFR recording has finished. :param time_finished: The time_finished of this PerformanceTuningAnalysisResult. diff --git a/src/oci/jms/models/performance_tuning_analysis_result_summary.py b/src/oci/jms/models/performance_tuning_analysis_result_summary.py index 9b729296f..33e5eb7da 100644 --- a/src/oci/jms/models/performance_tuning_analysis_result_summary.py +++ b/src/oci/jms/models/performance_tuning_analysis_result_summary.py @@ -527,7 +527,7 @@ def time_created(self, time_created): def time_started(self): """ **[Required]** Gets the time_started of this PerformanceTuningAnalysisResultSummary. - The time the JFR capture started. + The time the JFR recording has started. :return: The time_started of this PerformanceTuningAnalysisResultSummary. @@ -539,7 +539,7 @@ def time_started(self): def time_started(self, time_started): """ Sets the time_started of this PerformanceTuningAnalysisResultSummary. - The time the JFR capture started. + The time the JFR recording has started. :param time_started: The time_started of this PerformanceTuningAnalysisResultSummary. @@ -551,7 +551,7 @@ def time_started(self, time_started): def time_finished(self): """ **[Required]** Gets the time_finished of this PerformanceTuningAnalysisResultSummary. - The time the JFR capture finished. + The time the JFR recording has finished. :return: The time_finished of this PerformanceTuningAnalysisResultSummary. @@ -563,7 +563,7 @@ def time_finished(self): def time_finished(self, time_finished): """ Sets the time_finished of this PerformanceTuningAnalysisResultSummary. - The time the JFR capture finished. + The time the JFR recording has finished. :param time_finished: The time_finished of this PerformanceTuningAnalysisResultSummary. diff --git a/src/oci/jms/models/request_deployed_application_migration_analyses_details.py b/src/oci/jms/models/request_deployed_application_migration_analyses_details.py new file mode 100644 index 000000000..c5643f382 --- /dev/null +++ b/src/oci/jms/models/request_deployed_application_migration_analyses_details.py @@ -0,0 +1,73 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class RequestDeployedApplicationMigrationAnalysesDetails(object): + """ + Details of the request to start a Java migration analyses. The analyses requires the managed instance OCID, deployed application key, + source JDK version, and target JDK version of each selected application. + """ + + def __init__(self, **kwargs): + """ + Initializes a new RequestDeployedApplicationMigrationAnalysesDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param targets: + The value to assign to the targets property of this RequestDeployedApplicationMigrationAnalysesDetails. + :type targets: list[oci.jms.models.DeployedApplicationMigrationAnalysesTarget] + + """ + self.swagger_types = { + 'targets': 'list[DeployedApplicationMigrationAnalysesTarget]' + } + + self.attribute_map = { + 'targets': 'targets' + } + + self._targets = None + + @property + def targets(self): + """ + **[Required]** Gets the targets of this RequestDeployedApplicationMigrationAnalysesDetails. + An array of migration analyses requests. + + + :return: The targets of this RequestDeployedApplicationMigrationAnalysesDetails. + :rtype: list[oci.jms.models.DeployedApplicationMigrationAnalysesTarget] + """ + return self._targets + + @targets.setter + def targets(self, targets): + """ + Sets the targets of this RequestDeployedApplicationMigrationAnalysesDetails. + An array of migration analyses requests. + + + :param targets: The targets of this RequestDeployedApplicationMigrationAnalysesDetails. + :type: list[oci.jms.models.DeployedApplicationMigrationAnalysesTarget] + """ + self._targets = targets + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/update_export_setting_details.py b/src/oci/jms/models/update_export_setting_details.py index 1e9713b31..a5b409f44 100644 --- a/src/oci/jms/models/update_export_setting_details.py +++ b/src/oci/jms/models/update_export_setting_details.py @@ -12,7 +12,7 @@ @init_model_state_from_kwargs class UpdateExportSettingDetails(object): """ - Attributes to update a Export setting. + Attributes to update an export setting. """ #: A constant which can be used with the export_duration property of a UpdateExportSettingDetails. @@ -261,7 +261,7 @@ def target_bucket_namespace(self, target_bucket_namespace): def target_bucket_region(self): """ Gets the target_bucket_region of this UpdateExportSettingDetails. - The namespace of the bucket where data will be exported. + The id of the region of the target bucket. :return: The target_bucket_region of this UpdateExportSettingDetails. @@ -273,7 +273,7 @@ def target_bucket_region(self): def target_bucket_region(self, target_bucket_region): """ Sets the target_bucket_region of this UpdateExportSettingDetails. - The namespace of the bucket where data will be exported. + The id of the region of the target bucket. :param target_bucket_region: The target_bucket_region of this UpdateExportSettingDetails. diff --git a/src/oci/jms/models/update_fleet_agent_configuration_details.py b/src/oci/jms/models/update_fleet_agent_configuration_details.py index 247154062..9f0004f2b 100644 --- a/src/oci/jms/models/update_fleet_agent_configuration_details.py +++ b/src/oci/jms/models/update_fleet_agent_configuration_details.py @@ -36,6 +36,14 @@ def __init__(self, **kwargs): The value to assign to the agent_polling_interval_in_minutes property of this UpdateFleetAgentConfigurationDetails. :type agent_polling_interval_in_minutes: int + :param is_collecting_managed_instance_metrics_enabled: + The value to assign to the is_collecting_managed_instance_metrics_enabled property of this UpdateFleetAgentConfigurationDetails. + :type is_collecting_managed_instance_metrics_enabled: bool + + :param is_collecting_usernames_enabled: + The value to assign to the is_collecting_usernames_enabled property of this UpdateFleetAgentConfigurationDetails. + :type is_collecting_usernames_enabled: bool + :param linux_configuration: The value to assign to the linux_configuration property of this UpdateFleetAgentConfigurationDetails. :type linux_configuration: oci.jms.models.FleetAgentOsConfiguration @@ -54,6 +62,8 @@ def __init__(self, **kwargs): 'java_usage_tracker_processing_frequency_in_minutes': 'int', 'work_request_validity_period_in_days': 'int', 'agent_polling_interval_in_minutes': 'int', + 'is_collecting_managed_instance_metrics_enabled': 'bool', + 'is_collecting_usernames_enabled': 'bool', 'linux_configuration': 'FleetAgentOsConfiguration', 'windows_configuration': 'FleetAgentOsConfiguration', 'mac_os_configuration': 'FleetAgentOsConfiguration' @@ -64,6 +74,8 @@ def __init__(self, **kwargs): 'java_usage_tracker_processing_frequency_in_minutes': 'javaUsageTrackerProcessingFrequencyInMinutes', 'work_request_validity_period_in_days': 'workRequestValidityPeriodInDays', 'agent_polling_interval_in_minutes': 'agentPollingIntervalInMinutes', + 'is_collecting_managed_instance_metrics_enabled': 'isCollectingManagedInstanceMetricsEnabled', + 'is_collecting_usernames_enabled': 'isCollectingUsernamesEnabled', 'linux_configuration': 'linuxConfiguration', 'windows_configuration': 'windowsConfiguration', 'mac_os_configuration': 'macOsConfiguration' @@ -73,6 +85,8 @@ def __init__(self, **kwargs): self._java_usage_tracker_processing_frequency_in_minutes = None self._work_request_validity_period_in_days = None self._agent_polling_interval_in_minutes = None + self._is_collecting_managed_instance_metrics_enabled = None + self._is_collecting_usernames_enabled = None self._linux_configuration = None self._windows_configuration = None self._mac_os_configuration = None @@ -173,6 +187,54 @@ def agent_polling_interval_in_minutes(self, agent_polling_interval_in_minutes): """ self._agent_polling_interval_in_minutes = agent_polling_interval_in_minutes + @property + def is_collecting_managed_instance_metrics_enabled(self): + """ + Gets the is_collecting_managed_instance_metrics_enabled of this UpdateFleetAgentConfigurationDetails. + Collect JMS agent metrics on all managed instances in the fleet. + + + :return: The is_collecting_managed_instance_metrics_enabled of this UpdateFleetAgentConfigurationDetails. + :rtype: bool + """ + return self._is_collecting_managed_instance_metrics_enabled + + @is_collecting_managed_instance_metrics_enabled.setter + def is_collecting_managed_instance_metrics_enabled(self, is_collecting_managed_instance_metrics_enabled): + """ + Sets the is_collecting_managed_instance_metrics_enabled of this UpdateFleetAgentConfigurationDetails. + Collect JMS agent metrics on all managed instances in the fleet. + + + :param is_collecting_managed_instance_metrics_enabled: The is_collecting_managed_instance_metrics_enabled of this UpdateFleetAgentConfigurationDetails. + :type: bool + """ + self._is_collecting_managed_instance_metrics_enabled = is_collecting_managed_instance_metrics_enabled + + @property + def is_collecting_usernames_enabled(self): + """ + Gets the is_collecting_usernames_enabled of this UpdateFleetAgentConfigurationDetails. + Collect username for application invocations for all managed instances in the fleet. + + + :return: The is_collecting_usernames_enabled of this UpdateFleetAgentConfigurationDetails. + :rtype: bool + """ + return self._is_collecting_usernames_enabled + + @is_collecting_usernames_enabled.setter + def is_collecting_usernames_enabled(self, is_collecting_usernames_enabled): + """ + Sets the is_collecting_usernames_enabled of this UpdateFleetAgentConfigurationDetails. + Collect username for application invocations for all managed instances in the fleet. + + + :param is_collecting_usernames_enabled: The is_collecting_usernames_enabled of this UpdateFleetAgentConfigurationDetails. + :type: bool + """ + self._is_collecting_usernames_enabled = is_collecting_usernames_enabled + @property def linux_configuration(self): """ diff --git a/src/oci/jms/models/update_jms_plugin_details.py b/src/oci/jms/models/update_jms_plugin_details.py new file mode 100644 index 000000000..b477b8f49 --- /dev/null +++ b/src/oci/jms/models/update_jms_plugin_details.py @@ -0,0 +1,150 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20210610 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateJmsPluginDetails(object): + """ + Attributes to update a JmsPlugin. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateJmsPluginDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param fleet_id: + The value to assign to the fleet_id property of this UpdateJmsPluginDetails. + :type fleet_id: str + + :param defined_tags: + The value to assign to the defined_tags property of this UpdateJmsPluginDetails. + :type defined_tags: dict(str, dict(str, object)) + + :param freeform_tags: + The value to assign to the freeform_tags property of this UpdateJmsPluginDetails. + :type freeform_tags: dict(str, str) + + """ + self.swagger_types = { + 'fleet_id': 'str', + 'defined_tags': 'dict(str, dict(str, object))', + 'freeform_tags': 'dict(str, str)' + } + + self.attribute_map = { + 'fleet_id': 'fleetId', + 'defined_tags': 'definedTags', + 'freeform_tags': 'freeformTags' + } + + self._fleet_id = None + self._defined_tags = None + self._freeform_tags = None + + @property + def fleet_id(self): + """ + Gets the fleet_id of this UpdateJmsPluginDetails. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The fleet_id of this UpdateJmsPluginDetails. + :rtype: str + """ + return self._fleet_id + + @fleet_id.setter + def fleet_id(self, fleet_id): + """ + Sets the fleet_id of this UpdateJmsPluginDetails. + The `OCID`__ of the fleet. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param fleet_id: The fleet_id of this UpdateJmsPluginDetails. + :type: str + """ + self._fleet_id = fleet_id + + @property + def defined_tags(self): + """ + Gets the defined_tags of this UpdateJmsPluginDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :return: The defined_tags of this UpdateJmsPluginDetails. + :rtype: dict(str, dict(str, object)) + """ + return self._defined_tags + + @defined_tags.setter + def defined_tags(self, defined_tags): + """ + Sets the defined_tags of this UpdateJmsPluginDetails. + Defined tags for this resource. Each key is predefined and scoped to a namespace. + Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}`. (See `Understanding Free-form Tags`__). + + __ https://docs.cloud.oracle.com/Content/Tagging/Tasks/managingtagsandtagnamespaces.htm + + + :param defined_tags: The defined_tags of this UpdateJmsPluginDetails. + :type: dict(str, dict(str, object)) + """ + self._defined_tags = defined_tags + + @property + def freeform_tags(self): + """ + Gets the freeform_tags of this UpdateJmsPluginDetails. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :return: The freeform_tags of this UpdateJmsPluginDetails. + :rtype: dict(str, str) + """ + return self._freeform_tags + + @freeform_tags.setter + def freeform_tags(self, freeform_tags): + """ + Sets the freeform_tags of this UpdateJmsPluginDetails. + Simple key-value pair that is applied without any predefined name, type, or scope. Exists for cross-compatibility only. + Example: `{\"bar-key\": \"value\"}`. (See `Managing Tags and Tag Namespaces`__.) + + __ https://docs.cloud.oracle.com/Content/Tagging/Concepts/understandingfreeformtags.htm + + + :param freeform_tags: The freeform_tags of this UpdateJmsPluginDetails. + :type: dict(str, str) + """ + self._freeform_tags = freeform_tags + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/jms/models/work_item_details.py b/src/oci/jms/models/work_item_details.py index 2f9eee62f..a57301211 100644 --- a/src/oci/jms/models/work_item_details.py +++ b/src/oci/jms/models/work_item_details.py @@ -27,6 +27,10 @@ class WorkItemDetails(object): #: This constant has a value of "LCM" KIND_LCM = "LCM" + #: A constant which can be used with the kind property of a WorkItemDetails. + #: This constant has a value of "DEPLOYED_APPLICATION" + KIND_DEPLOYED_APPLICATION = "DEPLOYED_APPLICATION" + #: A constant which can be used with the work_item_type property of a WorkItemDetails. #: This constant has a value of "LCM" WORK_ITEM_TYPE_LCM = "LCM" @@ -84,6 +88,7 @@ def __init__(self, **kwargs): Initializes a new WorkItemDetails object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: + * :class:`~oci.jms.models.DeployedApplicationWorkItemDetails` * :class:`~oci.jms.models.LcmWorkItemDetails` * :class:`~oci.jms.models.BasicWorkItemDetails` * :class:`~oci.jms.models.ApplicationWorkItemDetails` @@ -92,7 +97,7 @@ def __init__(self, **kwargs): :param kind: The value to assign to the kind property of this WorkItemDetails. - Allowed values for this property are: "BASIC", "APPLICATION", "LCM", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type kind: str @@ -124,6 +129,9 @@ def get_subtype(object_dictionary): """ type = object_dictionary['kind'] + if type == 'DEPLOYED_APPLICATION': + return 'DeployedApplicationWorkItemDetails' + if type == 'LCM': return 'LcmWorkItemDetails' @@ -141,7 +149,7 @@ def kind(self): **[Required]** Gets the kind of this WorkItemDetails. The kind of work item details. - Allowed values for this property are: "BASIC", "APPLICATION", "LCM", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -160,7 +168,7 @@ def kind(self, kind): :param kind: The kind of this WorkItemDetails. :type: str """ - allowed_values = ["BASIC", "APPLICATION", "LCM"] + allowed_values = ["BASIC", "APPLICATION", "LCM", "DEPLOYED_APPLICATION"] if not value_allowed_none_or_none_sentinel(kind, allowed_values): kind = 'UNKNOWN_ENUM_VALUE' self._kind = kind diff --git a/src/oci/jms/models/work_item_summary.py b/src/oci/jms/models/work_item_summary.py index 940d262a3..aca1c3123 100644 --- a/src/oci/jms/models/work_item_summary.py +++ b/src/oci/jms/models/work_item_summary.py @@ -43,6 +43,10 @@ class WorkItemSummary(object): #: This constant has a value of "RETRYING" STATUS_RETRYING = "RETRYING" + #: A constant which can be used with the status property of a WorkItemSummary. + #: This constant has a value of "SKIPPED" + STATUS_SKIPPED = "SKIPPED" + def __init__(self, **kwargs): """ Initializes a new WorkItemSummary object with values from keyword arguments. @@ -66,7 +70,7 @@ def __init__(self, **kwargs): :param status: The value to assign to the status property of this WorkItemSummary. - Allowed values for this property are: "ACCEPTED", "IN_PROGRESS", "CANCELING", "CANCELED", "SUCCEEDED", "NEEDS_ATTENTION", "RETRYING", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ACCEPTED", "IN_PROGRESS", "CANCELING", "CANCELED", "SUCCEEDED", "NEEDS_ATTENTION", "RETRYING", "SKIPPED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type status: str @@ -201,7 +205,7 @@ def status(self): **[Required]** Gets the status of this WorkItemSummary. The status of the work item. - Allowed values for this property are: "ACCEPTED", "IN_PROGRESS", "CANCELING", "CANCELED", "SUCCEEDED", "NEEDS_ATTENTION", "RETRYING", 'UNKNOWN_ENUM_VALUE'. + Allowed values for this property are: "ACCEPTED", "IN_PROGRESS", "CANCELING", "CANCELED", "SUCCEEDED", "NEEDS_ATTENTION", "RETRYING", "SKIPPED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. @@ -220,7 +224,7 @@ def status(self, status): :param status: The status of this WorkItemSummary. :type: str """ - allowed_values = ["ACCEPTED", "IN_PROGRESS", "CANCELING", "CANCELED", "SUCCEEDED", "NEEDS_ATTENTION", "RETRYING"] + allowed_values = ["ACCEPTED", "IN_PROGRESS", "CANCELING", "CANCELED", "SUCCEEDED", "NEEDS_ATTENTION", "RETRYING", "SKIPPED"] if not value_allowed_none_or_none_sentinel(status, allowed_values): status = 'UNKNOWN_ENUM_VALUE' self._status = status diff --git a/src/oci/jms_java_downloads/java_download_client.py b/src/oci/jms_java_downloads/java_download_client.py index 058d9e23b..b845a3cd2 100644 --- a/src/oci/jms_java_downloads/java_download_client.py +++ b/src/oci/jms_java_downloads/java_download_client.py @@ -832,11 +832,11 @@ def delete_java_license_acceptance_record(self, java_license_acceptance_record_i def generate_artifact_download_url(self, generate_artifact_download_url_details, **kwargs): """ - Generates a short-lived download URL and returns it in the response payload. - The returned URL can then be used for downloading the specific Java runtime artifact. + Generates a download URL and returns it in the response payload. + The URL in the response can then be used for downloading the specific Java runtime artifact. Use the :func:`get_java_release` API - to get information about available artifacts for a specific release. Each such artifact is uniquely identified by an `artifactId`. + to get information about available artifacts for a specific release. Each artifact is uniquely identified by an `artifactId`. Refer :func:`java_artifact` for more details. @@ -1874,7 +1874,7 @@ def list_java_download_tokens(self, compartment_id, **kwargs): :param str search_by_user: (optional) A filter to return only resources that match the user principal detail. The search string can be any of the property values from the :func:`principal` object. - This object is used as response datatype for the `createdBy` and `lastUpdatedBy` fields in applicable resource. + This object is used as a response datatype for the `createdBy` and `lastUpdatedBy` fields in applicable resource. :param int limit: (optional) The maximum number of items to return. @@ -2031,7 +2031,7 @@ def list_java_license_acceptance_records(self, compartment_id, **kwargs): :param str search_by_user: (optional) A filter to return only resources that match the user principal detail. The search string can be any of the property values from the :func:`principal` object. - This object is used as response datatype for the `createdBy` and `lastUpdatedBy` fields in applicable resource. + This object is used as a response datatype for the `createdBy` and `lastUpdatedBy` fields in applicable resource. :param str id: (optional) Unique Java license acceptance record identifier. diff --git a/src/oci/jms_java_downloads/models/generate_artifact_download_url_details.py b/src/oci/jms_java_downloads/models/generate_artifact_download_url_details.py index c74533fbf..25578a110 100644 --- a/src/oci/jms_java_downloads/models/generate_artifact_download_url_details.py +++ b/src/oci/jms_java_downloads/models/generate_artifact_download_url_details.py @@ -20,21 +20,56 @@ def __init__(self, **kwargs): Initializes a new GenerateArtifactDownloadUrlDetails object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class): + :param compartment_id: + The value to assign to the compartment_id property of this GenerateArtifactDownloadUrlDetails. + :type compartment_id: str + :param artifact_id: The value to assign to the artifact_id property of this GenerateArtifactDownloadUrlDetails. :type artifact_id: int """ self.swagger_types = { + 'compartment_id': 'str', 'artifact_id': 'int' } self.attribute_map = { + 'compartment_id': 'compartmentId', 'artifact_id': 'artifactId' } + self._compartment_id = None self._artifact_id = None + @property + def compartment_id(self): + """ + Gets the compartment_id of this GenerateArtifactDownloadUrlDetails. + The tenancy `OCID`__ of the user initiating the download. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The compartment_id of this GenerateArtifactDownloadUrlDetails. + :rtype: str + """ + return self._compartment_id + + @compartment_id.setter + def compartment_id(self, compartment_id): + """ + Sets the compartment_id of this GenerateArtifactDownloadUrlDetails. + The tenancy `OCID`__ of the user initiating the download. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param compartment_id: The compartment_id of this GenerateArtifactDownloadUrlDetails. + :type: str + """ + self._compartment_id = compartment_id + @property def artifact_id(self): """ diff --git a/src/oci/os_management_hub/models/create_custom_software_source_details.py b/src/oci/os_management_hub/models/create_custom_software_source_details.py index ccd7558f9..e3a917b52 100644 --- a/src/oci/os_management_hub/models/create_custom_software_source_details.py +++ b/src/oci/os_management_hub/models/create_custom_software_source_details.py @@ -66,6 +66,10 @@ def __init__(self, **kwargs): The value to assign to the is_created_from_package_list property of this CreateCustomSoftwareSourceDetails. :type is_created_from_package_list: bool + :param is_latest_content_only: + The value to assign to the is_latest_content_only property of this CreateCustomSoftwareSourceDetails. + :type is_latest_content_only: bool + :param packages: The value to assign to the packages property of this CreateCustomSoftwareSourceDetails. :type packages: list[str] @@ -83,6 +87,7 @@ def __init__(self, **kwargs): 'is_automatically_updated': 'bool', 'is_auto_resolve_dependencies': 'bool', 'is_created_from_package_list': 'bool', + 'is_latest_content_only': 'bool', 'packages': 'list[str]' } @@ -98,6 +103,7 @@ def __init__(self, **kwargs): 'is_automatically_updated': 'isAutomaticallyUpdated', 'is_auto_resolve_dependencies': 'isAutoResolveDependencies', 'is_created_from_package_list': 'isCreatedFromPackageList', + 'is_latest_content_only': 'isLatestContentOnly', 'packages': 'packages' } @@ -112,6 +118,7 @@ def __init__(self, **kwargs): self._is_automatically_updated = None self._is_auto_resolve_dependencies = None self._is_created_from_package_list = None + self._is_latest_content_only = None self._packages = None self._software_source_type = 'CUSTOM' @@ -231,6 +238,40 @@ def is_created_from_package_list(self, is_created_from_package_list): """ self._is_created_from_package_list = is_created_from_package_list + @property + def is_latest_content_only(self): + """ + Gets the is_latest_content_only of this CreateCustomSoftwareSourceDetails. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :return: The is_latest_content_only of this CreateCustomSoftwareSourceDetails. + :rtype: bool + """ + return self._is_latest_content_only + + @is_latest_content_only.setter + def is_latest_content_only(self, is_latest_content_only): + """ + Sets the is_latest_content_only of this CreateCustomSoftwareSourceDetails. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :param is_latest_content_only: The is_latest_content_only of this CreateCustomSoftwareSourceDetails. + :type: bool + """ + self._is_latest_content_only = is_latest_content_only + @property def packages(self): """ diff --git a/src/oci/os_management_hub/models/create_versioned_custom_software_source_details.py b/src/oci/os_management_hub/models/create_versioned_custom_software_source_details.py index b3fd9bd31..acc68b438 100644 --- a/src/oci/os_management_hub/models/create_versioned_custom_software_source_details.py +++ b/src/oci/os_management_hub/models/create_versioned_custom_software_source_details.py @@ -66,6 +66,10 @@ def __init__(self, **kwargs): The value to assign to the is_created_from_package_list property of this CreateVersionedCustomSoftwareSourceDetails. :type is_created_from_package_list: bool + :param is_latest_content_only: + The value to assign to the is_latest_content_only property of this CreateVersionedCustomSoftwareSourceDetails. + :type is_latest_content_only: bool + :param packages: The value to assign to the packages property of this CreateVersionedCustomSoftwareSourceDetails. :type packages: list[str] @@ -83,6 +87,7 @@ def __init__(self, **kwargs): 'software_source_version': 'str', 'is_auto_resolve_dependencies': 'bool', 'is_created_from_package_list': 'bool', + 'is_latest_content_only': 'bool', 'packages': 'list[str]' } @@ -98,6 +103,7 @@ def __init__(self, **kwargs): 'software_source_version': 'softwareSourceVersion', 'is_auto_resolve_dependencies': 'isAutoResolveDependencies', 'is_created_from_package_list': 'isCreatedFromPackageList', + 'is_latest_content_only': 'isLatestContentOnly', 'packages': 'packages' } @@ -112,6 +118,7 @@ def __init__(self, **kwargs): self._software_source_version = None self._is_auto_resolve_dependencies = None self._is_created_from_package_list = None + self._is_latest_content_only = None self._packages = None self._software_source_type = 'VERSIONED' @@ -231,6 +238,40 @@ def is_created_from_package_list(self, is_created_from_package_list): """ self._is_created_from_package_list = is_created_from_package_list + @property + def is_latest_content_only(self): + """ + Gets the is_latest_content_only of this CreateVersionedCustomSoftwareSourceDetails. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :return: The is_latest_content_only of this CreateVersionedCustomSoftwareSourceDetails. + :rtype: bool + """ + return self._is_latest_content_only + + @is_latest_content_only.setter + def is_latest_content_only(self, is_latest_content_only): + """ + Sets the is_latest_content_only of this CreateVersionedCustomSoftwareSourceDetails. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :param is_latest_content_only: The is_latest_content_only of this CreateVersionedCustomSoftwareSourceDetails. + :type: bool + """ + self._is_latest_content_only = is_latest_content_only + @property def packages(self): """ diff --git a/src/oci/os_management_hub/models/custom_software_source.py b/src/oci/os_management_hub/models/custom_software_source.py index 755bc303f..19f9cd157 100644 --- a/src/oci/os_management_hub/models/custom_software_source.py +++ b/src/oci/os_management_hub/models/custom_software_source.py @@ -138,6 +138,10 @@ def __init__(self, **kwargs): The value to assign to the is_created_from_package_list property of this CustomSoftwareSource. :type is_created_from_package_list: bool + :param is_latest_content_only: + The value to assign to the is_latest_content_only property of this CustomSoftwareSource. + :type is_latest_content_only: bool + :param packages: The value to assign to the packages property of this CustomSoftwareSource. :type packages: list[str] @@ -171,6 +175,7 @@ def __init__(self, **kwargs): 'is_automatically_updated': 'bool', 'is_auto_resolve_dependencies': 'bool', 'is_created_from_package_list': 'bool', + 'is_latest_content_only': 'bool', 'packages': 'list[str]' } @@ -202,6 +207,7 @@ def __init__(self, **kwargs): 'is_automatically_updated': 'isAutomaticallyUpdated', 'is_auto_resolve_dependencies': 'isAutoResolveDependencies', 'is_created_from_package_list': 'isCreatedFromPackageList', + 'is_latest_content_only': 'isLatestContentOnly', 'packages': 'packages' } @@ -232,6 +238,7 @@ def __init__(self, **kwargs): self._is_automatically_updated = None self._is_auto_resolve_dependencies = None self._is_created_from_package_list = None + self._is_latest_content_only = None self._packages = None self._software_source_type = 'CUSTOM' @@ -351,6 +358,40 @@ def is_created_from_package_list(self, is_created_from_package_list): """ self._is_created_from_package_list = is_created_from_package_list + @property + def is_latest_content_only(self): + """ + Gets the is_latest_content_only of this CustomSoftwareSource. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :return: The is_latest_content_only of this CustomSoftwareSource. + :rtype: bool + """ + return self._is_latest_content_only + + @is_latest_content_only.setter + def is_latest_content_only(self, is_latest_content_only): + """ + Sets the is_latest_content_only of this CustomSoftwareSource. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :param is_latest_content_only: The is_latest_content_only of this CustomSoftwareSource. + :type: bool + """ + self._is_latest_content_only = is_latest_content_only + @property def packages(self): """ diff --git a/src/oci/os_management_hub/models/update_custom_software_source_details.py b/src/oci/os_management_hub/models/update_custom_software_source_details.py index 2f9fd429e..099c80ef1 100644 --- a/src/oci/os_management_hub/models/update_custom_software_source_details.py +++ b/src/oci/os_management_hub/models/update_custom_software_source_details.py @@ -62,6 +62,10 @@ def __init__(self, **kwargs): The value to assign to the is_auto_resolve_dependencies property of this UpdateCustomSoftwareSourceDetails. :type is_auto_resolve_dependencies: bool + :param is_latest_content_only: + The value to assign to the is_latest_content_only property of this UpdateCustomSoftwareSourceDetails. + :type is_latest_content_only: bool + """ self.swagger_types = { 'compartment_id': 'str', @@ -73,7 +77,8 @@ def __init__(self, **kwargs): 'vendor_software_sources': 'list[Id]', 'custom_software_source_filter': 'CustomSoftwareSourceFilter', 'is_automatically_updated': 'bool', - 'is_auto_resolve_dependencies': 'bool' + 'is_auto_resolve_dependencies': 'bool', + 'is_latest_content_only': 'bool' } self.attribute_map = { @@ -86,7 +91,8 @@ def __init__(self, **kwargs): 'vendor_software_sources': 'vendorSoftwareSources', 'custom_software_source_filter': 'customSoftwareSourceFilter', 'is_automatically_updated': 'isAutomaticallyUpdated', - 'is_auto_resolve_dependencies': 'isAutoResolveDependencies' + 'is_auto_resolve_dependencies': 'isAutoResolveDependencies', + 'is_latest_content_only': 'isLatestContentOnly' } self._compartment_id = None @@ -99,6 +105,7 @@ def __init__(self, **kwargs): self._custom_software_source_filter = None self._is_automatically_updated = None self._is_auto_resolve_dependencies = None + self._is_latest_content_only = None self._software_source_type = 'CUSTOM' @property @@ -193,6 +200,40 @@ def is_auto_resolve_dependencies(self, is_auto_resolve_dependencies): """ self._is_auto_resolve_dependencies = is_auto_resolve_dependencies + @property + def is_latest_content_only(self): + """ + Gets the is_latest_content_only of this UpdateCustomSoftwareSourceDetails. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :return: The is_latest_content_only of this UpdateCustomSoftwareSourceDetails. + :rtype: bool + """ + return self._is_latest_content_only + + @is_latest_content_only.setter + def is_latest_content_only(self, is_latest_content_only): + """ + Sets the is_latest_content_only of this UpdateCustomSoftwareSourceDetails. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :param is_latest_content_only: The is_latest_content_only of this UpdateCustomSoftwareSourceDetails. + :type: bool + """ + self._is_latest_content_only = is_latest_content_only + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/os_management_hub/models/versioned_custom_software_source.py b/src/oci/os_management_hub/models/versioned_custom_software_source.py index 81f9c9227..f57df992f 100644 --- a/src/oci/os_management_hub/models/versioned_custom_software_source.py +++ b/src/oci/os_management_hub/models/versioned_custom_software_source.py @@ -136,6 +136,10 @@ def __init__(self, **kwargs): The value to assign to the is_created_from_package_list property of this VersionedCustomSoftwareSource. :type is_created_from_package_list: bool + :param is_latest_content_only: + The value to assign to the is_latest_content_only property of this VersionedCustomSoftwareSource. + :type is_latest_content_only: bool + :param packages: The value to assign to the packages property of this VersionedCustomSoftwareSource. :type packages: list[str] @@ -169,6 +173,7 @@ def __init__(self, **kwargs): 'software_source_version': 'str', 'is_auto_resolve_dependencies': 'bool', 'is_created_from_package_list': 'bool', + 'is_latest_content_only': 'bool', 'packages': 'list[str]' } @@ -200,6 +205,7 @@ def __init__(self, **kwargs): 'software_source_version': 'softwareSourceVersion', 'is_auto_resolve_dependencies': 'isAutoResolveDependencies', 'is_created_from_package_list': 'isCreatedFromPackageList', + 'is_latest_content_only': 'isLatestContentOnly', 'packages': 'packages' } @@ -230,6 +236,7 @@ def __init__(self, **kwargs): self._software_source_version = None self._is_auto_resolve_dependencies = None self._is_created_from_package_list = None + self._is_latest_content_only = None self._packages = None self._software_source_type = 'VERSIONED' @@ -349,6 +356,40 @@ def is_created_from_package_list(self, is_created_from_package_list): """ self._is_created_from_package_list = is_created_from_package_list + @property + def is_latest_content_only(self): + """ + Gets the is_latest_content_only of this VersionedCustomSoftwareSource. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :return: The is_latest_content_only of this VersionedCustomSoftwareSource. + :rtype: bool + """ + return self._is_latest_content_only + + @is_latest_content_only.setter + def is_latest_content_only(self, is_latest_content_only): + """ + Sets the is_latest_content_only of this VersionedCustomSoftwareSource. + Indicates whether the software source will include only the latest versions of content from vendor software sources, while accounting for other constraints set in the custom or versioned custom software source (such as a package list or filters). + * For a module filter that does not specify a stream, this will include all available streams, and within each stream only the latest version of packages. + * For a module filter that does specify a stream, this will include only the latest version of packages for the specified stream. + * For a package filter that does not specify a version, this will include only the latest available version of the package. + * For a package filter that does specify a version, this will include only the specified version of the package (the isLatestContentOnly attribute is ignored). + * For a package list, this will include only the specified version of packages and modules in the list (the isLatestContentOnly attribute is ignored). + + + :param is_latest_content_only: The is_latest_content_only of this VersionedCustomSoftwareSource. + :type: bool + """ + self._is_latest_content_only = is_latest_content_only + @property def packages(self): """ diff --git a/src/oci/os_management_hub/software_source_client.py b/src/oci/os_management_hub/software_source_client.py index cde36fecb..b55d5b8a0 100644 --- a/src/oci/os_management_hub/software_source_client.py +++ b/src/oci/os_management_hub/software_source_client.py @@ -465,7 +465,7 @@ def change_software_source_compartment(self, software_source_id, change_software def create_entitlement(self, create_entitlement_details, **kwargs): """ - Registers the necessary entitlement credentials for OS vendor software sources. + Registers the necessary entitlement credentials for OS vendor software sources for a tenancy. :param oci.os_management_hub.models.CreateEntitlementDetails create_entitlement_details: (required) diff --git a/src/oci/psql/models/__init__.py b/src/oci/psql/models/__init__.py index e3dd1feff..75ed75f48 100644 --- a/src/oci/psql/models/__init__.py +++ b/src/oci/psql/models/__init__.py @@ -64,6 +64,8 @@ from .restart_db_instance_in_db_system_details import RestartDbInstanceInDbSystemDetails from .restore_db_system_details import RestoreDbSystemDetails from .shape_collection import ShapeCollection +from .shape_memory_options import ShapeMemoryOptions +from .shape_ocpu_options import ShapeOcpuOptions from .shape_summary import ShapeSummary from .source_details import SourceDetails from .storage_details import StorageDetails @@ -72,6 +74,7 @@ from .update_db_config_params import UpdateDbConfigParams from .update_db_system_db_instance_details import UpdateDbSystemDbInstanceDetails from .update_db_system_details import UpdateDbSystemDetails +from .update_network_details import UpdateNetworkDetails from .update_storage_details_params import UpdateStorageDetailsParams from .vault_secret_password_details import VaultSecretPasswordDetails from .weekly_backup_policy import WeeklyBackupPolicy @@ -144,6 +147,8 @@ "RestartDbInstanceInDbSystemDetails": RestartDbInstanceInDbSystemDetails, "RestoreDbSystemDetails": RestoreDbSystemDetails, "ShapeCollection": ShapeCollection, + "ShapeMemoryOptions": ShapeMemoryOptions, + "ShapeOcpuOptions": ShapeOcpuOptions, "ShapeSummary": ShapeSummary, "SourceDetails": SourceDetails, "StorageDetails": StorageDetails, @@ -152,6 +157,7 @@ "UpdateDbConfigParams": UpdateDbConfigParams, "UpdateDbSystemDbInstanceDetails": UpdateDbSystemDbInstanceDetails, "UpdateDbSystemDetails": UpdateDbSystemDetails, + "UpdateNetworkDetails": UpdateNetworkDetails, "UpdateStorageDetailsParams": UpdateStorageDetailsParams, "VaultSecretPasswordDetails": VaultSecretPasswordDetails, "WeeklyBackupPolicy": WeeklyBackupPolicy, diff --git a/src/oci/psql/models/backup.py b/src/oci/psql/models/backup.py index 89d14ae0f..40476cf23 100644 --- a/src/oci/psql/models/backup.py +++ b/src/oci/psql/models/backup.py @@ -324,7 +324,7 @@ def source_type(self, source_type): def time_created(self): """ **[Required]** Gets the time_created of this Backup. - The date and time the backup was created, expressed in + The date and time the backup request was received, expressed in `RFC 3339`__ timestamp format. Example: `2016-08-25T21:10:29.600Z` @@ -341,7 +341,7 @@ def time_created(self): def time_created(self, time_created): """ Sets the time_created of this Backup. - The date and time the backup was created, expressed in + The date and time the backup request was received, expressed in `RFC 3339`__ timestamp format. Example: `2016-08-25T21:10:29.600Z` diff --git a/src/oci/psql/models/backup_summary.py b/src/oci/psql/models/backup_summary.py index 318b9b545..c1fc4b16f 100644 --- a/src/oci/psql/models/backup_summary.py +++ b/src/oci/psql/models/backup_summary.py @@ -322,7 +322,7 @@ def lifecycle_details(self, lifecycle_details): def source_type(self): """ Gets the source_type of this BackupSummary. - Specifies whether the backup was created manually, or by a management policy. + Specifies whether the backup was created manually, taken on schedule defined in the a backup policy, or copied from the remote location. :return: The source_type of this BackupSummary. @@ -334,7 +334,7 @@ def source_type(self): def source_type(self, source_type): """ Sets the source_type of this BackupSummary. - Specifies whether the backup was created manually, or by a management policy. + Specifies whether the backup was created manually, taken on schedule defined in the a backup policy, or copied from the remote location. :param source_type: The source_type of this BackupSummary. diff --git a/src/oci/psql/models/configuration.py b/src/oci/psql/models/configuration.py index d34042bf6..7f0d0efb5 100644 --- a/src/oci/psql/models/configuration.py +++ b/src/oci/psql/models/configuration.py @@ -31,6 +31,14 @@ class Configuration(object): #: This constant has a value of "FAILED" LIFECYCLE_STATE_FAILED = "FAILED" + #: A constant which can be used with the config_type property of a Configuration. + #: This constant has a value of "DEFAULT" + CONFIG_TYPE_DEFAULT = "DEFAULT" + + #: A constant which can be used with the config_type property of a Configuration. + #: This constant has a value of "CUSTOM" + CONFIG_TYPE_CUSTOM = "CUSTOM" + def __init__(self, **kwargs): """ Initializes a new Configuration object with values from keyword arguments. @@ -66,10 +74,24 @@ def __init__(self, **kwargs): The value to assign to the lifecycle_details property of this Configuration. :type lifecycle_details: str + :param db_version: + The value to assign to the db_version property of this Configuration. + :type db_version: str + + :param config_type: + The value to assign to the config_type property of this Configuration. + Allowed values for this property are: "DEFAULT", "CUSTOM", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + :type config_type: str + :param shape: The value to assign to the shape property of this Configuration. :type shape: str + :param is_flexible: + The value to assign to the is_flexible property of this Configuration. + :type is_flexible: bool + :param instance_ocpu_count: The value to assign to the instance_ocpu_count property of this Configuration. :type instance_ocpu_count: int @@ -78,10 +100,6 @@ def __init__(self, **kwargs): The value to assign to the instance_memory_size_in_gbs property of this Configuration. :type instance_memory_size_in_gbs: int - :param db_version: - The value to assign to the db_version property of this Configuration. - :type db_version: str - :param configuration_details: The value to assign to the configuration_details property of this Configuration. :type configuration_details: oci.psql.models.ConfigurationDetails @@ -107,10 +125,12 @@ def __init__(self, **kwargs): 'time_created': 'datetime', 'lifecycle_state': 'str', 'lifecycle_details': 'str', + 'db_version': 'str', + 'config_type': 'str', 'shape': 'str', + 'is_flexible': 'bool', 'instance_ocpu_count': 'int', 'instance_memory_size_in_gbs': 'int', - 'db_version': 'str', 'configuration_details': 'ConfigurationDetails', 'freeform_tags': 'dict(str, str)', 'defined_tags': 'dict(str, dict(str, object))', @@ -125,10 +145,12 @@ def __init__(self, **kwargs): 'time_created': 'timeCreated', 'lifecycle_state': 'lifecycleState', 'lifecycle_details': 'lifecycleDetails', + 'db_version': 'dbVersion', + 'config_type': 'configType', 'shape': 'shape', + 'is_flexible': 'isFlexible', 'instance_ocpu_count': 'instanceOcpuCount', 'instance_memory_size_in_gbs': 'instanceMemorySizeInGBs', - 'db_version': 'dbVersion', 'configuration_details': 'configurationDetails', 'freeform_tags': 'freeformTags', 'defined_tags': 'definedTags', @@ -142,10 +164,12 @@ def __init__(self, **kwargs): self._time_created = None self._lifecycle_state = None self._lifecycle_details = None + self._db_version = None + self._config_type = None self._shape = None + self._is_flexible = None self._instance_ocpu_count = None self._instance_memory_size_in_gbs = None - self._db_version = None self._configuration_details = None self._freeform_tags = None self._defined_tags = None @@ -339,6 +363,60 @@ def lifecycle_details(self, lifecycle_details): """ self._lifecycle_details = lifecycle_details + @property + def db_version(self): + """ + **[Required]** Gets the db_version of this Configuration. + Version of the PostgreSQL database. + + + :return: The db_version of this Configuration. + :rtype: str + """ + return self._db_version + + @db_version.setter + def db_version(self, db_version): + """ + Sets the db_version of this Configuration. + Version of the PostgreSQL database. + + + :param db_version: The db_version of this Configuration. + :type: str + """ + self._db_version = db_version + + @property + def config_type(self): + """ + Gets the config_type of this Configuration. + The type of configuration. Either user-created or a default configuration. + + Allowed values for this property are: "DEFAULT", "CUSTOM", 'UNKNOWN_ENUM_VALUE'. + Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. + + + :return: The config_type of this Configuration. + :rtype: str + """ + return self._config_type + + @config_type.setter + def config_type(self, config_type): + """ + Sets the config_type of this Configuration. + The type of configuration. Either user-created or a default configuration. + + + :param config_type: The config_type of this Configuration. + :type: str + """ + allowed_values = ["DEFAULT", "CUSTOM"] + if not value_allowed_none_or_none_sentinel(config_type, allowed_values): + config_type = 'UNKNOWN_ENUM_VALUE' + self._config_type = config_type + @property def shape(self): """ @@ -365,12 +443,38 @@ def shape(self, shape): """ self._shape = shape + @property + def is_flexible(self): + """ + Gets the is_flexible of this Configuration. + Whether the configuration supports flexible shapes. + + + :return: The is_flexible of this Configuration. + :rtype: bool + """ + return self._is_flexible + + @is_flexible.setter + def is_flexible(self, is_flexible): + """ + Sets the is_flexible of this Configuration. + Whether the configuration supports flexible shapes. + + + :param is_flexible: The is_flexible of this Configuration. + :type: bool + """ + self._is_flexible = is_flexible + @property def instance_ocpu_count(self): """ **[Required]** Gets the instance_ocpu_count of this Configuration. CPU core count. + It's value is set to 0 if configuration is for a flexible shape. + :return: The instance_ocpu_count of this Configuration. :rtype: int @@ -383,6 +487,8 @@ def instance_ocpu_count(self, instance_ocpu_count): Sets the instance_ocpu_count of this Configuration. CPU core count. + It's value is set to 0 if configuration is for a flexible shape. + :param instance_ocpu_count: The instance_ocpu_count of this Configuration. :type: int @@ -395,6 +501,8 @@ def instance_memory_size_in_gbs(self): **[Required]** Gets the instance_memory_size_in_gbs of this Configuration. Memory size in gigabytes with 1GB increment. + It's value is set to 0 if configuration is for a flexible shape. + :return: The instance_memory_size_in_gbs of this Configuration. :rtype: int @@ -407,36 +515,14 @@ def instance_memory_size_in_gbs(self, instance_memory_size_in_gbs): Sets the instance_memory_size_in_gbs of this Configuration. Memory size in gigabytes with 1GB increment. + It's value is set to 0 if configuration is for a flexible shape. + :param instance_memory_size_in_gbs: The instance_memory_size_in_gbs of this Configuration. :type: int """ self._instance_memory_size_in_gbs = instance_memory_size_in_gbs - @property - def db_version(self): - """ - **[Required]** Gets the db_version of this Configuration. - Version of the PostgreSQL database. - - - :return: The db_version of this Configuration. - :rtype: str - """ - return self._db_version - - @db_version.setter - def db_version(self, db_version): - """ - Sets the db_version of this Configuration. - Version of the PostgreSQL database. - - - :param db_version: The db_version of this Configuration. - :type: str - """ - self._db_version = db_version - @property def configuration_details(self): """ diff --git a/src/oci/psql/models/configuration_summary.py b/src/oci/psql/models/configuration_summary.py index 50d634bf4..1398bd72c 100644 --- a/src/oci/psql/models/configuration_summary.py +++ b/src/oci/psql/models/configuration_summary.py @@ -44,13 +44,17 @@ def __init__(self, **kwargs): The value to assign to the lifecycle_details property of this ConfigurationSummary. :type lifecycle_details: str + :param db_version: + The value to assign to the db_version property of this ConfigurationSummary. + :type db_version: str + :param shape: The value to assign to the shape property of this ConfigurationSummary. :type shape: str - :param db_version: - The value to assign to the db_version property of this ConfigurationSummary. - :type db_version: str + :param is_flexible: + The value to assign to the is_flexible property of this ConfigurationSummary. + :type is_flexible: bool :param instance_ocpu_count: The value to assign to the instance_ocpu_count property of this ConfigurationSummary. @@ -80,8 +84,9 @@ def __init__(self, **kwargs): 'time_created': 'datetime', 'lifecycle_state': 'str', 'lifecycle_details': 'str', - 'shape': 'str', 'db_version': 'str', + 'shape': 'str', + 'is_flexible': 'bool', 'instance_ocpu_count': 'int', 'instance_memory_size_in_gbs': 'int', 'freeform_tags': 'dict(str, str)', @@ -96,8 +101,9 @@ def __init__(self, **kwargs): 'time_created': 'timeCreated', 'lifecycle_state': 'lifecycleState', 'lifecycle_details': 'lifecycleDetails', - 'shape': 'shape', 'db_version': 'dbVersion', + 'shape': 'shape', + 'is_flexible': 'isFlexible', 'instance_ocpu_count': 'instanceOcpuCount', 'instance_memory_size_in_gbs': 'instanceMemorySizeInGBs', 'freeform_tags': 'freeformTags', @@ -111,8 +117,9 @@ def __init__(self, **kwargs): self._time_created = None self._lifecycle_state = None self._lifecycle_details = None - self._shape = None self._db_version = None + self._shape = None + self._is_flexible = None self._instance_ocpu_count = None self._instance_memory_size_in_gbs = None self._freeform_tags = None @@ -281,6 +288,30 @@ def lifecycle_details(self, lifecycle_details): """ self._lifecycle_details = lifecycle_details + @property + def db_version(self): + """ + **[Required]** Gets the db_version of this ConfigurationSummary. + Version of the PostgreSQL database. + + + :return: The db_version of this ConfigurationSummary. + :rtype: str + """ + return self._db_version + + @db_version.setter + def db_version(self, db_version): + """ + Sets the db_version of this ConfigurationSummary. + Version of the PostgreSQL database. + + + :param db_version: The db_version of this ConfigurationSummary. + :type: str + """ + self._db_version = db_version + @property def shape(self): """ @@ -308,28 +339,28 @@ def shape(self, shape): self._shape = shape @property - def db_version(self): + def is_flexible(self): """ - **[Required]** Gets the db_version of this ConfigurationSummary. - Version of the PostgreSQL database. + Gets the is_flexible of this ConfigurationSummary. + Whether the configuration supports flexible shapes. - :return: The db_version of this ConfigurationSummary. - :rtype: str + :return: The is_flexible of this ConfigurationSummary. + :rtype: bool """ - return self._db_version + return self._is_flexible - @db_version.setter - def db_version(self, db_version): + @is_flexible.setter + def is_flexible(self, is_flexible): """ - Sets the db_version of this ConfigurationSummary. - Version of the PostgreSQL database. + Sets the is_flexible of this ConfigurationSummary. + Whether the configuration supports flexible shapes. - :param db_version: The db_version of this ConfigurationSummary. - :type: str + :param is_flexible: The is_flexible of this ConfigurationSummary. + :type: bool """ - self._db_version = db_version + self._is_flexible = is_flexible @property def instance_ocpu_count(self): @@ -337,6 +368,8 @@ def instance_ocpu_count(self): **[Required]** Gets the instance_ocpu_count of this ConfigurationSummary. CPU core count. + It's value is set to 0 if configuration is for a flexible shape. + :return: The instance_ocpu_count of this ConfigurationSummary. :rtype: int @@ -349,6 +382,8 @@ def instance_ocpu_count(self, instance_ocpu_count): Sets the instance_ocpu_count of this ConfigurationSummary. CPU core count. + It's value is set to 0 if configuration is for a flexible shape. + :param instance_ocpu_count: The instance_ocpu_count of this ConfigurationSummary. :type: int @@ -361,6 +396,8 @@ def instance_memory_size_in_gbs(self): **[Required]** Gets the instance_memory_size_in_gbs of this ConfigurationSummary. Memory size in gigabytes with 1GB increment. + It's value is set to 0 if configuration is for a flexible shape. + :return: The instance_memory_size_in_gbs of this ConfigurationSummary. :rtype: int @@ -373,6 +410,8 @@ def instance_memory_size_in_gbs(self, instance_memory_size_in_gbs): Sets the instance_memory_size_in_gbs of this ConfigurationSummary. Memory size in gigabytes with 1GB increment. + It's value is set to 0 if configuration is for a flexible shape. + :param instance_memory_size_in_gbs: The instance_memory_size_in_gbs of this ConfigurationSummary. :type: int diff --git a/src/oci/psql/models/create_configuration_details.py b/src/oci/psql/models/create_configuration_details.py index 054e7d2d5..31ed3d29c 100644 --- a/src/oci/psql/models/create_configuration_details.py +++ b/src/oci/psql/models/create_configuration_details.py @@ -32,13 +32,17 @@ def __init__(self, **kwargs): The value to assign to the description property of this CreateConfigurationDetails. :type description: str + :param db_version: + The value to assign to the db_version property of this CreateConfigurationDetails. + :type db_version: str + :param shape: The value to assign to the shape property of this CreateConfigurationDetails. :type shape: str - :param db_version: - The value to assign to the db_version property of this CreateConfigurationDetails. - :type db_version: str + :param is_flexible: + The value to assign to the is_flexible property of this CreateConfigurationDetails. + :type is_flexible: bool :param instance_ocpu_count: The value to assign to the instance_ocpu_count property of this CreateConfigurationDetails. @@ -69,8 +73,9 @@ def __init__(self, **kwargs): 'display_name': 'str', 'compartment_id': 'str', 'description': 'str', - 'shape': 'str', 'db_version': 'str', + 'shape': 'str', + 'is_flexible': 'bool', 'instance_ocpu_count': 'int', 'instance_memory_size_in_gbs': 'int', 'db_configuration_overrides': 'DbConfigurationOverrideCollection', @@ -83,8 +88,9 @@ def __init__(self, **kwargs): 'display_name': 'displayName', 'compartment_id': 'compartmentId', 'description': 'description', - 'shape': 'shape', 'db_version': 'dbVersion', + 'shape': 'shape', + 'is_flexible': 'isFlexible', 'instance_ocpu_count': 'instanceOcpuCount', 'instance_memory_size_in_gbs': 'instanceMemorySizeInGBs', 'db_configuration_overrides': 'dbConfigurationOverrides', @@ -96,8 +102,9 @@ def __init__(self, **kwargs): self._display_name = None self._compartment_id = None self._description = None - self._shape = None self._db_version = None + self._shape = None + self._is_flexible = None self._instance_ocpu_count = None self._instance_memory_size_in_gbs = None self._db_configuration_overrides = None @@ -181,6 +188,30 @@ def description(self, description): """ self._description = description + @property + def db_version(self): + """ + **[Required]** Gets the db_version of this CreateConfigurationDetails. + Version of the PostgreSQL database. + + + :return: The db_version of this CreateConfigurationDetails. + :rtype: str + """ + return self._db_version + + @db_version.setter + def db_version(self, db_version): + """ + Sets the db_version of this CreateConfigurationDetails. + Version of the PostgreSQL database. + + + :param db_version: The db_version of this CreateConfigurationDetails. + :type: str + """ + self._db_version = db_version + @property def shape(self): """ @@ -208,35 +239,37 @@ def shape(self, shape): self._shape = shape @property - def db_version(self): + def is_flexible(self): """ - **[Required]** Gets the db_version of this CreateConfigurationDetails. - Version of the PostgreSQL database. + Gets the is_flexible of this CreateConfigurationDetails. + Whether the configuration supports flexible shapes. - :return: The db_version of this CreateConfigurationDetails. - :rtype: str + :return: The is_flexible of this CreateConfigurationDetails. + :rtype: bool """ - return self._db_version + return self._is_flexible - @db_version.setter - def db_version(self, db_version): + @is_flexible.setter + def is_flexible(self, is_flexible): """ - Sets the db_version of this CreateConfigurationDetails. - Version of the PostgreSQL database. + Sets the is_flexible of this CreateConfigurationDetails. + Whether the configuration supports flexible shapes. - :param db_version: The db_version of this CreateConfigurationDetails. - :type: str + :param is_flexible: The is_flexible of this CreateConfigurationDetails. + :type: bool """ - self._db_version = db_version + self._is_flexible = is_flexible @property def instance_ocpu_count(self): """ - **[Required]** Gets the instance_ocpu_count of this CreateConfigurationDetails. + Gets the instance_ocpu_count of this CreateConfigurationDetails. CPU core count. + Skip or set it's value to 0 if configuration is for a flexible shape. + :return: The instance_ocpu_count of this CreateConfigurationDetails. :rtype: int @@ -249,6 +282,8 @@ def instance_ocpu_count(self, instance_ocpu_count): Sets the instance_ocpu_count of this CreateConfigurationDetails. CPU core count. + Skip or set it's value to 0 if configuration is for a flexible shape. + :param instance_ocpu_count: The instance_ocpu_count of this CreateConfigurationDetails. :type: int @@ -258,9 +293,11 @@ def instance_ocpu_count(self, instance_ocpu_count): @property def instance_memory_size_in_gbs(self): """ - **[Required]** Gets the instance_memory_size_in_gbs of this CreateConfigurationDetails. + Gets the instance_memory_size_in_gbs of this CreateConfigurationDetails. Memory size in gigabytes with 1GB increment. + Skip or set it's value to 0 if configuration is for a flexible shape. + :return: The instance_memory_size_in_gbs of this CreateConfigurationDetails. :rtype: int @@ -273,6 +310,8 @@ def instance_memory_size_in_gbs(self, instance_memory_size_in_gbs): Sets the instance_memory_size_in_gbs of this CreateConfigurationDetails. Memory size in gigabytes with 1GB increment. + Skip or set it's value to 0 if configuration is for a flexible shape. + :param instance_memory_size_in_gbs: The instance_memory_size_in_gbs of this CreateConfigurationDetails. :type: int diff --git a/src/oci/psql/models/create_db_system_details.py b/src/oci/psql/models/create_db_system_details.py index f87926c95..1adb54e70 100644 --- a/src/oci/psql/models/create_db_system_details.py +++ b/src/oci/psql/models/create_db_system_details.py @@ -453,7 +453,7 @@ def instances_details(self, instances_details): @property def credentials(self): """ - Gets the credentials of this CreateDbSystemDetails. + **[Required]** Gets the credentials of this CreateDbSystemDetails. :return: The credentials of this CreateDbSystemDetails. :rtype: oci.psql.models.Credentials diff --git a/src/oci/psql/models/default_configuration.py b/src/oci/psql/models/default_configuration.py index 85246e151..9c45a9855 100644 --- a/src/oci/psql/models/default_configuration.py +++ b/src/oci/psql/models/default_configuration.py @@ -66,10 +66,18 @@ def __init__(self, **kwargs): The value to assign to the lifecycle_details property of this DefaultConfiguration. :type lifecycle_details: str + :param db_version: + The value to assign to the db_version property of this DefaultConfiguration. + :type db_version: str + :param shape: The value to assign to the shape property of this DefaultConfiguration. :type shape: str + :param is_flexible: + The value to assign to the is_flexible property of this DefaultConfiguration. + :type is_flexible: bool + :param instance_ocpu_count: The value to assign to the instance_ocpu_count property of this DefaultConfiguration. :type instance_ocpu_count: int @@ -78,10 +86,6 @@ def __init__(self, **kwargs): The value to assign to the instance_memory_size_in_gbs property of this DefaultConfiguration. :type instance_memory_size_in_gbs: int - :param db_version: - The value to assign to the db_version property of this DefaultConfiguration. - :type db_version: str - :param configuration_details: The value to assign to the configuration_details property of this DefaultConfiguration. :type configuration_details: oci.psql.models.DefaultConfigurationDetails @@ -94,10 +98,11 @@ def __init__(self, **kwargs): 'time_created': 'datetime', 'lifecycle_state': 'str', 'lifecycle_details': 'str', + 'db_version': 'str', 'shape': 'str', + 'is_flexible': 'bool', 'instance_ocpu_count': 'int', 'instance_memory_size_in_gbs': 'int', - 'db_version': 'str', 'configuration_details': 'DefaultConfigurationDetails' } @@ -108,10 +113,11 @@ def __init__(self, **kwargs): 'time_created': 'timeCreated', 'lifecycle_state': 'lifecycleState', 'lifecycle_details': 'lifecycleDetails', + 'db_version': 'dbVersion', 'shape': 'shape', + 'is_flexible': 'isFlexible', 'instance_ocpu_count': 'instanceOcpuCount', 'instance_memory_size_in_gbs': 'instanceMemorySizeInGBs', - 'db_version': 'dbVersion', 'configuration_details': 'configurationDetails' } @@ -121,10 +127,11 @@ def __init__(self, **kwargs): self._time_created = None self._lifecycle_state = None self._lifecycle_details = None + self._db_version = None self._shape = None + self._is_flexible = None self._instance_ocpu_count = None self._instance_memory_size_in_gbs = None - self._db_version = None self._configuration_details = None @property @@ -287,6 +294,30 @@ def lifecycle_details(self, lifecycle_details): """ self._lifecycle_details = lifecycle_details + @property + def db_version(self): + """ + **[Required]** Gets the db_version of this DefaultConfiguration. + Version of the PostgreSQL database. + + + :return: The db_version of this DefaultConfiguration. + :rtype: str + """ + return self._db_version + + @db_version.setter + def db_version(self, db_version): + """ + Sets the db_version of this DefaultConfiguration. + Version of the PostgreSQL database. + + + :param db_version: The db_version of this DefaultConfiguration. + :type: str + """ + self._db_version = db_version + @property def shape(self): """ @@ -313,11 +344,37 @@ def shape(self, shape): """ self._shape = shape + @property + def is_flexible(self): + """ + Gets the is_flexible of this DefaultConfiguration. + True if the configuration supports flexible shapes, false otherwise. + + + :return: The is_flexible of this DefaultConfiguration. + :rtype: bool + """ + return self._is_flexible + + @is_flexible.setter + def is_flexible(self, is_flexible): + """ + Sets the is_flexible of this DefaultConfiguration. + True if the configuration supports flexible shapes, false otherwise. + + + :param is_flexible: The is_flexible of this DefaultConfiguration. + :type: bool + """ + self._is_flexible = is_flexible + @property def instance_ocpu_count(self): """ **[Required]** Gets the instance_ocpu_count of this DefaultConfiguration. - CPU core count. Minimum value is 1. + CPU core count. + + Its value is set to 0 if configuration is for a flexible shape. :return: The instance_ocpu_count of this DefaultConfiguration. @@ -329,7 +386,9 @@ def instance_ocpu_count(self): def instance_ocpu_count(self, instance_ocpu_count): """ Sets the instance_ocpu_count of this DefaultConfiguration. - CPU core count. Minimum value is 1. + CPU core count. + + Its value is set to 0 if configuration is for a flexible shape. :param instance_ocpu_count: The instance_ocpu_count of this DefaultConfiguration. @@ -343,6 +402,8 @@ def instance_memory_size_in_gbs(self): **[Required]** Gets the instance_memory_size_in_gbs of this DefaultConfiguration. Memory size in gigabytes with 1GB increment. + Its value is set to 0 if configuration is for a flexible shape. + :return: The instance_memory_size_in_gbs of this DefaultConfiguration. :rtype: int @@ -355,36 +416,14 @@ def instance_memory_size_in_gbs(self, instance_memory_size_in_gbs): Sets the instance_memory_size_in_gbs of this DefaultConfiguration. Memory size in gigabytes with 1GB increment. + Its value is set to 0 if configuration is for a flexible shape. + :param instance_memory_size_in_gbs: The instance_memory_size_in_gbs of this DefaultConfiguration. :type: int """ self._instance_memory_size_in_gbs = instance_memory_size_in_gbs - @property - def db_version(self): - """ - **[Required]** Gets the db_version of this DefaultConfiguration. - Version of the PostgreSQL database. - - - :return: The db_version of this DefaultConfiguration. - :rtype: str - """ - return self._db_version - - @db_version.setter - def db_version(self, db_version): - """ - Sets the db_version of this DefaultConfiguration. - Version of the PostgreSQL database. - - - :param db_version: The db_version of this DefaultConfiguration. - :type: str - """ - self._db_version = db_version - @property def configuration_details(self): """ diff --git a/src/oci/psql/models/default_configuration_summary.py b/src/oci/psql/models/default_configuration_summary.py index 79a9c721c..044f15afa 100644 --- a/src/oci/psql/models/default_configuration_summary.py +++ b/src/oci/psql/models/default_configuration_summary.py @@ -40,13 +40,17 @@ def __init__(self, **kwargs): The value to assign to the lifecycle_details property of this DefaultConfigurationSummary. :type lifecycle_details: str + :param db_version: + The value to assign to the db_version property of this DefaultConfigurationSummary. + :type db_version: str + :param shape: The value to assign to the shape property of this DefaultConfigurationSummary. :type shape: str - :param db_version: - The value to assign to the db_version property of this DefaultConfigurationSummary. - :type db_version: str + :param is_flexible: + The value to assign to the is_flexible property of this DefaultConfigurationSummary. + :type is_flexible: bool :param instance_ocpu_count: The value to assign to the instance_ocpu_count property of this DefaultConfigurationSummary. @@ -63,8 +67,9 @@ def __init__(self, **kwargs): 'time_created': 'datetime', 'lifecycle_state': 'str', 'lifecycle_details': 'str', - 'shape': 'str', 'db_version': 'str', + 'shape': 'str', + 'is_flexible': 'bool', 'instance_ocpu_count': 'int', 'instance_memory_size_in_gbs': 'int' } @@ -75,8 +80,9 @@ def __init__(self, **kwargs): 'time_created': 'timeCreated', 'lifecycle_state': 'lifecycleState', 'lifecycle_details': 'lifecycleDetails', - 'shape': 'shape', 'db_version': 'dbVersion', + 'shape': 'shape', + 'is_flexible': 'isFlexible', 'instance_ocpu_count': 'instanceOcpuCount', 'instance_memory_size_in_gbs': 'instanceMemorySizeInGBs' } @@ -86,8 +92,9 @@ def __init__(self, **kwargs): self._time_created = None self._lifecycle_state = None self._lifecycle_details = None - self._shape = None self._db_version = None + self._shape = None + self._is_flexible = None self._instance_ocpu_count = None self._instance_memory_size_in_gbs = None @@ -221,6 +228,30 @@ def lifecycle_details(self, lifecycle_details): """ self._lifecycle_details = lifecycle_details + @property + def db_version(self): + """ + **[Required]** Gets the db_version of this DefaultConfigurationSummary. + Version of the PostgreSQL database. + + + :return: The db_version of this DefaultConfigurationSummary. + :rtype: str + """ + return self._db_version + + @db_version.setter + def db_version(self, db_version): + """ + Sets the db_version of this DefaultConfigurationSummary. + Version of the PostgreSQL database. + + + :param db_version: The db_version of this DefaultConfigurationSummary. + :type: str + """ + self._db_version = db_version + @property def shape(self): """ @@ -248,34 +279,36 @@ def shape(self, shape): self._shape = shape @property - def db_version(self): + def is_flexible(self): """ - **[Required]** Gets the db_version of this DefaultConfigurationSummary. - Version of the PostgreSQL database. + Gets the is_flexible of this DefaultConfigurationSummary. + True if the configuration supports flexible shapes, false otherwise. - :return: The db_version of this DefaultConfigurationSummary. - :rtype: str + :return: The is_flexible of this DefaultConfigurationSummary. + :rtype: bool """ - return self._db_version + return self._is_flexible - @db_version.setter - def db_version(self, db_version): + @is_flexible.setter + def is_flexible(self, is_flexible): """ - Sets the db_version of this DefaultConfigurationSummary. - Version of the PostgreSQL database. + Sets the is_flexible of this DefaultConfigurationSummary. + True if the configuration supports flexible shapes, false otherwise. - :param db_version: The db_version of this DefaultConfigurationSummary. - :type: str + :param is_flexible: The is_flexible of this DefaultConfigurationSummary. + :type: bool """ - self._db_version = db_version + self._is_flexible = is_flexible @property def instance_ocpu_count(self): """ **[Required]** Gets the instance_ocpu_count of this DefaultConfigurationSummary. - CPU core count. Minimum value is 1. + CPU core count. + + It's value is set to 0 if configuration is for a flexible shape. :return: The instance_ocpu_count of this DefaultConfigurationSummary. @@ -287,7 +320,9 @@ def instance_ocpu_count(self): def instance_ocpu_count(self, instance_ocpu_count): """ Sets the instance_ocpu_count of this DefaultConfigurationSummary. - CPU core count. Minimum value is 1. + CPU core count. + + It's value is set to 0 if configuration is for a flexible shape. :param instance_ocpu_count: The instance_ocpu_count of this DefaultConfigurationSummary. @@ -301,6 +336,8 @@ def instance_memory_size_in_gbs(self): **[Required]** Gets the instance_memory_size_in_gbs of this DefaultConfigurationSummary. Memory size in gigabytes with 1GB increment. + It's value is set to 0 if configuration is for a flexible shape. + :return: The instance_memory_size_in_gbs of this DefaultConfigurationSummary. :rtype: int @@ -313,6 +350,8 @@ def instance_memory_size_in_gbs(self, instance_memory_size_in_gbs): Sets the instance_memory_size_in_gbs of this DefaultConfigurationSummary. Memory size in gigabytes with 1GB increment. + It's value is set to 0 if configuration is for a flexible shape. + :param instance_memory_size_in_gbs: The instance_memory_size_in_gbs of this DefaultConfigurationSummary. :type: int diff --git a/src/oci/psql/models/management_policy_details.py b/src/oci/psql/models/management_policy_details.py index c2fff5cf6..48be8dce0 100644 --- a/src/oci/psql/models/management_policy_details.py +++ b/src/oci/psql/models/management_policy_details.py @@ -46,7 +46,11 @@ def __init__(self, **kwargs): def maintenance_window_start(self): """ Gets the maintenance_window_start of this ManagementPolicyDetails. - The start of the maintenance window. + The start of the maintenance window in UTC. + + This string is of the format: \"{day-of-week} {time-of-day}\". + \"{day-of-week}\" is a case-insensitive string like \"mon\", \"tue\", &c. + \"{time-of-day}\" is the \"Time\" portion of an RFC3339-formatted timestamp. Any second or sub-second time data will be truncated to zero. :return: The maintenance_window_start of this ManagementPolicyDetails. @@ -58,7 +62,11 @@ def maintenance_window_start(self): def maintenance_window_start(self, maintenance_window_start): """ Sets the maintenance_window_start of this ManagementPolicyDetails. - The start of the maintenance window. + The start of the maintenance window in UTC. + + This string is of the format: \"{day-of-week} {time-of-day}\". + \"{day-of-week}\" is a case-insensitive string like \"mon\", \"tue\", &c. + \"{time-of-day}\" is the \"Time\" portion of an RFC3339-formatted timestamp. Any second or sub-second time data will be truncated to zero. :param maintenance_window_start: The maintenance_window_start of this ManagementPolicyDetails. diff --git a/src/oci/psql/models/shape_memory_options.py b/src/oci/psql/models/shape_memory_options.py new file mode 100644 index 000000000..cf187b788 --- /dev/null +++ b/src/oci/psql/models/shape_memory_options.py @@ -0,0 +1,196 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20220915 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ShapeMemoryOptions(object): + """ + Options for the the shape memory + """ + + def __init__(self, **kwargs): + """ + Initializes a new ShapeMemoryOptions object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param default_per_ocpu_in_gbs: + The value to assign to the default_per_ocpu_in_gbs property of this ShapeMemoryOptions. + :type default_per_ocpu_in_gbs: int + + :param min_in_gbs: + The value to assign to the min_in_gbs property of this ShapeMemoryOptions. + :type min_in_gbs: int + + :param min_per_ocpu_in_gbs: + The value to assign to the min_per_ocpu_in_gbs property of this ShapeMemoryOptions. + :type min_per_ocpu_in_gbs: int + + :param max_in_gbs: + The value to assign to the max_in_gbs property of this ShapeMemoryOptions. + :type max_in_gbs: int + + :param max_per_ocpu_in_gbs: + The value to assign to the max_per_ocpu_in_gbs property of this ShapeMemoryOptions. + :type max_per_ocpu_in_gbs: int + + """ + self.swagger_types = { + 'default_per_ocpu_in_gbs': 'int', + 'min_in_gbs': 'int', + 'min_per_ocpu_in_gbs': 'int', + 'max_in_gbs': 'int', + 'max_per_ocpu_in_gbs': 'int' + } + + self.attribute_map = { + 'default_per_ocpu_in_gbs': 'defaultPerOcpuInGBs', + 'min_in_gbs': 'minInGBs', + 'min_per_ocpu_in_gbs': 'minPerOcpuInGBs', + 'max_in_gbs': 'maxInGBs', + 'max_per_ocpu_in_gbs': 'maxPerOcpuInGBs' + } + + self._default_per_ocpu_in_gbs = None + self._min_in_gbs = None + self._min_per_ocpu_in_gbs = None + self._max_in_gbs = None + self._max_per_ocpu_in_gbs = None + + @property + def default_per_ocpu_in_gbs(self): + """ + **[Required]** Gets the default_per_ocpu_in_gbs of this ShapeMemoryOptions. + Default per OCPU configuration in GBs + + + :return: The default_per_ocpu_in_gbs of this ShapeMemoryOptions. + :rtype: int + """ + return self._default_per_ocpu_in_gbs + + @default_per_ocpu_in_gbs.setter + def default_per_ocpu_in_gbs(self, default_per_ocpu_in_gbs): + """ + Sets the default_per_ocpu_in_gbs of this ShapeMemoryOptions. + Default per OCPU configuration in GBs + + + :param default_per_ocpu_in_gbs: The default_per_ocpu_in_gbs of this ShapeMemoryOptions. + :type: int + """ + self._default_per_ocpu_in_gbs = default_per_ocpu_in_gbs + + @property + def min_in_gbs(self): + """ + **[Required]** Gets the min_in_gbs of this ShapeMemoryOptions. + Minimum Memory configuration in GBs + + + :return: The min_in_gbs of this ShapeMemoryOptions. + :rtype: int + """ + return self._min_in_gbs + + @min_in_gbs.setter + def min_in_gbs(self, min_in_gbs): + """ + Sets the min_in_gbs of this ShapeMemoryOptions. + Minimum Memory configuration in GBs + + + :param min_in_gbs: The min_in_gbs of this ShapeMemoryOptions. + :type: int + """ + self._min_in_gbs = min_in_gbs + + @property + def min_per_ocpu_in_gbs(self): + """ + **[Required]** Gets the min_per_ocpu_in_gbs of this ShapeMemoryOptions. + Minimum Memory configuration per OCPU in GBs + + + :return: The min_per_ocpu_in_gbs of this ShapeMemoryOptions. + :rtype: int + """ + return self._min_per_ocpu_in_gbs + + @min_per_ocpu_in_gbs.setter + def min_per_ocpu_in_gbs(self, min_per_ocpu_in_gbs): + """ + Sets the min_per_ocpu_in_gbs of this ShapeMemoryOptions. + Minimum Memory configuration per OCPU in GBs + + + :param min_per_ocpu_in_gbs: The min_per_ocpu_in_gbs of this ShapeMemoryOptions. + :type: int + """ + self._min_per_ocpu_in_gbs = min_per_ocpu_in_gbs + + @property + def max_in_gbs(self): + """ + **[Required]** Gets the max_in_gbs of this ShapeMemoryOptions. + Maximum Memory configuration in GBs + + + :return: The max_in_gbs of this ShapeMemoryOptions. + :rtype: int + """ + return self._max_in_gbs + + @max_in_gbs.setter + def max_in_gbs(self, max_in_gbs): + """ + Sets the max_in_gbs of this ShapeMemoryOptions. + Maximum Memory configuration in GBs + + + :param max_in_gbs: The max_in_gbs of this ShapeMemoryOptions. + :type: int + """ + self._max_in_gbs = max_in_gbs + + @property + def max_per_ocpu_in_gbs(self): + """ + **[Required]** Gets the max_per_ocpu_in_gbs of this ShapeMemoryOptions. + Maximum Memory configuration per OCPU in GBs + + + :return: The max_per_ocpu_in_gbs of this ShapeMemoryOptions. + :rtype: int + """ + return self._max_per_ocpu_in_gbs + + @max_per_ocpu_in_gbs.setter + def max_per_ocpu_in_gbs(self, max_per_ocpu_in_gbs): + """ + Sets the max_per_ocpu_in_gbs of this ShapeMemoryOptions. + Maximum Memory configuration per OCPU in GBs + + + :param max_per_ocpu_in_gbs: The max_per_ocpu_in_gbs of this ShapeMemoryOptions. + :type: int + """ + self._max_per_ocpu_in_gbs = max_per_ocpu_in_gbs + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/psql/models/shape_ocpu_options.py b/src/oci/psql/models/shape_ocpu_options.py new file mode 100644 index 000000000..3195a83f0 --- /dev/null +++ b/src/oci/psql/models/shape_ocpu_options.py @@ -0,0 +1,103 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20220915 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class ShapeOcpuOptions(object): + """ + Options for the the shape OCPU + """ + + def __init__(self, **kwargs): + """ + Initializes a new ShapeOcpuOptions object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param min: + The value to assign to the min property of this ShapeOcpuOptions. + :type min: int + + :param max: + The value to assign to the max property of this ShapeOcpuOptions. + :type max: int + + """ + self.swagger_types = { + 'min': 'int', + 'max': 'int' + } + + self.attribute_map = { + 'min': 'min', + 'max': 'max' + } + + self._min = None + self._max = None + + @property + def min(self): + """ + **[Required]** Gets the min of this ShapeOcpuOptions. + Minimum OCPU configuration + + + :return: The min of this ShapeOcpuOptions. + :rtype: int + """ + return self._min + + @min.setter + def min(self, min): + """ + Sets the min of this ShapeOcpuOptions. + Minimum OCPU configuration + + + :param min: The min of this ShapeOcpuOptions. + :type: int + """ + self._min = min + + @property + def max(self): + """ + **[Required]** Gets the max of this ShapeOcpuOptions. + Maximum OCPU configuration + + + :return: The max of this ShapeOcpuOptions. + :rtype: int + """ + return self._max + + @max.setter + def max(self, max): + """ + Sets the max of this ShapeOcpuOptions. + Maximum OCPU configuration + + + :param max: The max of this ShapeOcpuOptions. + :type: int + """ + self._max = max + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/psql/models/shape_summary.py b/src/oci/psql/models/shape_summary.py index 3d324dc37..c6275e4e8 100644 --- a/src/oci/psql/models/shape_summary.py +++ b/src/oci/psql/models/shape_summary.py @@ -28,6 +28,10 @@ def __init__(self, **kwargs): The value to assign to the shape property of this ShapeSummary. :type shape: str + :param is_flexible: + The value to assign to the is_flexible property of this ShapeSummary. + :type is_flexible: bool + :param ocpu_count: The value to assign to the ocpu_count property of this ShapeSummary. :type ocpu_count: int @@ -36,25 +40,42 @@ def __init__(self, **kwargs): The value to assign to the memory_size_in_gbs property of this ShapeSummary. :type memory_size_in_gbs: int + :param shape_ocpu_options: + The value to assign to the shape_ocpu_options property of this ShapeSummary. + :type shape_ocpu_options: oci.psql.models.ShapeOcpuOptions + + :param shape_memory_options: + The value to assign to the shape_memory_options property of this ShapeSummary. + :type shape_memory_options: oci.psql.models.ShapeMemoryOptions + """ self.swagger_types = { 'id': 'str', 'shape': 'str', + 'is_flexible': 'bool', 'ocpu_count': 'int', - 'memory_size_in_gbs': 'int' + 'memory_size_in_gbs': 'int', + 'shape_ocpu_options': 'ShapeOcpuOptions', + 'shape_memory_options': 'ShapeMemoryOptions' } self.attribute_map = { 'id': 'id', 'shape': 'shape', + 'is_flexible': 'isFlexible', 'ocpu_count': 'ocpuCount', - 'memory_size_in_gbs': 'memorySizeInGBs' + 'memory_size_in_gbs': 'memorySizeInGBs', + 'shape_ocpu_options': 'shapeOcpuOptions', + 'shape_memory_options': 'shapeMemoryOptions' } self._id = None self._shape = None + self._is_flexible = None self._ocpu_count = None self._memory_size_in_gbs = None + self._shape_ocpu_options = None + self._shape_memory_options = None @property def id(self): @@ -106,6 +127,30 @@ def shape(self, shape): """ self._shape = shape + @property + def is_flexible(self): + """ + Gets the is_flexible of this ShapeSummary. + Indicates if the shape is a flex shape. + + + :return: The is_flexible of this ShapeSummary. + :rtype: bool + """ + return self._is_flexible + + @is_flexible.setter + def is_flexible(self, is_flexible): + """ + Sets the is_flexible of this ShapeSummary. + Indicates if the shape is a flex shape. + + + :param is_flexible: The is_flexible of this ShapeSummary. + :type: bool + """ + self._is_flexible = is_flexible + @property def ocpu_count(self): """ @@ -154,6 +199,46 @@ def memory_size_in_gbs(self, memory_size_in_gbs): """ self._memory_size_in_gbs = memory_size_in_gbs + @property + def shape_ocpu_options(self): + """ + Gets the shape_ocpu_options of this ShapeSummary. + + :return: The shape_ocpu_options of this ShapeSummary. + :rtype: oci.psql.models.ShapeOcpuOptions + """ + return self._shape_ocpu_options + + @shape_ocpu_options.setter + def shape_ocpu_options(self, shape_ocpu_options): + """ + Sets the shape_ocpu_options of this ShapeSummary. + + :param shape_ocpu_options: The shape_ocpu_options of this ShapeSummary. + :type: oci.psql.models.ShapeOcpuOptions + """ + self._shape_ocpu_options = shape_ocpu_options + + @property + def shape_memory_options(self): + """ + Gets the shape_memory_options of this ShapeSummary. + + :return: The shape_memory_options of this ShapeSummary. + :rtype: oci.psql.models.ShapeMemoryOptions + """ + return self._shape_memory_options + + @shape_memory_options.setter + def shape_memory_options(self, shape_memory_options): + """ + Sets the shape_memory_options of this ShapeSummary. + + :param shape_memory_options: The shape_memory_options of this ShapeSummary. + :type: oci.psql.models.ShapeMemoryOptions + """ + self._shape_memory_options = shape_memory_options + def __repr__(self): return formatted_flat_dict(self) diff --git a/src/oci/psql/models/update_db_system_details.py b/src/oci/psql/models/update_db_system_details.py index 7fd37f978..5358a8e15 100644 --- a/src/oci/psql/models/update_db_system_details.py +++ b/src/oci/psql/models/update_db_system_details.py @@ -28,6 +28,18 @@ def __init__(self, **kwargs): The value to assign to the description property of this UpdateDbSystemDetails. :type description: str + :param shape: + The value to assign to the shape property of this UpdateDbSystemDetails. + :type shape: str + + :param instance_ocpu_count: + The value to assign to the instance_ocpu_count property of this UpdateDbSystemDetails. + :type instance_ocpu_count: int + + :param instance_memory_size_in_gbs: + The value to assign to the instance_memory_size_in_gbs property of this UpdateDbSystemDetails. + :type instance_memory_size_in_gbs: int + :param db_configuration_params: The value to assign to the db_configuration_params property of this UpdateDbSystemDetails. :type db_configuration_params: oci.psql.models.UpdateDbConfigParams @@ -40,6 +52,10 @@ def __init__(self, **kwargs): The value to assign to the storage_details property of this UpdateDbSystemDetails. :type storage_details: oci.psql.models.UpdateStorageDetailsParams + :param network_details: + The value to assign to the network_details property of this UpdateDbSystemDetails. + :type network_details: oci.psql.models.UpdateNetworkDetails + :param freeform_tags: The value to assign to the freeform_tags property of this UpdateDbSystemDetails. :type freeform_tags: dict(str, str) @@ -52,9 +68,13 @@ def __init__(self, **kwargs): self.swagger_types = { 'display_name': 'str', 'description': 'str', + 'shape': 'str', + 'instance_ocpu_count': 'int', + 'instance_memory_size_in_gbs': 'int', 'db_configuration_params': 'UpdateDbConfigParams', 'management_policy': 'ManagementPolicyDetails', 'storage_details': 'UpdateStorageDetailsParams', + 'network_details': 'UpdateNetworkDetails', 'freeform_tags': 'dict(str, str)', 'defined_tags': 'dict(str, dict(str, object))' } @@ -62,18 +82,26 @@ def __init__(self, **kwargs): self.attribute_map = { 'display_name': 'displayName', 'description': 'description', + 'shape': 'shape', + 'instance_ocpu_count': 'instanceOcpuCount', + 'instance_memory_size_in_gbs': 'instanceMemorySizeInGBs', 'db_configuration_params': 'dbConfigurationParams', 'management_policy': 'managementPolicy', 'storage_details': 'storageDetails', + 'network_details': 'networkDetails', 'freeform_tags': 'freeformTags', 'defined_tags': 'definedTags' } self._display_name = None self._description = None + self._shape = None + self._instance_ocpu_count = None + self._instance_memory_size_in_gbs = None self._db_configuration_params = None self._management_policy = None self._storage_details = None + self._network_details = None self._freeform_tags = None self._defined_tags = None @@ -125,6 +153,80 @@ def description(self, description): """ self._description = description + @property + def shape(self): + """ + Gets the shape of this UpdateDbSystemDetails. + The name of the shape for the database system nodes. + Example: `VM.Standard.E4.Flex` + + + :return: The shape of this UpdateDbSystemDetails. + :rtype: str + """ + return self._shape + + @shape.setter + def shape(self, shape): + """ + Sets the shape of this UpdateDbSystemDetails. + The name of the shape for the database system nodes. + Example: `VM.Standard.E4.Flex` + + + :param shape: The shape of this UpdateDbSystemDetails. + :type: str + """ + self._shape = shape + + @property + def instance_ocpu_count(self): + """ + Gets the instance_ocpu_count of this UpdateDbSystemDetails. + The total number of OCPUs available to each database system node. + + + :return: The instance_ocpu_count of this UpdateDbSystemDetails. + :rtype: int + """ + return self._instance_ocpu_count + + @instance_ocpu_count.setter + def instance_ocpu_count(self, instance_ocpu_count): + """ + Sets the instance_ocpu_count of this UpdateDbSystemDetails. + The total number of OCPUs available to each database system node. + + + :param instance_ocpu_count: The instance_ocpu_count of this UpdateDbSystemDetails. + :type: int + """ + self._instance_ocpu_count = instance_ocpu_count + + @property + def instance_memory_size_in_gbs(self): + """ + Gets the instance_memory_size_in_gbs of this UpdateDbSystemDetails. + The total amount of memory available to each database system node, in gigabytes. + + + :return: The instance_memory_size_in_gbs of this UpdateDbSystemDetails. + :rtype: int + """ + return self._instance_memory_size_in_gbs + + @instance_memory_size_in_gbs.setter + def instance_memory_size_in_gbs(self, instance_memory_size_in_gbs): + """ + Sets the instance_memory_size_in_gbs of this UpdateDbSystemDetails. + The total amount of memory available to each database system node, in gigabytes. + + + :param instance_memory_size_in_gbs: The instance_memory_size_in_gbs of this UpdateDbSystemDetails. + :type: int + """ + self._instance_memory_size_in_gbs = instance_memory_size_in_gbs + @property def db_configuration_params(self): """ @@ -185,6 +287,26 @@ def storage_details(self, storage_details): """ self._storage_details = storage_details + @property + def network_details(self): + """ + Gets the network_details of this UpdateDbSystemDetails. + + :return: The network_details of this UpdateDbSystemDetails. + :rtype: oci.psql.models.UpdateNetworkDetails + """ + return self._network_details + + @network_details.setter + def network_details(self, network_details): + """ + Sets the network_details of this UpdateDbSystemDetails. + + :param network_details: The network_details of this UpdateDbSystemDetails. + :type: oci.psql.models.UpdateNetworkDetails + """ + self._network_details = network_details + @property def freeform_tags(self): """ diff --git a/src/oci/psql/models/update_network_details.py b/src/oci/psql/models/update_network_details.py new file mode 100644 index 000000000..036ee86e5 --- /dev/null +++ b/src/oci/psql/models/update_network_details.py @@ -0,0 +1,76 @@ +# coding: utf-8 +# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. +# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. + +# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20220915 + + +from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 +from oci.decorators import init_model_state_from_kwargs + + +@init_model_state_from_kwargs +class UpdateNetworkDetails(object): + """ + Network details for the database system. + """ + + def __init__(self, **kwargs): + """ + Initializes a new UpdateNetworkDetails object with values from keyword arguments. + The following keyword arguments are supported (corresponding to the getters/setters of this class): + + :param nsg_ids: + The value to assign to the nsg_ids property of this UpdateNetworkDetails. + :type nsg_ids: list[str] + + """ + self.swagger_types = { + 'nsg_ids': 'list[str]' + } + + self.attribute_map = { + 'nsg_ids': 'nsgIds' + } + + self._nsg_ids = None + + @property + def nsg_ids(self): + """ + Gets the nsg_ids of this UpdateNetworkDetails. + List of Network Security Group `OCIDs`__ associated with the database system. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :return: The nsg_ids of this UpdateNetworkDetails. + :rtype: list[str] + """ + return self._nsg_ids + + @nsg_ids.setter + def nsg_ids(self, nsg_ids): + """ + Sets the nsg_ids of this UpdateNetworkDetails. + List of Network Security Group `OCIDs`__ associated with the database system. + + __ https://docs.cloud.oracle.com/Content/General/Concepts/identifiers.htm + + + :param nsg_ids: The nsg_ids of this UpdateNetworkDetails. + :type: list[str] + """ + self._nsg_ids = nsg_ids + + def __repr__(self): + return formatted_flat_dict(self) + + def __eq__(self, other): + if other is None: + return False + + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not self == other diff --git a/src/oci/psql/postgresql_client.py b/src/oci/psql/postgresql_client.py index b34349882..fd6e4efa2 100644 --- a/src/oci/psql/postgresql_client.py +++ b/src/oci/psql/postgresql_client.py @@ -2075,7 +2075,7 @@ def list_configurations(self, **kwargs): A filter to return only resources that match the entire display name given. :param str db_version: (optional) - Verison of the PostgreSQL database, such as 14.9. + Version of the PostgreSQL database, such as 14.9. :param str shape: (optional) The name of the shape for the configuration. @@ -2395,7 +2395,7 @@ def list_default_configurations(self, **kwargs): A filter to return only resources that match the entire display name given. :param str db_version: (optional) - Verison of the PostgreSQL database, such as 14.9. + Version of the PostgreSQL database, such as 14.9. :param str shape: (optional) The name of the shape for the configuration. diff --git a/src/oci/regions_definitions.py b/src/oci/regions_definitions.py index 41b7c2eb5..ad056d37c 100644 --- a/src/oci/regions_definitions.py +++ b/src/oci/regions_definitions.py @@ -42,6 +42,7 @@ 'bog': 'sa-bogota-1', 'vap': 'sa-valparaiso-1', 'xsp': 'ap-singapore-2', + 'ruh': 'me-riyadh-1', 'lfi': 'us-langley-1', 'luf': 'us-luke-1', 'ric': 'us-gov-ashburn-1', @@ -108,6 +109,7 @@ 'sa-bogota-1': 'oc1', 'sa-valparaiso-1': 'oc1', 'ap-singapore-2': 'oc1', + 'me-riyadh-1': 'oc1', 'us-langley-1': 'oc2', 'us-luke-1': 'oc2', @@ -205,6 +207,7 @@ 'sa-bogota-1', 'sa-valparaiso-1', 'ap-singapore-2', + 'me-riyadh-1', 'us-langley-1', 'us-luke-1', 'us-gov-ashburn-1', diff --git a/src/oci/version.py b/src/oci/version.py index c64b75830..ad93c9a0d 100644 --- a/src/oci/version.py +++ b/src/oci/version.py @@ -2,4 +2,4 @@ # Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. -__version__ = "2.130.0" +__version__ = "2.131.0"