SolutionGuidance / psm

Welcome to the Medicare/Medicaid Provider Enrollment Screening Portal
http://projectpsm.org/
Other
26 stars 20 forks source link

Spring annotations controllers #1044

Closed jasonaowen closed 6 years ago

jasonaowen commented 6 years ago

As promised in #1042, this is the continuation of configuring controllers via Spring annotations instead of XML:

When a project is set up to support it, Spring is able to automatically discover new controllers (and other components) by looking for the proper annotation. This makes configuration much simpler, and makes it easier to, for example, add new controllers.

Spring is also able to automatically determine a component's dependencies if they are declared as constructor arguments. In addition to simplifying configuration, this allows us to reduce Java boilerplate code by removing getters and setters.

Again, I open this as a PR now both in the interest of getting experiments merged as part of winding down my contributions to the PSM, and because it will make solving #1032 a bit easier.


To test this, I created a new provider through the self-registration form, went through the forgot password flow, relied on the integration tests to create a new enrollment, made sure the provider dashboard works, ignored the disabled onboarding endpoints, verified that I could view my profile as p1, and reset my password from the link on the my profile page.

jasonaowen commented 6 years ago

Out of curiosity, what are the "disabled onboarding endpoints"?

They have to do with the external providers / profile importing functionality, which has been in a disabled and maybe-broken, maybe-working, no-way-to-know state since we picked up the PSM; see also #181.