私はBerkely DBを使用していますが、突然変異が見つからないというエラーがあります。これは何を意味するのでしょうか?Berkeley DBの突然変異エラー
Exception: com.sleepycat.persist.evolve.IncompatibleClassException: Mutation is missing to evolve class: TopMoveDAO.TopMoveClass version: 0 Error: java.lang.ClassNotFoundException: TopMoveDAO.TopMoveClasscom.sleepycat.persist.evolve.IncompatibleClassException: Mutation is missing to evolve class: TopMoveDAO.TopMoveClass version: 0 Error: java.lang.ClassNotFoundException: TopMoveDAO.TopMoveClass
com.sleepycat.persist.impl.PersistCatalogで
。(PersistCatalog.java:365)com.sleepycat.persist.impl.Storeで 。(Store.java:180) com.sleepycatました。 persist.EntityStore。(EntityStore.java:165) TopMoveDAO.TopMovePut.setup(TopMovePut.java:40) でTopMoveDAO.TopMovePut.mainでTopMoveDAO.TopMovePut.run(TopMovePut.java:59) で(TopMovePut.java :84)
package TopMoveDAO;
import java.io.File;
import java.util.Timer;
import java.util.TimerTask;
import com.sleepycat.je.DatabaseException;
import com.sleepycat.je.Environment;
import com.sleepycat.je.EnvironmentConfig;
import com.sleepycat.persist.EntityStore;
import com.sleepycat.persist.StoreConfig;
public class TopMovePut {
//private static File envHome = new File("C:/dev/je-3.3.75/");
private static File envHome = new File("C:/dev/db/berkeley");
private Environment envmnt;
private EntityStore store;
private TopMoveDA sda;
//Next we create a method that simply opens our database environment and entity store for us.
// The setup() method opens the environment and store
// for us.
public void setup()
throws DatabaseException {
EnvironmentConfig envConfig = new EnvironmentConfig();
StoreConfig storeConfig = new StoreConfig();
envConfig.setAllowCreate(true);
storeConfig.setAllowCreate(true);
// Open the environment and entity store
envmnt = new Environment(envHome, envConfig);
store = new EntityStore(envmnt, "EntityStore", storeConfig);
}
//We also need a method to close our environment and store.
// Close our environment and store.
public void shutdown()
throws DatabaseException {
store.close();
envmnt.close();
}
//Populate the entity store
private void run()
throws DatabaseException {
setup();
// Open the data accessor. This is used to store
// persistent objects.
sda = new TopMoveDA(store);
// Instantiate and store some entity classes
PriceElement pe1 = new PriceElement();
pe1.setSecCode("UNO");
pe1.setLastPrice(1);
sda.pIdx.put(pe1);
shutdown();
}
//main
public static void main(String args[]) {
//SimpleStorePut ssp = new SimpleStorePut();
TopMovePut tmp = new TopMovePut();
try {
//ssp.run();
tmp.run();
} catch (DatabaseException dbe) {
System.err.println("TopMovePut: " + dbe.toString());
dbe.printStackTrace();
} catch (Exception e) {
System.out.println("Exception: " + e.toString());
e.printStackTrace();
}
System.out.println("All done - TopMovePut.");
}
}
リンク:http://www.oracle.com/technology/documentation/berkeley-db/je/java/com/sleepycat/persist/evolve/package- summary.htmlは利用できません。新しいものはhttp://docs.oracle.com/cd/E17277_02/html/java/com/sleepycat/persist/evolve/package-summary.htmlです。 – Veniamin