chronicler
chronicler copied to clipboard
DOCS: Improve documentation
If you have any ideas, how I can improve documentation - leave notes here. Feel free to open a PR.
You are probably aware of it, but just to remind you if you aren't.
The example in README.md uses this class as a model:
case class Resume(
@tag id: String,
@tag candidateName: String,
@tag candidateSurname: String,
@field position: String,
@field age: Option[Int],
@field rate: Double,
@timestamp created: Long
)
However, a snippet from macros module reveals that Option is only supported on tag values (which can only be Strings)
private val TIMESTAMP_TYPE = tpdls[Long]
private val SUPPORTED_TAGS_TYPES =
Seq(tpdls[Option[String]], tpdls[String])
final private val SUPPORTED_FIELD_TYPES =
Seq(tpdls[Boolean], tpdls[Int], tpdls[Double], tpdls[String], tpdls[Float], TIMESTAMP_TYPE)
It would be helpful to have sample comparing to the code using @tag scala-influxdb-client since many people will be familiar with it first. Like:
val point = Point("cpu", System.currentTimeMillis())
database.write(point,
precision = Precision.MILLISECONDS,
consistency = Consistency.ALL,
retentionPolicy = "custom_rp")
etc.