Commanding Error Message Yamcs Quickstart

74 views
Skip to first unread message

Onur Gürdoğan

unread,
Apr 14, 2021, 3:28:35 AM4/14/21
to yamcs
Hi,

I have started to facing some issue while I wanted to open "Send Command" and "MDB/Commands" sections. After I tried to open those sections there are no Command descriptions appears, although I have 10+ command examples inside xtce. I could be able to open it and send it 1 week ago but yesterday I faced this. I hope error message can be seen below, in any case I sharing it here also:

1.

10:25:14.513 _global [23] CallObserver Internal server error while handling call: org.yamcs.http.InternalServerErrorException: java.lang.NullPointerException
        org.yamcs.http.RouteHandler.handleException(RouteHandler.java:118)
        org.yamcs.http.RouteHandler.dispatch(RouteHandler.java:87)
        org.yamcs.http.RouteHandler.handle(RouteHandler.java:51)
        org.yamcs.http.Handler.handle(Handler.java:23)
        org.yamcs.http.Handler.channelRead0(Handler.java:29)
        org.yamcs.http.Handler.channelRead0(Handler.java:9)

2. 

10:25:14.518 _global [23] HttpRequestHandler 80f2210a GET /api/mdb/myproject/commands?system=/myproject&noAbstract=true&pos=0&limit=100 500
 

CommandErrorMessageYamcs.png

fabia...@spaceapplications.com

unread,
Apr 14, 2021, 3:45:15 AM4/14/21
to yamcs
Hi, can you show more of that stacktrace? The real cause should be somewhere in the middle. I only see the head and tail in your text/screenshots.
And if you can tell the version of yamcs-core (see pom.xml) that you're using, that will also help us to interpret the stacktrace correctly.

Onur Gürdoğan

unread,
Apr 14, 2021, 3:55:51 AM4/14/21
to yamcs
Hi Fabian,

Sure I can share it! My bad not sharing it at the first time.. 

```
10:41:42.145 _global [27] CallObserver Internal server error while handling call: org.yamcs.http.InternalServerErrorException: java.lang.NullPointerException
        org.yamcs.http.RouteHandler.handleException(RouteHandler.java:118)
        org.yamcs.http.RouteHandler.dispatch(RouteHandler.java:87)
        org.yamcs.http.RouteHandler.handle(RouteHandler.java:51)
        org.yamcs.http.Handler.handle(Handler.java:23)
        org.yamcs.http.Handler.channelRead0(Handler.java:29)
        org.yamcs.http.Handler.channelRead0(Handler.java:9)
        io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:99)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
        io.netty.handler.codec.MessageToMessageCodec.channelRead(MessageToMessageCodec.java:111)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        org.yamcs.http.HttpRequestHandler.channelRead(HttpRequestHandler.java:158)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436)
        io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324)
        io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:296)
        io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.handler.traffic.AbstractTrafficShapingHandler.channelRead(AbstractTrafficShapingHandler.java:513)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
        io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)
        io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:719)
        io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:655)
        io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:581)
        io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493)
        io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
        io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
        io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.NullPointerException
        org.yamcs.http.api.XtceToGpbAssembler.toUnitInfo(XtceToGpbAssembler.java:956)
        org.yamcs.http.api.XtceToGpbAssembler.toArgumentTypeInfo(XtceToGpbAssembler.java:780)
        org.yamcs.http.api.XtceToGpbAssembler.toArgumentInfo(XtceToGpbAssembler.java:411)
        org.yamcs.http.api.XtceToGpbAssembler.toCommandInfo(XtceToGpbAssembler.java:362)
        org.yamcs.http.api.MdbApi.listCommands(MdbApi.java:485)
        org.yamcs.http.api.MdbApi.listCommands(MdbApi.java:93)
        org.yamcs.protobuf.AbstractMdbApi.callMethod(AbstractMdbApi.java:269)
        org.yamcs.http.RouteHandler.dispatch(RouteHandler.java:84)
        org.yamcs.http.RouteHandler.handle(RouteHandler.java:51)
        org.yamcs.http.Handler.handle(Handler.java:23)
        org.yamcs.http.Handler.channelRead0(Handler.java:29)
        org.yamcs.http.Handler.channelRead0(Handler.java:9)
        io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:99)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
        io.netty.handler.codec.MessageToMessageCodec.channelRead(MessageToMessageCodec.java:111)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        org.yamcs.http.HttpRequestHandler.channelRead(HttpRequestHandler.java:158)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436)
        io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324)
        io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:296)
        io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.handler.traffic.AbstractTrafficShapingHandler.channelRead(AbstractTrafficShapingHandler.java:513)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
        io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)
        io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:719)
        io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:655)
        io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:581)
        io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493)
        io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
        io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
        io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        java.base/java.lang.Thread.run(Thread.java:834)

10:41:42.146 _global [27] HttpRequestHandler 4611fe63 GET /api/mdb/myproject/commands?pos=0&limit=100 500
```

My version of yamcs-core is: 5.4.1

2 days ago one of my colleague perfom "git pull" and "git fetch origin" without a new "mvn build". Is it can be a problem? Something is may conflicting?

14 Nisan 2021 Çarşamba tarihinde saat 10:45:15 UTC+3 itibarıyla fabia...@spaceapplications.com şunları yazdı:

Onur Gürdoğan

unread,
Apr 14, 2021, 4:37:08 AM4/14/21
to yamcs
I did perform a new clean start-up. It worked fine with the default xtce (with new enum parameters) file but when I added CommandMetaData inside of it and tried to open command related pages, it failed again :/

14 Nisan 2021 Çarşamba tarihinde saat 10:55:51 UTC+3 itibarıyla Onur Gürdoğan şunları yazdı:

fabia...@spaceapplications.com

unread,
Apr 14, 2021, 5:11:30 AM4/14/21
to yamcs
Looks like an issue relating to the units of one or more of your command arguments in XTCE file.
(this is the line that throws the exception: https://github.com/yamcs/yamcs/blob/yamcs-5.4.1/yamcs-core/src/main/java/org/yamcs/http/api/XtceToGpbAssembler.java#L956 )

It should be something of this form:

<xtce:UnitSet>
  <xtce:Unit description="current">Amperes</xtce:Unit>
</xtce:UnitSet>


or an empty tag if there is no units:
<xtce:UnitSet />

But we should catch such errors earlier, so if you can provide the UnitSet XML that is causing difficulties, we can make sure to add an extra check already when the server starts.

fabia...@spaceapplications.com

unread,
Apr 14, 2021, 5:14:46 AM4/14/21
to yamcs
> 2 days ago one of my colleague perfom "git pull" and "git fetch origin" without a new "mvn build". Is it can be a problem? Something is may conflicting?

Not necessarily. The quickstart repo only needs to compile its own code, which happens also automatically when you do yamcs:run.

Onur Gürdoğan

unread,
Apr 14, 2021, 5:38:40 AM4/14/21
to yamcs

Well you are right. I found a UnitSet that is completely unnecessary as given below.

``` 
<UnitSet>
     <Unit/>
<UnitSet>
```

When I removed it, it worked fine. Thank you!
14 Nisan 2021 Çarşamba tarihinde saat 12:14:46 UTC+3 itibarıyla fabia...@spaceapplications.com şunları yazdı:
Reply all
Reply to author
Forward
0 new messages