Heroku App accessible only from a few devices - heroku

I deployed a web app to Heroku yesterday and it seemed to work if I access the URL from my machine. However I was not able to access from any other devices on the same AND different network.
I thought that maybe it's just my browser cached the website and in reality it's down.
Some of the web services that tell you if a specific URL is down or not report various results - some say it's down, some say it's up.
(Not sure if I can post links here!)
http://downforeveryoneorjustme.com/rock-paper-scissors-.herokuapp.com
https://currentlydown.com/rock-paper-scissors-.herokuapp.com
But then again - I am able to see it via https://browserling.com/
I thought that this might be due to cached DNS but 1 day is way too long and Android flushes DNS after every 10 minutes (as far as I know)

To see if your app on Heroku is running and responding to requests, use the Heroku Toolbelt command
heroku logs --tail
This command shows messages about the app status, i.e when it is up or if it crashes.
Having the logs running with the tail option show the requests as they happen.
If you are on the Heroku free plan, then your application will sleep after 30 minutes of activity.
Once sleeping, the next request to your Heroku app will automatically wake the app up. The time taken to wake your app is largely dependant on how quickly your app starts, but should be a matter of seconds hopefully.
If an application is a little slow in starting, this could lead to a timeout and making it seem like you app is down.
If you do not see real-time log entries when trying to access your Heroku app from a particular device or network, my only thought is that there is some network policy or device blocking access to certain IP ranges (ie. Amazon Web Services).

Related

How to check why my Heroku application cannot reach remote host?

I have deployed heroku application - Ktor server that was working for 2 years and everything was working perfect. Since few days my application cannot access host (https://api.um.warszawa.pl/). It's getting timeout error all the time. API is accessible from my local machine. How can I check who blocked the access and why? Where can I ask for enabling the access again? Any ideas?
I have the same issue. I have had contacted the API team at Warsaw Town Hall - they have told me that City's Centre of Network and Data could set location restrictions on the API due to CHARLIE-CRP alarm.

My bot is staying online even after I've shut down all possible hosts

Today I noticed that my bot was sending double messages (usually means that it's running 2 clients). After I shut down my bot from heroku, it was still online. Any idea how can I fix this?
Check if you are running the bot locally, and make sure all servers linked to the bot are turned off, sometimes the bot takes a while to completely shut down and go offline in discord, so try waiting for a few minutes.
in Heroku => navigate to resources tab and turn off npm worker: start

Occasional 404 response Heroku

I have deployed an Elixir/Phoenix web app on Heroku 2x instance, the backend is in Postgres. The app works fine most of the time but every now and then it returns no such app I am not able to figure out, why is it happening. I have checked the logs and metrics but nothing is helping. In fact, no logging happens when such errors are happening. It feels as if temporarily the DNS resolver on their side has crashed. I haven't added any custom domain and using the default domain name provided by Heroku.

Accessing a Firebase-deployed App over a VPN

I built an app to offer a client of the company I work for that I deployed to Firebase. It uses Firebase storage for retrieving files as well as the realtime database. It's actually just the front-end portion of a two-app suite I made; the backend portion is used by an admin for uploading files, checking data, etc --- which data then becomes available to view over the frontend. Both use firebase.
It turns out the devices that would need to access the app (tablets mostly) are inside of an extranet with a server that can establish VPN connections only. Now I'm being asked how I can build the app so these devices can access the app.
I don't know much about the inner-workings of Firebase but it seems to me I may have couple of options:
1) Figure out how to make the FB database accessible over VPN (preferable)
2) Reconfigure the app to use something like MongoDB. Instead of deploying on a remote server, let the on-site server service the devices using the app. Send files that are needed by the server via FTP over the VPN, then process these files on-site.
Problem: I'm using a Mac and the on-site server uses Windows. It will be a pain to install things on a Windows machine remotely, let alone set up the VPN.
Any ideas? I'm sure there are parts of this question where I've made wrong assumptions --- I've never needed to do things over a VPN before.

Glassfish 4.1.1, domain installed as a service does not restart as a service

I got a Glassfish 4.1.1 copy with two domains on Win2012R2 (no clusters, no instances). I've set a windows service for each of those.
Both services run regularly up until the moment when I restart either or both of them thru their admin web console (server (Admin Server) -> Restart). The following happens:
The domain-related service stops, but does not start again,
The allegedly stopped domain is perfectly functional (deployed apps and admin console are there) (!!!),
When I try to start the win service manually, I get Error 1067 (GF reports "something" is already listening on required ports and that's the domain itself that is now, somehow, NOT run as a service!),
I can start the service again only after I've stopped the domain thru server (Admin Server) -> Stop.
Why did I mention two domains? Because this does not happen when I have just one domain with its' service.
Domains do not share ports, only things in common are the JDK/JRE and general GF files.
Is this a bug in Glassfish or did I set something wrong?
This is a limitation, rather than a bug. The problem is that GlassFish has no way to tell whether or not it is running as a service (and, if it is, what the name of that service would be).
The restart command means that GlassFish is restarting itself, so Windows detects that the process it started has been terminated and shows the service as stopped, but GlassFish spawns a new JVM itself. It has no capability to tell Windows to start the service again.
Essentially, the behaviour you are seeing is expected.
After some more testing, I realized what was going on:
Glassfish is definitively capable of restarting its' own Windows service,
The thing that was happening is it takes GF a few seconds do this on its' own,
But, before GF domain could restart as a service, I clicked the URL to return to admin console, every time. That forced it to run as an ordinary executable.
It does seem like the restart happens faster with just one win service, but I won't claim that as an absolute truth without more testing, for which I have no time now.

Resources