Skip to content

Commit

Permalink
New webhooks playStart, playStop, recordStart issue #4666
Browse files Browse the repository at this point in the history
  • Loading branch information
lastpeony committed Jan 17, 2023
1 parent f7297b1 commit 0f612e8
Show file tree
Hide file tree
Showing 14 changed files with 57 additions and 1 deletion.
14 changes: 14 additions & 0 deletions 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
New webhooks playStart, playStop, recordStart issue #4666

# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the commit.
#
# On branch newWebHooks
# Your branch is up to date with 'origin/newWebHooks'.
#
# Changes to be committed:
# modified: src/main/java/io/antmedia/AntMediaApplicationAdapter.java
# modified: src/main/java/io/antmedia/statistic/ViewerStats.java
# modified: src/test/java/io/antmedia/test/AntMediaApplicationAdaptorUnitTest.java
# modified: src/test/java/io/antmedia/test/statistic/DashViewerStatsTest.java
#
7 changes: 7 additions & 0 deletions null/webapps/junit/streams/010377385515858588541652.m3u8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:0
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:0.000000,
010377385515858588541652000000000.ts
#EXT-X-ENDLIST
Empty file.
7 changes: 7 additions & 0 deletions null/webapps/junit/streams/130648337158084781489317.m3u8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:0
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:0.000000,
130648337158084781489317000000000.ts
#EXT-X-ENDLIST
Empty file.
7 changes: 7 additions & 0 deletions null/webapps/junit/streams/305147821057798436984629.m3u8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:0
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:0.000000,
305147821057798436984629000000000.ts
#EXT-X-ENDLIST
Empty file.
7 changes: 7 additions & 0 deletions null/webapps/junit/streams/371459229667024016956787.m3u8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:0
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:0.000000,
371459229667024016956787000000000.ts
#EXT-X-ENDLIST
Empty file.
7 changes: 7 additions & 0 deletions null/webapps/junit/streams/393657863698685730684471.m3u8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:0
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:0.000000,
393657863698685730684471000000000.ts
#EXT-X-ENDLIST
Empty file.
7 changes: 7 additions & 0 deletions null/webapps/junit/streams/668883968102040044966364.m3u8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:0
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:0.000000,
668883968102040044966364000000000.ts
#EXT-X-ENDLIST
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -1817,11 +1817,11 @@ public void testRecordStartedHook() throws Exception {
doReturn(new StringBuilder()).when(spyAdaptor).sendPOST(anyString(),anyMap());

spyAdaptor.startPublish(streamId, 0, IAntMediaStreamHandler.PUBLISH_TYPE_WEBRTC);
verify(spyAdaptor, times(1)).sendStartRecordWebHook(streamId);
Awaitility.await().atMost(5, TimeUnit.SECONDS).pollInterval(1, TimeUnit.SECONDS).until(
()-> {
boolean called = false;
try{
verify(spyAdaptor, times(1)).sendStartRecordWebHook(streamId);
verify(spyAdaptor,times(1)).notifyHook(broadcast.getListenerHookURL(),streamId,AntMediaApplicationAdapter.HOOK_ACTION_START_RECORD, broadcast.getName(),broadcast.getCategory(),null,null,null,null);
called = true;
}catch (Exception e){
Expand Down

0 comments on commit 0f612e8

Please sign in to comment.