Skip to content

Commit

Permalink
Bump msgs, transport, and fuel-tools version in Harmonic (#210)
Browse files Browse the repository at this point in the history
* bump msgs, transport, and fuel-tools version

---------

Signed-off-by: Ian Chen <[email protected]>
  • Loading branch information
iche033 committed Mar 9, 2023
1 parent a892e6a commit 7e28e78
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
6 changes: 3 additions & 3 deletions .github/ci/packages.apt
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@ binutils-dev
libgflags-dev
libgz-cmake3-dev
libgz-common5-dev
libgz-fuel-tools8-dev
libgz-fuel-tools9-dev
libgz-sim8-dev
libgz-gui8-dev
libgz-math7-dev
libgz-math7-eigen3-dev
libgz-msgs9-dev
libgz-msgs10-dev
libgz-physics6-dev
libgz-plugin2-dev
libgz-rendering8-dev
libgz-sensors8-dev
libgz-tools2-dev
libgz-transport12-dev
libgz-transport13-dev
libsdformat13-dev
libtinyxml2-dev
libwebsockets-dev
Expand Down
8 changes: 4 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,13 @@ set(GZ_TOOLS_VER 2)

#--------------------------------------
# Find gz-transport
gz_find_package(gz-transport12 REQUIRED)
set(GZ_TRANSPORT_VER ${gz-transport12_VERSION_MAJOR})
gz_find_package(gz-transport13 REQUIRED)
set(GZ_TRANSPORT_VER ${gz-transport13_VERSION_MAJOR})

#--------------------------------------
# Find gz-msgs
gz_find_package(gz-msgs9 REQUIRED)
set(GZ_MSGS_VER ${gz-msgs9_VERSION_MAJOR})
gz_find_package(gz-msgs10 REQUIRED)
set(GZ_MSGS_VER ${gz-msgs10_VERSION_MAJOR})

#--------------------------------------
# Find gz-math
Expand Down
9 changes: 6 additions & 3 deletions plugins/websocket_server/WebsocketServer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,8 @@ void WebsocketServer::OnMessage(int _socketId, const std::string _msg)
for (const std::string &topic : topics)
{
std::vector<transport::MessagePublisher> publishers;
this->node.TopicInfo(topic, publishers);
std::vector<transport::MessagePublisher> subscribers;
this->node.TopicInfo(topic, publishers, subscribers);
for (const transport::MessagePublisher &publisher : publishers)
{
msgs::Publish *pubMsg = msg.add_publisher();
Expand Down Expand Up @@ -925,7 +926,8 @@ void WebsocketServer::OnMessage(int _socketId, const std::string _msg)
for (auto queryTopic: allTopics)
{
std::vector<transport::MessagePublisher> publishers;
this->node.TopicInfo(queryTopic, publishers);
std::vector<transport::MessagePublisher> subscribers;
this->node.TopicInfo(queryTopic, publishers, subscribers);
for (auto pub: publishers)
{
if (pub.MsgTypeName() == "gz.msgs.Image")
Expand Down Expand Up @@ -1205,7 +1207,8 @@ bool WebsocketServer::UpdateMsgTypeSubscriptionCount(const std::string &_topic,
// check if limit reached for the subscribed msg type
// if not, update subscription count
std::vector<transport::MessagePublisher> publishers;
this->node.TopicInfo(_topic, publishers);
std::vector<transport::MessagePublisher> subscribers;
this->node.TopicInfo(_topic, publishers, subscribers);
if (!publishers.empty())
{
std::string msgType = publishers.begin()->MsgTypeName();
Expand Down

0 comments on commit 7e28e78

Please sign in to comment.