xpages partial refresh can't save after replicate local replica

青春壹個敷衍的年華 提交于 2019-12-11 05:41:49

问题


Scenario:

  1. User preview xpage for editing in web browser.
  2. Developer replicate a local replica to the server.
  3. User click save button and trigger save action partial/full refresh

In 8.5.2 crash the whole database based on can't find java design classes. In 8.5.3 no error CS/SS accrued but there are no changes applied to the document. Seems like if you replicate the sessionID is overridden. Is there a way to fix/detect it?

Any ideas?

thx


回答1:


It relates to this effect: Meaning of java.lang.ClassCastException: someClass incompatible with someClass.

Simply said, every design change resets XSP engine. Since 8.5.3 you can control it by property "Refresh entire application when design changes" in XPage properties - turning it off (default since that version) will just "soft reset" XSP engine.

Anyway, you may loose some scoped variables and beans. This concludes to some rules to obey:

  • Do not allow developers to change design in production during working hours.
  • Notify users about the problem (onError event for partial refresh) - Tim's comment explains, that you won't get an error from partial refresh after design change, unfortunately. Simple CSJS code pinging app availability and report problem when app does not respond could work, but I don't advise that: we use "keep alive" control from ExtLib, and troubleshooting in domlog.nsf became a nightmare - it is full of pings (almost all the time - many users keep their browsers open overnight).

  • If data are very important, implement auto save mechanism similar to Google apps.

BTW: This effect is similar to time-outed session - partial refreshes will fail and user need to reload the page (and possibly loose edits).



来源:https://stackoverflow.com/questions/19115096/xpages-partial-refresh-cant-save-after-replicate-local-replica

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!