SESSION failure summary

Description of the problem:  Refreshing the home page of I am a buyer under the USER domain name causes the session under the ENTERPRISE domain to become invalid
Operation steps: 1.  After the user logs in to the seller's homepage, click "I am a buyer" to jump to the new version of the user center
                  2 Refresh the page on the seller's homepage, and the probability error "Session not found" is reported
Error reasons:  1 USER has a jsonp request to call enterprise/api to get recommended stores. The enterprise/api is used for internal calls between systems and cannot be accessed by the browser. The call to the interface below the api will invalidate the session
                   2 jsnop has the ability to restore the enterprise session, USER's page will execute jsonp regularly, resulting in a probability of errors

The solution is to    replace the jsnop request with USER's background to directly call the merchant's interface

 
-------------------------
How to avoid similar problems in the future:
  Enterprise's api interface is used for session-free calls, and it is forbidden to open it directly to the browser. After 4.0, the merchant platform has already divided the api project, and the http api interface will not be maintained in the future, but all replaced by the dubbo interface
  This perception has been reinforced within the Merchant Group
 
In-depth analysis of the cause of the problem
1 The new employee who provides the "Get Recommended Store" interface does not know that the HTTP service under enterprise.web.api will invalidate the session. This function is hidden, but it is necessary

 

2 On "The Influence of Human Stability on Project Quality"

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326847766&siteId=291194637