InvalidPropertyException: Invalid bean classDO property: No property 'classDAO'

Hi I am trying to inject a new bean on our server. Every time I try to start the server it throws this error.

org.springframework.beans.factory.BeanCreationException: An error occurred while creating a bean named "walletToWalletService" defined in URL [file: /opt/WSappl/webapps/axis2/WEB-INF/springjdbc.xml]: Initialization from bean failed; Nested Exception - org.springframework.beans.InvalidPropertyException: Invalid property 'walletToWalletDAO' class bean class [com.cbas.jdbc.walletToWallet.WalletToWalletServiceImpl]: Property walletToWalletDAO not found

Here is the springjdbc.xml file

 <bean id="walletToWalletDAO" class="com.cbas.jdbc.walletToWallet.WalletToWalletDAO">
            <property name="dataSource">
                    <ref bean="dataSource" />
            </property>
    </bean>

    <bean id="walletToWalletService" class="com.cbas.jdbc.walletToWallet.WalletToWalletServiceImpl">
            <property name="walletToWalletDAO">
                    <ref bean="walletToWalletDAO" />
            </property>
    </bean>

      

And here is my DAO class

package com.cbas.jdbc.walletToWallet;

import com.cbas.jdbc.common.BaseDAO;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.jdbc.core.RowMapper;
import org.springframework.jdbc.core.namedparam.BeanPropertySqlParameterSource;
import org.springframework.jdbc.core.namedparam.SqlParameterSource;
import org.springframework.jdbc.core.simple.SimpleJdbcInsert;

public class WalletToWalletDAO extends BaseDAO
{
  private static String TABLE = "WALLET_EVENT_LOG";

  public static String FIELD_ID = "ID";
  public static String FIELD_MSISDN = "MSISDN";
  public static String FIELD_AMOUNT = "AMOUNT";
  public static String FIELD_DEST_ACCOUNT = "DEST_ACCOUNT";
  public static String FIELD_TRANSFER_DATE = "TRANSFER_DATE";
  public static String FIELD_CHANNEL_TYPE = "CHANNEL_TYPE";

  protected String getTable()
  {
    return this.TABLE;
  }

  protected RowMapper getObjectMapper()
  {
    return new WalletToWalletRowMapper();
  }

  protected long save(WalletToWalletBean record) {
    SqlParameterSource parameters = new BeanPropertySqlParameterSource(record);
    SimpleJdbcInsert simpleJdbcInsert = getSimpleJdbcInsert().withTableName(getTable()).usingGeneratedKeyColumns(new String[] { "ID" });
    return simpleJdbcInsert.executeAndReturnKey(parameters).longValue();
  }

  protected void delete(long id) {
    StringBuilder builder = new StringBuilder("DELETE FROM ");
    builder.append(getTable());
    builder.append(" WHERE ");
    builder.append(FIELD_ID).append("=");
    builder.append(id);
    getJdbcTemplate().execute(builder.toString());
  }
}

      

+3


source to share





All Articles