问:
UnresolvedElementException: Discovered unresolved method during parsing: org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class)
I'm writing an application using Quarkus and GraalVM to build a native image. I use scriptella for ETL and the build keeps failing for Janino driver. As far as i can tell, there is a deprecated method org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class) and it fails because of it'S absence in janino V3.1.9
I have reflection-config.json  set up correctly and works for other scriptella drivers such as csv. Any idea how can i do a workaround the deprecated method?

build output:

```========================================================================================================================
GraalVM Native Image: Generating 'demo-1.0.0-SNAPSHOT-runner' (executable)...
========================================================================================================================
[1/7] Initializing...                                                                                (9,8s @ 0,40GB)
 Version info: 'GraalVM 22.3.0.1-Final Java 17 Mandrel Distribution'
 Java version info: '17.0.5+8'
 C compiler: gcc (redhat, x86_64, 8.5.0)
 Garbage collector: Serial GC
 8 user-specific feature(s)
 - com.oracle.svm.thirdparty.gson.GsonFeature
 - io.quarkus.caffeine.runtime.graal.CacheConstructorsFeature
 - io.quarkus.hibernate.orm.runtime.graal.DisableLoggingFeature: Disables INFO logging during the analysis phase for the [org.hibernate.Version, org.hibernate.annotations.common.Version, org.hibernate.dialect.Dialect] categories
 - io.quarkus.runner.Feature: Auto-generated class by Quarkus from the existing extensions
 - io.quarkus.runtime.graal.DisableLoggingFeature: Disables INFO logging during the analysis phase for the [org.jboss.threads] categories
 - io.quarkus.runtime.graal.ResourcesFeature: Register each line in META-INF/quarkus-native-resources.txt as a resource on Substrate VM
 - org.hibernate.graalvm.internal.GraalVMStaticFeature: Hibernate ORM's static reflection registrations for GraalVM
 - org.hibernate.graalvm.internal.QueryParsingSupport: Hibernate ORM's support for HQL Parser in GraalVM
10:20:02,153 INFO  [org.hib.sea.map.orm.boo.imp.HibernateSearchPreIntegrationService] HSEARCH000034: Hibernate Search version 6.1.7.Final
10:20:02,244 INFO  [org.hib.sea.map.orm.boo.imp.HibernateSearchPreIntegrationService] HSEARCH000034: Hibernate Search version 6.1.7.Final
[2/7] Performing analysis...  [*]                                                                       (14,4s @ 0,72GB)
   6.032 (73,61%) of  8.195 classes reachable
   6.524 (48,72%) of 13.390 fields reachable
  22.390 (37,96%) of 58.976 methods reachable
     496 classes,   381 fields, and 2.328 methods registered for reflection

Fatal error: com.oracle.graal.pointsto.util.AnalysisError$ParsingError: Error encountered while parsing scriptella.driver.janino.JaninoConnection.executeQuery(scriptella.spi.Resource, scriptella.spi.ParametersCallback, scriptella.spi.QueryCallback)
Parsing context:
   at scriptella.driver.janino.JaninoConnection.executeQuery(JaninoConnection.java:68)
   at scriptella.core.QueryExecutor.execute(QueryExecutor.java:71)
   at scriptella.core.ContentExecutor.execute(ContentExecutor.java:73)
   at scriptella.core.ElementInterceptor.executeNext(ElementInterceptor.java:56)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:41)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)

        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.AnalysisError.parsingError(AnalysisError.java:153)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.createFlowsGraph(MethodTypeFlow.java:104)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.ensureFlowsGraphCreated(MethodTypeFlow.java:83)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.getOrCreateMethodFlowsGraph(MethodTypeFlow.java:65)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.typestate.DefaultVirtualInvokeTypeFlow.onObservedUpdate(DefaultVirtualInvokeTypeFlow.java:109)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.TypeFlow.update(TypeFlow.java:562)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.PointsToAnalysis$1.run(PointsToAnalysis.java:488)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.CompletionExecutor.executeCommand(CompletionExecutor.java:193)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.CompletionExecutor.lambda$executeService$0(CompletionExecutor.java:177)
        at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1395)
        at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
        at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
        at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
        at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
        at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
Caused by: org.graalvm.compiler.java.BytecodeParser$BytecodeParserError: com.oracle.graal.pointsto.constraints.UnresolvedElementException: Discovered unresolved method during parsing: org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class). This error is reported at image build time because class scriptella.driver.janino.CodeCompiler is registered for linking at image build time by command line
        at parsing scriptella.driver.janino.CodeCompiler.compile(CodeCompiler.java:62)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.throwParserError(BytecodeParser.java:2518)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.throwParserError(SharedGraphBuilderPhase.java:110)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.iterateBytecodesForBlock(BytecodeParser.java:3393)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.handleBytecodeBlock(BytecodeParser.java:3345)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.processBlock(BytecodeParser.java:3190)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.build(BytecodeParser.java:1138)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.buildRootMethod(BytecodeParser.java:1030)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.GraphBuilderPhase$Instance.run(GraphBuilderPhase.java:97)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase.run(SharedGraphBuilderPhase.java:84)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.Phase.run(Phase.java:49)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:446)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.Phase.apply(Phase.java:42)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.Phase.apply(Phase.java:38)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.AnalysisParsedGraph.parseBytecode(AnalysisParsedGraph.java:135)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.meta.AnalysisMethod.ensureGraphParsed(AnalysisMethod.java:685)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.phases.InlineBeforeAnalysisGraphDecoder.lookupEncodedGraph(InlineBeforeAnalysis.java:180)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.doInline(PEGraphDecoder.java:1162)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.tryInline(PEGraphDecoder.java:1145)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.trySimplifyInvoke(PEGraphDecoder.java:1003)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.handleInvoke(PEGraphDecoder.java:957)
        at jdk.internal.vm.compiler/org.graalvm.compiler.nodes.GraphDecoder.processNextNode(GraphDecoder.java:817)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.phases.InlineBeforeAnalysisGraphDecoder.processNextNode(InlineBeforeAnalysis.java:240)
        at jdk.internal.vm.compiler/org.graalvm.compiler.nodes.GraphDecoder.decode(GraphDecoder.java:548)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.decode(PEGraphDecoder.java:833)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.phases.InlineBeforeAnalysis.decodeGraph(InlineBeforeAnalysis.java:98)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlowBuilder.parse(MethodTypeFlowBuilder.java:179)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlowBuilder.apply(MethodTypeFlowBuilder.java:349)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.createFlowsGraph(MethodTypeFlow.java:93)
        ... 13 more
Caused by: com.oracle.graal.pointsto.constraints.UnresolvedElementException: Discovered unresolved method during parsing: org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class). This error is reported at image build time because class scriptella.driver.janino.CodeCompiler is registered for linking at image build time by command line
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.reportUnresolvedElement(SharedGraphBuilderPhase.java:333)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.handleUnresolvedMethod(SharedGraphBuilderPhase.java:323)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.handleUnresolvedInvoke(SharedGraphBuilderPhase.java:279)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.genInvokeVirtual(BytecodeParser.java:1721)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.processBytecode(BytecodeParser.java:5286)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.iterateBytecodesForBlock(BytecodeParser.java:3385)
        ... 38 more
------------------------------------------------------------------------------------------------------------------------
                        1,1s (4,3% of total time) in 20 GCs | Peak RSS: 2,84GB | CPU load: 4,87
========================================================================================================================
Failed generating 'demo-1.0.0-SNAPSHOT-runner' after 24,5s.
Error: Image build request failed with exit status 1
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  35.694 s
[INFO] Finished at: 2023-01-13T11:20:16+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:2.14.1.Final:build (default) on project demo: Failed to build quarkus application: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
[ERROR]         [error]: Build step io.quarkus.deployment.pkg.steps.NativeImageBuildStep#build threw an exception: io.quarkus.deployment.pkg.steps.NativeImageBuildStep$ImageGenerationFailureException: Image generation failed. Exit code: 1
[ERROR]         at io.quarkus.deployment.pkg.steps.NativeImageBuildStep.imageGenerationFailed(NativeImageBuildStep.java:421)
[ERROR]         at io.quarkus.deployment.pkg.steps.NativeImageBuildStep.build(NativeImageBuildStep.java:262)
[ERROR]         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR]         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[ERROR]         at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR]         at java.base/java.lang.reflect.Method.invoke(Method.java:566)
[ERROR]         at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:909)
[ERROR]         at io.quarkus.builder.BuildContext.run(BuildContext.java:281)
[ERROR]         at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR]         at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
[ERROR]         at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
[ERROR]         at java.base/java.lang.Thread.run(Thread.java:834)
[ERROR]         at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
```
<p>I check graalVM and quarkus documentaion, i tried building args such as
<code>--initialize-at-runtime=org.codehaus.janino.ScriptEvaluator </code>
but it didn't change anything</p>
<p>I also added other classes for reflection - same result</p>
<p>[UPDATE]</p>
<p>I managed to fix the build using GraalVM 22.3.0 && Java 11 (which is needed for the project) and when i build the native image <code>quarkus build --native</code> it's successful.</p>
<p>The issue that I'm working on now is the reflection using <strong>scriptella</strong>, I included</p>
```quarkus.native.additional-build-args =\-H:ReflectionConfigurationFiles=reflection-config.json,\
                                       -H:ResourceConfigurationFiles=resources-config.json,\
                                       -H:JNIConfigurationFiles=jniconfig.json,\
                                       -H:IncludeResourceBundles=com.sun.org.apache.xerces.internal.impl.msg.XMLMessages
```
<p>and that's the error I'm facing now</p>
```ERROR [io.qua.ver.htt.run.QuarkusErrorHandler] (executor-thread-0) HTTP Request to /etl/csv failed, error id: 3ddf8c2e-0c9b-44c9-8967-5c03abdfe3a1-2: com.oracle.svm.core.jdk.UnsupportedFeatureError: Runtime reflection is not supported for public scriptella.configuration.ConnectionEl()
```

