Solve Problem: Microsoft Spotlight Lock Screen Can’t Update Automatically in Windows11

1. Start Menu -> Computer Management -> Service and Application -> Service 2. Find "Background Intelligence Transfer Service" -> Property -> Set Automatic 3. Personalize -> Lock Screen -> Set "Picture" 4. Navigate to target directory in file navigator %LOCALAPPDATA%\Packages\Microsoft.Windows.ContentDeliveryManager_cw5n1h2txyewy\Settings 5. Delete Settings.data 6. Go back to parent path -> LocalState folder-> Assets folder -> …

HttpSession

What is HttpSession Server will create a independent HttpSession for each register user. What does HttpSeesion do When user first time visit the Servlet, the server will create a independent Session for user. And generate an Session ID. This Session ID could be stored in explorer’s cookie. When user visit this Servlet next time, the …

@RequestMapping, @GetMapping and @PostMapping in Spring

@RequestMapping Originally, Spring had only @RequestMapping annotation for mapping all the incoming HTTP request URLs to the corresponding controller methods. @RequestMapping(value = "/users", method = RequestMethod.GET) public Users getUsers() { } @RequestMapping(value = "/users", method = RequestMethod.POST) public User createUser(User user) { } @RequestMapping(value = "/users/{id}", method = RequestMethod.GET) public User getUser(@PathVariable("id") String id) { …

The Spring @Controller and @RestController Annotations

In Spring Boot, the controller class is responsible for processing incoming REST API requests, preparing a model, and returning the view to be rendered as a response. The controller classes in Spring are annotated either by the @Controller or the @RestController annotation. These mark controller classes as a request handler to allow Spring to recognize …

How to convert Array to List

Plain Java public void givenUsingCoreJava_whenArrayConvertedToList_thenCorrect() { Integer[] sourceArray = { 0, 1, 2, 3, 4, 5 }; List<Integer> targetList = Arrays.asList(sourceArray); } Commons Collection public void givenUsingCommonsCollections_whenArrayConvertedToList_thenCorrect() { Integer[] sourceArray = { 0, 1, 2, 3, 4, 5 }; List<Integer> targetList = new ArrayList<>(6); CollectionUtils.addAll(targetList, sourceArray); } Guava public void givenUsingGuava_whenListConvertedToArray_thenCorrect() { List<Integer> sourceList = …