AMP Interface and API no longer showing number of active users on minecraft bedrock since update

  • 280 Views
  • Last Post 1 weeks ago
Cardy posted this 19 November 2020

OS Name/Version:

CentOS 8.2.2004

Product Name/Version:

AMP Release "Europa" v2.0.8.2, built 10/11/2020 17:57

Module Minecraft (Bedrock)

AMP Version │ 2.0.8.2

Release Stream │ Mainline

Problem Description:

Before the latest release when a user joined the server the manage instance page showed the correct number of users. This is no longer being updated and always shows 0.

I believe this is an issue related to the API as I have been writing a script to get the number of users from the API which was working fine.

I could query the instance of minecraft that was running using

"/API/Core/GetStatus" and the key "Metrics.Active Users.RawValue" would return the active number of users.

The API for the instance now always shows 0 for this metric.

I also query the endpoint "/API/Core/GetUserList" for the user list again previously this provided a list of the users xuid and Username. This now just appears to return an empty list.

Steps to reproduce:

Start bedrock instance Click on the instance and select manage Click on the status button so Active users is visible join the server Active Users remains at 0

Query the API for the endpoints above and even though I am successfully logged in I get back 0 for Active Users and the userlist is empty when querying appropriate endpoints.

Actions taken to resolve so far:

I have logged out on the frontend and cleared my cache. I have restarted the instances and even rebooted the server to get a clean startup after the upgrade. I have checked the logs but nothing is obvious to me as to why there is a problem.

Order By: Standard | Newest | Votes
Mike posted this 19 November 2020

This is a duplicate of the issue immediately below yours. There's a temporary workaround in the Nightly build. They changed the logging format for Bedrock.

Cardy posted this 19 November 2020

Hi Mike,

Thanks for the quick reply. I tried changing the server to the nightly build but when I run on my bedrock instance it shows the main port for minecraft as CLOSED.

ampinstmgr --Showinstanceports Kids02

[Info] AMP Instance Manager v2.0.8.2 built 10/11/2020 17:59
[Info] Release spec: Release - built by CUBECODERS/buildbot on CCL-DEV
[Info] Port usage for Kids02 (Kids)
[Info] Instance is currently running.
[Info] LISTENING    8082    TCP (Core.Webserver.Port)
[Info] LISTENING    2225    TCP (FileManagerPlugin.SFTP.SFTPPortNumber)
[Info] CLOSED       26677   Both    (MinecraftModule.Minecraft.PortNumber)

The server appears as running according to the console in the instance manager and I can see stats from it I can also query the console.

Lee

Mike posted this 19 November 2020

Ampinstmgr doesn't show the status quite right for ports where the protocol is 'both'. It's a bit of a hack due to the way the same module handles both Bedrock and java edition but they use different protocols.

Cardy posted this 19 November 2020

Mmmm I can't actually connect to the server using the client though and the server is not showing the port specified 26677 as actually being open for connections to the bedrock instance in the server itself.

Mike posted this 19 November 2020

Check using netstat

Cardy posted this 19 November 2020

Hi Mike,

Thanks for your continued help. I did check netstat and it was not showing as being in use that's what meant by the port is not open in the server itself, I should have been clearer.

I restarted the whole server and it seems to have sorted out the server binding to the port but the number of users and the list of users when checked as originally reported are still not working even with the nightly build.

I still get a number of users as 0 and an empty user list via the API.

Lee

Mike posted this 19 November 2020

Do they show in the panel correctly?

Cardy posted this 19 November 2020

No the panel does not show any users connected even when I am connected to the instance.

Mike posted this 19 November 2020

Some more changes are probably needed then, when they change the logging format then AMP needs a fair few changes to accommodate this.

Cardy posted this 19 November 2020

I'm guessing this is why my trigger for "When the last user leaves the server" Run "start a backup" isn't working as they API doesn't know the last user left.

hedgehogspen posted this 20 November 2020

I'm seeing the same, though in my case the console correctly shows users logging in and out, it's just the Status page that's not updating.

A further thing I noticed was that the 'Starting Server' Notification just sits there, even once the console shows the server as started (and I can log in).

This is on the main build and not nighly btw.

Cardy posted this 22 November 2020

Hi hedgehogspen,

I had that same problem of the status always showing starting but I found after a reboot it seemed to fix itself.

I suspect the amp manager getting restarted would have solved it too, but could cause the api and the status page (which I suspect uses the api to stop reporting the number of players)

Cardy posted this 23 November 2020

I have updated to the latest version 2.0.8.6

The release runs fine but I has not resolved the problem with the status page showing no users.

Kylaris posted this 02 December 2020

I am having the same problem. It always shows 0/10 users.

hedgehogspen posted this 06 December 2020

Yup, also on 2.0.8.6 and still have the same problem. As you say Cardy, a restart seemed to resolve the Notification issue.

Have also noticed that scheduled tasks are no longer working, but can see from another thread that Mike is looking at that, so I suspect the API thing is of lower priority.

Gotta love an API change...but hey, I'm sure if MS didn't keep changing stuff all the time Mike would only get bored :-)

Mike posted this 06 December 2020

It wasn't an API change, its an issue that prevents AMP from knowing that players have joined/left. Message syntax changed.

Cardy posted this 07 December 2020

You've got to love it when the up stream vendor changes the format of the system without notice.

Fingers crossed its an easy fix to the new format.

Cardy posted this 15 December 2020

I was wondering if there was any update on this as the number of players and the names of players are still not available in the API.

Scott posted this 24 February 2021

Hi, it's been a couple months, and I just wanted to follow up if this was in the works for an upcoming release?

Thanks, Scott

Cardy posted this 02 March 2021

I still find that the number of users is not shown, they are also not available in the userlist via the API which I am guessing is a related issue.

It seems to work on Java Minecraft but not on bedrock.

Mike posted this 02 March 2021

Bedrock hasn't had any development time scheduled for it recently while we've been addressing other priorities. It will be looked at but it's just been less important for now.

elrooko posted this 2 weeks ago

Assuming this would affect webhooks as well from Bedrock? I'm not getting any events published out of bedrock so all my discord webhooks are not showing up...frustrating.

Is there an ETA?

ranstop posted this 1 weeks ago

Can confirm this is still an issue today. This has also broke my webhooks which i relied on.

Do we have an ETA on this fix?

Thanks!

Close