Body:
I'm writing an application using Quarkus and GraalVM to build a native image. I use scriptella for ETL and the build keeps failing for Janino driver. As far as i can tell, there is a deprecated method org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class) and it fails because of it'S absence in janino V3.1.9
I have reflection-config.json  set up correctly and works for other scriptella drivers such as csv. Any idea how can i do a workaround the deprecated method?

build output:

========================================================================================================================
GraalVM Native Image: Generating 'demo-1.0.0-SNAPSHOT-runner' (executable)...
========================================================================================================================
[1/7] Initializing...                                                                                (9,8s @ 0,40GB)
 Version info: 'GraalVM 22.3.0.1-Final Java 17 Mandrel Distribution'
 Java version info: '17.0.5+8'
 C compiler: gcc (redhat, x86_64, 8.5.0)
 Garbage collector: Serial GC
 8 user-specific feature(s)
 - com.oracle.svm.thirdparty.gson.GsonFeature
 - io.quarkus.caffeine.runtime.graal.CacheConstructorsFeature
 - io.quarkus.hibernate.orm.runtime.graal.DisableLoggingFeature: Disables INFO logging during the analysis phase for the [org.hibernate.Version, org.hibernate.annotations.common.Version, org.hibernate.dialect.Dialect] categories
 - io.quarkus.runner.Feature: Auto-generated class by Quarkus from the existing extensions
 - io.quarkus.runtime.graal.DisableLoggingFeature: Disables INFO logging during the analysis phase for the [org.jboss.threads] categories
 - io.quarkus.runtime.graal.ResourcesFeature: Register each line in META-INF/quarkus-native-resources.txt as a resource on Substrate VM
 - org.hibernate.graalvm.internal.GraalVMStaticFeature: Hibernate ORM's static reflection registrations for GraalVM
 - org.hibernate.graalvm.internal.QueryParsingSupport: Hibernate ORM's support for HQL Parser in GraalVM
10:20:02,153 INFO  [org.hib.sea.map.orm.boo.imp.HibernateSearchPreIntegrationService] HSEARCH000034: Hibernate Search version 6.1.7.Final
10:20:02,244 INFO  [org.hib.sea.map.orm.boo.imp.HibernateSearchPreIntegrationService] HSEARCH000034: Hibernate Search version 6.1.7.Final
[2/7] Performing analysis...  [*]                                                                       (14,4s @ 0,72GB)
   6.032 (73,61%) of  8.195 classes reachable
   6.524 (48,72%) of 13.390 fields reachable
  22.390 (37,96%) of 58.976 methods reachable
     496 classes,   381 fields, and 2.328 methods registered for reflection

Fatal error: com.oracle.graal.pointsto.util.AnalysisError$ParsingError: Error encountered while parsing scriptella.driver.janino.JaninoConnection.executeQuery(scriptella.spi.Resource, scriptella.spi.ParametersCallback, scriptella.spi.QueryCallback)
Parsing context:
   at scriptella.driver.janino.JaninoConnection.executeQuery(JaninoConnection.java:68)
   at scriptella.core.QueryExecutor.execute(QueryExecutor.java:71)
   at scriptella.core.ContentExecutor.execute(ContentExecutor.java:73)
   at scriptella.core.ElementInterceptor.executeNext(ElementInterceptor.java:56)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:41)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)
   at scriptella.core.StatisticInterceptor.execute(StatisticInterceptor.java:37)

        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.AnalysisError.parsingError(AnalysisError.java:153)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.createFlowsGraph(MethodTypeFlow.java:104)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.ensureFlowsGraphCreated(MethodTypeFlow.java:83)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.getOrCreateMethodFlowsGraph(MethodTypeFlow.java:65)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.typestate.DefaultVirtualInvokeTypeFlow.onObservedUpdate(DefaultVirtualInvokeTypeFlow.java:109)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.TypeFlow.update(TypeFlow.java:562)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.PointsToAnalysis$1.run(PointsToAnalysis.java:488)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.CompletionExecutor.executeCommand(CompletionExecutor.java:193)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.util.CompletionExecutor.lambda$executeService$0(CompletionExecutor.java:177)
        at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1395)
        at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
        at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
        at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
        at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
        at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
Caused by: org.graalvm.compiler.java.BytecodeParser$BytecodeParserError: com.oracle.graal.pointsto.constraints.UnresolvedElementException: Discovered unresolved method during parsing: org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class). This error is reported at image build time because class scriptella.driver.janino.CodeCompiler is registered for linking at image build time by command line
        at parsing scriptella.driver.janino.CodeCompiler.compile(CodeCompiler.java:62)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.throwParserError(BytecodeParser.java:2518)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.throwParserError(SharedGraphBuilderPhase.java:110)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.iterateBytecodesForBlock(BytecodeParser.java:3393)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.handleBytecodeBlock(BytecodeParser.java:3345)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.processBlock(BytecodeParser.java:3190)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.build(BytecodeParser.java:1138)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.buildRootMethod(BytecodeParser.java:1030)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.GraphBuilderPhase$Instance.run(GraphBuilderPhase.java:97)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase.run(SharedGraphBuilderPhase.java:84)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.Phase.run(Phase.java:49)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:446)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.Phase.apply(Phase.java:42)
        at jdk.internal.vm.compiler/org.graalvm.compiler.phases.Phase.apply(Phase.java:38)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.AnalysisParsedGraph.parseBytecode(AnalysisParsedGraph.java:135)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.meta.AnalysisMethod.ensureGraphParsed(AnalysisMethod.java:685)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.phases.InlineBeforeAnalysisGraphDecoder.lookupEncodedGraph(InlineBeforeAnalysis.java:180)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.doInline(PEGraphDecoder.java:1162)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.tryInline(PEGraphDecoder.java:1145)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.trySimplifyInvoke(PEGraphDecoder.java:1003)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.handleInvoke(PEGraphDecoder.java:957)
        at jdk.internal.vm.compiler/org.graalvm.compiler.nodes.GraphDecoder.processNextNode(GraphDecoder.java:817)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.phases.InlineBeforeAnalysisGraphDecoder.processNextNode(InlineBeforeAnalysis.java:240)
        at jdk.internal.vm.compiler/org.graalvm.compiler.nodes.GraphDecoder.decode(GraphDecoder.java:548)
        at jdk.internal.vm.compiler/org.graalvm.compiler.replacements.PEGraphDecoder.decode(PEGraphDecoder.java:833)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.phases.InlineBeforeAnalysis.decodeGraph(InlineBeforeAnalysis.java:98)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlowBuilder.parse(MethodTypeFlowBuilder.java:179)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlowBuilder.apply(MethodTypeFlowBuilder.java:349)
        at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.flow.MethodTypeFlow.createFlowsGraph(MethodTypeFlow.java:93)
        ... 13 more
