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

#34 better flyway config #35

Merged
merged 14 commits into from
May 26, 2017
Merged

#34 better flyway config #35

merged 14 commits into from
May 26, 2017

Conversation

BGehrels
Copy link
Contributor

@BGehrels BGehrels commented May 23, 2017

Fixes #34.

README.md Outdated
@@ -179,6 +159,39 @@ This will only work if your application has configured spring-boot-actuator
```
and if it implements the `org.zalando.nakadiproducer.snapshots.SnapshotEventProvider` interface as a Spring Bean. Otherwise, the library will respond with an error message when you request a snapshot creation.

## X-Flow-ID (Optional)
Copy link
Member

Choose a reason for hiding this comment

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

Some sections have (optional), others (Optional). I guess this should be unified?

public SnapshotEventCreationEndpoint snapshotEventCreationEndpoint(SnapshotCreationService snapshotCreationService) {
return new SnapshotEventCreationEndpoint(snapshotCreationService);
}
@ManagementContextConfiguration
Copy link
Member

Choose a reason for hiding this comment

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

What is the effect of this? The javadoc was not that insight-giving to me.

Copy link
Contributor Author

@BGehrels BGehrels May 26, 2017

Choose a reason for hiding this comment

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

see commit comment :-)

Copy link
Member

@ePaul ePaul May 26, 2017

Choose a reason for hiding this comment

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

Okay, the annotation was moved from the outer class (and the spring.factories entry adapted too).

import org.springframework.beans.factory.annotation.Qualifier;

/**
* Qualifier annotation for a FlywayCallback to be injected in to nakadi-producers Flyway instance.
Copy link
Member

Choose a reason for hiding this comment

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

Nitpick: nakadi-producersnakadi-producer's. (Same in NakadiProducerFlywayDataSource.)

}

@org.springframework.context.annotation.Configuration
public static class Configuration {
Copy link
Member

Choose a reason for hiding this comment

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

If you name the class e.g. Config, you can import the annotation.

Though I had problems with @Configuration classes in Integration tests, they often were activated for other ITs than the intended one too, causing much confusion.

@ePaul
Copy link
Member

ePaul commented May 26, 2017

👍

1 similar comment
@BGehrels
Copy link
Contributor Author

👍

@BGehrels BGehrels merged commit 9c44417 into master May 26, 2017
@BGehrels BGehrels deleted the #34-better-flyway-config branch May 26, 2017 10:29
@ePaul ePaul added auto-configuration everything about the auto-configuration features enhancement labels Jul 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-configuration everything about the auto-configuration features enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants