# 消息队列

<mark style="color:orange;">当前该特性暂未上线，正在规划中\~</mark>

Fireboom可接入GraphQL数据源，且支持GraphQL订阅，详情见[实时推送](/ji-chu-ke-shi-hua-kai-fa/api-gou-jian/shi-shi-tui-song.md)。

借助该能力可接入消息队列，特别适合处理物联网事件。

实现该功能需要2个步骤：

1. 将消息队列转换成GraphQL数据源
2. 将GraphQL数据源接入Fireboom

利用上述原理，飞布映射实时消息到graphql订阅，并通过REST API的方式呈现给客户端。

同时，开发者还可以使用自定义脚本处理订阅事件，实现数据落库等功能。

在该功能未实现前，可<mark style="color:red;">手动</mark>实现上述功能：

1，利用现成的库，将消息队列转换成GraphQL服务，例如：

* nodejs示例：<https://github.com/apollographql/graphql-subscriptions>
* golang示例：<https://github.com/lcRuri/fireboom-doc/blob/main/%E6%B6%88%E6%81%AF%E9%98%9F%E5%88%97/kafka%20graphql.md>

2，在Fireboom数据源中添加GraphQL数据源，详情见 [GraphQL 数据源](/ji-chu-ke-shi-hua-kai-fa/shu-ju-yuan/graphql-api.md)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.fireboom.io/ji-chu-ke-shi-hua-kai-fa/shu-ju-yuan/xiao-xi-dui-lie.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
