Project

General

Profile

Actions

Bug #12433

open

APIForNG. Ошибка в методе 7 установка свойств при работе с листовыми типами в листовых типах

Added by Радек Мария over 1 year ago. Updated over 1 year ago.

Status:
Resolved
Priority:
Normal
Category:
-
Target version:
-
Start date:
05/30/2023
Due date:
% Done:

100%

Estimated time:
Detected in build:
git
Platform:
Published in build:
1.4.796

Description

При попытке сохранить тип LIST в типе LIST (список списков) через метод 7
(PUT /projects/{project_name}/nodes/{uuid_of_node}/attributes/)
на запрос вида

{
  "attributes": {
    "listattr":       {
         "value": [         {
            "value": [            {
               "value": "1111",
               "type": "STRING" 
            }],
            "valuesType": "STRING",
            "type": "LIST" 
         }],
         "valuesType": "LIST",
         "type": "LIST" 
      }
  }
}

Возвращается ошибка:

{
   "success": false,
   "error":    {
      "code": "class com.unitesk.requality.api.models.JsonEnumValue cannot be cast to class com.unitesk.requality.api.models.GJsonListValue (com.unitesk.requality.api.models.JsonEnumValue and com.unitesk.requality.api.models.GJsonListValue are in unnamed module of loader org.eclipse.osgi.internal.loader.EquinoxClassLoader @51141f64)",
      "message": "java.lang.ClassCastException: class com.unitesk.requality.api.models.JsonEnumValue cannot be cast to class com.unitesk.requality.api.models.GJsonListValue (com.unitesk.requality.api.models.JsonEnumValue and com.unitesk.requality.api.models.GJsonListValue are in unnamed module of loader org.eclipse.osgi.internal.loader.EquinoxClassLoader @51141f64)\r\n\tat com.unitesk.requality.api.services.nodes.NodesService.jsonAttrToValue(NodesService.java:770)\r\n\tat com.unitesk.requality.api.services.nodes.NodesService.jsonAttrToValue(NodesService.java:776)\r\n\tat com.unitesk.requality.api.services.nodes.NodesService.httpPutAttributes(NodesService.java:458)\r\n\tat java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\r\n\tat java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)\r\n\tat java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\r\n\tat java.base/java.lang.reflect.Method.invoke(Method.java:568)\r\n\tat org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory.lambda$static$0(ResourceMethodInvocationHandlerFactory.java:52)\r\n\tat org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:134)\r\n\tat org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:177)\r\n\tat org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$TypeOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:219)\r\n\tat org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:81)\r\n\tat org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:478)\r\n\tat org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:400)\r\n\tat org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:81)\r\n\tat org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:256)\r\n\tat org.glassfish.jersey.internal.Errors$1.call(Errors.java:248)\r\n\tat org.glassfish.jersey.internal.Errors$1.call(Errors.java:244)\r\n\tat org.glassfish.jersey.internal.Errors.process(Errors.java:292)\r\n\tat org.glassfish.jersey.internal.Errors.process(Errors.java:274)\r\n\tat org.glassfish.jersey.internal.Errors.process(Errors.java:244)\r\n\tat org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:265)\r\n\tat org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:235)\r\n\tat org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:684)\r\n\tat org.glassfish.jersey.jetty.JettyHttpContainer.handle(JettyHttpContainer.java:175)\r\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)\r\n\tat org.eclipse.jetty.server.Server.handle(Server.java:516)\r\n\tat org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:487)\r\n\tat org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732)\r\n\tat org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479)\r\n\tat org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)\r\n\tat
org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)\r\n\tat org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)\r\n\tat org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)\r\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338)\r\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315)\r\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173)\r\n\tat org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131)\r\n\tat org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409)\r\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)\r\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)\r\n\tat java.base/java.lang.Thread.run(Thread.java:833)\r\n",
      "extra": {}
   }
}

Actions #1

Updated by Denis Kildishev over 1 year ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 100
Actions #2

Updated by Denis Kildishev over 1 year ago

  • Published in build set to 1.4.796
Actions

Also available in: Atom PDF