Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MRS] The v2 job API cannot be accessed #140

Open
1 task done
dmicheneau opened this issue Jan 20, 2023 · 1 comment
Open
1 task done

[MRS] The v2 job API cannot be accessed #140

dmicheneau opened this issue Jan 20, 2023 · 1 comment
Assignees
Labels
bug Something isn't working category/mrs Resource category MRS terraform-provider-issue

Comments

@dmicheneau
Copy link
Collaborator

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

Try to create a job spark for a mrs analysis cluster

Affected Resource(s)

  • flexibleengine_mrs_job_v2

Terraform Configuration Files

"resource": {
        "flexibleengine_mrs_job_v2": {
            "example-mrs-job": {
                "cluster_id": "xxxxxxxxxxx",
                "lifecycle": {
                    "prevent_destroy": true
                },
                "name": "example-mrs-job",
                "parameters": "admin xxxxxxxx 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output",
                "program_parameters": {
                    "--class": "com.orange.bigdata.spark.examples.DriverBehavior"
                },
                "program_path": "s3a://obs-demo-analysis/program/driver_behavior.jar",
                "type": "SparkSubmit"
            }
        }
    }

Panic Output

terraform apply

Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
  + create

Terraform will perform the following actions:

  # flexibleengine_mrs_job_v2.example-mrs-job will be created
  + resource "flexibleengine_mrs_job_v2" "example-mrs-job" {
      + cluster_id         = "xxxxxxxxxxxx"
      + finish_time        = (known after apply)
      + id                 = (known after apply)
      + name               = "example-mrs-job"
      + parameters         = "admin xxxxxxxxx 1 s3a://obs-demo-analysis/input s3a://obs-demo-analysis/output"
      + program_parameters = {
          + "--class" = "com.orange.bigdata.spark.examples.DriverBehavior"
        }
      + program_path       = "s3a://obs-demo-analysis/program/driver_behavior.jar"
      + region             = (known after apply)
      + start_time         = (known after apply)
      + status             = (known after apply)
      + submit_time        = (known after apply)
      + type               = "SparkSubmit"
    }

Plan: 1 to add, 0 to change, 0 to destroy.

Do you want to perform these actions?
  Terraform will perform the actions described above.
  Only 'yes' will be accepted to approve.

  Enter a value: yes

flexibleengine_mrs_job_v2.example-mrs-job: Creating...
╷
│ Error: Error execution MapReduce job: Bad request with: [POST https://mrs.eu-west-0.prod-cloud-ocb.orange-business.com/v2/bb4a068de4b24eea97b11d43e9b5910d/clusters/30b44829-2aa6-4f31-95cb-0895737de1e7/job-executions], error message: {"error_code":"0167","error_msg":"The v2 job API cannot be accessed."}
│ 
│   with flexibleengine_mrs_job_v2.example-mrs-job,
│   on mr-job.tf.json line 16, in resource.flexibleengine_mrs_job_v2.example-mrs-job:
│   16:             }
│ 

Expected Behavior

Steps to Reproduce

Expected Behavior

Create job resource for MRS cluster with Spark

Steps To Reproduce

Please list the steps required to reproduce the issue, for example:

  1. Create a MRS cluster 1.8.9 or 2.0.1 Analysis
  2. Create a job
  3. terraform apply

Environment

terraform version: 1.3.7
Provider Version: 1.36.0
@dmicheneau dmicheneau added bug Something isn't working category/mrs Resource category MRS terraform-provider-issue labels Jan 20, 2023
@dmicheneau
Copy link
Collaborator Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working category/mrs Resource category MRS terraform-provider-issue
Projects
None yet
Development

No branches or pull requests

1 participant