Cassandra File too Large Error on Start Up - cassandra
When restarting a node in my cluster I sometimes get this error message
INFO [IndexSummaryManager:1] 2016-04-12 19:32:53,574 IndexSummaryRedistribution.java:74 - Redistributing index summaries
ERROR [HintsWriteExecutor:1] 2016-04-12 20:02:15,636 CassandraDaemon.java:195 - Exception in thread Thread[HintsWriteExecutor:1,5,main]
org.apache.cassandra.io.FSWriteError: java.nio.file.FileSystemException: bin/../data/hints/389cb0d3-87b9-4221-8352-065e8ce50fdb-1460462523225-1.crc32: File too large
at org.apache.cassandra.hints.HintsWriter.writeChecksum(HintsWriter.java:116) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsWriter.close(HintsWriter.java:124) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsStore.closeWriter(HintsStore.java:201) ~[apache-cassandra-3.2.1.jar:3.2.1]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[na:1.8.0_72]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_72]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[na:1.8.0_72]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_72]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_72]
Caused by: java.nio.file.FileSystemException: bin/../data/hints/389cb0d3-87b9-4221-8352-065e8ce50fdb-1460462523225-1.crc32: File too large
at sun.nio.fs.UnixException.translateToIOException(UnixException.java:91) ~[na:1.8.0_72]
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) ~[na:1.8.0_72]
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) ~[na:1.8.0_72]
at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214) ~[na:1.8.0_72]
at java.nio.file.spi.FileSystemProvider.newOutputStream(FileSystemProvider.java:434) ~[na:1.8.0_72]
at java.nio.file.Files.newOutputStream(Files.java:216) ~[na:1.8.0_72]
at org.apache.cassandra.hints.HintsWriter.writeChecksum(HintsWriter.java:110) ~[apache-cassandra-3.2.1.jar:3.2.1]
... 7 common frames omitted
The node then starts shutting down, but gets stuck repeated throwing an exception and retrying every few seconds. This is the main problem for me because it stopped the cluster from accepting connections
ERROR [HintsWriteExecutor:1] 2016-04-12 20:02:15,638 StorageService.java:440 - Stopping gossiper
WARN [HintsWriteExecutor:1] 2016-04-12 20:02:15,651 StorageService.java:347 - Stopping gossip by operator request
INFO [HintsWriteExecutor:1] 2016-04-12 20:02:15,651 Gossiper.java:1455 - Announcing shutdown
DEBUG [HintsWriteExecutor:1] 2016-04-12 20:02:15,653 StorageService.java:1921 - Node /169.34.103.150 state shutdown, token [-1028691827956217809, -1257393635657191129, -1285475466194230655, -1398822673992383910, -1549844858878358481, -1638651369075180065, -1660825917518666149, -1802478872312866489, -1834618755337322564, -188187624477415935, -2034018930607672685, -210049110249018365, -2157250079133002505, -2171215058533514263, -2183510006393476006, -2193567329545672696, -2317710820662725097, -2319735333341559730, -2333531623390263516, -2458839661565177963, -2489690089103800827, -2710032230533922787, -2780200665893123668, -283628639049224915, -2886550293705646069, -293132189636842303, -2945647150702034785, -2965944925251907629, -2990231874502594267, -2991676811317743630, -2997538046339800243, -3176643432551515484, -3176889844544735478, -3201806929871841501, -3211631881211211792, -322057073400957538, -3242716520974847469, -3424682940569182570, -3441313897213257083, -3448874645237774640, -3452014929671888774, -3487048220426765500, -3523033168154067409, -3738270231064896111, -3792947624538231469, -3850123184653095411, -3859434367535677710, -3993763147657603241, -4010731345091378481, -4258687888114256086, -429860111391304244, -4318544125783476774, -4471769468265919226, -4588065176944445932, -4669765414071774677, -4670558952147294236, -4710259358376415554, -4907784900060021493, -4934593823248165235, -4934821923831720820, -5013288056003569837, -5110268421077583856, -5133973510660140774, -5159515181162633178, -5276029184678521021, -5286266972273013716, -540287937883749850, -5456649087226389873, -5495658378651725051, -5501165049612471047, -5535468008960837763, -5716046948204274477, -5721008906555397374, -5753456205099778029, -5770577886564351775, -5790919034460455792, -5929058167490034525, -5943865033771694477, -608562636816376813, -6109108822129963089, -6140834685397419488, -6170120179807852740, -6179956847809119210, -6245955388738336647, -6286189790411746933, -6299162407942815080, -6315904471665416400, -6364734987085439789, -6419018190136685454, -6451287738650323275, -6547213964231430849, -6548484474977763138, -6549052151069571925, -6698516302891374040, -6872407277556537836, -6901128430416607497, -6935384932230430038, -6937998036050345125, -7031528786091227188, -7106019277455303867, -7119774336125808637, -7191744312745689956, -7225558820114789693, -7349977359560186580, -7422626834116218143, -7431995410347149964, -7466585374358878727, -750799820874518113, -7610594360825096930, -7616154542884798259, -7629884030042898550, -7728553164832596613, -7789353727430662940, -779402220858888622, -7843332228444504745, -7854439386306622129, -815495344326874929, -8338520822777210140, -8649102261484559375, -8796027903791901112, -8898390484583881495, -8923261220379460832, -8943079358447105951, -9050583546904370510, -9080494386502531561, -9139630196350606101, -939306213156730751, -942614916980620152, 1049830730407134075, 1125127596836820990, 1133356003300268705, 1133623932124213230, 1247043876318218235, 1490023295198042772, 1497436537080113324, 1516791905674857253, 1603966065250122923, 1646125781869948326, 1740544126107535998, 1756218012030701589, 1804735370513211257, 1812139850525677114, 1819880350303805394, 1841691686666460445, 1888363141244474676, 2010883847009222978, 2016297526252235227, 2021110586668181290, 2084880932156441613, 2093427980091185166, 2112052724153374980, 2186638483475842552, 2195406825247987731, 2283720951686386464, 23875829161989945, 2521818329391092608, 2522645057607851918, 2524720168145693638, 2541003400153964040, 2650684785592761012, 2723290502273715430, 2808119513098478236, 2821997019638778146, 2891379770529557184, 2907285214187020532, 2963307217336709534, 3061757915053031951, 3122571062025066142, 3128771694670016319, 3130206542424936603, 3197285318974197102, 3218987271686146429, 3329594065878248111, 3331926835266199716, 3526280986313508860, 3542343528340649978, 3589794725284000659, 3610364312437568329, 3701861372719378732, 373747767999916658, 3826422069022675393, 3856151860383170644, 3862031127704782057, 4049338078570571707, 4137865494092400430, 4241199357440741315, 4520402233521387342, 456519309520244643, 4715328215899051522, 4817677510120292180, 497627869146346949, 4995322204306807081, 5030633110404844305, 5038572404428039197, 5042627643214511398, 5281377762367584052, 5494577271219306513, 5530410713928998603, 5537215727145277166, 567120218785751902, 575743986375007756, 5784212620383428248, 5837914425280614947, 5977153680566647690, 5996674261833528410, 6083452088392300601, 6112178449036583235, 6264713703969393897, 6287772759341778176, 6314363909221383341, 6321343658409071604, 6475821468968027456, 6543311556613206558, 6912492987521221000, 6922280123185191829, 694545242943535806, 7183280296372529849, 7306070312091628992, 7412331756775823975, 7518294356359523088, 7567542433462808235, 7589810674525331548, 7637277610587157806, 773319528418720822, 7760484456189230502, 7816590204960057932, 7820991841796591957, 7836345109808448402, 7859570796753174, 8003409347394992259, 8012927612089894493, 8031750463661605171, 8051744553293723603, 8066222841813137181, 8073294271415597086, 8117861819974218900, 817982542709209563, 8198846486095494968, 8214665766962397555, 8277428606113435880, 8279100634451559360, 8316406004646641445, 8367052745804770548, 8373819718798220972, 8439087240414018142, 8444359473760446267, 8449256096936507263, 8717779586961798956, 8912188109780463904, 8920579922439529433, 8951968899880736480, 9043168611036813220, 9044578575232639242, 9045812874827336349, 9140634849238500115, 915715308827014103]
INFO [HintsWriteExecutor:1] 2016-04-12 20:02:15,653 StorageService.java:1924 - Node /169.34.103.150 state jump to shutdown
DEBUG [PendingRangeCalculator:1] 2016-04-12 20:02:15,655 PendingRangeCalculatorService.java:64 - finished calculation for 74 keyspaces in 0ms
ERROR [HintsWriteExecutor:1] 2016-04-12 20:02:17,655 StorageService.java:450 - Stopping native transport
INFO [HintsWriteExecutor:1] 2016-04-12 20:02:17,705 Server.java:182 - Stop listening for CQL clients
ERROR [HintsWriteExecutor:1] 2016-04-12 20:02:23,219 CassandraDaemon.java:195 - Exception in thread Thread[HintsWriteExecutor:1,5,main]
org.apache.cassandra.io.FSWriteError: java.nio.channels.ClosedChannelException
at org.apache.cassandra.hints.HintsWriter.newSession(HintsWriter.java:146) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsWriteExecutor.flushInternal(HintsWriteExecutor.java:221) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsWriteExecutor.flush(HintsWriteExecutor.java:203) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsWriteExecutor.lambda$flush$217(HintsWriteExecutor.java:196) ~[apache-cassandra-3.2.1.jar:3.2.1]
at java.util.concurrent.ConcurrentHashMap$KeySetView.forEach(ConcurrentHashMap.java:4649) ~[na:1.8.0_72]
at org.apache.cassandra.hints.HintsWriteExecutor.flush(HintsWriteExecutor.java:196) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsWriteExecutor.access$000(HintsWriteExecutor.java:36) ~[apache-cassandra-3.2.1.jar:3.2.1]
at org.apache.cassandra.hints.HintsWriteExecutor$FlushBufferPoolTask.run(HintsWriteExecutor.java:155) ~[apache-cassandra-3.2.1.jar:3.2.1]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[na:1.8.0_72]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_72]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[na:1.8.0_72]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_72]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_72]
Caused by: java.nio.channels.ClosedChannelException: null
at sun.nio.ch.FileChannelImpl.ensureOpen(FileChannelImpl.java:110) ~[na:1.8.0_72]
at sun.nio.ch.FileChannelImpl.size(FileChannelImpl.java:300) ~[na:1.8.0_72]
at org.apache.cassandra.hints.HintsWriter.newSession(HintsWriter.java:142) ~[apache-cassandra-3.2.1.jar:3.2.1]
... 12 common frames omitted
I googled around a bit and think the initial exception is caused by the node trying to replay a hint that is very large and it cant load.
I tried to find some parameters that can prevent this, but all I could find was turning off hint handoff (hinted_handoff_enabled) or reducing the time hint handoff runs for (max_hint_window_in_ms). I don't think I can live with an inconsistent cluster and was hoping for an option to split the hints into multiple files, but couldn't find such an option.
Has anyone seen this issue before? Is there a way to split hints into multiple files? How else might I deal with this?
EDIT: I hunted through my config and found this
max_hints_file_size_in_mb: 128
That seems pretty concervative to me, given the machine I'm running on. If my hints are limited to 128MB then I really dont understand why I have the above exception.
When run on this node nodetool threw an exception. Other nodes were ok, but I only ran nodetool the next morning (12 hours after the exception).
The file the exception complains about is no longer there, but the file name should be ok because I have many other files with similar names (same length). It is interesting the the exception is complaining about a .crc32 file (not a .hint file)
Related
IDE Fatal Erors
My Android Studio gives me this fatal error. So Far, I did ivalidated cache, I restored to default settings, I even configured VM acceleration but nothing worked. I also getting syntax highlighting has been temporarily turned off because of an internal error in my mainActivity.kt, and it doesn't show any preview despite the #Preview tag. The stacktrace is as follows: java.lang.NullPointerException at com.intellij.openapi.wm.impl.welcomeScreen.WelcomeScreenComponentFactory.lambda$createEventLink$1(WelcomeScreenComponentFactory.java:303) at com.intellij.util.messages.impl.MessageBusImpl.invokeMethod(MessageBusImpl.java:645) at com.intellij.util.messages.impl.MessageBusImpl.invokeListener(MessageBusImpl.java:624) at com.intellij.util.messages.impl.MessageBusImpl.deliverMessage(MessageBusImpl.java:417) at com.intellij.util.messages.impl.MessageBusImpl.pumpWaitingBuses(MessageBusImpl.java:390) at com.intellij.util.messages.impl.MessageBusImpl.pumpMessages(MessageBusImpl.java:372) at com.intellij.util.messages.impl.MessageBusImpl.access$200(MessageBusImpl.java:33) at com.intellij.util.messages.impl.MessageBusImpl$MessagePublisher.invoke(MessageBusImpl.java:179) at com.sun.proxy.$Proxy96.notificationsChanged(Unknown Source) at com.intellij.openapi.wm.impl.welcomeScreen.WelcomeBalloonLayoutImpl.updatePopup(WelcomeBalloonLayoutImpl.java:181) at com.intellij.openapi.wm.impl.welcomeScreen.WelcomeBalloonLayoutImpl$3.dispose(WelcomeBalloonLayoutImpl.java:124) at com.intellij.openapi.util.ObjectTree.runWithTrace(ObjectTree.java:139) at com.intellij.openapi.util.ObjectTree.executeAll(ObjectTree.java:169) at com.intellij.openapi.util.Disposer.dispose(Disposer.java:217) at com.intellij.openapi.util.Disposer.dispose(Disposer.java:205) at com.intellij.ui.BalloonLayoutImpl.dispose(BalloonLayoutImpl.java:84) at com.intellij.openapi.wm.impl.welcomeScreen.WelcomeBalloonLayoutImpl.dispose(WelcomeBalloonLayoutImpl.java:51) at com.intellij.openapi.util.ObjectTree.runWithTrace(ObjectTree.java:139) at com.intellij.openapi.util.ObjectTree.executeAll(ObjectTree.java:169) at com.intellij.openapi.util.Disposer.dispose(Disposer.java:217) at com.intellij.openapi.util.Disposer.dispose(Disposer.java:205) at com.intellij.openapi.wm.impl.welcomeScreen.FlatWelcomeFrame.dispose(FlatWelcomeFrame.java:232) at com.intellij.openapi.util.ObjectTree.runWithTrace(ObjectTree.java:139) at com.intellij.openapi.util.ObjectTree.executeAll(ObjectTree.java:169) at com.intellij.openapi.util.Disposer.dispose(Disposer.java:217) at com.intellij.openapi.util.Disposer.dispose(Disposer.java:205) at com.intellij.openapi.wm.impl.welcomeScreen.FlatWelcomeFrame$1.projectOpened(FlatWelcomeFrame.java:124) at com.intellij.util.messages.impl.MessageBusImpl.invokeMethod(MessageBusImpl.java:645) at com.intellij.util.messages.impl.MessageBusImpl.invokeListener(MessageBusImpl.java:624) at com.intellij.util.messages.impl.MessageBusImpl.access$300(MessageBusImpl.java:33) at com.intellij.util.messages.impl.MessageBusImpl$MessagePublisher.executeOrAddToQueue(MessageBusImpl.java:208) at com.intellij.util.messages.impl.CompositeMessageBus$ToDirectChildrenMessagePublisher.publish(CompositeMessageBus.java:105) at com.intellij.util.messages.impl.MessageBusImpl$MessagePublisher.invoke(MessageBusImpl.java:166) at com.sun.proxy.$Proxy128.projectOpened(Unknown Source) at com.intellij.openapi.project.impl.ProjectManagerExImplKt$openProject$1.run(ProjectManagerExImpl.kt:468) at com.intellij.openapi.application.TransactionGuardImpl.runWithWritingAllowed(TransactionGuardImpl.java:214) at com.intellij.openapi.application.TransactionGuardImpl.access$200(TransactionGuardImpl.java:21) at com.intellij.openapi.application.TransactionGuardImpl$2.run(TransactionGuardImpl.java:196) at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:805) at com.intellij.openapi.application.impl.ApplicationImpl.lambda$invokeAndWait$7(ApplicationImpl.java:450) at com.intellij.openapi.application.impl.LaterInvocator$1.run(LaterInvocator.java:134) at com.intellij.openapi.application.impl.FlushQueue.doRun(FlushQueue.java:82) at com.intellij.openapi.application.impl.FlushQueue.runNextEvent(FlushQueue.java:131) at com.intellij.openapi.application.impl.FlushQueue.flushNow(FlushQueue.java:47) at com.intellij.openapi.application.impl.FlushQueue$FlushNow.run(FlushQueue.java:187) at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:776) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:727) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:746) at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:891) at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:760) at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$6(IdeEventQueue.java:447) at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:818) at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$7(IdeEventQueue.java:446) at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:805) at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:492) at com.intellij.ide.IdeEventQueue.pumpEventsForHierarchy(IdeEventQueue.java:951) at com.intellij.openapi.progress.util.ProgressWindow.lambda$startBlocking$6(ProgressWindow.java:221) at com.intellij.openapi.application.impl.ApplicationImpl.runUnlockingIntendedWrite(ApplicationImpl.java:831) at com.intellij.openapi.progress.util.ProgressWindow.startBlocking(ProgressWindow.java:217) at com.intellij.openapi.progress.impl.ProgressRunner.lambda$execFromEDT$6(ProgressRunner.java:321) at java.base/java.util.concurrent.CompletableFuture.uniAcceptNow(CompletableFuture.java:753) at java.base/java.util.concurrent.CompletableFuture.uniAcceptStage(CompletableFuture.java:731) at java.base/java.util.concurrent.CompletableFuture.thenAccept(CompletableFuture.java:2108) at com.intellij.openapi.progress.impl.ProgressRunner.execFromEDT(ProgressRunner.java:318) at com.intellij.openapi.progress.impl.ProgressRunner.submit(ProgressRunner.java:259) at com.intellij.openapi.progress.impl.ProgressRunner.submitAndGet(ProgressRunner.java:185) at com.intellij.openapi.project.impl.ProjectUiFrameAllocator.run(ProjectFrameAllocator.kt:116) at com.intellij.openapi.project.impl.ProjectManagerExImpl.doOpenAsync(ProjectManagerExImpl.kt:119) at com.intellij.openapi.project.impl.ProjectManagerExImpl.openProjectAsync(ProjectManagerExImpl.kt:110) at com.intellij.openapi.project.impl.ProjectManagerExImpl.openProject(ProjectManagerExImpl.kt:72) at com.intellij.ide.impl.ProjectUtil.tryOpenOrImport(ProjectUtil.java:172) at com.intellij.ide.impl.ProjectUtil.openOrImport(ProjectUtil.java:131) at com.intellij.ide.impl.ProjectUtil.openOrImport(ProjectUtil.java:127) at com.android.tools.idea.actions.AndroidOpenFileAction.openOrImportProject(AndroidOpenFileAction.java:179) at com.android.tools.idea.actions.AndroidOpenFileAction.doOpenFile(AndroidOpenFileAction.java:149) at com.android.tools.idea.actions.AndroidOpenFileAction.lambda$actionPerformed$0(AndroidOpenFileAction.java:111) at com.intellij.openapi.fileChooser.ex.FileChooserDialogImpl.choose(FileChooserDialogImpl.java:146) at com.intellij.openapi.fileChooser.FileChooser.chooseFiles(FileChooser.java:102) at com.intellij.openapi.fileChooser.FileChooser.chooseFiles(FileChooser.java:80) at com.android.tools.idea.actions.AndroidOpenFileAction.actionPerformed(AndroidOpenFileAction.java:101) at com.intellij.openapi.actionSystem.ex.ActionUtil.lambda$performActionDumbAwareWithCallbacks$4(ActionUtil.java:239) at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareWithCallbacks(ActionUtil.java:260) at com.intellij.openapi.actionSystem.ex.ActionUtil.performActionDumbAwareWithCallbacks(ActionUtil.java:239) at com.intellij.openapi.wm.impl.welcomeScreen.WelcomeScreenActionsUtil.performAnActionForComponent(WelcomeScreenActionsUtil.java:96) at com.intellij.openapi.wm.impl.welcomeScreen.WelcomeScreenActionsUtil$LargeIconWithTextWrapper.lambda$new$0(WelcomeScreenActionsUtil.java:125) at java.desktop/javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1967) at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2308) at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:405) at java.desktop/javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:262) at java.desktop/javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:270) at java.desktop/java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:297) at java.desktop/java.awt.Component.processMouseEvent(Component.java:6654) at java.desktop/javax.swing.JComponent.processMouseEvent(JComponent.java:3345) at java.desktop/java.awt.Component.processEvent(Component.java:6419) at java.desktop/java.awt.Container.processEvent(Container.java:2263) at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5029) at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321) at java.desktop/java.awt.Component.dispatchEvent(Component.java:4861) at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4918) at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4547) at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4488) at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2307) at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2790) at java.desktop/java.awt.Component.dispatchEvent(Component.java:4861) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:778) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:727) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95) at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:751) at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:749) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:748) at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:891) at com.intellij.ide.IdeEventQueue.dispatchMouseEvent(IdeEventQueue.java:820) at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:757) at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$6(IdeEventQueue.java:447) at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:818) at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$7(IdeEventQueue.java:446) at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:805) at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:498) at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203) at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124) at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)```
What happens on line 303 of WelcomeScreenComponentFactory.java:303 ? In general a NPE or null pointer exception happens when you attempt to reference a method or property of an variable in code and that variable is not initialized or is pointing at null. if on line 303 you have someObject.someMethod() then can infer that someObject was null when the line was run. Sounds like when you're calling that library method the object being passed to it is null, but can maybe run in debug mode and step back through the stack trace to see what call/setup your app made before the exception is thrown as well.
Android WebView App :: Errors Name : File error accessing recents directory ; Task 255 failed or timed out ; CancellationException
I have lots of links in my app, I have used the Firebase database for data fetch and data send and also used broadcast receiver. Most of the time my app is not crashing with these errors, but sometimes it crashed. When it crashed, I opened the logcat the I found this 2022-04-22 02:22:46.387 1260-1445/? E/WifiVendorHal: getWifiLinkLayerStats_1_3_Internal(l.974) failed {.code = ERROR_NOT_SUPPORTED, .description = } 2022-04-22 02:32:18.834 18124-18124/? E/A: Task 255 failed or timed out. Client 79711845498329053 disconnecting from SearchService! java.util.concurrent.CancellationException: Task was cancelled. at com.google.common.util.concurrent.d.s(PG:3) at com.google.common.util.concurrent.d.get(PG:4) at com.google.common.util.concurrent.eb.a(PG:1) at com.google.common.util.concurrent.ci.r(PG:2) at com.google.common.util.concurrent.cb.run(PG:4) at com.google.android.apps.gsa.shared.util.c.a.ba.run(PG:1) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:246) at android.app.ActivityThread.main(ActivityThread.java:8653) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130) 2022-04-22 02:32:18.838 18124-18124/? E/A: Task 255 failed or timed out. Client 79711845498329051 disconnecting from SearchService! java.util.concurrent.CancellationException: Task was cancelled. at com.google.common.util.concurrent.d.s(PG:3) at com.google.common.util.concurrent.d.get(PG:4) at com.google.common.util.concurrent.eb.a(PG:1) at com.google.common.util.concurrent.ci.r(PG:2) at com.google.common.util.concurrent.cb.run(PG:4) at com.google.android.apps.gsa.shared.util.c.a.ba.run(PG:1) at android.os.Handler.handleCallback(Handler.java:938) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:246) at android.app.ActivityThread.main(ActivityThread.java:8653) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130) 2022-04-22 02:32:18.850 18124-17677/? E/BgTaskExecutorImpl: PERIODIC background task MDD_CELLULAR_CHARGING_TASK was cancelled. java.util.concurrent.CancellationException: Task was cancelled. at com.google.common.util.concurrent.d.s(PG:3) at com.google.common.util.concurrent.d.get(PG:4) at com.google.common.util.concurrent.eb.a(PG:1) at com.google.common.util.concurrent.ci.r(PG:2) at com.google.common.util.concurrent.cb.run(PG:4) at com.google.android.apps.gsa.shared.util.c.a.cf.b(PG:1) at com.google.android.apps.gsa.shared.util.c.a.ci.run(PG:1) at com.google.android.libraries.i.ae.run(PG:1) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at com.google.android.libraries.i.i.run(PG:2) at com.google.android.libraries.i.p.run(PG:4) at java.lang.Thread.run(Thread.java:923) 2022-04-22 02:32:18.857 18124-17615/? E/BgTaskExecutorImpl: PERIODIC background task MDD_WIFI_CHARGING_TASK was cancelled. java.util.concurrent.CancellationException: Task was cancelled. at com.google.common.util.concurrent.d.s(PG:3) at com.google.common.util.concurrent.d.get(PG:4) at com.google.common.util.concurrent.eb.a(PG:1) at com.google.common.util.concurrent.ci.r(PG:2) at com.google.common.util.concurrent.cb.run(PG:4) at com.google.android.apps.gsa.shared.util.c.a.cf.b(PG:1) at com.google.android.apps.gsa.shared.util.c.a.ci.run(PG:1) at com.google.android.libraries.i.ae.run(PG:1) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at com.google.android.libraries.i.i.run(PG:2) at com.google.android.libraries.i.p.run(PG:4) at java.lang.Thread.run(Thread.java:923) sometimes it shows this also 2022-04-22 09:28:15.894 1928-2047/? E/TaskPersister: File error accessing recents directory (directory doesn't exist?). 2022-04-22 09:49:15.232 21150-21150/ W/System.err: at w.Internet_Checker_BroadCast_Reciver.onReceive(Internet_Checker_BroadCast_Reciver.java:27) I have studied it more. I found a thing , when the app is crashing the logcat prints as the last line is(will it be the reason?) : 2022-04-22 12:22:25.941 17481-17552/w D/OneSignal: UserStateSynchronizer internalSyncUserState from session call: false jsonBody: null
WL12.2 processMultipartConfigAnnotation raises exception [duplicate]
This question already has answers here: nullPointerException when deploy webLogic 12c application (6 answers) Closed 2 years ago. I build WL12.2 with IceFace3.3.0GA_P07 and using jsf-api-2.2.20.jar, slf4j-api-1.7.28.0.jar, javax.servlet.jstl-1.2.jar on the classpath now, I am getting a NullPointerException <[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <4ca7b60a-acef-4505-94ce-91dd597eab38-00000009> <1599853451390> <[severity-value: 8] [rid: 0] [partition-id: 0] [partition-name: DOMAIN] > <BEA-149205> <Failed to initialize the application "FTOLWeb" due to error weblogic.application.ModuleException: java.lang.NullPointerException weblogic.application.ModuleException: java.lang.NullPointerException<br/> at weblogic.application.internal.ExtensibleModuleWrapper.prepare(ExtensibleModuleWrapper.java:114)<br/> at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:100)<br/> at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:192)<br/> at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:187) at weblogic.application.utils.StateMachineDriver$ParallelChange.run(StateMachineDriver.java:83) at weblogic.application.utils.StateMachineDriver.nextStateInParallel(StateMachineDriver.java:144) at weblogic.application.internal.flow.ModuleStateDriver.parallelPrepare(ModuleStateDriver.java:46) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:75) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:55) at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:729) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:241) at weblogic.application.internal.SingleModuleDeployment.prepare(SingleModuleDeployment.java:52) at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:158) at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:65) at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:166) at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:41) at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:193) at weblogic.management.deploy.internal.AppTransition$1.transitionAppInternal(AppTransition.java:32) at weblogic.management.deploy.internal.AppTransition.transitionApp(AppTransition.java:138) at weblogic.management.deploy.internal.ConfiguredDeployments$2.doItem(ConfiguredDeployments.java:741) at weblogic.management.deploy.internal.parallel.BucketInvoker.invoke(BucketInvoker.java:138) at weblogic.management.deploy.internal.ConfiguredDeployments.transitionAppsParallel(ConfiguredDeployments.java:749) at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:363) at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:232) at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:219) at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:133) at weblogic.server.AbstractServerService.postConstruct(AbstractServerService.java:76) at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.glassfish.hk2.utilities.reflection.ReflectionHelper.invoke(ReflectionHelper.java:1287) at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:333) at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:375) at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:487) at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:305) at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85) at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2126) at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:116) at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:698) at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78) at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:212) at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:235) at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:358) at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:487) at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:305) at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85) at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2126) at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:116) at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:90) at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.oneJob(CurrentTaskFuture.java:1237) at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.run(CurrentTaskFuture.java:1168) at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$UpOneLevel.run(CurrentTaskFuture.java:786) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:681) at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352) at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337) at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57) at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41) at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:655) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:420) at weblogic.work.ExecuteThread.run(ExecuteThread.java:360) Caused By: java.lang.NullPointerException at weblogic.servlet.internal.WebAnnotationProcessor.processMultipartConfigAnnotation(WebAnnotationProcessor.java:287) at weblogic.servlet.internal.AnnotationProcessingManager.processAnnotationForClasses(AnnotationProcessingManager.java:201) at weblogic.servlet.internal.AnnotationProcessingManager.processAnnotations(AnnotationProcessingManager.java:145) at weblogic.servlet.internal.AnnotationProcessingManager.processAnnotationsOutsideWebFragment(AnnotationProcessingManager.java:173) at weblogic.servlet.internal.AnnotationProcessingManager.processAnnotations(AnnotationProcessingManager.java:130) at weblogic.servlet.internal.AnnotationProcessingManager.processAnnotations(AnnotationProcessingManager.java:105) at weblogic.servlet.internal.WebAppModule.processAnnotations(WebAppModule.java:2180) at weblogic.servlet.internal.WebAppModule.processAnnotations(WebAppModule.java:2142) at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:814) at weblogic.application.internal.ExtensibleModuleWrapper$PrepareStateChange.next(ExtensibleModuleWrapper.java:295) at weblogic.application.internal.ExtensibleModuleWrapper$PrepareStateChange.next(ExtensibleModuleWrapper.java:285) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.ExtensibleModuleWrapper.prepare(ExtensibleModuleWrapper.java:109) at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:100) at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:192) at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:187) at weblogic.application.utils.StateMachineDriver$ParallelChange.run(StateMachineDriver.java:83) at weblogic.application.utils.StateMachineDriver.nextStateInParallel(StateMachineDriver.java:144) at weblogic.application.internal.flow.ModuleStateDriver.parallelPrepare(ModuleStateDriver.java:46) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:75) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:55) at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:729) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:241) at weblogic.application.internal.SingleModuleDeployment.prepare(SingleModuleDeployment.java:52) at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:158) at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:65) at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:166) at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:41) at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:193) at weblogic.management.deploy.internal.AppTransition$1.transitionAppInternal(AppTransition.java:32) at weblogic.management.deploy.internal.AppTransition.transitionApp(AppTransition.java:138) at weblogic.management.deploy.internal.ConfiguredDeployments$2.doItem(ConfiguredDeployments.java:741) at weblogic.management.deploy.internal.parallel.BucketInvoker.invoke(BucketInvoker.java:138) at weblogic.management.deploy.internal.ConfiguredDeployments.transitionAppsParallel(ConfiguredDeployments.java:749) at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:363) at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:232) at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:219) at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:133) at weblogic.server.AbstractServerService.postConstruct(AbstractServerService.java:76) at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Method.java:498) at org.glassfish.hk2.utilities.reflection.ReflectionHelper.invoke(ReflectionHelper.java:1287) at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:333) at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:375) at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:487) at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:305) at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85) at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2126) at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:116) at org.jvnet.hk2.internal.ServiceLocatorImpl.getService(ServiceLocatorImpl.java:698) at org.jvnet.hk2.internal.ThreeThirtyResolver.resolve(ThreeThirtyResolver.java:78) at org.jvnet.hk2.internal.ClazzCreator.resolve(ClazzCreator.java:212) at org.jvnet.hk2.internal.ClazzCreator.resolveAllDependencies(ClazzCreator.java:235) at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:358) at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:487) at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:305) at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:85) at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2126) at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:116) at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:90) at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.oneJob(CurrentTaskFuture.java:1237) at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.run(CurrentTaskFuture.java:1168) at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$UpOneLevel.run(CurrentTaskFuture.java:786) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:681)<br/> at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352)<br/> at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337)<br/> at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57)<br/> at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)<br/> at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:655)<br/> at weblogic.work.ExecuteThread.execute(ExecuteThread.java:420)<br/> at weblogic.work.ExecuteThread.run(ExecuteThread.java:360)<br/>
this is the answer, nullPointerException when deploy webLogic 12c application Namely, that I had the jsf2.2.jar once in WEB-INF/lib dir and once in the classpath. I removed it from WEB-INF/lib! Back to my original problem WL12.2 upgrade gives timeout on database which seems to be giving me "HTML parsing or JS evaluation error [code: 200]: element.getAttribute is not a function" on console
Android Things - I2C2 is already in use (code 16)
I am trying to connect ADS1015 ADC with my Pico Pro Maker. Unfortunately, I got folowing error: E/AndroidRuntime: FATAL EXCEPTION: main Process: com.cililing.harvbox.thingsapp, PID: 1855 java.lang.RuntimeException: java.lang.reflect.InvocationTargetException at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:448) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) Caused by: java.lang.reflect.InvocationTargetException at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) Caused by: com.google.android.things.pio.PioException: android.os.ServiceSpecificException: I2C2 is already in use (code 16) at com.google.android.things.pio.I2cDeviceImpl.<init>(I2cDeviceImpl.java:43) at com.google.android.things.pio.PeripheralManager.openI2cDevice(PeripheralManager.java:246) at com.google.android.things.contrib.driver.adc.ads1xxx.Ads1xxx.<init>(Ads1xxx.java:200) at com.google.android.things.contrib.driver.adc.ads1xxx.Ads1xxx.<init>(Ads1xxx.java:187) at com.cililing.harvbox.thingsapp.thingscontroller.controllers.ADS1015ControllerImpl.<init>(ADS1015Controller.kt:12) at com.cililing.harvbox.thingsapp.ui.MainActivity$i2CController$2.invoke(MainActivity.kt:40) at com.cililing.harvbox.thingsapp.ui.MainActivity$i2CController$2.invoke(MainActivity.kt:33) at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:74) at com.cililing.harvbox.thingsapp.ui.MainActivity.getI2CController(Unknown Source:25) at com.cililing.harvbox.thingsapp.ui.MainActivity.access$getI2CController$p(MainActivity.kt:33) at com.cililing.harvbox.thingsapp.ui.MainActivity$i2cLogger$1.run(MainActivity.kt:47) at android.os.Handler.handleCallback(Handler.java:790) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:164) at android.app.ActivityThread.main(ActivityThread.java:6494) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) Caused by: android.os.ServiceSpecificException: I2C2 is already in use (code 16) at android.os.Parcel.readException(Parcel.java:2027) at android.os.Parcel.readException(Parcel.java:1959) at com.google.android.things.pio.IPeripheralManagerClient$Stub$Proxy.OpenI2cDevice(IPeripheralManagerClient.java:1243) at com.google.android.things.pio.I2cDeviceImpl.<init>(I2cDeviceImpl.java:41) at com.google.android.things.pio.PeripheralManager.openI2cDevice(PeripheralManager.java:246) at com.google.android.things.contrib.driver.adc.ads1xxx.Ads1xxx.<init>(Ads1xxx.java:200) at com.google.android.things.contrib.driver.adc.ads1xxx.Ads1xxx.<init>(Ads1xxx.java:187) at com.cililing.harvbox.thingsapp.thingscontroller.controllers.ADS1015ControllerImpl.<init>(ADS1015Controller.kt:12) at com.cililing.harvbox.thingsapp.ui.MainActivity$i2CController$2.invoke(MainActivity.kt:40) at com.cililing.harvbox.thingsapp.ui.MainActivity$i2CController$2.invoke(MainActivity.kt:33) at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:74) at com.cililing.harvbox.thingsapp.ui.MainActivity.getI2CController(Unknown Source:25) at com.cililing.harvbox.thingsapp.ui.MainActivity.access$getI2CController$p(MainActivity.kt:33) at com.cililing.harvbox.thingsapp.ui.MainActivity$i2cLogger$1.run(MainActivity.kt:47) at android.os.Handler.handleCallback(Handler.java:790) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:164) at android.app.ActivityThread.main(ActivityThread.java:6494) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) I am using following driver: https://github.com/androidthings/contrib-drivers/tree/master/adc What I've already done: uninstall all apps reinstall whole AndroidThings I tired both, I2C1 and I2C2 try to read value on new app (only example from library). I have no idea what can I do more. I am pretty sure that device is connected properly (scl-scl, sda-sda, addr-gnd, a0-other_analog_output) to main board and error is actually kind of strange, as I am sure that none other app uses those pins. code responsible for connecting with peripheral: class ADS1015ControllerImpl(val i2cName: String, val range: Int) : ADS1015Controller { private val instance: Ads1xxx = Ads1xxx(i2cName, Ads1xxx.Configuration.ADS1015) init { instance.inputRange = range } override fun read(channel: Int, logger: (Int) -> Unit) { logger.invoke( instance.readSingleEndedInput(channel) ) } override fun release() { instance.close() } }
The error message I2C2 is already in use (code 16) means you are trying to open more than one connection to the same I2C bus without closing the previous instance. The code to open the I2C connection lives within the Ads1xxx constructor. You must either manage a single instance of this class in your code, or be certain that you call close() on the current Ads1xxx before initializing another one. Based on the stack trace, it also looks like this device is being initialized by a lazy load when the value it first accessed, so it's possible that this constructor is not getting invoked at the point you expected, causing things to come out of order.
In fact, the problem was a badly soldered plug. :)
Weblogic 12.2.1.3 InvalidJarIndexException
I'm having a huge issue with Weblogic 12.2.1.3 trying to deploy an application which, by the way, deploys fine to Weblogic 12.1.3. There seems to be some kind of incompatibilities with libraries used by Weblogic 12.2.1.3. I have tried adding preferred packages but no success yet. I'm posting below the stack trace showing this exception. Please comment any ideas on this: ####<May 21, 2018 10:47:18,491 AM EDT> <Error> <Console> <EADCDRITSP2429> <AdminServer> <[ACTIVE] ExecuteThread: '14' for queue: 'weblogic.kernel.Default (self-tuning)'> <system> <> <5d345739-6009-4af0-b810-114da13abb45-00000034> <1526914038491> <[severity-value: 8] [rid: 0] [partition-id: 0] [partition-name: DOMAIN] > <BEA-240003> <Administration Console encountered the following error: weblogic.application.ModuleException: sun.misc.InvalidJarIndexException: Invalid index:sun.misc.InvalidJarIndexException:Invalid index at sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:1140) at sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:1050) at sun.misc.URLClassPath.getResource(URLClassPath.java:239) at java.net.URLClassLoader$1.run(URLClassLoader.java:365) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at weblogic.utils.classloaders.GenericClassLoader.doParentDelegate(GenericClassLoader.java:584) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:526) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:496) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:473) at weblogic.utils.classloaders.GenericClassLoader.doParentDelegate(GenericClassLoader.java:584) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:526) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:496) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:473) at weblogic.utils.classloaders.GenericClassLoader.doParentDelegate(GenericClassLoader.java:584) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:526) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:496) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:473) at weblogic.utils.classloaders.GenericClassLoader.doParentDelegate(GenericClassLoader.java:584) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:526) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:496) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:473) at weblogic.utils.classloaders.GenericClassLoader.doParentDelegate(GenericClassLoader.java:584) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:526) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:496) at weblogic.utils.classloaders.ChangeAwareClassLoader.loadClass(ChangeAwareClassLoader.java:72) at java.lang.ClassLoader.loadClass(ClassLoader.java:411) at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:676) at groovy.lang.GroovyClassLoader.loadClass(GroovyClassLoader.java:544) at org.codehaus.groovy.control.ClassNodeResolver.tryAsLoaderClassOrScript(ClassNodeResolver.java:183) at org.codehaus.groovy.control.ClassNodeResolver.findClassNode(ClassNodeResolver.java:168) at org.codehaus.groovy.control.ClassNodeResolver.resolveName(ClassNodeResolver.java:124) at org.codehaus.groovy.control.ResolveVisitor.resolveToOuter(ResolveVisitor.java:661) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:274) at org.codehaus.groovy.control.ResolveVisitor.resolveFromStaticInnerClasses(ResolveVisitor.java:404) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:274) at org.codehaus.groovy.control.ResolveVisitor.resolveFromStaticInnerClasses(ResolveVisitor.java:404) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:274) at org.codehaus.groovy.control.ResolveVisitor.resolveFromStaticInnerClasses(ResolveVisitor.java:404) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:274) at org.codehaus.groovy.control.ResolveVisitor.visitClass(ResolveVisitor.java:1202) at org.codehaus.groovy.control.ResolveVisitor.startResolving(ResolveVisitor.java:146) at org.codehaus.groovy.control.CompilationUnit$11.call(CompilationUnit.java:648) at org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits(CompilationUnit.java:928) at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:590) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:539) at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:297) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:267) at groovy.lang.GroovyShell.parseClass(GroovyShell.java:692) at groovy.lang.GroovyShell.parse(GroovyShell.java:704) at groovy.lang.GroovyShell.parse(GroovyShell.java:740) at groovy.lang.GroovyShell.parse(GroovyShell.java:731) at groovy.lang.GroovyShell$parse.call(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120) at ch.qos.logback.classic.gaffer.GafferConfigurator.run(GafferConfigurator.groovy:71) at ch.qos.logback.classic.gaffer.GafferConfigurator$run.callCurrent(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:49) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:149) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:161) at ch.qos.logback.classic.gaffer.GafferConfigurator.run(GafferConfigurator.groovy:44) at ch.qos.logback.classic.gaffer.GafferUtil.runGafferConfiguratorOn(GafferUtil.java:43) at ch.qos.logback.classic.util.ContextInitializer.configureByResource(ContextInitializer.java:67) at ch.qos.logback.classic.util.ContextInitializer.autoConfig(ContextInitializer.java:150) at org.slf4j.impl.StaticLoggerBinder.init(StaticLoggerBinder.java:84) at org.slf4j.impl.StaticLoggerBinder.<clinit>(StaticLoggerBinder.java:55) at org.slf4j.LoggerFactory.bind(LoggerFactory.java:145) at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:124) at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:328) at ch.qos.logback.classic.util.StatusViaSLF4JLoggerFactory.addStatus(StatusViaSLF4JLoggerFactory.java:32) at ch.qos.logback.classic.util.StatusViaSLF4JLoggerFactory.addInfo(StatusViaSLF4JLoggerFactory.java:20) at ch.qos.logback.classic.servlet.LogbackServletContainerInitializer.onStartup(LogbackServletContainerInitializer.java:32) at weblogic.servlet.internal.WebAppServletContext.initContainerInitializer(WebAppServletContext.java:1404) at weblogic.servlet.internal.WebAppServletContext.initContainerInitializers(WebAppServletContext.java:1364) at weblogic.servlet.internal.WebAppServletContext.initContainerInitializers(WebAppServletContext.java:1345) at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1917) at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3101) at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1843) at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:884) at weblogic.application.internal.ExtensibleModuleWrapper$StartStateChange.next(ExtensibleModuleWrapper.java:360) at weblogic.application.internal.ExtensibleModuleWrapper$StartStateChange.next(ExtensibleModuleWrapper.java:356) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.ExtensibleModuleWrapper.start(ExtensibleModuleWrapper.java:138) at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:124) at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:233) at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:228) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:78) at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:52) at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:752) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:45) at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:262) at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:66) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:90) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:631) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:171) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:121) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:348) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:907) at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1468) at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:459) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:181) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:217) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:14) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:69) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:670) at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352) at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337) at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57) at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41) at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTu`enter code here`ningWorkManagerImpl.java:644) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:415) at weblogic.work.ExecuteThread.run(ExecuteThread.java:355)
Problem was solved by adding -Djava.system.class.loader=com.oracle.classloader.weblogic.LaunchClassLoader to the startup arguments