Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions kamelets/data-type-action.kamelet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ spec:
template:
beans:
- name: dataTypeProcessor
type: "#class:org.apache.camel.processor.transformer.DataTypeProcessor"
type: "#class:org.apache.camel.processor.transformer.DelegatingDataTypeProcessor"
from:
uri: "kamelet:source"
steps:
Expand All @@ -65,6 +65,5 @@ spec:
- setProperty:
name: CamelDataType
simple: "{{format}}"
- bean:
ref: "{{dataTypeProcessor}}"
method: process
- process:
ref: "dataTypeProcessor"
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ spec:
template:
beans:
- name: dataTypeProcessor
type: "#class:org.apache.camel.processor.transformer.DataTypeProcessor"
type: "#class:org.apache.camel.processor.transformer.DelegatingDataTypeProcessor"
from:
uri: "kamelet:source"
steps:
Expand All @@ -65,6 +65,5 @@ spec:
- setProperty:
name: CamelDataType
simple: "{{format}}"
- bean:
ref: "{{dataTypeProcessor}}"
method: process
- process:
ref: "dataTypeProcessor"
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,15 @@ actions:
path: "/rest/api/latest/search"
parameters:
- name: jql
value: "citrus:urlEncode(${jira.jql})+ORDER+BY+key+desc"
value: "citrus:urlEncode(${jira.jql})+ORDER+BY+created+DESC"
- name: expand
value: "schema%2Cnames"
- name: fields
value: "%2Anavigable"
- name: maxResults
value: "1"
- name: startAt
value: "0"
headers:
- name: Authorization
value: "Basic citrus:encodeBase64(${jira.username}:${jira.password})"
Expand Down Expand Up @@ -95,6 +101,36 @@ actions:
]
}

# Verify myself request
- http:
server: "jiraServer"
receiveRequest:
GET:
path: "/rest/api/latest/myself"
headers:
- name: Authorization
value: "Basic citrus:encodeBase64(${jira.username}:${jira.password})"

- http:
server: "jiraServer"
sendResponse:
response:
status: 200
reasonPhrase: "OK"
version: "HTTP/1.1"
contentType: "application/json"
body:
data: |
{
"name": "citrus",
"emailAddress": "citrus@example.com",
"displayName": "Citrus User",
"timeZone": "America/New_York",
"avatarUrls": {
"48x48": "${jira.url}/secure/useravatar?ownerId=citrus&avatarId=10342"
}
}

# Verify search request
- http:
server: "jiraServer"
Expand All @@ -103,11 +139,15 @@ actions:
path: "/rest/api/latest/search"
parameters:
- name: jql
value: "citrus:urlEncode(${jira.jql})+ORDER+BY+key+desc"
- name: maxResults
value: "50"
value: "citrus:urlEncode(${jira.jql})"
- name: expand
value: "schema%2Cnames"
- name: fields
value: "%2Anavigable"
- name: maxResults
value: "50"
- name: startAt
value: "0"
headers:
- name: Authorization
value: "Basic citrus:encodeBase64(${jira.username}:${jira.password})"
Expand Down
Loading