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

refactor: add possibility to support different URI schemes #69

Closed
wants to merge 3 commits into from

Conversation

JKRhb
Copy link
Contributor

@JKRhb JKRhb commented Mar 28, 2022

Dealing with the addition of DTLS to the library, I noticed that the current structure of the library does not really allow for differentiating between URI schemes. This PR proposes a new structure that allows for adding additional network and channel types that can be chosen based on the URI scheme that is encountered.

This way, in contrast to what is currently proposed in #35, additional ways of transporting CoAP packets can be defined in their own classes and do not need to be integrated into the UDP channel/network classes. This also makes the library easier to extend with features like CoAP over TCP or CoAP over WebSockets.

Unfortunately, this PR requires #35 to be rebased/adjusted (sorry @Sorunome) but I hope it won't be too much work :/

@JKRhb JKRhb marked this pull request as draft March 28, 2022 15:14
@JKRhb JKRhb force-pushed the urischeme-support branch 2 times, most recently from 0982a54 to e8c6d29 Compare March 28, 2022 15:43
@JKRhb JKRhb marked this pull request as ready for review March 28, 2022 15:43
@shamblett
Copy link
Owner

This looks OK to me, I take it it's now ready to merge, just checking.

@JKRhb
Copy link
Contributor Author

JKRhb commented Apr 16, 2022

@shamblett Thank you for your feedback :) Besides the merge conflict it would be ready, however, maybe the change could also be incorporated into @JosefWN's PR #76?

@JosefWN
Copy link
Contributor

JosefWN commented Apr 16, 2022

I can incorporate it if you want and if @shamblett is ok with it, working on mutlicast and adding more examples/tests to find and work out any issues in the PR

@shamblett
Copy link
Owner

No problem from me with this approach.

@JosefWN
Copy link
Contributor

JosefWN commented Apr 16, 2022

Hope I didn't miss anything: 4a44d63 :)

Also includes a fix for a formatting issue I had caused in the builder, which I discovered when I re-generated the CoapConfigs (which I did just in case).

@JKRhb
Copy link
Contributor Author

JKRhb commented Apr 16, 2022

Awesome, thank you :) Then I'll close this PR :)

@JKRhb JKRhb closed this Apr 16, 2022
@JKRhb JKRhb deleted the urischeme-support branch July 16, 2022 22:31
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.

3 participants