Caused by: com.oracle.graal.pointsto.constraints.UnresolvedElementException: Discovered unresolved method during parsing: org.codehaus.janino.ScriptEvaluator.setExtendedType(java.lang.Class). This error is reported at image build time because class scriptella.driver.janino.CodeCompiler is registered for linking at image build time by command line
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.reportUnresolvedElement(SharedGraphBuilderPhase.java:333)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.handleUnresolvedMethod(SharedGraphBuilderPhase.java:323)
        at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.phases.SharedGraphBuilderPhase$SharedBytecodeParser.handleUnresolvedInvoke(SharedGraphBuilderPhase.java:279)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.genInvokeVirtual(BytecodeParser.java:1721)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.processBytecode(BytecodeParser.java:5286)
        at jdk.internal.vm.compiler/org.graalvm.compiler.java.BytecodeParser.iterateBytecodesForBlock(BytecodeParser.java:3385)
        ... 38 more
------------------------------------------------------------------------------------------------------------------------
                        1,1s (4,3% of total time) in 20 GCs | Peak RSS: 2,84GB | CPU load: 4,87
========================================================================================================================
Failed generating 'demo-1.0.0-SNAPSHOT-runner' after 24,5s.
Error: Image build request failed with exit status 1
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  35.694 s
[INFO] Finished at: 2023-01-13T11:20:16+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:2.14.1.Final:build (default) on project demo: Failed to build quarkus application: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
[ERROR]         [error]: Build step io.quarkus.deployment.pkg.steps.NativeImageBuildStep#build threw an exception: io.quarkus.deployment.pkg.steps.NativeImageBuildStep$ImageGenerationFailureException: Image generation failed. Exit code: 1
[ERROR]         at io.quarkus.deployment.pkg.steps.NativeImageBuildStep.imageGenerationFailed(NativeImageBuildStep.java:421)
[ERROR]         at io.quarkus.deployment.pkg.steps.NativeImageBuildStep.build(NativeImageBuildStep.java:262)
[ERROR]         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR]         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[ERROR]         at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR]         at java.base/java.lang.reflect.Method.invoke(Method.java:566)
[ERROR]         at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:909)
[ERROR]         at io.quarkus.builder.BuildContext.run(BuildContext.java:281)
[ERROR]         at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
[ERROR]         at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
[ERROR]         at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
[ERROR]         at java.base/java.lang.Thread.run(Thread.java:834)
[ERROR]         at org.jboss.threads.JBossThread.run(JBossThread.java:501)
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

I check graalVM and quarkus documentaion, i tried building args such as
--initialize-at-runtime=org.codehaus.janino.ScriptEvaluator
but it didn't change anything

I also added other classes for reflection - same result

[UPDATE]

I managed to fix the build using GraalVM 22.3.0 && Java 11 (which is needed for the project) and when i build the native image quarkus build --native it's successful.

The issue that I'm working on now is the reflection using scriptella, I included

quarkus.native.additional-build-args =\-H:ReflectionConfigurationFiles=reflection-config.json,\
                                       -H:ResourceConfigurationFiles=resources-config.json,\
                                       -H:JNIConfigurationFiles=jniconfig.json,\
                                       -H:IncludeResourceBundles=com.sun.org.apache.xerces.internal.impl.msg.XMLMessages

and that's the error I'm facing now

ERROR [io.qua.ver.htt.run.QuarkusErrorHandler] (executor-thread-0) HTTP Request to /etl/csv failed, error id: 3ddf8c2e-0c9b-44c9-8967-5c03abdfe3a1-2: com.oracle.svm.core.jdk.UnsupportedFeatureError: Runtime reflection is not supported for public scriptella.configuration.ConnectionEl()


来源: stackexchange

问:
boto3 returning more rows than actual rows in timestream
I'm trying to run a query from aws timestream using boto3 in sam from the query I have received 51362 rows whereas when I checked in timestream there were only 1500 rows.

51362 rows using boto3.

ContentLicense: CC BY-SA 4.0


问:
FirebaseMessagingError : Exactly one of topic, token or condition is required
I looked at the documentation and implemented FirebaseMessaging.

but it returns FirebaseMessagingError :

Exactly one of topic, token or condition is required.

I obviously sent tokens as in the code below.

what's wrong with my code?

```<code>const message = {
    notification: { 'title', 'message' },
    tokens: ['MY_REG_TOKEN_001'],
};

admin
    .messaging()
    .sendMulticast(message)
    .then((response) => {
        console.log(
            __filename,
            response.successCount + " messages were sent successfully"
        );
        if (response.failureCount > 0) {
            const failedTokens = [];
            response.responses.forEach((resp, idx) => {
                if (!resp.success) {
                    failedTokens.push(arrRegTokens[idx]);
                }
            });
            console.log(
                __filename,
                "List of tokens that caused failures: " + failedTokens
            );
        }
    })
    .catch((error) => {
        console.log(__filename, "Error sending message:", message);
        console.log(__filename, "error :", error);
    });
</code>```

Body:
I looked at the documentation and implemented FirebaseMessaging.

but it returns FirebaseMessagingError :

Exactly one of topic, token or condition is required.

I obviously sent tokens as in the code below.

what's wrong with my code?

const message = {
    notification: { 'title', 'message' },
    tokens: ['MY_REG_TOKEN_001'],
};

admin
    .messaging()
    .sendMulticast(message)
    .then((response) => {
        console.log(
            __filename,
            response.successCount + " messages were sent successfully"
        );
        if (response.failureCount > 0) {
            const failedTokens = [];
            response.responses.forEach((resp, idx) => {
                if (!resp.success) {
                    failedTokens.push(arrRegTokens[idx]);
                }
            });
            console.log(
                __filename,
                "List of tokens that caused failures: " + failedTokens
            );
        }
    })
    .catch((error) => {
        console.log(__filename, "Error sending message:", message);
        console.log(__filename, "error :", error);
    });


问:
How to exit leval in unreal engine from visual studio
How can I stop simulation in Unreal Engine from Visual Studio.

Taking this function:

```<code>UFUNCTION(BlueprintCallable, Category = "Character Movement")
static void AddAcceleration(UCharacterMovementComponent* MovementComponent, FVector WishDirection, float MaxSpeed, float Acceleration, float ConstantAcceleration, float DeltaTime);
</code>```

When I call this function from blueprint and forget to provide Movement Component and click on play level. Then unreal takes me to Visual Studio showing nullptr error and unreal editor window becomes non-responsive, now how to stop game simulation from Visual Studio.

