Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Elasticsearch: towards 1.0 #1179

Merged
merged 9 commits into from
Sep 18, 2018
Merged

Elasticsearch: towards 1.0 #1179

merged 9 commits into from
Sep 18, 2018

Conversation

ennru
Copy link
Member

@ennru ennru commented Aug 30, 2018

Major API changes

<= v0.20 now
IncomingMessage WriteMessage (non case class)
IncomingIndexMessage use WriteMessage.createIndexMessage
IncomingUpdateMessage use WriteMessage.createUpdateMessage
IncomingUpsertMessage use WriteMessage.createUpsertMessage
IncomingDeleteMessage use WriteMessage.createDeleteMessage
IncomingMessageResult WriteResult
OutgoingMessage ReadResult

ElasticsearchSinkSettings is now called ElasticsearchWriteSettings and no case class anymore. The fields to specify retrying are replaced by RetryLogic with the two implementations RetryNever (default) and RetryAtFixedRate.

ElasticsearchSourceSettings is no case class anymore.

To support implementing stream elements created by the Elasticsearch stages, akka.stream.alpakka.elasticsearch.testkit.MessageFactory offers factory methods.

Fixes #1070

@ennru
Copy link
Member Author

ennru commented Aug 30, 2018

@takezoe, @mbknor WDYT?

@mbknor
Copy link
Contributor

mbknor commented Aug 30, 2018

@ennru Based on your comments, I think this looks good

* Moved implementation to `impl`
* Un-case-classed settings
* Renamed `ElasticsearchSinkSettings` to `ElasticSearchWriteSettings`

API CHANGES
Copy link
Member

@2m 2m left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Just a couple of nitpicks.

def getId: String = id

/** Java API */
def getSource: T = source
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary getter for Java since the types are java-friendly.

val success: Boolean = error.isEmpty

/** Java API */
def getMessage: WriteMessage[T2, C2] = message
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary java getter.

@ennru ennru merged commit 2236a2b into akka:master Sep 18, 2018
@ennru ennru deleted the ennru_es-towards-1.0 branch September 18, 2018 18:51
@ennru ennru added this to the 1.0-M1 milestone Sep 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants