title: Class required a bean of type 'java.lang.String' that could not be found
body: <p>I try to a mailservice in Spring. I use Spring-Boot version 2.1.7.Release and amazon-sqs-java-messaging-lib version 1.0.8. </p>
  
  <p>My code looks like:</p>
  
  <pre><code>    @Service
  @RequiredArgsConstructor
  public class MailService {
  
  private static final Logger logger = Logger.getLogger(MailService.class.getName());
  private final AmazonSQS amazonSQS;
  
  @Value("${aws.sqs.queue.mail}")
  private final String sqsQueueMail;
  
  public void sendMail(final SQSMailParams mailParams) {
  
      final String queueUrl = amazonSQS.getQueueUrl(sqsQueueMail).getQueueUrl();
  
      try {
          final String messageBody = SQSMailParams.createSQSMailParams(mailParams, mailParams.getTemplateKey(), mailParams.getProcessId()).toJson();
          final SendMessageRequest sendMessageRequest = new SendMessageRequest(queueUrl, messageBody);
          sendMessageRequest.setMessageGroupId("TOLL-BOX-MAIL");
  
          amazonSQS.sendMessage(sendMessageRequest);
          logger.info("TOLL-BOX mail added to mail queue");
      } catch (JsonProcessingException e) {
          logger.error("Mail cannot be added to the mail queue: " + String.join(",", mailParams.recipients) + "." + e);
      }
  
      }
  }
  </code></pre>
  
  <p>But i get the following failure by running the code.</p>
  
  <pre><code>2020-03-02 07:34:00.242 ERROR 10568 --- [           main] o.s.b.d.LoggingFailureAnalysisReporter   : 
  
  ***************************
  APPLICATION FAILED TO START
  ***************************
  
  Description:
  
  Parameter 1 of constructor in de.svg.tollbox.service.MailService required a bean of type 'java.lang.String' that could not be found.
  
  
  Action:
  
  Consider defining a bean of type 'java.lang.String' in your configuration.
  
  Disconnected from the target VM, address: '127.0.0.1:43565', transport: 'socket'
  
  Process finished with exit code 1
  </code></pre>
  
  <p>Could someone tell me what im doing wrong thank you.</p>