I could close the engine, but then all my unsaved progress is lost.

Body:
How can I stop simulation in Unreal Engine from Visual Studio.

Taking this function:

UFUNCTION(BlueprintCallable, Category = "Character Movement")
static void AddAcceleration(UCharacterMovementComponent* MovementComponent, FVector WishDirection, float MaxSpeed, float Acceleration, float ConstantAcceleration, float DeltaTime);

When I call this function from blueprint and forget to provide Movement Component and click on play level. Then unreal takes me to Visual Studio showing nullptr error and unreal editor window becomes non-responsive, now how to stop game simulation from Visual Studio.

I could close the engine, but then all my unsaved progress is lost.


问:
Pyomo Debug No Solution

I have a very strange problem. I made a notebook containing my model, a very simple linear problem with some constraints. And it works, i.e. the solution is found. The env is made with conda.
In this case I get:

```<code>{'Problem':
[{'Name': 'unknown',
'Lower bound': 23.02222576,
'Upper bound': 23.02222576,
'Number of objectives': 1,
'Number of constraints': 395,
'Number of variables': 961,
'Number of nonzeros': 200,
'Sense': 'minimize'}],
 'Solver': [{'Status': 'ok', 'User time': -1.0, 'System time': 0.02, 'Wallclock time': 0.01, 'Termination condition': 'optimal', 'Termination message': 'Model was solved to optimality (subject to tolerances), and an optimal solution is available.', 'Statistics': {'Branch and bound': {'Number of bounded subproblems': None, 'Number of created subproblems': None}, 'Black box': {'Number of iterations': 448}}, 'Error rc': 0, 'Time': 0.020696401596069336}], 'Solution': [OrderedDict([('number of solutions', 0), ('number of solutions displayed', 0)])]}
</code>```

Now, I copied the notebook code inside my big python service. Same code, more or less.
The solver is cbc installed system wide.
The solution is never found.
Before posting my code, I would understand how to debug .

In the second case, I get always:

```<code>{'Problem':
[{'Name': 'unknown',
'Lower bound': None,
'Upper bound': inf, 'Number of objectives': 1,
'Number of constraints': 395,
'Number of variables': 961,
'Number of nonzeros': 202, 'Sense': 'minimize'}],
'Solver': [{'Status': 'warning', 'User time': -1.0, 'System time': 0.01, 'Wallclock time': 0.01, 'Termination condition': 'infeasible', 'Termination message': 'Model was proven to be infeasible.', 'Statistics': {'Branch and bound': {'Number of bounded subproblems': 0, 'Number of created subproblems': 0}, 'Black box': {'Number of iterations': 0}}, 'Error rc': 0, 'Time': 0.024977684020996094}], 'Solution': [OrderedDict([('number of solutions', 1), ('number of solutions displayed', 1)]), {'Status': 'unknown', 'Problem': {}, 'Objective': {}, 'Variable': {}, 'Constraint': {}}]}
</code>```

The number of constraints and variable is the same in both cases, and I could swear that the code is the same. The only difference is the 'cbc' solver that in the first case is from conda.

I checked the variables with model.pprint(), and in the second case, I saw that some of them never get increased or changed.

Another strange thing, is that the number of iterations is zero in the second case....

[EDIT]

My fault. The configuration parameters were different between the 2 env.

Title: Pyomo Debug No Solution

Body:
I have a very strange problem. I made a notebook containing my model, a very simple linear problem with some constraints. And it works, i.e. the solution is found. The env is made with conda.
In this case I get:

{'Problem':
[{'Name': 'unknown',
'Lower bound': 23.02222576,
'Upper bound': 23.02222576,
'Number of objectives': 1,
'Number of constraints': 395,
'Number of variables': 961,
'Number of nonzeros': 200,
'Sense': 'minimize'}],
 'Solver': [{'Status': 'ok', 'User time': -1.0, 'System time': 0.02, 'Wallclock time': 0.01, 'Termination condition': 'optimal', 'Termination message': 'Model was solved to optimality (subject to tolerances), and an optimal solution is available.', 'Statistics': {'Branch and bound': {'Number of bounded subproblems': None, 'Number of created subproblems': None}, 'Black box': {'Number of iterations': 448}}, 'Error rc': 0, 'Time': 0.020696401596069336}], 'Solution': [OrderedDict([('number of solutions', 0), ('number of solutions displayed', 0)])]}

Now, I copied the notebook code inside my big python service. Same code, more or less.
The solver is cbc installed system wide.
The solution is never found.
Before posting my code, I would understand how to debug .

In the second case, I get always:

{'Problem':
[{'Name': 'unknown',
'Lower bound': None,
'Upper bound': inf, 'Number of objectives': 1,
'Number of constraints': 395,
'Number of variables': 961,
'Number of nonzeros': 202, 'Sense': 'minimize'}],
'Solver': [{'Status': 'warning', 'User time': -1.0, 'System time': 0.01, 'Wallclock time': 0.01, 'Termination condition': 'infeasible', 'Termination message': 'Model was proven to be infeasible.', 'Statistics': {'Branch and bound': {'Number of bounded subproblems': 0, 'Number of created subproblems': 0}, 'Black box': {'Number of iterations': 0}}, 'Error rc': 0, 'Time': 0.024977684020996094}], 'Solution': [OrderedDict([('number of solutions', 1), ('number of solutions displayed', 1)]), {'Status': 'unknown', 'Problem': {}, 'Objective': {}, 'Variable': {}, 'Constraint': {}}]}

The number of constraints and variable is the same in both cases, and I could swear that the code is the same. The only difference is the 'cbc' solver that in the first case is from conda.

I checked the variables with model.pprint(), and in the second case, I saw that some of them never get increased or changed.

Another strange thing, is that the number of iterations is zero in the second case....

[EDIT]

My fault. The configuration parameters were different between the 2 env.


问:
problem connecting to mongodb from NodeJS
I would like to connect to my mongodb database from node js.
I'm new to Mongo, for my project I decided to put my database on an Ubuntu server. I have a user who is "admin" who has the admin role but when I connect from nodeJS creating a new database mongo returns an authentication error.

my NodeJS code:

```<code>const mongoose = require("mongoose");
mongoose.set("strictQuery", true);
//connect to db
mongoose
    .connect("mongodb://" + process.env.DB_USER_PASS + "@2.56.247.250:27017/dbname/")
    .then(() => console.log('Connecté a la base de donné'))
    .catch((err) => console.log("Erreur de connexion :", err));
</code>```

error returned by mongo:

```<code>Erreur de connexion : MongoServerError: Invalid database name: 'messio/'
    at Connection.onMessage (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\connection.js:230:30)
    at MessageStream.<anonymous> (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\connection.js:61:60)
    at MessageStream.emit (node:events:513:28)
    at processIncomingData (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\message_stream.js:125:16)
    at MessageStream._write (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\message_stream.js:33:9)
    at writeOrBuffer (node:internal/streams/writable:392:12)
    at _write (node:internal/streams/writable:333:10)
    at Writable.write (node:internal/streams/writable:337:10)
    at Socket.ondata (node:internal/streams/readable:766:22)
    at Socket.emit (node:events:513:28) {
  ok: 0,
  code: 73,
  codeName: 'InvalidNamespace',
  connectionGeneration: 0,
  [Symbol(errorLabels)]: Set(2) { 'HandshakeError', 'ResetPool' }
}
</code>```

Body:
I would like to connect to my mongodb database from node js.
I'm new to Mongo, for my project I decided to put my database on an Ubuntu server. I have a user who is "admin" who has the admin role but when I connect from nodeJS creating a new database mongo returns an authentication error.

my NodeJS code:

const mongoose = require("mongoose");
mongoose.set("strictQuery", true);
//connect to db
mongoose
    .connect("mongodb://" + process.env.DB_USER_PASS + "@2.56.247.250:27017/dbname/")
    .then(() => console.log('Connecté a la base de donné'))
    .catch((err) => console.log("Erreur de connexion :", err));

error returned by mongo:

Erreur de connexion : MongoServerError: Invalid database name: 'messio/'
    at Connection.onMessage (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\connection.js:230:30)
    at MessageStream.<anonymous> (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\connection.js:61:60)
    at MessageStream.emit (node:events:513:28)
    at processIncomingData (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\message_stream.js:125:16)
    at MessageStream._write (C:\Users\arnau\Desktop\messIO\node_modules\mongodb\lib\cmap\message_stream.js:33:9)
    at writeOrBuffer (node:internal/streams/writable:392:12)
    at _write (node:internal/streams/writable:333:10)
    at Writable.write (node:internal/streams/writable:337:10)
    at Socket.ondata (node:internal/streams/readable:766:22)
    at Socket.emit (node:events:513:28) {
  ok: 0,
  code: 73,
  codeName: 'InvalidNamespace',
  connectionGeneration: 0,
  [Symbol(errorLabels)]: Set(2) { 'HandshakeError', 'ResetPool' }
}


问:
Why does html2canvas not display text on a table in the Chrome browser?
Html2canvas doesn't display text on a table in the Chrome browser.
What I see in the Chrome: enter image description here
Table without text, but in the Safari and Edge it works correctly.
Here is my code:

```<code>const exportReportToPdf = () => {
  const heatmapBody = $('.heatmap-j tbody');

  const height = heatmapBody.height();
  const width = heatmapBody.width();

  html2canvas(heatmapBody[0]).then((canvas) => {
    const pdf = new jsPDF({
      orientation: 'landscape',
      unit: 'mm',
      format: [width, height],
    });
    pdf.addImage(canvas.toDataURL('image/png'), png, 0, 0, width, height);
    pdf.save('HeatMap.pdf');
  });
};
</code>```

Also when html2canvas start reproducing I have such error 2 times in console:enter image description here

I expect see table with text.

I tried change options, but always had the same result

Body:
Html2canvas doesn't display text on a table in the Chrome browser.
What I see in the Chrome: enter image description here
Table without text, but in the Safari and Edge it works correctly.
Here is my code:

const exportReportToPdf = () => {
  const heatmapBody = $('.heatmap-j tbody');

  const height = heatmapBody.height();
  const width = heatmapBody.width();

  html2canvas(heatmapBody[0]).then((canvas) => {
    const pdf = new jsPDF({
      orientation: 'landscape',
      unit: 'mm',
      format: [width, height],
    });
    pdf.addImage(canvas.toDataURL('image/png'), png, 0, 0, width, height);
    pdf.save('HeatMap.pdf');
  });
};

Also when html2canvas start reproducing I have such error 2 times in console:enter image description here

I expect see table with text.

I tried change options, but always had the same result


问:
Very long time of loading img assets in next.js app
Recently I was working on next.js project and I run for one issue which I'm struggling a lot and I can't find any solution.

When I'm checking the app on vercel/netlify servers, images are loading very very slow. I'm using next/image.

My files are compressed in webp format. Also I'm storing them in CDN.
I was setting parameters like priority='true', loading='eager' and nothing accelerated the loading time. Average I'm waiting about 2-3 seconds. I felt like using classic img tag was a little bit faster.

Did any of you have same issue and maybe you have solution?
Thanks


问:
Electron + React: Clear fs module
I have an Electron + React app based on create-react-app. In the React code, I'd like to use excel4node to generate an Excel file. The issue is that excel4node tries to import modules such as fs and http which are not available on the renderer side. This results in the following Webpack error:

```<code>[0] ERROR in ./node_modules/image-size/dist/index.js 7:11-24
[0] Module not found: Error: Can't resolve 'fs' in 'C:\[...]\node_modules\image-size\dist'
</code>```

I do not want to use any methods from excel4node which are accessing these modules, such as writing the Excel file to disk for example -- I would be fine with these functions erroring if they were called.

Is it possible to overwrite the problematic modules with something like an empty module just so that the import works? Since I used create-react-app I do not have easy access to the webpack configuration, so if there is a different way that I would prefer that.

Title: Electron + React: Clear fs module

Body:
I have an Electron + React app based on create-react-app. In the React code, I'd like to use excel4node to generate an Excel file. The issue is that excel4node tries to import modules such as fs and http which are not available on the renderer side. This results in the following Webpack error:

[0] ERROR in ./node_modules/image-size/dist/index.js 7:11-24
[0] Module not found: Error: Can't resolve 'fs' in 'C:\[...]\node_modules\image-size\dist'

I do not want to use any methods from excel4node which are accessing these modules, such as writing the Excel file to disk for example -- I would be fine with these functions erroring if they were called.

Is it possible to overwrite the problematic modules with something like an empty module just so that the import works? Since I used create-react-app I do not have easy access to the webpack configuration, so if there is a different way that I would prefer that.


问:
Debezium MySql Connector - How to write changes to another MySql table?
I am trying to test Debezium in a standalone, non-docker environment, to copy changed data from one MySql table to another MySql table. The source and sink tables are the same structure in different databases (source db.table: testiot.INPUT_TEMP, sink db.table: tiotbak:INPUT_TEMP_BK). It looks like the source table is being read but the sink table is not created. Please help.

My source.properties file:

```<code>name=connect-mysql
connector.class=io.debezium.connector.mysql.MySqlConnector
tasks.max=1
database.hostname=localhost
database.port=3306
database.user=debezium
database.password=dbz
database.dbname=testiot
database.server.id=184054
topic.prefix=testiot
database.server.name=localhost
database.allowPublicKeyRetrieval=true
schema.history.internal.kafka.bootstrap.servers=localhost:9092
schema.history.internal.kafka.topic=testiot.INPUT_TEMP_BK
database.history.kafka.bootstrap.servers=localhost:9092
database.history.kafka.topic=testiot.INPUT_TEMP_BK
</code>```

My sink.properties file:

```<code>name=connect-mysql
connector.class=io.confluent.connect.jdbc.JdbcSinkConnector
tasks.max=1
connection.url=jdbc:mysql://localhost:3306/tiotbak?user=debezium&password=dbz&allowPublicKeyRetrieval=true&useSSL=false
topic.prefix=testiot
database.hostname=localhost
database.port=3306
database.user=debezium
database.password=Debez@01
database.dbname=tiotbak
database.server.id=184054
database.server.name=localhost
auto.create=true
insert.mode=upsert
pk.fields=DEVICE_ID
pk.mode=record_value
record_value=record_value
</code>```

The command I am using to execute is:

```<code>sudo ./bin/connect-standalone.sh ./config/connect-debezium-mysql-worker.properties ./config/connect-debezium-mysql-source.properties ./config/connect-debezium-mysql-sink.properties
</code>```

Body:
I am trying to test Debezium in a standalone, non-docker environment, to copy changed data from one MySql table to another MySql table. The source and sink tables are the same structure in different databases (source db.table: testiot.INPUT_TEMP, sink db.table: tiotbak:INPUT_TEMP_BK). It looks like the source table is being read but the sink table is not created. Please help.

My source.properties file:

name=connect-mysql
connector.class=io.debezium.connector.mysql.MySqlConnector
tasks.max=1
database.hostname=localhost
database.port=3306
database.user=debezium
database.password=dbz
database.dbname=testiot
database.server.id=184054
topic.prefix=testiot
database.server.name=localhost
database.allowPublicKeyRetrieval=true
schema.history.internal.kafka.bootstrap.servers=localhost:9092
schema.history.internal.kafka.topic=testiot.INPUT_TEMP_BK
database.history.kafka.bootstrap.servers=localhost:9092
database.history.kafka.topic=testiot.INPUT_TEMP_BK

