Missing videoTrack in a multitrack stream in Ant media server 2.4.1 - ant-media-server

We have a Multitrack web conference implementation using AMS 2.4.1 version. Its working great for our use case, except in one scenario. When there are N (< 3) number of users and they on there camera simultaneously, then few remote users are not rendered as we don't receive the video tracks for those users in newStreamAvailable. We only receive the audio track for those users. We are able to reproduce this quite frequently.
As a backup, I am trying to poll AMS using getTrackList with the main track Id to get all available streams, but I am not getting any message trackList
var jsCmd =
{
command : "getTrackList",
streamId : streamId, // this is roomId or main track id
token : token
}
Any insight would be helpful.
Thanks,

We were able to resolve the issue, posting here to help anyone who might be facing a similar issue.
With push notifications from the server, we might encounter issues when for some reason push operation doesn't succeed. In that case, it's better to have a backup plan to pull from the server and sync.
The Ant Media Server suggests pulling the server periodically for the room info. The server will respond with active streams and the application should synchronize.
For reference, please refer to following link https://resources.antmedia.io/docs/webrtc-websocket-messaging-reference

Related

Multiple Realm clients showing new information but MongoDB showing old

Extremely weird bug we’ve been facing today.
We have an iOS app which has updated a document using Realm SDK and I know it has been pushed successfully because I checked the forCurrentlyOutstandingWork session to confirm a 100% upload and also opened up another device to validate if it got the new updated information and it has.
The problem is even though Realm clients across multiple devices are showing the new updated information, the MongoDB doesn’t show the new updated information. It did update after 15 mins automatically but this issue happened to us multiple times today.
Has anybody else faced this issue and found a solution to it ? Or should this never happen and we need to report a bug ?
TIA
Edit:
Realm sync write log -
Logs:
[
"Upload message contained 1 changeset(s)",
"Integrating upload required conflict resolution to be performed on 0 of the changesets",
"Latest server version is now 249"
]
Partition:
1
Write Summary:
{
"Image": {
"updated": [
"612ce539db1dbb2655f6c723"
]
}
}
This was an issue in MongoDB/Realm. I reached out to the support and they resolved it by pushing an update on the 9th of September 2021.
The replication to MongoDB is asynchronous due to the fact that conflict resolution must be performed against incoming writes from MongoDB clients (which sync does not control), to prevent the situation where a write made to MongoDB and a write made by a Realm client pass right by each other and leave the two states inconsistent. Ideally, these writes should happen within a few milliseconds but some latency can occasionally occur (especially around server restarts), but we closely monitor this and are always looking to optimize this.
Engineer on the Sync Team

Telegram, tracking message edit/delete and editing my own messages (Client, not Bot API)

So I'm trying to implement the logging of telegram chats into my ELK storage in a proper way, and the existing solution with tgcli is too old (I also have a PoC which logs message edits from Android client via Xposed, but its implemented on top of UI level and is ineffective)
I need to receive edits/deletion of messages, and do it with client Telegram API.
Spent a day on researching it:
support for editing messages appeared in May 15, 2016 (telegram blog)
telegram-cli's tgl library is 2 years old and most likely has no support for that layer
I looked into telegramdesktop source as it was very promising, unfortunately their git history has no scheme changes poiting to edit support.
And the official layer version list is truncated. Security via obscurity eh.
from some tests done with golang library used in shelomentsevd/telegramgo, edits in supergroup are handled by TL_updateChannelTooLong message
Now I don't want to lose more time picking the libraries/sources. So, I'm asking about the experience with either of the following libraries, I'm looking for exactly one library which will allow to implement the required features fast - for someone who doesn't want to dive deep into MTProto's specifics.
sochix/TLSharp is missing explicit examples about getting edits. Probably would be hard
danog/MadelineProto seems like a good place to start
there are also tdlib, libqtelegram, TelegramAPI
It's much easier to do it in telethon.
Here is a sample code I've put together gathering snippets directly from the docs.
from telethon import TelegramClient, events
API_ID = ...
API_HASH = " ... "
client = TelegramClient('session', api_id=API_ID, api_hash=API_HASH)
#client.on(events.MessageDeleted)
async def handler(event):
# Log all deleted message IDs
for msg_id in event.deleted_ids:
print('Message', msg_id, 'was deleted in', event.chat_id)
#client.on(events.MessageEdited)
async def handler(event):
# Log the date of new edits
print('Message', event.id, 'changed at', event.date)
with client:
client.run_until_disconnected()
Docs for: MessageEdited, MessageDeleted)

Python receive Google Drive push notification

Since the Drive SDK v3 we are able to receive push notifications from Google Drive whenever a file has changed. At the moment I'm working on a Drive application in Python and I would like to receive such notifications. Do I really need a web server for this or can I implement this maybe with a socket or something like this?
I know that I can get changes by polling the changes.list method but I want to avoid this because of so many API calls. Is there maybe a better way to get informed if a file has changed?
EDIT: I captured my web traffic and saw, that the original Google Drive Client for Windows uses push notifications. So in some way it must be possible to get push notifications in a desktop application but is this maybe some sort of Google magic which we can't use with the current API
For Google Drive apps that need to keep track of changes to files, the Changes collection provides an efficient way to detect changes to all files, including those that have been shared with a user. The collection works by providing the current state of each file, if and only if the file has changed since a given point in time.
Retrieving changes requires a pageToken to indicate a point in time to fetch changes from.
# Begin with our last saved start token for this user or the
# current token from getStartPageToken()
page_token = saved_start_page_token;
while page_token is not None:
response = drive_service.changes().list(pageToken=page_token,
fields='*',
spaces='drive').execute()
for change in response.get('changes'):
# Process change
print 'Change found for file: %s' % change.get('fileId')
if 'newStartPageToken' in response:
# Last page, save this token for the next polling interval
saved_start_page_token = response.get('newStartPageToken')
page_token = response.get('nextPageToken')

how can i monitor iccube server and data via an external tool

I'd like to put iccube under solid monitoring so that we know when a) cube load failure or b) cube last update time exceeded the expected.
is there an api i can use to integrate with standard monitoring tools?rest, command-line etc ...
thanks in advance, assaf
Regarding the schema load failure you can check the notification service (www); you can for example receive an eMail on failure. Note that you can implement (JAVA) your own transport service to receive notifications. There is no "notification" for last update time exceeded but if you could use an external LOAD command (www) for loading your schema; in that case you will know the last update time and perform whatever logic required.
Edit: XMLA commands can be sent via any tools (e.g., Bash).
Hope that helps.

Does the Xively API -> Product Management -> Devices -> Update a Device work for anyone?

As you know, Cosm just turned into Xively on Tuesday.
They've added APIs for Products and Devices, and I'm trying to connect to them.
I'm running into problems getting the "Update a Device" API to work. The specific API is documented here:
https://xively.com/dev/docs/api/product_management/devices/update_device/
Anyone else have problems getting this call to return anything other than a 500 error message: '{"title":"Oops, something's broken","errors":"We've been unable to complete your request due to a problem with our server"}' ?
it's probably best mailing support#xively.com with this question I think. I just tried making the serial number update request on one of my devices via the API, and it seemed to work ok; so if you mail them then they'll be able to investigate your specific device.

Resources