I am working on push notification in my Windows Phone App and I am having this issues.
From time to time the BackgroundTask which is responsible for push notification handling isn't wake up I know it- cause I've spread logs after each code line in my Task.
I know for sure that my token is valid and I am getting the notifications from the server.
This happens only when debugger is not attached.
I don't see any exception either in my log.
I can see in my logs, that one line before I am showing the Toast is cut at the end in a middle of writing (guess the task was terminated suddenly?)
Any ideas what can cause this behavior?
I think that the main problem was that I tried to use too many of CPU time , while writing logs and using my heavy application services (MvvmCross) such as Sqlite.
After removing logs, and heavy consuming time operations - everything worked :)
Related
I have a couple of IoT devices hosted on Thinger.IO and as part of their code execution from time to time they try to invoke thinger.io endpoints. This basically is their way of letting you connect with your business back-end services and handle IoT devices events.
It basically looks something like this:
as here at step 3 we make a reference to Thinger.IO's input resources. This basically lets your back-end to invoke functions on your IoT device. The issue that I am facing right now is related to step 2
My endpoints just stopped getting invoked. When I try to test the endpoint using their embedded client:
I get an error which is saying:
I don't really understand that. The last time an endpoint was invoked was on the 27th of February (5 days ago) and since then I've had my device completely turned off.
SIDE NOTE: The problem is not with my back-end because we can successfully invoke the endpoint using Postman.
Thee free cloud (community version) of Thinger.io has some rate limiters to throttle requests per user. However, it seems that you are not reaching those limits, so it should be a bug introduced in latest release 2.9.9 in Community Version. Will look into it. Thanks for reporting.
Edit: It should be fixed now in 2.9.91 version. Consider using a private cloud instance if you are connecting a couple of devices ;)
If crash happened on mobile device, how developer team can receive it?
What should be logged to restore what happened? Just actions on objects and page transitions?
If my markup will looks wrong on some devices or application will behave strange or come to weird state, I want functionality to collect screenshot and info from device and send it. What is the best practices here?
The question is about sending the crash stack trace and logs out. Not about QML app per se but about its C++ base or just about C++ app if we have one. The app should have logging enabled and collect its activity info, maybe for the period of time or until the logs get large enough. We were splitting log in chunks files and removing the oldest after we've accumulated, say, 5 of 100kb chunks.
Crash stack/minidump. Both call stack for all threads and the time of the crash plus minidump of the code with all variables visible can be collected.
How to send the log and crash stack/minidump out? There solutions like BreakPad we supposed to link with/ enable in the app code. The app will take care of sending all the crash info out when it runs again after the crash.
Quite a few things to implement, no to mention the web service that collects the crash info from client apps.
And you have to have "symbols" for the app release code kept in order to be able to trace the stack and see variable values at the time of a crash.
How does stackdriver debug application which are in production?
Will the server be down during this period?
How would the latency be?
Is there a way we can debug to an incident that's 'already happened'? e.g. I have an application running in production. And there was an issue - say, I wasn't able to add an item to the shopping cart, or some other issue. Can we go back and debug the issue? Or does it debug the live application?
Stackdriver Debugger's core functionality is rapidly taking a snapshot of your running operation. This means your server is not down, but also means that you can't go back in time either.
Stackdriver Debugger has a quickstart and various other docs that can be useful in getting a basic understanding of what the product does.
Stackdriver Debugger is an always on, whole service debugger. You don't debug just a single server/VM but rather all of your servers belonging to the same service, at the same time. It captures the call stack and variables from a single server when the condition hits and then cancels the snapshot from all other servers.
Stackdriver Debugger agent doesn't stop the process, but briefly pauses the thread hitting the snapshot line and condition. Usually the thread is paused for about 3ms to capture ~64K of information, your time may vary.
Stakdriver Debugger agents are written from scratch with the purpose of optimizing for application latency. They use all sort of tricks to avoid pausing the running thread/server. (e.g., serialization of the data happens after the thread is released)
Stackdriver Debugger is a realtime interactive debugger. There is really now way to debug something that happen in the past. However, since it's a production debugger you can set your snapshot location in production and wait of the event to happen again.
One other feature of Stackdriver Debugger that might find useful are logpoints. These are log statement that you can insert dynamically to your application with a specific case/condition in mind. You don't have to make code changes or re-deploy your service. see the blogpost.
Background: This is largely a learning exercise. I am working on a task scheduling program. I have been asked to make it so that the application I am working on will send emails to users telling them they have messages waiting to be looked at. I already have the part that sends emails working right, but that only works when the user is actively on a page. I essentially want to make it so that the server decides to send emails at a certain time for instance midnight to tell users how many messages and meetings they have unread updates on during that day. I am not familiar with how to make the app do work when not receiving input from the user.
What I am looking for: How do I make ASP run a function on at a scheduled time.
Here we had difficulties with the functionality of a browser when scheduling the browser (starting with a specific page) on the server.
A Temporary solution was to make one page in your project that reloads after waiting 5 minutes <META http-equiv='refresh' content='6000'>, and start this page on a client or on the server. Note: The copy running on the server stops when rebooting the server.
The final solution was to make a .Net package using the right server-side objects, and schedule this package in task scheduler.
Use Windows Schedule Task to get IE to run the page at a scheduled interval.
e.g.
You will have to make sure that it runs unattended and with an account that is allowed to run it. Also you will want the page to close the window after having finished.
(How to configure and what Schedule Task looks like varies depending on your Windows Version)
We have an ASP.Net web application on IIS7 that is used to upload Excel files and then load them into a SQL database by running jobs on the SQL server. The app will wait until the job completes then show the user a message. Due to some larger files being used the app is throwing the error below.
Network Error (tcp_error)
A communication error occurred: "" The Web Server may be down, too
busy, or experiencing other problems preventing it from responding to
requests. You may wish to try again at a later time. For assistance,
contact your network support team.
The app uses an asp:View to progress from various steps. I have tried to bump the session timeout and httpRuntime executionTimeout values to account for how long the job takes to run but it does not appear to have any effect. I know the job completes but the app isn't showing that feedback to the user. I think the error is thrown as the app hits the logic to display the user the view showing all the final messages.
I can only guess that a) there is another setting I'm not aware of for timeout, b) another config file setting is overruling my web config setting for the app, or c) the asp:View is counting all the various steps as one long process and not reseting the "clock" as each step is completed.
As I said, the file upload fine, and the job completes fine, the app just can't advance to that last step where it shows the user the view upon the end. Any ideas on what I can look for to fix this issue? My only other option would be to rewrite the app to not wait for the job to finish and handle notifying the user some other way.
Update 1
After further testing it appears the error is from the ASP.Net custom code we created that does a SQL bulk copy and not the running of the SQL job. The current test runs around 220 seconds testing locally but causes a timeout on a test server.
Update 2
After more research I'm inclinded to think user pevgeniev is correct and this is just a limiting factor of the browser. The only thing that prevents me from marking this as answered is I don't know why file uploads don't appear to have the same issue.
If you're getting this error in the browser, than the timeout is on the client side, and there isn't much you could do server side. As you've suggested, you could rewrite the app, so that it polls for the result from the client, rather than expecting to finish the task in a single request.