KamoCRM

SearchService marks its injection constructor, so the service starts

FixEmailService
Shipped
September 23, 2026 at 6:33 AM UTC
Author
Kamo
Commit
2798ccf

9809d4b gave SearchService a second constructor (a clock, for tests) and marked neither, so Spring chose neither, looked for a no-argument constructor, and the pod died at startup with "No default constructor found" (via ExchangeProvider). Every unit test passed because they call a constructor directly; the rollout stalled with the old pods still serving. The public constructor is now @Autowired, and MailSearchWiringTest builds SearchService, MailboxTargetResolver, BatchOperationService, EmailController and MetadataController the way the application context does - it fails with the production error when the annotation is removed.

All changes

Like what you see shipping?

All of it arrives in your workspace on its own. Start on the free plan and read this page again in a month.

Start Free ForeverView Pricing