Spring Boot - 🧪 Mini Project: String Intelligence Engine for Retail Products #192
akash-coded
started this conversation in
Tasks
Replies: 3 comments
-
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
0 replies
-
|
PRASETHA N |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
🧪 Mini Project: String Intelligence Engine for Retail Products
🏪 Context:
You’ve just joined a retail e-commerce startup. Your task is to build a microservice that powers search relevance and tag processing for product names, descriptions, and customer queries using string operations — all exposed via REST endpoints.
The service must:
8081🎯 Project Objectives:
Stringfunctions andCollections@RestController,@RequestParam,@Value📁 Folder Structure (GitHub Markdown)
📌 Step-by-Step Exercise
🧩 STEP 1: Setup Spring Boot Project
Instructions:
Go to https://start.spring.io/
Add dependencies:
Set project name:
string-intelligenceHint: Use Java 17 or 21.
📜 STEP 2: Configure
application.properties🧠 Pro Tip: Try hitting
/actuator/infoonce app runs.🧩 STEP 3: Create
ProductDTO.javainmodel/🧩 STEP 4: Implement String Utilities in
StringUtilsPro.java🧩 STEP 5: Implement Service Logic in
ProductStringService.java🧩 STEP 6: Create Controller
ProductStringController.java🔁 Practice Tasks (Student Must Do)
/containsAllWordsAPI to check if a title contains all query words/slugreturns--between words, fix the regexStringutility to clean HTML tags from descriptions🧪 Bonus: Postman Testing Ideas
Test
/slugwith:{ "productName": "iPhone 15 Pro Max - 128GB" }➜ Should return:
iphone-15-pro-max-128gbTest
/highlight?keyword=applewith:{ "tags": "Apple iPhone Premium Smartphone" }Test
/match?title=Sony WH-1000XM5&search=sony➜ Should returntrue🚨 Actuator Testing
Hit:
/actuator/health/actuator/info/actuator/metrics/http.server.requestsAnalyze how many times
/slugis hit🧠 Concepts Reinforced
@RequestParam+@RequestBodyusageBeta Was this translation helpful? Give feedback.
All reactions