habuma / spring-in-action-6-samples

Sample code from Spring in Action 6
487 stars 343 forks source link

Chapter 2: fixing OrderController and DesignTacoController to access the same TaccoOrder session Attribute #17

Open MohamedMoubarakHussein opened 1 year ago

MohamedMoubarakHussein commented 1 year ago

There was a problem in the original code. the log file after making the order request it shows --- [nio-8080-exec-2] com.myspring.demo.controller.OrderTaco : Taco_Order(id=null, PlacedAt=null, tacos=[], name=Mohamed, street=Street, city=city, state=state, zip=000000000) tacos is empty because the code cannot access the same Session Attribute TacoOrder in the OrderController and DesignTacoController.