My sink.properties file:

name=connect-mysql
connector.class=io.confluent.connect.jdbc.JdbcSinkConnector
tasks.max=1
connection.url=jdbc:mysql://localhost:3306/tiotbak?user=debezium&password=dbz&allowPublicKeyRetrieval=true&useSSL=false
topic.prefix=testiot
database.hostname=localhost
database.port=3306
database.user=debezium
database.password=Debez@01
database.dbname=tiotbak
database.server.id=184054
database.server.name=localhost
auto.create=true
insert.mode=upsert
pk.fields=DEVICE_ID
pk.mode=record_value
record_value=record_value

The command I am using to execute is:

sudo ./bin/connect-standalone.sh ./config/connect-debezium-mysql-worker.properties ./config/connect-debezium-mysql-source.properties ./config/connect-debezium-mysql-sink.properties


问:
I need side bar in laravel jetstream inertia vue
I need side bar in  laravel jetstream inertia vue

enter image description here

```<code><script setup>
import { ref } from 'vue';
import { Inertia } from '@inertiajs/inertia';
import { Head, Link } from '@inertiajs/inertia-vue3';
import ApplicationMark from '@/Components/ApplicationMark.vue';
import Banner from '@/Components/Banner.vue';
import Dropdown from '@/Components/Dropdown.vue';
import DropdownLink from '@/Components/DropdownLink.vue';
import NavLink from '@/Components/NavLink.vue';
import ResponsiveNavLink from '@/Components/ResponsiveNavLink.vue';

defineProps({
    title: String,
});

const showingNavigationDropdown = ref(false);

const switchToTeam = (team) => {
    Inertia.put(route('current-team.update'), {
        team_id: team.id,
    }, {
        preserveState: false,
    });
};

const logout = () => {
    Inertia.post(route('logout'));
};
</script>

<template>
    <div>
        <Head :title="title" />

        <Banner />

        <div class="min-h-screen bg-gray-100">
            <nav class="bg-white border-b border-gray-100">
                <!-- Primary Navigation Menu -->
                <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
                    <div class="flex justify-between h-16">
                        <div class="flex">
                            <!-- Logo -->
                            <div class="shrink-0 flex items-center">
                                <Link :href="route('dashboard')">
                                    <ApplicationMark class="block h-9 w-auto" />
                                </Link>
                            </div>

                            <!-- Navigation Links -->
                            <div class="hidden space-x-8 sm:-my-px sm:ml-10 sm:flex">
                                <NavLink :href="route('dashboard')" :active="route().current('dashboard')">
                                    Dashboard
                                </NavLink>
                            </div>
                        </div>

                        <div class="hidden sm:flex sm:items-center sm:ml-6">
                            <div class="ml-3 relative">
                                <!-- Teams Dropdown -->
                                <Dropdown v-if="$page.props.jetstream.hasTeamFeatures" align="right" width="60">
                                    <template #trigger>
                                        <span class="inline-flex rounded-md">
                                            <button type="button" class="inline-flex items-center px-3 py-2 border border-transparent text-sm leading-4 font-medium rounded-md text-gray-500 bg-white hover:bg-gray-50 hover:text-gray-700 focus:outline-none focus:bg-gray-50 active:bg-gray-50 transition">
                                                {{ $page.props.user.current_team.name }}

                                                <svg class="ml-2 -mr-0.5 h-4 w-4" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M8.25 15L12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9" />
                                                </svg>
                                            </button>
                                        </span>
                                    </template>

                                    <template #content>
                                        <div class="w-60">
                                            <!-- Team Management -->
                                            <template v-if="$page.props.jetstream.hasTeamFeatures">
                                                <div class="block px-4 py-2 text-xs text-gray-400">
                                                    Manage Team
                                                </div>

                                                <!-- Team Settings -->
                                                <DropdownLink :href="route('teams.show', $page.props.user.current_team)">
                                                    Team Settings
                                                </DropdownLink>

                                                <DropdownLink v-if="$page.props.jetstream.canCreateTeams" :href="route('teams.create')">
                                                    Create New Team
                                                </DropdownLink>

                                                <div class="border-t border-gray-100" />

                                                <!-- Team Switcher -->
                                                <div class="block px-4 py-2 text-xs text-gray-400">
                                                    Switch Teams
                                                </div>

                                                <template v-for="team in $page.props.user.all_teams" :key="team.id">
                                                    <form @submit.prevent="switchToTeam(team)">
                                                        <DropdownLink as="button">
                                                            <div class="flex items-center">
                                                                <svg v-if="team.id == $page.props.user.current_team_id" class="mr-2 h-5 w-5 text-green-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
                                                                </svg>

                                                                <div>{{ team.name }}</div>
                                                            </div>
                                                        </DropdownLink>
                                                    </form>
                                                </template>
                                            </template>
                                        </div>
                                    </template>
                                </Dropdown>
                            </div>

                            <!-- Settings Dropdown -->
                            <div class="ml-3 relative">
                                <Dropdown align="right" width="48">
                                    <template #trigger>
                                        <button v-if="$page.props.jetstream.managesProfilePhotos" class="flex text-sm border-2 border-transparent rounded-full focus:outline-none focus:border-gray-300 transition">
                                            <img class="h-8 w-8 rounded-full object-cover" :src="$page.props.user.profile_photo_url" :alt="$page.props.user.name">
                                        </button>

                                        <span v-else class="inline-flex rounded-md">
                                            <button type="button" class="inline-flex items-center px-3 py-2 border border-transparent text-sm leading-4 font-medium rounded-md text-gray-500 bg-white hover:text-gray-700 focus:outline-none focus:bg-gray-50 active:bg-gray-50 transition">
                                                {{ $page.props.user.name }}

                                                <svg class="ml-2 -mr-0.5 h-4 w-4" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5" />
                                                </svg>
                                            </button>
                                        </span>
                                    </template>

                                    <template #content>
                                        <!-- Account Management -->
                                        <div class="block px-4 py-2 text-xs text-gray-400">
                                            Manage Account
                                        </div>

                                        <DropdownLink :href="route('profile.show')">
                                            Profile
                                        </DropdownLink>

                                        <DropdownLink v-if="$page.props.jetstream.hasApiFeatures" :href="route('api-tokens.index')">
                                            API Tokens
                                        </DropdownLink>

                                        <div class="border-t border-gray-100" />

                                        <!-- Authentication -->
                                        <form @submit.prevent="logout">
                                            <DropdownLink as="button">
                                                Log Out
                                            </DropdownLink>
                                        </form>
                                    </template>
                                </Dropdown>
                            </div>
                        </div>

                        <!-- Hamburger -->
                        <div class="-mr-2 flex items-center sm:hidden">
                            <button class="inline-flex items-center justify-center p-2 rounded-md text-gray-400 hover:text-gray-500 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 focus:text-gray-500 transition" @click="showingNavigationDropdown = ! showingNavigationDropdown">
                                <svg
                                    class="h-6 w-6"
                                    stroke="currentColor"
                                    fill="none"
                                    viewBox="0 0 24 24"
                                >
                                    <path
                                        :class="{'hidden': showingNavigationDropdown, 'inline-flex': ! showingNavigationDropdown }"
                                        stroke-linecap="round"
                                        stroke-linejoin="round"
                                        stroke-width="2"
                                        d="M4 6h16M4 12h16M4 18h16"
                                    />
                                    <path
                                        :class="{'hidden': ! showingNavigationDropdown, 'inline-flex': showingNavigationDropdown }"
                                        stroke-linecap="round"
                                        stroke-linejoin="round"
                                        stroke-width="2"
                                        d="M6 18L18 6M6 6l12 12"
                                    />
                                </svg>
                            </button>
                        </div>
                    </div>
                </div>

                <!-- Responsive Navigation Menu -->
                <div :class="{'block': showingNavigationDropdown, 'hidden': ! showingNavigationDropdown}" class="sm:hidden">
                    <div class="pt-2 pb-3 space-y-1">
                        <ResponsiveNavLink :href="route('dashboard')" :active="route().current('dashboard')">
                            Dashboard
                        </ResponsiveNavLink>
                    </div>

                    <!-- Responsive Settings Options -->
                    <div class="pt-4 pb-1 border-t border-gray-200">
                        <div class="flex items-center px-4">
                            <div v-if="$page.props.jetstream.managesProfilePhotos" class="shrink-0 mr-3">
                                <img class="h-10 w-10 rounded-full object-cover" :src="$page.props.user.profile_photo_url" :alt="$page.props.user.name">
                            </div>

                            <div>
                                <div class="font-medium text-base text-gray-800">
                                    {{ $page.props.user.name }}
                                </div>
                                <div class="font-medium text-sm text-gray-500">
                                    {{ $page.props.user.email }}
                                </div>
                            </div>
                        </div>

                        <div class="mt-3 space-y-1">
                            <ResponsiveNavLink :href="route('profile.show')" :active="route().current('profile.show')">
                                Profile
                            </ResponsiveNavLink>

                            <ResponsiveNavLink v-if="$page.props.jetstream.hasApiFeatures" :href="route('api-tokens.index')" :active="route().current('api-tokens.index')">
                                API Tokens
                            </ResponsiveNavLink>

                            <!-- Authentication -->
                            <form method="POST" @submit.prevent="logout">
                                <ResponsiveNavLink as="button">
                                    Log Out
                                </ResponsiveNavLink>
                            </form>

                            <!-- Team Management -->
                            <template v-if="$page.props.jetstream.hasTeamFeatures">
                                <div class="border-t border-gray-200" />

                                <div class="block px-4 py-2 text-xs text-gray-400">
                                    Manage Team
                                </div>

                                <!-- Team Settings -->
                                <ResponsiveNavLink :href="route('teams.show', $page.props.user.current_team)" :active="route().current('teams.show')">
                                    Team Settings
                                </ResponsiveNavLink>

                                <ResponsiveNavLink v-if="$page.props.jetstream.canCreateTeams" :href="route('teams.create')" :active="route().current('teams.create')">
                                    Create New Team
                                </ResponsiveNavLink>

                                <div class="border-t border-gray-200" />

                                <!-- Team Switcher -->
                                <div class="block px-4 py-2 text-xs text-gray-400">
                                    Switch Teams
                                </div>

                                <template v-for="team in $page.props.user.all_teams" :key="team.id">
                                    <form @submit.prevent="switchToTeam(team)">
                                        <ResponsiveNavLink as="button">
                                            <div class="flex items-center">
                                                <svg v-if="team.id == $page.props.user.current_team_id" class="mr-2 h-5 w-5 text-green-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
                                                </svg>
                                                <div>{{ team.name }}</div>
                                            </div>
                                        </ResponsiveNavLink>
                                    </form>
                                </template>
                            </template>
                        </div>
                    </div>
                </div>
            </nav>

            <!-- Page Heading -->
            <header v-if="$slots.header" class="bg-white shadow">
                <div class="max-w-7xl mx-auto py-6 px-4 sm:px-6 lg:px-8">
                    <slot name="header" />
                </div>
            </header>

            <!-- Page Content -->
            <main>
                <slot />
            </main>
        </div>
    </div>
</template>

</code>```

