kafka-source-after-ssh-restart.td 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. # Copyright Materialize, Inc. and contributors. All rights reserved.
  2. #
  3. # Use of this software is governed by the Business Source License
  4. # included in the LICENSE file at the root of this repository.
  5. #
  6. # As of the Change Date specified in that file, in accordance with
  7. # the Business Source License, use of this software will be governed
  8. # by the Apache License, Version 2.0.
  9. # Ensure that the source becomes healthy again once the SSH tunnel is restarted.
  10. # We specifically make sure that new data written to the Kafka topic is visible
  11. # in the source, as that is the true measure of health, vs what is reported in
  12. # the mz_source_statuses relation.
  13. $ kafka-ingest topic=thetopic format=bytes
  14. three
  15. > SELECT * FROM fixed_text_tbl
  16. text
  17. ----
  18. one
  19. two
  20. three
  21. > SELECT * FROM dynamic_text_tbl
  22. text
  23. ----
  24. one
  25. two
  26. three
  27. > SELECT * FROM fixed_plus_csr_tbl
  28. f1 f2
  29. ----------
  30. fish 1000
  31. > SELECT * FROM dynamic_plus_csr_tbl
  32. f1 f2
  33. ----------
  34. fish 1000
  35. # ensure they all were marked as running correctly
  36. > SELECT status FROM mz_internal.mz_source_statuses st
  37. JOIN mz_sources s ON st.id = s.id
  38. WHERE s.name in ('fixed_text', 'dynamic_text', 'fixed_plus_csr', 'dynamic_plus_csr')
  39. running
  40. running
  41. running
  42. running