Skip to content

Commit

Permalink
docs: update changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
AnWeber committed Feb 12, 2023
1 parent f8d12da commit 58ae9d5
Show file tree
Hide file tree
Showing 4 changed files with 85 additions and 21 deletions.
82 changes: 73 additions & 9 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,85 @@
## 6.0.0 (2023-02-xx)
## 6.0.0 (2023-02-12)

#### Breaking Changes

- Protocol Specific Request Clients are replaced with generic interface RequestClient.
- use `$requestClient.send(<body>)` to send string or Buffer with current client
- add EventListener `$requestClient.on('message', (response) => ...)` to access respones of client
- Protocol Specific Request Clients are replaced with generic interface RequestClient (`$requestClient`).
- to access previous Client you can use `$requestClient.nativeClient`
- removed Variables: amqpClient, amqpChannel, grpcStream, mqttClient, websocketClient

- requireUncached is removed

#### Features

- simplified asserts ([docs](https://httpyac.github.io/guide/assert.html))
- support Intellij Request Body separator
- support Intellij TextResponseStreaming (onEachLIne, onEachMessage)
- add `proxyExcludeList` config (AnWeber/vscode-httpyac#176)
- use `$requestClient.send(<body>)` to send string or Buffer with current client. Add EventListener `$requestClient.on('message', (response) => ...)` to access respones of client

```
MQTT tcp://broker.hivemq.com
topic: httpyac
{{@streaming
async function writeStream(){
await sleep(1000);
$requestClient.on("message", (response) => {
console.info(response);
});
$requestClient.send("find me");
await sleep(1000);
$requestClient.send("wait for response");
await sleep(1000);
}
exports.waitPromise = writeStream();
}}
```

- extended and simpler assert logic ([docs](https://httpyac.github.io/guide/assert.html))

```
GET https://httpbin.org/anything
?? status == 200
```

- multiple specification of request body per response (like Intellij Request Body separator)

```
MQTT tcp://broker.hivemq.com
topic: httpyac
Send one
===
Send two
=== wait-for-server
=== wait-for-server
Send three
```

- websocket requests with same url as a websocket request are requested with the same url. You can keep a WebSocket Client open and send additional requests.

```
# @keepStreaming
wss://scrumpoker.foo
###
wss://scrumpoker.foo
["CONNECT\naccept-version:1.1,1.0\nheart-beat:10000,10000\n\n\u0000"]
===
["SUBSCRIBE\nid:sub-0\ndestination:/user/topic/username\n\n\u0000"]
===
["SUBSCRIBE\nid:sub-1\ndestination:/user/topic/notification\n\n\u0000"]
===
["SUBSCRIBE\nid:sub-3\ndestination:/topic/setting/cardset/{{roomId}}\n\n\u0000"]
===
["SEND\ndestination:/ws/room/register\n\n{\"roomID\":\"{{roomId}}\"}\u0000"]
===
["SEND\ndestination:/ws/user/username\n\n{\"username\":\"httpyac\"}\u0000"]
###
wss://scrumpoker.foo
["SEND\ndestination:/ws/room/{{roomId}}/estimate\n\n{\"estimation\":\"5\"}\u0000"]
```

- add parallel option to cli and test runner to execute requests in parallel.
- process each line of an event stream like Intellij ([see](https://www.jetbrains.com/help/idea/http-response-handling-examples.html#stream_scripting))
- add `proxyExcludeList` config to exclude some url from proxy calls (AnWeber/vscode-httpyac#176)

#### Fixes

Expand Down
18 changes: 9 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"license": "MIT",
"publisher": "AnWeber",
"description": "HTTP/REST CLI Client for *.http files",
"version": "5.10.2",
"version": "6.0.0",
"homepage": "https://github.com/AnWeber/httpyac",
"repository": {
"type": "git",
Expand Down Expand Up @@ -69,7 +69,7 @@
"@trivago/prettier-plugin-sort-imports": "^4.0.0",
"@types/aws4": "^1.11.2",
"@types/encodeurl": "^1.0.0",
"@types/eventsource": "^1.1.10",
"@types/eventsource": "1.1.10",
"@types/inquirer": "^9.0.3",
"@types/jest": "^29.2.6",
"@types/lodash": "^4.14.191",
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/kafka/kafkaHttpRegionParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { KafkaRequestClient } from './kafkaRequestClient';

export const parseKafkaLine = utils.parseRequestLineFactory({
protocol: 'KAFKA',
methodRegex: /^\s*(kafka)\s*(?<url>.+?)\s*$/iu,
methodRegex: /^\s*(kafka)\s+(?<url>.+?)\s*$/iu,
requestClientFactory(request, context) {
return new KafkaRequestClient(request, context);
},
Expand Down

0 comments on commit 58ae9d5

Please sign in to comment.