this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar

this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar

Body:
I need side bar in  laravel jetstream inertia vue

enter image description here

<template>

        <Banner />

                                <Link :href="route('dashboard')">
                                    <ApplicationMark class="block h-9 w-auto" />
                                </Link>

                                <NavLink :href="route('dashboard')" :active="route().current('dashboard')">
                                    Dashboard
                                </NavLink>

                                <Dropdown v-if="$page.props.jetstream.hasTeamFeatures" align="right" width="60">
                                    <template #trigger>

                                            <button type="button" class="inline-flex items-center px-3 py-2 border border-transparent text-sm leading-4 font-medium rounded-md text-gray-500 bg-white hover:bg-gray-50 hover:text-gray-700 focus:outline-none focus:bg-gray-50 active:bg-gray-50 transition">
                                                {{ $page.props.user.current_team.name }}

                                                <svg class="ml-2 -mr-0.5 h-4 w-4" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M8.25 15L12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9" />
                                                </svg>
                                            </button>

                                    </template>

                                    <template #content>

                                            <template v-if="$page.props.jetstream.hasTeamFeatures">

                                                    Manage Team

                                                <DropdownLink :href="route('teams.show', $page.props.user.current_team)">
                                                    Team Settings
                                                </DropdownLink>

                                                <DropdownLink v-if="$page.props.jetstream.canCreateTeams" :href="route('teams.create')">
                                                    Create New Team
                                                </DropdownLink>

                                                    Switch Teams

                                                <template v-for="team in $page.props.user.all_teams" :key="team.id">
                                                    <form @submit.prevent="switchToTeam(team)">
                                                        <DropdownLink as="button">

                                                                <svg v-if="team.id == $page.props.user.current_team_id" class="mr-2 h-5 w-5 text-green-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
                                                                </svg>

{{ team.name }}

                                                        </DropdownLink>
                                                    </form>
                                                </template>
                                            </template>

                                    </template>
                                </Dropdown>

                                <Dropdown align="right" width="48">
                                    <template #trigger>
                                        <button v-if="$page.props.jetstream.managesProfilePhotos" class="flex text-sm border-2 border-transparent rounded-full focus:outline-none focus:border-gray-300 transition">

                                        </button>

                                            <button type="button" class="inline-flex items-center px-3 py-2 border border-transparent text-sm leading-4 font-medium rounded-md text-gray-500 bg-white hover:text-gray-700 focus:outline-none focus:bg-gray-50 active:bg-gray-50 transition">
                                                {{ $page.props.user.name }}

                                                <svg class="ml-2 -mr-0.5 h-4 w-4" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5" />
                                                </svg>
                                            </button>

                                    </template>

                                    <template #content>

                                            Manage Account

                                        <DropdownLink :href="route('profile.show')">
                                            Profile
                                        </DropdownLink>

                                        <DropdownLink v-if="$page.props.jetstream.hasApiFeatures" :href="route('api-tokens.index')">
                                            API Tokens
                                        </DropdownLink>

                                        <form @submit.prevent="logout">
                                            <DropdownLink as="button">
                                                Log Out
                                            </DropdownLink>
                                        </form>
                                    </template>
                                </Dropdown>

                            <button class="inline-flex items-center justify-center p-2 rounded-md text-gray-400 hover:text-gray-500 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 focus:text-gray-500 transition" @click="showingNavigationDropdown = ! showingNavigationDropdown">
                                <svg
                                    class="h-6 w-6"
                                    stroke="currentColor"
                                    fill="none"
                                    viewBox="0 0 24 24"
                                >
                                    <path
                                        :class="{'hidden': showingNavigationDropdown, 'inline-flex': ! showingNavigationDropdown }"
                                        stroke-linecap="round"
                                        stroke-linejoin="round"
                                        stroke-width="2"
                                        d="M4 6h16M4 12h16M4 18h16"
                                    />
                                    <path
                                        :class="{'hidden': ! showingNavigationDropdown, 'inline-flex': showingNavigationDropdown }"
                                        stroke-linecap="round"
                                        stroke-linejoin="round"
                                        stroke-width="2"
                                        d="M6 18L18 6M6 6l12 12"
                                    />
                                </svg>
                            </button>

                        <ResponsiveNavLink :href="route('dashboard')" :active="route().current('dashboard')">
                            Dashboard
                        </ResponsiveNavLink>

                                    {{ $page.props.user.name }}

                                    {{ $page.props.user.email }}

                            <ResponsiveNavLink :href="route('profile.show')" :active="route().current('profile.show')">
                                Profile
                            </ResponsiveNavLink>

                            <ResponsiveNavLink v-if="$page.props.jetstream.hasApiFeatures" :href="route('api-tokens.index')" :active="route().current('api-tokens.index')">
                                API Tokens
                            </ResponsiveNavLink>

                            <form method="POST" @submit.prevent="logout">
                                <ResponsiveNavLink as="button">
                                    Log Out
                                </ResponsiveNavLink>
                            </form>

                            <template v-if="$page.props.jetstream.hasTeamFeatures">

                                    Manage Team

                                <ResponsiveNavLink :href="route('teams.show', $page.props.user.current_team)" :active="route().current('teams.show')">
                                    Team Settings
                                </ResponsiveNavLink>

                                <ResponsiveNavLink v-if="$page.props.jetstream.canCreateTeams" :href="route('teams.create')" :active="route().current('teams.create')">
                                    Create New Team
                                </ResponsiveNavLink>

                                    Switch Teams

                                <template v-for="team in $page.props.user.all_teams" :key="team.id">
                                    <form @submit.prevent="switchToTeam(team)">
                                        <ResponsiveNavLink as="button">

                                                <svg v-if="team.id == $page.props.user.current_team_id" class="mr-2 h-5 w-5 text-green-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
                                                    <path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
                                                </svg>

