Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add MQTT5.0 codec. #10

Merged
merged 23 commits into from
Mar 11, 2022
Merged

Add MQTT5.0 codec. #10

merged 23 commits into from
Mar 11, 2022

Conversation

alvin1221
Copy link
Contributor

No description provided.

Copy link
Contributor Author

@alvin1221 alvin1221 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please note that nng_msg_proto_set_property()/nng_msg_proto_get_property() functions can not be called by client application.

include/nng/nng.h Outdated Show resolved Hide resolved
include/nng/nng.h Show resolved Hide resolved
src/mqtt/mqtt_codec.c Outdated Show resolved Hide resolved
"id: %d, value: %d (U8)", prop_id, prop->data.p_value.u8);
break;
case U16:
read_uint16(buf, &prop->data.p_value.u16);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should check return value

src/mqtt/mqtt_codec.c Outdated Show resolved Hide resolved
src/mqtt/mqtt_codec.c Outdated Show resolved Hide resolved
@alvin1221 alvin1221 changed the title Add properties codec functions. Add MQTT5.0 codec. Feb 25, 2022
@JaylinYu JaylinYu closed this in b8a7fbc Feb 28, 2022
@alvin1221 alvin1221 reopened this Mar 1, 2022
@alvin1221
Copy link
Contributor Author

FIX #19

@alvin1221 alvin1221 force-pushed the alvin/mqtt5_codec branch 3 times, most recently from 59bfdfa to ec40ed4 Compare March 2, 2022 09:58
Copy link
Member

@JaylinYu JaylinYu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not done yet

@JaylinYu
Copy link
Member

JaylinYu commented Mar 8, 2022

please test and rework whole PR

@JaylinYu
Copy link
Member

JaylinYu commented Mar 8, 2022

and keep the original field in conn_param feasible. because we use it everywhere.

nni_msg_append(msg, &(cparam->rx_max), 2);
remaining_len += 3;
}
if (cparam->assignedid == true) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

assignedID does not work now
assign clientid failed

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@alvin1221 fix this

src/sp/protocol/mqtt/mqtt_parser.c Show resolved Hide resolved
src/sp/protocol/mqtt/mqtt_parser.c Show resolved Hide resolved
src/sp/protocol/mqtt/mqtt_parser.c Show resolved Hide resolved
src/sp/protocol/mqtt/mqtt_parser.c Show resolved Hide resolved
src/sp/protocol/mqtt/mqtt_parser.c Outdated Show resolved Hide resolved
Copy link
Member

@JaylinYu JaylinYu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so far so good

@JaylinYu JaylinYu merged commit ec449fa into main Mar 11, 2022
JaylinYu added a commit that referenced this pull request Mar 11, 2022
@JaylinYu JaylinYu deleted the alvin/mqtt5_codec branch March 11, 2022 03:45
This was referenced Mar 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants