When VisionPortalImpl tries to remove cameraMonitorViewId from viewsInUse, it uses ArrayList.remove(int) instead of ArrayList.remove(Object). This causes an IndexOutOfBoundsError. Line 663 of VisionPortalImpl should change from:
viewsInUse.remove(cameraMonitorViewId);
to
viewsInUse.remove(Integer.valueOf(cameraMonitorViewId));
If other people think this is correct I will submit a PR.