{{ team.name }}

                                        </ResponsiveNavLink>
                                    </form>
                                </template>
                            </template>

                    <slot name="header" />

                <slot />

</template>

this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar

this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar
this code app layout i need side bar


问:
Loop through directory and files with with date string to find the file with highest suffix (e.g. "firsttable_20230113093000_12")
I am looking to adapt a shell script to find a way to cycle through files that have different table names as well as different dates between files that have the same table name, and return the highest suffix file.

An example of my files in a given directory:

```<code>firsttable_20230112093000_1
firsttable_20230112093000_2
firsttable_20230112093000_3
firsttable_20230112093000_4
firsttable_19990202090000_1
firsttable_19990202090000_2
secondtable_20220112090000_1
secondtable_20220112090000_2
secondtable_20220112090000_3
</code>```

Desired Result:

```<code>firsttable_20230112093000_4
firsttable_19990202090000_2
secondtable_20220112090000_3
</code>```

What's been done

Originally I only needed to find the highest suffix as the dates would be the same for all tables, and what I had worked:

```<code>allTables=(
  'firsttable'
  'secondtable'
  'thirdtable'
  ...
  )

for table in ${allTables[@]}; do
  substring="_2"
  searchstring="$table$substring"
  # Check if the file for a given table exists:
  if ls $Path/$searchString* 1> /dev/null 2>&1; then
    echo "$searchString* files exist. Proceeding..."
    lastFile=$(ls "$Path/searchString"* | sort -rV | head -n1)
    echo "Highest suffix file: $lastFile"
  else
    echo "File searchstring not found: '$Path/$searchString' "
  fi
done
</code>```

If I was to apply that to my new directory shown above, it would only be able to find:

```<code>Highest suffix file: firsttable_20230112093000_4
Highest suffix file: secondtable_20220112090000_3
</code>```

I need to find a way to make the script also look at the dates and see if they are different, and if they are, treat them as such. Would this require a regex to assess the filename? The filename format stays the same: "tablename_$$$$$$$$$$$$$$_nn" (underscore placing after table and date, suffix can go above single figures, date is always 14 characters)

Thanks in advance for any help!

Body:
I am looking to adapt a shell script to find a way to cycle through files that have different table names as well as different dates between files that have the same table name, and return the highest suffix file.

An example of my files in a given directory:

firsttable_20230112093000_1
firsttable_20230112093000_2
firsttable_20230112093000_3
firsttable_20230112093000_4
firsttable_19990202090000_1
firsttable_19990202090000_2
secondtable_20220112090000_1
secondtable_20220112090000_2
secondtable_20220112090000_3

Desired Result:

firsttable_20230112093000_4
firsttable_19990202090000_2
secondtable_20220112090000_3

What's been done

Originally I only needed to find the highest suffix as the dates would be the same for all tables, and what I had worked:

allTables=(
  'firsttable'
  'secondtable'
  'thirdtable'
  ...
  )

for table in ${allTables[@]}; do
  substring="_2"
  searchstring="$table$substring"
  # Check if the file for a given table exists:
  if ls $Path/$searchString* 1> /dev/null 2>&1; then
    echo "$searchString* files exist. Proceeding..."
    lastFile=$(ls "$Path/searchString"* | sort -rV | head -n1)
    echo "Highest suffix file: $lastFile"
  else
    echo "File searchstring not found: '$Path/$searchString' "
  fi
done

If I was to apply that to my new directory shown above, it would only be able to find:

Highest suffix file: firsttable_20230112093000_4
Highest suffix file: secondtable_20220112090000_3

I need to find a way to make the script also look at the dates and see if they are different, and if they are, treat them as such. Would this require a regex to assess the filename? The filename format stays the same: "tablename_$$$$$$$$$$$$$$_nn" (underscore placing after table and date, suffix can go above single figures, date is always 14 characters)

Thanks in advance for any help!


问:
MimeUtility decode code can't work on cloud
I have a hive udf for cleaning text, the text is encoded with "quoted-printable", this is the code I refer from online:

```<code>    InputStream is = new ByteArrayInputStream(text.getBytes());
    try {
        InputStream isAfterDecode = MimeUtility.decode(is, "quoted-printable");
        text = new BufferedReader(
                new InputStreamReader(isAfterDecode, StandardCharsets.UTF_8))
                .lines()
                .collect(Collectors.joining(System.lineSeparator()));
    } catch (MessagingException e) {
        throw new RuntimeException(e);
    }
</code>```

When I test it on my IDEA, it worked fine. However, when I packaged it as a Hive function jar and uploaded to Cloud(Dataproc) to use it by SparkSql, it can't work. Do I need to do anything else?

I though it may be caused by the environment?

Body:
I have a hive udf for cleaning text, the text is encoded with "quoted-printable", this is the code I refer from online:

    InputStream is = new ByteArrayInputStream(text.getBytes());
    try {
        InputStream isAfterDecode = MimeUtility.decode(is, "quoted-printable");
        text = new BufferedReader(
                new InputStreamReader(isAfterDecode, StandardCharsets.UTF_8))
                .lines()
                .collect(Collectors.joining(System.lineSeparator()));
    } catch (MessagingException e) {
        throw new RuntimeException(e);
    }

When I test it on my IDEA, it worked fine. However, when I packaged it as a Hive function jar and uploaded to Cloud(Dataproc) to use it by SparkSql, it can't work. Do I need to do anything else?

I though it may be caused by the environment?


问:
Set quotas in the Custom Search API
I want to set quotas for the custom search API. However I cannot find any documentation what the difference is between the "Queries per day" quota and "Site Restricted Queries per day" quota. Could someone explain this?

Title: Set quotas in the Custom Search API


问:
When fine-tuning RoBERTa model to add specific domain knowledge, what is overall process?
Adding token about domain to tokenizer and fine-tuning is both essential?

a. Is it right process to adding domain token to tokenizer before fine-tuning model?
b. If I just adding domain token without fine-tuning, it could be improve in performance?
c. If I just fine-tuning without adding domain token, it could be improve in performance?
d. For improve model in performance, how many domain sentences would be need?

Thanks

I added just 5K domain token.
I have just a few domain sentence for fine-tuning.