Hi, all! In addition to the refactoring in my former message, we are trying to share DAL between BS and OP for metro version. But we do not want to check the generated code into repository as WSO2 code did.
Here we've found there are some code is not generated in OP, such as MarketSummaryBean which is the parent class of CustomMarketSummaryBean. CustomMarketSummaryBean is used in MarketSummaryDAO. If we try to share DAO between BS and OP, this will cause compilation error. The reason caused this issue is the type definition difference in WSDL/XSD between BS and OP. Do you have any suggestion to make it better? Regards On Wed, Jul 1, 2009 at 6:05 PM, Ming Jin <[email protected]> wrote: > Hi, all > > We have thought about the refactoring points between Metro version and WSO2 > version code again. One possible way to improve it is to make the two > version share the same DAL. > > To reuse the DAL, we need to find out the differences between the DAOs. > > We've found that "Double" is the only one point which affects the DAOs. > > * The following code can be found in createOrder() method of MSSQLOrderDAO > and MySQLOrderDAO in the Metro code: > insertOrder.setFloat(4, order.getQuantity().floatValue()); > > It's the only difference between Metro version and Axis2 version in terms > of DAL. > > Therefore, the minimal effort to share the DAL is to decouple > CustomOrderBean and OrderDataBean. That is to say, we would like to remove > the inhiratance relationship between CustomOrderBean and OrderDataBean. > > What do you think? any comments? > > Regards, > > ---- > Ming Jin > > Consultant > Thoughtworks, Inc > ------ Ming Jin Consultant Thoughtworks, Inc
