public static <K, V> Printed<K, V> toFile(final String filePath) {
        Objects.requireNonNull(filePath, "filePath can't be null");
        if (Utils.isBlank(filePath)) {
            throw new TopologyException("filePath can't be an empty string");
        }
        try {
            return new Printed<>(Files.newOutputStream(Paths.get(filePath)));
        } catch (final IOException e) {
            throw new TopologyException("Unable to write stream to file at [" + filePath + "] " + e.getMessage());
        }
    }
@Test
    public void shouldCreateProcessorThatPrintsToFile() throws IOException {
        final File file = TestUtils.tempFile();
        final ProcessorSupplier<String, Integer, Void, Void> processorSupplier = new PrintedInternal<>(
                Printed.<String, Integer>toFile(file.getPath()))
                .build("processor");
        final Processor<String, Integer, Void, Void> processor = processorSupplier.get();
        processor.process(new Record<>("hi", 1, 0L));
        processor.close();
        try (final InputStream stream = Files.newInputStream(file.toPath())) {
            final byte[] data = new byte[stream.available()];
            stream.read(data);
            assertThat(new String(data, StandardCharsets.UTF_8.name()), equalTo("[processor]: hi, 1\n"));
        }
    }