Home » Archives for Steven Wall

Author Archives: Steven Wall

Fixing the Spring Web error: Expected lookupPath in request attribute “org.springframework.web.util.UrlPathHelper.PATH”

The other day I was upgrading my Spring Boot app from 2.3.1 to 2.6.6 to address the recent Spring vulnerability. This upgraded the dependent Spring libraries from 5.2.7 to 5.3.18. At start-up my application dynamically adds some REST endpoints by adding new RequestMappingInfo objects to the RequestMappingHandlerMapping bean already registered in the application context: ApplicationContext ctx = event.getApplicationContext(); RequestMappingHandlerMapping requestMappingHandlerMapping ...

Read More »

AWS CodeBuild Error: Unable to access jarfile

java-interview-questions-answers

Using AWS CodeBuild, I was using a buildspec that was to run an executable JAR file to execute JUnit tests. Here is my buildspec: 1 version: 0.2 env:   secrets-manager:     CLIENT_ID: AppSecrets/someapp:CLIENT_ID     CLIENT_SECRET: AppSecrets/someapp:CLIENT_SECRET phases:   install:     runtime-versions:       java: corretto11   build:     commands:       - echo $CLIENT_ID       - echo $CLIENT_SECRET       - java -jar -DclientId=$CLIENT_ID -DclientSecret=$CLIENT_SECRET junit-platform-console-standalone-1.7.0.jar -cp myapp.jar --select-package="com.wall.steve" As you can see, I ...

Read More »

AWS CloudFormation: Target Group does not have an associated Load Balancer

java-interview-questions-answers

Yesterday I was using an AWS CloudFormation template to ultimately create an ECS Service (Fargate type), but also create resources including an Application Load Balancer, Target Group and IAM Roles. When the stack was being created, I received the following error: The target group with targetGroupArn arn:aws:elasticloadbalancing:us-east-1:599074885545:targetgroup/a204516-S2S-Sandbox-TargetGroup/9f4aa2eb4051a952 does not have an associated load balancer. (Service: AmazonECS; Status Code: 400; Error ...

Read More »

Elasticsearch – Ignore special characters in query with pattern replace filter and custom analyzer

java-interview-questions-answers

Using Elasticsearch 5, we had a field like drivers license number where values may include special characters and inconsistent upper/lower case behavior as the values were entered by the users with limited validation.  For example, these are hypothetical values: CA-123-456-789 WI.12345.6789 tx123456789 az-123-xyz-456 … In our application, the end user need to search by that field. We had a business ...

Read More »