Menu

Why remove stateManager.beforeInvocation in DistributedStateManager.beforeInvocation with HA-JDBC version 3.0.3?

Help
yylqinghao
2014-08-14
2014-08-25
  • yylqinghao

    yylqinghao - 2014-08-14

    Hi, paul, I see that with HA-JDBC version 3.0.3, you removed "this.stateManager.beforeInvocation(event);" in DistributedStateManager.beforeInvocation method, and the same to afterInvocation/afterInvoker/beforeInvoker too. Why?

    In this.stateManager.beforeInvocation(event), HA-JDBC may try to save the transaction info if Cluster state management is not configured to simple, and durability is fine/coarse.

    But with version 3.0.3, you removed it, then can transaction info be saved as before? Maybe you think there is no necessary to save it, but what may happen if all HA-JDBCs die after a transaction is partial commited?

     
  • Paul Ferraro

    Paul Ferraro - 2014-08-14

    It is not needed in 3.0.3, because the local node is no longer excluded from calls to CommandDispatcher.executeAll(...). The local state manager's beforeInvocation(..) is triggered from PreInvocationCommand.execute(...).

     
  • yylqinghao

    yylqinghao - 2014-08-14

    No, in 3.0.3, The local state manager's beforeInvocation(..) is not triggered from PreInvocationCommand.execute(...)!

    And if local state manager's beforeInvocation(..) is triggered from PreInvocationCommand.execute(...), then every HA-JDBC will save the transaction info in their own embedded database, Can them avoid repeatly recover on startup?

     

    Last edit: yylqinghao 2014-08-15
  • yylqinghao

    yylqinghao - 2014-08-25

    Hi, Paul, were you look into this issue?

     
  • Paul Ferraro

    Paul Ferraro - 2014-08-25

    I'll sort this out today.

     

Log in to post a comment.