aeron-archive/src/main/java/io/aeron/archive/client/AeronArchive.java
public void stopRecording(final long subscriptionId)
    {
        lock.lock();
        try
        {
            ensureOpen();

            final long correlationId = aeron.nextCorrelationId();

            if (!archiveProxy.stopRecording(subscriptionId, correlationId, controlSessionId))
            {
                throw new ArchiveException("failed to send stop recording request");
            }

            pollForResponse(correlationId);
        }
        finally
        {
            lock.unlock();
        }
    }
public void stopRecording(final long subscriptionId)
    {
        lock.lock();
        try
        {
            ensureOpen();

            final long correlationId = aeron.nextCorrelationId();

            if (!archiveProxy.stopRecording(subscriptionId, correlationId, controlSessionId))
            {
                throw new ArchiveException("failed to send stop recording request");
            }

            pollForResponse(correlationId);
        }
        finally
        {
            lock.unlock();
        }
    }
Stop recording for a subscriptionId that has been returned from
{@link #startRecording(String, int, SourceLocation)} or
{@link #extendRecording(long, String, int, SourceLocation)}.

@param subscriptionId is the {@link Subscription#registrationId()} for the recording in the archive.