Comments (4)
Another possible solution might be to disable and re-enable the stack on a link timeout.
from opendatacon.
After some investigation:
- There's no way to close the connection directly. The opendnp3 API only exposes a Shutdown() interface on the channel which destroys everything. The only way to get it to close is to disable all the stations on the channel together, and that's not feasible with the current architecture.
- Disabling and enabling the stack should solve the immediate issue of ensuring the startup integrity scan is triggered, and for the single drop case the connection will close, but it leaves the issue of broken connections remaining open for multidrop...
So I'll implement the disable/enable workaround and open a separate issue for the underlying broken connection issue.
from opendatacon.
Commits
c0dac2f
3b36018
07208b6
should solve this issue.
A summary of the changes:
- Refactored the link state logic and channel handling in general
- This exposed a regression that appeared in June 2018 on multidrop channel listening - fixed
- It also exposed a logical error or false assumption about the link layer callbacks from opendnp3
- There's not always a callback when a link recovers, because there isn't always a keepalive success or link status change
- Fixed by setting the link up on IIN callback for master and time without a keepalive failure for outstation
- There's not always a callback when a link recovers, because there isn't always a keepalive success or link status change
- Added a watchdog for each channel to coordinate a synchronised restart of protocol stacks if all links on a channel go down
This all means that multidrop station failures don't affect the other stations on a channel, but channels still get reset if all station are affected.
TODO: add test cases
- For both Outstations and Masters, and both directions (and a mix) of TCP client/server
- single drop link failure = channel closed and re-established
- multidrop partial links failure = links fail and re-establish without channel close (comms point behaves)
- multidrop all links failure = channel closed and re-established
from opendatacon.
Tests added
from opendatacon.
Related Issues (20)
- Remove warning in ConfigParser.cpp HOT 1
- At shutdown command opendatacon is crashing HOT 4
- Implement Add / Del remaning sinks like file etc.
- Create /OpenDataCon List / help and ls_sinks to return Json Value HOT 1
- WebUI: Convert indexes from numerical to human readable
- WebUI -> Create a helper function
- Still the shutdown is crashing :'( HOT 6
- Adding returning json values for ls / list / help commands HOT 1
- JS modules like spd_log and every other 3rd party module can be downloaded at build time
- Cmake initialization failing at dnp3 port build / install step HOT 2
- Console UI not functioning properly HOT 2
- Microhttpd fails with alot of open filehandles HOT 3
- Monitor ASIO in case of task queue backups
- TCPSocketManager resolves hostname only on start HOT 1
- opendatacon should return numeric values not string from http interface
- Refactoring the Binary Control containers and their current states
- Should we use a different webserver library? HOT 6
- URGENT/BLOCKER Travis CI becoming non-free HOT 2
- Develop test cases for http and rest api code
- Python std lib packaging missing binary modules under Windows
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opendatacon.