I am looking for solution to remove state machine's self connection. By self-connection, I mean the connection to itself.
On Jsplumb website, connections are removed on clicking it. I am performing some other action on onclick of connection so I would like to have some other option for removing this connection specifically in self connection situation.
In other case, where there is connection between two separate states, I am able to remove connection just by dragging arrow of connection away from the state. This can be tried on http://jsplumbtoolkit.com/statemachine/jquery.html.
For self connection it is not possible to drag arrow point.
I tried to search why this is happening in jsPlumb (version 1.4) js file.. I found that for self connection it doesn't add class '_jsPlumb_endpoint_full' i.e. it doesn't add endpoint at arrow while for connection between two states it adds this class for arrow point.
Can somebody please suggest me or at least provide a hint on this ?
Related
Briefly question. As the title shows of, Im searching for a possibility to config openWRT so that only one client connection will be allowed over an access point. Further connection trials should be rejected if one client is connected already. Is this possible by configuration only within the openWRT config?
I think you need to set the maxassoc option in the wifi-iface section. Setting it to 1 should do it.
The option is described here: https://openwrt.org/docs/guide-user/network/wifi/basic#common_options1
I have created an Amazon RDS DB instance. I can connect to it and perform operations with SSMS. I can also bind to it using Entity Framework DB-first and generate my model. However, when I run my app, using the same connection string that was generated in the data access project, I get a "the network path was not found" error while trying to establish a connection to the DB.
Let me be clear: the db exists, the right ports are open, and the connection string is correct. I am the only one connecting to the database and the status is "available".
So what's going on? Has anyone experienced something like this?
Let me also further mention that I have already checked the usual things like internet connectivity, firewall rules, state of the database, etc.
well it started working all of a sudden. So I guess this problem will only pop up again in production or something.
I'm using code from a demo program using Devart's MyDac component using Delphi 2009 to connect to a remote database using SSL.
I have made and verified the certificates and keys and set the connection parameters in MyDAC to use them eg
MyConnection.protocol := 'mpSSL';
MyConnection.SSLOptions.CACert := 'C:\ca-cert.pem';
MyConnection.SSLOptions.Cert := 'C:\client-cert.pem';
MyConnection.SSLOptions.Key := 'C:\client-key.pem';
MyConnection.SSLOptions.Chipherlist := 'All';
When I tell MyConnection to connect (after setting the user name / password etc) it connects to the database with no problems.
However as a test I deliberately put in an invalid key name of 'C:\XXXclient-key.pem and it still connected OK so maybe it wasn't using SSL at all.
So my question is:
How can I use Delphi to detect if a connection is really using SSL or not?
I think I'll close this question myself as it seem far more complex than I thought it was and I need much more information before this question makes sense. It appears that the sql statement;
SHOW STATUS LIKE 'Ssl_cipher'
can help as its value will be empty if its not using ssl or will contain an value if it is.
The touble was the Mysql server I was using (ISP Nativespace) did not even have a variable name called Ssl_cipher so it looks like it doesn't support ssl anyway. Trying the same thing using another ISP I did see the variable name but it had no value, showing that was also not using ssl even I though it could do it.
It now appears that there is much more that needs doing before a ssl connection can be set up. Creating a new user on the db that only ever uses ssl, setting up permissions for them, running code on the server etc.
Not at all as simple as Devart's web page on securebridge leads one to believe!
"It is enough to place several components on the form and specify the
server address and the user login information to establish a secure
connection."
Err... not quite!
So I am working on a project where my iOS application acts as a server and receives connections from clients that send location data. My application reads this data from a socket and either updates the location of the clients on a MKMapView or creates a new one if it is a new connection.
I have my code completely unit tested so I feel some what confident about it. However, I am trying to write an acceptance test that will start my app and have a client connect to the socket, send some data and see if my app adds an MKAnnotation to the map view. Now I have had a little bit of experience with UI Automation but my issue is how can I write this networking code.
Here is what I need the test to do:
1.) Go to view controller where this networking code is happening (Easy enough with UI Automation)
2.) Once the view controller is loaded the server will start on port 2500 (Easy enough)
3.) Have a client connect to the server and send a message (This is what I don't know how to accomplish)
4.) Assert that the MKMapView has an annotation with the information I sent (Easy with UI Automation)
I know there is nothing native to javascript that will allow me to work directly with sockets, but could I use a library that uses web sockets? Other than that option I have not been able to find any resources online to solve testing a problem like this. I am open to any suggestions since I really don't know how to tackle this problem. I am sure there must be some way to test this. Thank you in advance and I am eagerly awaiting any suggetions!!
I'm getting started with websocket-rails, trying to convert an old polling system for notifications (on Ruby 2.1/Rails 4.0) to something a bit more modern with WS. I'm using WebsocketRails in standalone mode, here is my configuration, basically, the default:
WebsocketRails.setup do |config|
config.standalone = true
end
I have also setup a fresh Redis running on the default port - there seems to be no communication issues here.
On the client side, I have added the websocket-rails's JS and when trying to open an connection and subscribe to a channel, with:
#dispatcher = new WebSocketRails "localhost:3001/websocket"
#channel = #dispatcher.subscribe "notifications"
I see an error in the Chrome console:
WebSocket connection to 'ws://localhost:3001/websocket' failed: Invalid frame header
In Firefox, the error is different but still an error:
The connection to ws://localhost:3001/websocket was interrupted while the page was loading.
From the websocket server logs, I can see that a connection has been initiated and then dropped, but there are no other logs, even tho log level is "debug"... There are no other errors that I can see and a cursory Google search doesn't bring up anything regarding "invalid frame header", so I'm pretty much stuck.
Any help would be appreciated!
EDIT: I ended up using NodeJS+Faye to get things moving, and it has been working so well that I'm happy to introduce this new moving part in the system. I'm sure the issue was just something temporary based on my specific setup but sometimes, you just have to get things done.
I think you are looking for the following resources:
From the question thread: debugging websocket in google chrome
Chrome developer tools now have the ability to list WebSocket frames and also inspect the data if the frames are not binary.
Process:
Launch Chrome Developer tools
Load your page and initiate the WebSocket connections
Click the Network Tab.
Select the WebSocket connection from the list on the left (it will have status of "101 Switching Protocols".
Click the Frames sub-tab. Binary frames will show up with a length and time-stamp and indicate whether they are masked. Text frames will show also include the payload content.
Theres also this (somewhat old) blog article from 2012: Inspecting WebSocket Traffic with Chrome Developer Tools
I think that there's something wrong with the format of the data being sent over the wire.
Carefully look at the format of the message. Has it been properly stringified? Do your brackets and parens, {}, [], and () all match? Did your IDE insert an extra somewhere? Try validating a message with a linter or an online validator.
Inspect the message on both the sender and receiver sides. Make sure that everything is correct.
This may not be the answer to the author's original question but I want to add a possible solution to this Invalid Frame Header error.
From my small research, Invalid Frame Header can be generated on Websocket protocol when the server sends an empty response (message with 0 length). 0 length in TCP signals that connection has been closed and therefore any data transmission after the empty message fails.
This is the link that helped me to find this solution. I hope someone in the future will find this useful and save some time.