Skip to content

Unable to create application perspectives #35

Open
@JohnEllwoodNHS

Description

@JohnEllwoodNHS

Using the latest version of the Instana provider (4.0.0) I am unable to create an application perspective, even using the example in the docs:

resource "instana_application_config" "example" {
  label               = "label"
  scope               = "INCLUDE_ALL_DOWNSTREAM"  #Optional, default = INCLUDE_NO_DOWNSTREAM
  boundary_scope      = "INBOUND"  #Optional, default = INBOUND
  tag_filter          = "agent.tag:stage EQUALS 'test' OR aws.ec2.tag:stage EQUALS 'test' OR call.tag:stage@na EQUALS 'test'"
}

The response is always a 500 error:

 Error: failed to send HTTP PUT request to Instana API; status code = 500; status message = 500 Internal Server Error; 
│ Body: {"errors":["Unexpected error during request processing"]}
│
│   with instana_application_config.example,
│   on example_application_perspective.tf line 1, in resource "instana_application_config" "example":
│    1: resource "instana_application_config" "example" {
│

TF for other resources such as events and alerts are working fine. The API key in use has full permissions to manage all resource types.

Curling the endpoint works:

curl -X POST -H "authorization: apiToken ****************" -H "Content-Type: application/json"  https://**********-********.instana.io/api/application-monitoring/settings/application -d '{
  "label": "example",
  "tagFilterExpression": {
    "type": "EXPRESSION",
    "logicalOperator": "OR",
    "elements": [
      {
        "type": "TAG_FILTER",
        "name": "kubernetes.namespace.name",
        "operator": "EQUALS",
        "value": "example",
        "entity": "DESTINATION"
      }
    ]
  }
}'

.... but what I believe is the equivalent TF fails:

resource "instana_application_config" "example" {
  label               = "label"
  tag_filter          = "kubernetes.namespace.name EQUALS 'example'"
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions