title: Primefaces TabMenu active tab remembered on logout
body: <p>As the title explains by itself, I have an issue with managing the currently active tab in the tab menu. I'm using JSF 2.1 w/ PF 3.4. Here is the code fragment with the tab menu:</p>
  
  <pre><code>&lt;h:form&gt;
      &lt;p:tabMenu activeIndex="#{navigationMB.activeIndex}"  &gt;
          &lt;p:menuitem value="Početna" action="#{navigationMB.navigateStudent('home')}" icon="ui-icon-home" /&gt;
          &lt;p:menuitem value="Konsultacije" action="#{navigationMB.navigateStudent('konsultacije')}"  icon="ui-icon-search" /&gt;
          &lt;p:menuitem value="Zakazivanje" action="#{navigationMB.navigateStudent('zakazivanje')}"  icon="ui-icon-document"/&gt;
          &lt;p:menuitem value="Profesori" action="#{navigationMB.navigateStudent('profesori')}"/&gt;
          &lt;p:menuitem value="Moj profil" action="#{navigationMB.navigateStudent('profil')}"  icon="ui-icon-person" /&gt;
      &lt;/p:tabMenu&gt;
  &lt;/h:form&gt;
  </code></pre>
  
  <p>Here is the code of the backing bean which serves for the sole purpose of navigating that tab menu:</p>
  
  <pre><code>@Named(value = "navigationMB")
  @RequestScoped
  public class NavigationMB {
  
  private int activeIndex = 0;
  public NavigationMB() {
  
  }
  
  public String navigateStudent(String page) {
  
      System.out.println("go to page " + page);
  
      if ("home".equals(page)) {
          activeIndex = 0;
          return "/student/home?faces-redirect=true";
      }
      if ("konsultacije".equals(page)) {
          activeIndex = 1;
          return "/student/allConsults?faces-redirect=true";
      }
      if ("zakazivanje".equals(page)) {
          activeIndex = 2;
          return "/student/newConsult?faces-redirect=true";
      }
      if ("profesori".equals(page)) {
          activeIndex = 3;
          return "/student/allProfessors?faces-redirect=true";
      }
      if ("profil".equals(page)) {
          activeIndex = 4;
          return "/student/profile?faces-redirect=true";
      }
  
      return "";
  }
  </code></pre>
  
  <p>This runs fine when just browsing, but when I logout (invalidate the session) and later return with same or different user, the activeIndex is remembered. Am I not understanding something here? I suppose that the request scoped bean would be created every time there's a navigation action, and even if the user doesn't navigate anywhere, the integer I set to 0 would always point to "home" but it doesn't. 
  Any help would be awesome.</p>
  
  <p>edit:</p>
  
  <p>It seems that even without logging out, when two users (two tabs in browser) navigate around, if user 1 clicks on, for instance, tab menu item 2, and user 2 refreshes his page, user 2 will see tab menu item 2 selected as well, and vice versa. </p>
  
  <p>edit2: I made a mistake with the previous edit, please forget about this above (I didn't notice that refresh on user 2 side actually loads user 1 with his view).</p>