Kotlin elasticsearch удалить несоответствие типаJAVA

Программисты JAVA общаются здесь
Anonymous
Kotlin elasticsearch удалить несоответствие типа

Сообщение Anonymous »


I'm trying to use elasticsearch low level client in my kotlin project. For document upsert, I run the following function.

elasticClient.update({ u->u.index("myindex").id("currentid").upsert(searchEntry) },searchEntry::class.java) But when i write the SAM, i get the following error. Type mismatch.

Type mismatch. Required: ObjectBuilder! Found: UpdateRequest.Builder! I'm following the official documentation, and I don't know why this is happening. documentation is based on Java, so is there any difference in using it in Kotlin?


Источник: https://stackoverflow.com/questions/780 ... pe-mismach

Вернуться в «JAVA»