Error attempting to use elasticsearch-grails-plugin: getting java.lang.IllegalStateException - spring

I'm running grails 4.0.1 attempting to use org.grails.plugins:elasticsearch:3.0.0 with elasticsearch 7.9.0. I'm not sure if I've misconfigured a bean along the way that I'd missed but any help in the right direction would be well received! Near ready to drop using the plugin if can't get it wired in my env but would like to keep up with it.
More complete trace contains
Caused by: org.springframework.beans.ConversionNotSupportedException: Failed to convert property value of type 'grails.core.support.proxy.DefaultProxyHandler' to required type 'grails.core.support.proxy.EntityProxyHandler' for property 'proxyHandler'; nested exception is java.lang.IllegalStateException: Cannot convert value of type 'grails.core.support.proxy.DefaultProxyHandler' to required type 'grails.core.support.proxy.EntityProxyHandler' for property 'proxyHandler': no matching editors or conversion strategy found
at org.springframework.beans.AbstractNestablePropertyAccessor.convertIfNecessary(AbstractNestablePropertyAccessor.java:590)
at org.springframework.beans.AbstractNestablePropertyAccessor.convertForProperty(AbstractNestablePropertyAccessor.java:604)
at org.springframework.beans.BeanWrapperImpl.convertForProperty(BeanWrapperImpl.java:219)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.convertForProperty(AbstractAutowireCapableBeanFactory.java:1723)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1679)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1426)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:592)
... 49 common frames omitted
Caused by: java.lang.IllegalStateException: Cannot convert value of type 'grails.core.support.proxy.DefaultProxyHandler' to required type 'grails.core.support.proxy.EntityProxyHandler' for property 'proxyHandler': no matching editors or conversion strategy found
at org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:262)
at org.springframework.beans.AbstractNestablePropertyAccessor.convertIfNecessary(AbstractNestablePropertyAccessor.java:585)

Related

Failed to convert from type [java.lang.String] to type [java.lang.Long] for value image.svg

I was able to load an image with thymeleaf with this clause : th:src="#{/images/EmptyChat.svg}"
But, now I'm getting this error :
Failed to convert from type [java.lang.String] to type [java.lang.Long] for value image.svg
How can I resolve this problem please?
I resolve the problem by converting the svg to png image.

how to replace java.sql.sqldata as it's unsupported in tibero

as java.sql.sqldata is not supported in tibero jdbc driver, we'd like to know how to modify it or any replacement
is java.sql.Array a replacement of java.sql.sqldata?
there's no code so far
if we implement java.sql.sqldata in tibero, we will hit the following error: Cause: java.sql.SQLException: JDBC-90608:Invalid input parameter

JsonDecoder parsing failing in spark streaming

I am trying to decode a message coming as part of avro message in my spark2.2 streaming. I have a schema defined for this json and whenever the json message comes with out honoring the json schema, my JsonDecoder fails with below error
Caused by: org.apache.avro.AvroTypeException: Expected field name not found: "some_field"
at org.apache.avro.io.JsonDecoder.doAction(JsonDecoder.java:477)
at org.apache.avro.io.parsing.Parser.advance(Parser.java:88)
at org.apache.avro.io.JsonDecoder.advance(JsonDecoder.java:139)
at org.apache.avro.io.JsonDecoder.readString(JsonDecoder.java:219)
at org.apache.avro.io.JsonDecoder.readString(JsonDecoder.java:214)
at org.apache.avro.io.ResolvingDecoder.readString(ResolvingDecoder.java:201)
at org.apache.avro.generic.GenericDatumReader.readString(GenericDatumReader.java:422)
at org.apache.avro.generic.GenericDatumReader.readString(GenericDatumReader.java:414)
at org.apache.avro.generic.GenericDatumReader.readWithoutConversion(GenericDatumReader.java:181)
at org.apache.avro.generic.GenericDatumReader.read(GenericDatumReader.java:153)
at org.apache.avro.generic.GenericDatumReader.readField(GenericDatumReader.java:232)
at org.apache.avro.generic.GenericDatumReader.readRecord(GenericDatumReader.java:222)
at org.apache.avro.generic.GenericDatumReader.readWithoutConversion(GenericDatumReader.java:175)
at org.apache.avro.generic.GenericDatumReader.read(GenericDatumReader.java:153)
at org.apache.avro.generic.GenericDatumReader.read(GenericDatumReader.java:145)
at org.apache.spark.sql.catalyst.expressions.GeneratedClass$GeneratedIterator.processNext(Unknown Source)
at org.apache.spark.sql.execution.BufferedRowIterator.hasNext(BufferedRowIterator.java:43)
at org.apache.spark.sql.execution.WholeStageCodegenExec$$anonfun$8$$anon$1.hasNext(WholeStageCodegenExec.scala:395)
at org.apache.spark.sql.execution.datasources.FileFormatWriter$SingleDirectoryWriteTask.execute(FileFormatWriter.scala:315)
at org.apache.spark.sql.execution.datasources.FileFormatWriter$$anonfun$org$apache$spark$sql$execution$datasources$FileFormatWriter$$executeTask$3.apply(FileFormatWriter.scala:258)
at org.apache.spark.sql.execution.datasources.FileFormatWriter$$anonfun$org$apache$spark$sql$execution$datasources$FileFormatWriter$$executeTask$3.apply(FileFormatWriter.scala:256)
at org.apache.spark.util.Utils$.tryWithSafeFinallyAndFailureCallbacks(Utils.scala:1375)
at org.apache.spark.sql.execution.datasources.FileFormatWriter$.org$apache$spark$sql$execution$datasources$FileFormatWriter$$executeTask(FileFormatWriter.scala:261)
I know jackson decoding has a way to ignore the extra as well as absent fields. Is there a way in org.apache.avro.io.JsonDecoder for the same behaviour?

How to read tomcat error log

Here is a screenshot of my tomcat spring boot error log. How do I read this?
Specifically,
1.) where do I read there is says "63 more"?
2.) Is the top-most error the most generic, or most specific? I'm thinking most generic because it says "caused by" and then another error.
Thanks.
First, get destination of log (console, file, database, ...) by find information in:
application.properties (for example: spring.log.**** = ...)
or log4j.properties/log4j.yml/log4j.yaml (if using log4j)
or log4j2.properties/log4j2.yml/log4j2.yaml (if using log4j2)
or logback.properties/logback.yml (if using logback)
and then you can get "63 more" there
It's the most specific
most specific error <== root cause is here
^ cause by: generic error
^ cause by: generic error
...
^ cause by: most generic error
The first line contains the exact reason for the error, such as this:
java.lang.NullPointerException
abc.def.ghi.handleRequest(MyController.java:30)
...
The more you go down, the more information you get about the root cause. Usually you can find the cause at the bottom of the log message containing the stack trace. In your case, the cause for the exception is "No converter found capable of converting from type ...".

The prefix "security" for element "security:http" is not bound

i get error
2009-05-24 21:49:56,399 ERROR [org.springframework.web.context.ContextLoader] - Context initialization failed
org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 38 in XML document from ServletContext resource [/WEB-INF/applicationContext.xml] is invalid; nested exception is org.xml.sax.SAXParseException: The prefix "security" for element "security:http" is not bound.
reference url: http://forum.springsource.org/showthread.php?p=242557#post242557
can anyone please comment what i did wrong?
You posted the question on the spring forum, and it was answered there.

Resources