I am using this plugin to help my web-app communicate with Atlassian JIRA.
So my question -> Is there a proper way to close net.rcarz.jiraclient.JiraClient instance when I'm done with it?
I'm guessing leaving it be and creating a client = new JiraClient(uri,creds) when next user logs in is not a good idea...
JiraClient doesn't keeps a connection open, it just uses the supplied credentials for each request. You don't have to close it. As far as I can tell, you a free to use multiple JiraClient concurrently.
Related
How do I make an actual remote call?
I've followed the guide: https://codelabs.developers.google.com/codelabs/webrtc-web/#4
And gotten their example fully integrated in my application (Angular, TypeScript, multi webcam &etc).
How do I make the remote call actually remote? - I get the idea of a signalling server, but maybe someone can show with basic strings?
I found this, but it's not been updated in a while so I'm not sure what's still valid:
Found some nice sequence diagrams https://webrtc.org/native-code/native-apis/
Setup call
(source: webrtc.org)
Receive a Call
(source: webrtc.org)
Close Down a Call
(source: webrtc.org)
My system has an app under an umbrella which starts up several GenServers, which on init make some dB calls, and thus get their own connection.
The problem is that in my tests of a controller where I have inserted some records into the dB, the controller makes a call to one of those GenServers, which then does some more dB queries. But since it is a different sandbox, it does not see the records.
I am looking for a solution in general that would allow existing, running GenServers to use the same sandbox as the test. I would greatly appreciate any ideas. I tried adding the following right after the sandbox checkout in the test setup, but didn't help:
Ecto.Adapters.SQL.Sandbox.allow(MyApp.Repo, self(), Some.GenServer)
The only working solution I found was to allow the GenServer to be started with an alternate name, starting it up thus using the same sandbox db connection as the test, having my controller use this differently named version, and shutting it down right before the end of the test.
Seems that I ended up with the same issue.
My solution was to keep the default Phoenix settings, and terminate and restart my process before each test, like this:
setup(%{conn: conn}) do
Supervisor.terminate_child(Some.Supervisor, Some.GenServer)
Supervisor.restart_child(Some.Supervisor, Some.GenServer)
{:ok, conn: conn}
end
Tests SHOULD NOT be async: true
Is there a way to test if current user has been authenticated to BBG? I have my c# program which uses BBG API, and want to check if the user logged in the service before, either via API calls or the BBG Terminal. This check can then be used to distinguish whether the user's network is unavailable or simply he hasn't logged in yet.
Thanks!
There's a couple of ways to interpret your question, so I'll answer both... (I'm speaking from the perspective of using the Java API, but it should be pretty similar on C#.)
1. Can I tell whether the user connect to Bloomberg (i.e. are there network issues / are they are logged in)?
Yes - you can create a new Session, try to start it using .start(). If it fails or returns false, you cannot connect. If it starts, you can call .openService("//blp/apiauth"). Again, if it fails or returns false, you cannot connect.
If you cannot connect, you may or may not be able to determine why you cannot... Nevertheless, I would suggest registering a callback to the BLP API logging framework. In our code, we we-direct these to the logging framework we use throughout our code.
2. The user has created a Session (pre-cursor to a Service) - can I tell if the Session has been started?
Unfortunately - no. There is nothing in the API to allow you to determine the state of the Session. (I suppose you could try starting it, and if it starts it wasn't started, and if it fails, it was started - but that strikes me as an unhelpful or risk appraoch.)
I tried using MULTI_MODE_PROCESS above API Level 11. But still I am not getting updating values in activity and values were updated in remote service. I am not able to share preferences in remote service and activity even in froyo,ginger bread versions.Is this a bug in Android ? Any solution we have for this ?
Without code, it's not clear exactly what you're doing, but my guess is that you did the same thing I did at first: simply change your existing call to getSharedPreferences() to use MULTI_MODE_PROCESS and expect synchronization. That's not enough; you also must call getSharedPreferences() again (with the multi-process flag) before accessing the SharedPreferences that may have been changed by another process.
My application needs up to 3 simultaneous download connections. I am currently using a (slightly altered) CWebClient class provided in the Carbide UI framework, however using multiple instances of this for each connection prompts me multiple types to "select access point"
An RSocketServ and an RConnection object exist in the class, these appear to be the things that open the access point. Would it be a good enough solution to make these static objects (singleton) so the access point is only called once?
Any one have any experience/thoughts?
Thanks!
Just in case you wonder, I am using S60 3rd ed. FP2 v1.1
RConnection should be the class that triggers the access point selection dialog.
If you write your own code, get one instance of RSocketServ and 3 instances of RSocket. That should be enough. The access point selection dialog will only occur when the connection is established, which will happen only once until you hit a non-coverage area or your downloads time out.
The other way is to suppress "Select Access Point" dialog. You can do it by using CIntConnectionInitiator to establish a connection. Although this class isn't documented there is a bunch of examples on forum.nokia.com.
Roll your own accesspoint (AP) selector and store the AP ID .
Then use TCommDbConnPref to set AP ID and suppress the dialog.