title: how to set redirect using WebFlux
body: <p>in the controller, I save the object. the saveOrUpdateUser method returns mono. but the redirect is faster than the object is saved to the database. Since I do not get this object in another method where the redirect occurs.</p>
  <pre><code>@PostMapping(&quot;users/{id}&quot;)
      public String saveOrUpdateUser(User user, Model model) {
          Mono&lt;User&gt; userDb;
          if (user.getId() == null) {
              userDb = userService.registerUser(user);
          } else {
              userDb = userService.update(user);
          }
        
          userDb.subscribe();
   
     
              return &quot;redirect:/admin/users&quot;;
      }
  </code></pre>
  <p>redirect to:</p>
  <pre><code>@GetMapping(&quot;users&quot;)
      public String getAllUser(Model model) {
  
          Flux&lt;User&gt; all = userService.findAll().sort(Comparator.comparingLong(User::getId));
  
          IReactiveDataDriverContextVariable reactiveDataDrivenMode =
                  new ReactiveDataDriverContextVariable(all, 1,1);
          model.addAttribute(&quot;users&quot;, reactiveDataDrivenMode);
        
           return &quot;usermainpage&quot;;
  </code></pre>