mycontroller-org / mycontroller-v1-legacy

The Open Source Controller
http://www.MyController.org
Apache License 2.0
148 stars 90 forks source link

Send Raw Message - Internal not showing sub-types #417

Closed seant100 closed 6 years ago

seant100 commented 6 years ago

On latest snapshot release when going to Action Board -> Send Raw message and selecting Internal, no sub-types are listed and hence cannot send a reboot command

cimba007 commented 6 years ago

@seant100 Something similar happened last time when I did a "dirty update" just replacing the .jar file. Did you replace the content of the www subfolder too?

If so did you try to clear the browser cache as mycontroller seems to be quite persistent with caching.

seant100 commented 6 years ago

@cimba007

I replaced the entire mycontroller directory - excluding backups folder and then replaced the database file with the one you provided for the slow graph issue.

In chrome I used "Empty Cache and Hard Reload" option and issue remains. I tried chrome in a "New Private Window" and same issue. I tried another browser (Firefox) and same issue.

Note: The other "Types" all show "Sub-Types" - it is only "Internal" that does not show the sub-types. I.e. When selecting Presentation, Set, Request or Stream the "Sub Types" dropdown is populated. So it is only when "Internal" is selected that the Sub-Types fails to populate.

cimba007 commented 6 years ago

@jkandasa

:8443/mc/rest/types/messageSubTypes?messageType=Internal Failed to load resource: the server responded with a status of 500 (Internal server error)
seant100 commented 6 years ago

@cimba007 Here is a screenshot of showing console error in chrome that occurs when selecting "Internal" - It gives Internal server error : Http 500 error response

untitled

cimba007 commented 6 years ago

Maybe related to this?

2017-11-04 19:13:02,237 ERROR [Acme.Utils.ThreadPool(2)-PooledThread: Acme.Serve.Serve$ServeConnection@158aa60] [org.mycontroller.standalone.api.jaxrs.exception.mappers.ApplicationExceptionMapper:42] ApplicationException,
org.jboss.resteasy.spi.ApplicationException: java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key I_SIGNAL_REPORT_REQUEST
    at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:152)
    at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:295)
    at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:249)
    at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:236)
    at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:395)
    at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:202)
    at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:221)
    at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56)
    at org.jboss.resteasy.plugins.server.tjws.TJWSServletDispatcher.service(TJWSServletDispatcher.java:40)
    at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at Acme.Serve.Serve$ServeConnection.runServlet(Serve.java:2328)
    at Acme.Serve.Serve$ServeConnection.parseRequest(Serve.java:2282)
    at Acme.Serve.Serve$ServeConnection.run(Serve.java:2054)
    at Acme.Utils$ThreadPool$PooledThread.run(Utils.java:1402)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key I_SIGNAL_REPORT_REQUEST
    at java.util.ResourceBundle.getObject(ResourceBundle.java:450)
    at java.util.ResourceBundle.getString(ResourceBundle.java:407)
    at org.mycontroller.standalone.utils.TypesUtils.getMessageSubTypes(TypesUtils.java:1002)
    at org.mycontroller.standalone.api.jaxrs.TypesHandler.getMessageSubTypes(TypesHandler.java:420)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:139)
    ... 15 common frames omitted

I guess the corresponding key is missing here:

https://github.com/mycontroller-org/mycontroller/blob/ed159dab66c596b45631f8cf5dcfd3b2fccb8b53/modules/core/src/main/java/org/mycontroller/standalone/message/McMessageUtils.java

jkandasa commented 6 years ago

@seant100 @cimba007 Thank you! Yes, it is bug I will fix it soon.

jkandasa commented 6 years ago

@cimba007 @seant100 fix added on SNAPSHOT version. Kindly check it and report back. Thank you!

seant100 commented 6 years ago

@jkandasa Yes the sub-types for Internal are working in new Snapshot. Thank you