keptn-sandbox / keptn-azure-devops-extension

Azure DevOps Extension for integrating Keptn with your Azure DevOps Pipelines
Apache License 2.0
6 stars 4 forks source link

Update Azure extension to include 0.8.4 keptn workflow events #34

Closed ghost closed 3 years ago

ghost commented 3 years ago

Previously with keptn you will use a deployment event to trigger a new jmeter execution. With the new implementation the type of event has changed and now you need to trigger a customize event to run the jmeter load test.

More info and an example about the deployment event here link

jetzlstorfer commented 3 years ago

@heydenb could you please have a look?

grabnerandi commented 3 years ago

Just to add some additional context and guidance. Currently the extension sends start-evaluation, deployment-finished and configuration-changed events. These are the old events Keptn used to use to trigger Keptn automation. As Diego pointed out - to truly support Keptn 0.8.x the extension needs to send the new SEQUENCE.TRIGGERED events.

The best would be to support at least evaluation and deployment triggered. Here are two example events showing the new event type and the data block

Triggering a Delivery Sequence

{
  "data": {
    "configurationChange": {
      "values": {
        "image": "grabnerandi/simplenodeservice:3.0.0"
      }
    },
    "deployment": {
      "deploymentURIsLocal": null,
      "deploymentstrategy": ""
    },
    "project": "delivery-demo",
    "service": "tnt-angr-svc",
    "stage": "staging"
  },
  "id": "8deb895e-ab9b-44a6-b00b-bab9efaffbf2",
  "source": "https://github.com/keptn/keptn/cli#configuration-change",
  "specversion": "1.0",
  "time": "2021-07-28T13:02:29.359Z",
  "type": "sh.keptn.event.staging.delivery.triggered",
  "shkeptncontext": "a4f2e373-d63c-4ef7-8fa6-cf81205bbfe8",
  "shkeptnspecversion": "0.2.1"
}

Triggering an Evaluation Sequence

{
  "data": {
    "evaluation": {
      "end": "2021-07-28T14:02:49.230Z",
      "start": "2021-07-28T13:52:49.192Z"
    },
    "image": "Cloud Automation Quality Gates",
    "labels": {
      "buildId": "10",
      "buildNumber": "10",
      "jobname": "Cloud Automation Quality Gates",
      "joburl": "https://myjenkins/job/Cloud%20Automation%20Quality%20Gates/10/"
    },
    "monitoring": null,
    "project": "dynatrace",
    "result": "pass",
    "service": "journeyservice",
    "stage": "quality-gate",
    "status": "succeeded",
    "tag": "10",
    "teststrategy": "manual"
  },
  "id": "96af60bb-08a3-4b11-bf95-4c6cb9f17c74",
  "source": "Jenkins",
  "specversion": "1.0",
  "time": "2021-07-28T14:03:49.819Z",
  "type": "sh.keptn.event.quality-gate.evaluation.triggered",
  "shkeptncontext": "39981cd8-47d2-4fd3-baaa-ca14908e5d62",
  "shkeptnspecversion": "0.2.1"
}

I hope this helps

heydenb commented 3 years ago

Two new event types were introduced. delivery and generic. Delivery allows you to define a sequence, an image and so on. While generic allows you to specifiy the entire body of the event. See the updated readme for more info