Closed buffxz closed 8 years ago
[main] DEBUG o.cryptocoinpartners.module.Context - no module file found for XchangeData.epl on classpath. Please ensure XchangeData.epl is in the resources directory.
2016-02-26 19:38:07 [main] ERROR org.cryptocoinpartners.bin.Main - Uncaught error while running ConsoleRunMode
javax.persistence.NoResultException: No entity found for query
at org.hibernate.jpa.internal.QueryImpl.getSingleResult(QueryImpl.java:498) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.util.EM.sqlQueryOne(EM.java:334) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.util.EM.queryOne(EM.java:314) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.schema.Currency.forSymbol(Currency.java:41) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.schema.Asset.forSymbol(Asset.java:22) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.schema.BaseStrategy.setPortfolio(BaseStrategy.java:30) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.schema.StrategyInstance.afterAttach(StrategyInstance.java:134) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.module.Context.attach(Context.java:166) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.module.Context.attachInstance(Context.java:192) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.bin.ConsoleRunMode.init(ConsoleRunMode.java:127) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.bin.ConsoleRunMode.run(ConsoleRunMode.java:53) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
at org.cryptocoinpartners.bin.Main.main(Main.java:129) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na]
2016-02-26 19:38:07 [pool-3-thread-1] DEBUG org.cryptocoinpartners.persist - PortfolioJpaDao$$EnhancerByGuice$$90733a76:merge. Succefully merged Portfolio ConsoleStrategy
Hi,
I have replicated this, seems like when it is persisting via a static injection, the transaction is not getting committed to DB. I will hopefully get a chance to fix it in the next 48 hours.
Regards
Douggie
Cool thanks. Could you also help to verify all the other command is OK? This project is great. However, this seems unusable to me now due to these issues. I always run into issue like complie, build, or start the shell script.
Could you help to clean this up? I can start contribute to this repo once I get this set up.
Hi,
I certainly will, I have checked all the other commands and the look good, my apologies for the incomplete code, just limited time and mainly focused on getting all the accounting and back testing working.
Regards
Douggie
On Sun, Feb 28, 2016 at 10:50 AM, Xu Zhuo Joshua notifications@github.com wrote:
Cool thanks. Could you also help to verify all the other command is OK? This project is great. However, this seems unusable to me now due to these issues. I always run into issue like complie, build, or start the shell script.
Could you help to clean this up? I can start contribute to this repo once I get this set up.
— Reply to this email directly or view it on GitHub https://github.com/timolson/cointrader/issues/134#issuecomment-189832475 .
Hi Xu,
Checked in a fix for this, basically the persistence now works by putting messages on a queue, then reading them off, this is to allow rapid algo performance without having to wait for the db persistence, which can be slow when running on VPS such as AWS or DigitialOcean. The issue was the application was exiting before the queue was drained, I have but a quick fix in, but we should look to add a shutdown hook that only shutdown the JVM once the persistence queue is empty.
https://github.com/timolson/cointrader/issues/135
On Sat, Feb 27, 2016 at 3:38 AM, Xu Zhuo Joshua notifications@github.com wrote:
2016-02-26 19:38:07 [main] ERROR org.cryptocoinpartners.bin.Main - Uncaught error while running ConsoleRunMode javax.persistence.NoResultException: No entity found for query at org.hibernate.jpa.internal.QueryImpl.getSingleResult(QueryImpl.java:498) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.util.EM.sqlQueryOne(EM.java:334) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.util.EM.queryOne(EM.java:314) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.schema.Currency.forSymbol(Currency.java:41) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.schema.Asset.forSymbol(Asset.java:22) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.schema.BaseStrategy.setPortfolio(BaseStrategy.java:30) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.schema.StrategyInstance.afterAttach(StrategyInstance.java:134) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.module.Context.attach(Context.java:166) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.module.Context.attachInstance(Context.java:192) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.bin.ConsoleRunMode.init(ConsoleRunMode.java:127) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.bin.ConsoleRunMode.run(ConsoleRunMode.java:53) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] at org.cryptocoinpartners.bin.Main.main(Main.java:129) ~[cointrader-0.3.0-SNAPSHOT-jar-with-dependencies.jar:na] 2016-02-26 19:38:07 [pool-3-thread-1] DEBUG org.cryptocoinpartners.persist - PortfolioJpaDao$$EnhancerByGuice$$90733a76:merge. Succefully merged Portfolio ConsoleStrategy
— Reply to this email directly or view it on GitHub https://github.com/timolson/cointrader/issues/134#issuecomment-189571393 .