Skip to content
This repository was archived by the owner on Apr 24, 2019. It is now read-only.

Using thread signals instead of restarting a thread #243

Merged
merged 1 commit into from
Nov 28, 2017

Conversation

bridadan
Copy link
Contributor

Status

READY

Migrations

NO

Description

The blinky thread was being restarted everytime a POST was received.
This wasn't working correctly for multiple POST requests, it would only
work for the first POST request. This is also a very heavyweight action.
This uses thread signals instead and keeps the blink thread alive for
the whole application

Todos

  • Tests
  • Documentation

Deploy Notes

Notes regarding deployment the contained body of work.

Steps to Test or Reproduce

Clone master and try POSTing twice. I have reproduced the failure on the NUCLEO_F429ZI in the online compiler.

Impacted Areas in Application

  • Blinky thread.

@teetak01
Copy link
Contributor

Is this still valid?

@bridadan
Copy link
Contributor Author

Yes, just tried with the latest master and the POST doesn't work the second time. After applying this fix the POST works as expected.

Looks like the history has gotten a bit goofed up with this branch though, I will close this PR and reopen from my fork.

@bridadan bridadan closed this Nov 16, 2017
@bridadan bridadan reopened this Nov 16, 2017
@bridadan
Copy link
Contributor Author

Well actually after going through the history of this PR it looks like your CI doesn't handle forks? In that case I'm just force pushing to this branch again.

@teetak01
Copy link
Contributor

rebuild

Copy link
Contributor

@teetak01 teetak01 left a comment

Choose a reason for hiding this comment

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

Rebase + fix merge-conflict.

The blinky thread was being restarted everytime a POST was received.
This wasn't working correctly for multiple POST requests, it would only
work for the first POST request. This is also a very heavyweight action.
This uses thread signals instead and keeps the blink thread alive for
the whole application
@bridadan
Copy link
Contributor Author

Rebased!

@teetak01 teetak01 merged commit 3afd408 into master Nov 28, 2017
@teetak01 teetak01 deleted the fix_blinky_thread branch November 28, 2017 06:58
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants