问:
Error while publishing the artifacts to Artifactory using Jenkins Pipeline Script

What I'm trying

I'm building an application using Artifactory maven and publishing the artifacts generated, to the Artifactory server.

What I need

If there are any suggestions, I would love to try them right away. ;)

Jenkins Pipeline Script

```<code> stage ('Build and Deploy Artifacts') {
    def server = Artifactory.newServer url: 'http://****/home', credentialsId: 'd***5c1'
    def rtMaven = Artifactory.newMavenBuild()
    rtMaven.resolver releaseRepo:'libs-release', snapshotRepo:'libs-snapshot', server: server
    rtMaven.deployer releaseRepo:'develop-release', snapshotRepo:'develop-snapshot', server: server
    rtMaven.tool = 'maven' // Tool name from Jenkins configuration
    def buildInfo = rtMaven.run pom: 'pom.xml', goals: 'clean install -Dmaven.test.skip=true' //buildInfo: buildInfo'
    buildInfo.env.capture = true
    server.publishBuildInfo buildInfo
}

</code>```

Errors being displayed on Jenkins

```Started by user Sunil boga
    [Pipeline] node
    Running on master in /var/lib/jenkins/workspace/JF
            [Pipeline] {
            [Pipeline] stage
            [Pipeline] { (Checkout)
            [Pipeline] checkout
     > git rev-parse --is-inside-work-tree # timeout=10
    Fetching changes from the remote Git repository
     > git config remote.origin.url https:***.git # timeout=10
    Fetching upstream changes from https:***.git
     > git --version # timeout=10
     > git fetch --tags --progress https:***.git +refs/heads/*:refs/remotes/origin/*
     > git rev-parse refs/remotes/origin/master^{commit} # timeout=10
     > git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
    Checking out Revision a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4 (refs/remotes/origin/master)
    Commit message: "Update docker-compose.yml"
     > git config core.sparsecheckout # timeout=10
     > git checkout -f a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4
     > git rev-list a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4 # timeout=10
    [Pipeline] }
    [Pipeline] // stage
    [Pipeline] stage
    [Pipeline] { (Build and Deploy Artifacts)
    [Pipeline] newArtifactoryServer
    [Pipeline] newMavenBuild
    [Pipeline] ArtifactoryMavenBuild
    Jenkins Artifactory Plugin version: 2.13.0
    Artifactory integration is enabled

[JF] $ java -classpath /var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven/boot/* -Dmaven.home=/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven -DbuildInfoConfig.propertiesFile=/var/lib/jenkins/workspace/JF@tmp/buildInfo7470386380438368064.properties -Dm3plugin.lib=/var/lib/jenkins/workspace/JF@tmp/cache/artifactory-plugin/2.13.0 -Dclassworlds.conf=/var/lib/jenkins/workspace/JF@tmp/classworlds7388179377818037761conf -Dmaven.multiModuleProjectDirectory=/var/lib/jenkins/workspace/JF org.codehaus.plexus.classworlds.launcher.Launcher -f pom.xml clean install -Dmaven.test.skip=true
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - Scanning for projects...
    [main] INFO org.jfrog.build.extractor.maven.BuildInfoRecorder - Initializing Artifactory Build-Info Recording
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - ------------------------------------------------------------------------
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - Building SampleProjectForCICD 0.0.1-SNAPSHOT
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - ------------------------------------------------------------------------
    [main] WARNING org.codehaus.plexus.PlexusContainer - The POM for com.oracle.jdbc:ojdbc8:jar:12.2.0.1 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-clean-plugin:2.6.1:clean (default-clean) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.clean.CleanMojo - Deleting /var/lib/jenkins/workspace/JF/target
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-resources-plugin:2.6:resources (default-resources) @ sampleproject ---
    [main] INFO org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering - Using 'UTF-8' encoding to copy filtered resources.
    [main] INFO org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering - Copying 1 resource
    [main] INFO org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering - Copying 3 resources
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-compiler-plugin:3.1:compile (default-compile) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.compiler.CompilerMojo - Changes detected - recompiling the module!
    [main] INFO org.codehaus.plexus.compiler.javac.JavacCompiler - Compiling 11 source files to /var/lib/jenkins/workspace/JF/target/classes
    [main] WARNING org.apache.maven.plugin.compiler.CompilerMojo - /var/lib/jenkins/workspace/JF/src/main/java/guru/springframework/controllers/ProductAPI.java: /var/lib/jenkins/workspace/JF/src/main/java/guru/springframework/controllers/ProductAPI.java uses unchecked or unsafe operations.
    [main] WARNING org.apache.maven.plugin.compiler.CompilerMojo - /var/lib/jenkins/workspace/JF/src/main/java/guru/springframework/controllers/ProductAPI.java: Recompile with -Xlint:unchecked for details.
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-resources-plugin:2.6:testResources (default-testResources) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.resources.TestResourcesMojo - Not copying test resources
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.compiler.TestCompilerMojo - Not compiling test sources
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-surefire-plugin:2.18.1:test (default-test) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.surefire.SurefirePlugin - Tests are skipped.
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-jar-plugin:2.6:jar (default-jar) @ sampleproject ---
    [main] INFO org.codehaus.plexus.archiver.jar.JarArchiver - Building jar: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- spring-boot-maven-plugin:1.5.1.RELEASE:repackage (default) @ sampleproject ---
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-install-plugin:2.5.2:install (default-install) @ sampleproject ---
    [main] INFO org.codehaus.plexus.PlexusContainer - Installing /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar to /var/lib/jenkins/.m2/repository/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar
    [main] INFO org.codehaus.plexus.PlexusContainer - Installing /var/lib/jenkins/workspace/JF/pom.xml to /var/lib/jenkins/.m2/repository/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.pom
    [main] INFO org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Deploying artifact: http://***:8081/artifactory/webapp/#/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Attempting retry #1
    [main] INFO org.apache.http.impl.execchain.RetryExec - I/O exception (java.net.SocketException) caught when processing request to {}->http://***:8081: Connection reset
    [main] INFO org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://***:8081
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Attempting retry #2
    [main] INFO org.apache.http.impl.execchain.RetryExec - I/O exception (java.net.SocketException) caught when processing request to {}->http://***:8081: Connection reset
    [main] INFO org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://***:8081
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Attempting retry #3
    [main] INFO org.apache.http.impl.execchain.RetryExec - I/O exception (java.net.SocketException) caught when processing request to {}->http://***:8081: Connection reset
    [main] INFO org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://***:8081
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] ERROR org.jfrog.build.extractor.maven.BuildInfoRecorder - org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed:
    java.lang.RuntimeException: Error occurred while publishing artifact to Artifactory: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar.
     Skipping deployment of remaining artifacts (if any) and build info.
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:296)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.net.SocketException: Connection reset
        at java.net.SocketOutputStream.socketWrite (SocketOutputStream.java:115)
        at java.net.SocketOutputStream.write (SocketOutputStream.java:155)
        at org.apache.http.impl.io.SessionOutputBufferImpl.streamWrite (SessionOutputBufferImpl.java:124)
        at org.apache.http.impl.io.SessionOutputBufferImpl.flushBuffer (SessionOutputBufferImpl.java:136)
        at org.apache.http.impl.io.SessionOutputBufferImpl.write (SessionOutputBufferImpl.java:167)
        at org.apache.http.impl.io.ContentLengthOutputStream.write (ContentLengthOutputStream.java:113)
        at org.apache.http.entity.FileEntity.writeTo (FileEntity.java:99)
        at org.apache.http.impl.DefaultBHttpClientConnection.sendRequestEntity (DefaultBHttpClientConnection.java:156)
        at org.apache.http.impl.conn.CPoolProxy.sendRequestEntity (CPoolProxy.java:162)
        at org.apache.http.protocol.HttpRequestExecutor.doSendRequest (HttpRequestExecutor.java:238)
        at org.apache.http.protocol.HttpRequestExecutor.execute (HttpRequestExecutor.java:123)
        at org.apache.http.impl.execchain.MainClientExec.execute (MainClientExec.java:271)
        at org.apache.http.impl.execchain.ProtocolExec.execute (ProtocolExec.java:184)
        at org.apache.http.impl.execchain.RetryExec.execute (RetryExec.java:88)
        at org.apache.http.impl.execchain.RedirectExec.execute (RedirectExec.java:110)
        at org.apache.http.impl.execchain.ServiceUnavailableRetryExec.execute (ServiceUnavailableRetryExec.java:84)
        at org.apache.http.impl.client.InternalHttpClient.doExecute (InternalHttpClient.java:184)
        at org.apache.http.impl.client.CloseableHttpClient.execute (CloseableHttpClient.java:82)
        at org.jfrog.build.client.PreemptiveHttpClient.execute (PreemptiveHttpClient.java:103)
        at org.jfrog.build.client.ArtifactoryHttpClient.execute (ArtifactoryHttpClient.java:216)
        at org.jfrog.build.client.ArtifactoryHttpClient.upload (ArtifactoryHttpClient.java:212)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.uploadFile (ArtifactoryBuildInfoClient.java:654)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.deployArtifact (ArtifactoryBuildInfoClient.java:344)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:294)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    [main] ERROR org.apache.maven.cli.MavenCli - Internal error: java.lang.RuntimeException: org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed: Error occurred while publishing artifact to Artifactory: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar.
    [main] ERROR org.apache.maven.cli.MavenCli -  Skipping deployment of remaining artifacts (if any) and build info. Connection reset
    [main] ERROR org.apache.maven.cli.MavenCli - -> [Help 1]
    org.apache.maven.InternalErrorException: Internal error: java.lang.RuntimeException: org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed:
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:122)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.lang.RuntimeException: org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed:
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:182)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.lang.RuntimeException: Error occurred while publishing artifact to Artifactory: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar.
     Skipping deployment of remaining artifacts (if any) and build info.
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:296)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.net.SocketException: Connection reset
        at java.net.SocketOutputStream.socketWrite (SocketOutputStream.java:115)
        at java.net.SocketOutputStream.write (SocketOutputStream.java:155)
        at org.apache.http.impl.io.SessionOutputBufferImpl.streamWrite (SessionOutputBufferImpl.java:124)
        at org.apache.http.impl.io.SessionOutputBufferImpl.flushBuffer (SessionOutputBufferImpl.java:136)
        at org.apache.http.impl.io.SessionOutputBufferImpl.write (SessionOutputBufferImpl.java:167)
        at org.apache.http.impl.io.ContentLengthOutputStream.write (ContentLengthOutputStream.java:113)
        at org.apache.http.entity.FileEntity.writeTo (FileEntity.java:99)
        at org.apache.http.impl.DefaultBHttpClientConnection.sendRequestEntity (DefaultBHttpClientConnection.java:156)
        at org.apache.http.impl.conn.CPoolProxy.sendRequestEntity (CPoolProxy.java:162)
        at org.apache.http.protocol.HttpRequestExecutor.doSendRequest (HttpRequestExecutor.java:238)
        at org.apache.http.protocol.HttpRequestExecutor.execute (HttpRequestExecutor.java:123)
        at org.apache.http.impl.execchain.MainClientExec.execute (MainClientExec.java:271)
        at org.apache.http.impl.execchain.ProtocolExec.execute (ProtocolExec.java:184)
        at org.apache.http.impl.execchain.RetryExec.execute (RetryExec.java:88)
        at org.apache.http.impl.execchain.RedirectExec.execute (RedirectExec.java:110)
        at org.apache.http.impl.execchain.ServiceUnavailableRetryExec.execute (ServiceUnavailableRetryExec.java:84)
        at org.apache.http.impl.client.InternalHttpClient.doExecute (InternalHttpClient.java:184)
        at org.apache.http.impl.client.CloseableHttpClient.execute (CloseableHttpClient.java:82)
        at org.jfrog.build.client.PreemptiveHttpClient.execute (PreemptiveHttpClient.java:103)
        at org.jfrog.build.client.ArtifactoryHttpClient.execute (ArtifactoryHttpClient.java:216)
        at org.jfrog.build.client.ArtifactoryHttpClient.upload (ArtifactoryHttpClient.java:212)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.uploadFile (ArtifactoryBuildInfoClient.java:654)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.deployArtifact (ArtifactoryBuildInfoClient.java:344)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:294)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    [main] ERROR org.apache.maven.cli.MavenCli -
    [main] ERROR org.apache.maven.cli.MavenCli - To see the full stack trace of the errors, re-run Maven with the -e switch.
    [main] ERROR org.apache.maven.cli.MavenCli - Re-run Maven using the -X switch to enable full debug logging.
    [main] ERROR org.apache.maven.cli.MavenCli -
    [main] ERROR org.apache.maven.cli.MavenCli - For more information about the errors and possible solutions, please read the following articles:
    [main] ERROR org.apache.maven.cli.MavenCli - [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/InternalErrorException
    [Pipeline] }
    [Pipeline] // stage
    [Pipeline] }
    [Pipeline] // node
    [Pipeline] End of Pipeline
    java.lang.RuntimeException: Maven build failed
        at org.jfrog.hudson.pipeline.steps.ArtifactoryMavenBuild$Execution.run(ArtifactoryMavenBuild.java:108)
        at org.jfrog.hudson.pipeline.steps.ArtifactoryMavenBuild$Execution.run(ArtifactoryMavenBuild.java:61)
        at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
        at hudson.security.ACL.impersonate(ACL.java:260)
        at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)
    Finished: FAILURE
```

答:
Deploying Artifacts

```<code>stage ('Deploy Artifacts') {

    //Artifactory server instance declaration
    def server = Artifactory.server 'server1' //server1 is the Server ID given to Artifactory server in Jenkins

    //Capturing the Build artifacts from Build server to upload
    def uploadSpec = """{
        "files": [
            {
                "pattern": "/var/lib/jenkins/workspace/JF/target/*.jar",
                "target": "fortna_sample/"
            }
        ]
    }"""
    server.upload(uploadSpec)

    //Capturing the artifacts from Artifactory server to download it into Jenkins machine at /var/lib/jenkins/workspace/JF/jarFile/
    def downloadSpec = """{
        "files": [
            {
                "pattern": "fortna_sample/sampleproject-0.0.1-SNAPSHOT.jar",
                "target": "jarFile/"
            }
        ]
    }"""
    server.download(downloadSpec)

    //Publishing build info to Artifactory - Method 2
    def buildInfo = Artifactory.newBuildInfo()
    server.upload spec: uploadSpec, buildInfo: buildInfo
    //server.download spec: downloadSpec, buildInfo: buildInfo
    server.publishBuildInfo buildInfo

    //Capturing Environment variables
    buildInfo.env.capture = true
    buildInfo.env.collect()
    buildInfo.retention maxBuilds: 10, maxDays: 7, deleteBuildArtifacts: true

    // Build Promotion Section
    def promotionConfig = [
        // Mandatory parameters
        'buildName'          : buildInfo.name,
        'buildNumber'        : buildInfo.number,
        'targetRepo'         : 'libs-release-local',

        // Optional parameters
        'comment'            : 'PROMOTION SUCCESSFULLY COMPLETED',
        'sourceRepo'         : 'fortna_sample',
        'status'             : 'Released',
        'includeDependencies': false,
        'copy'               : false,
        // 'failFast' is true by default.
        // Set it to false, if you don't want the promotion to abort upon receiving the first error.
        'failFast'           : true
    ]

    // Promote build
    //server.promote promotionConfig //this promotes the build automatically to the target specified in promotionConfig
    Artifactory.addInteractivePromotion server: server, promotionConfig: promotionConfig, displayName: "Promotions Time" //this need human interaction to promote
    echo "Build Completed Successfully and Promotions are manual"
}
</code>```

Body:
What I'm trying

I'm building an application using Artifactory maven and publishing the artifacts generated, to the Artifactory server.

What I need

If there are any suggestions, I would love to try them right away. ;)

Jenkins Pipeline Script

 stage ('Build and Deploy Artifacts') {
    def server = Artifactory.newServer url: 'http://****/home', credentialsId: 'd***5c1'
    def rtMaven = Artifactory.newMavenBuild()
    rtMaven.resolver releaseRepo:'libs-release', snapshotRepo:'libs-snapshot', server: server
    rtMaven.deployer releaseRepo:'develop-release', snapshotRepo:'develop-snapshot', server: server
    rtMaven.tool = 'maven' // Tool name from Jenkins configuration
    def buildInfo = rtMaven.run pom: 'pom.xml', goals: 'clean install -Dmaven.test.skip=true' //buildInfo: buildInfo'
    buildInfo.env.capture = true
    server.publishBuildInfo buildInfo
}

Errors being displayed on Jenkins

Started by user Sunil boga
    [Pipeline] node
    Running on master in /var/lib/jenkins/workspace/JF
            [Pipeline] {
            [Pipeline] stage
            [Pipeline] { (Checkout)
            [Pipeline] checkout
     > git rev-parse --is-inside-work-tree # timeout=10
    Fetching changes from the remote Git repository
     > git config remote.origin.url https:***.git # timeout=10
    Fetching upstream changes from https:***.git
     > git --version # timeout=10
     > git fetch --tags --progress https:***.git +refs/heads/*:refs/remotes/origin/*
     > git rev-parse refs/remotes/origin/master^{commit} # timeout=10
     > git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
    Checking out Revision a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4 (refs/remotes/origin/master)
    Commit message: "Update docker-compose.yml"
     > git config core.sparsecheckout # timeout=10
     > git checkout -f a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4
     > git rev-list a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4 # timeout=10
    [Pipeline] }
    [Pipeline] // stage
    [Pipeline] stage
    [Pipeline] { (Build and Deploy Artifacts)
    [Pipeline] newArtifactoryServer
    [Pipeline] newMavenBuild
    [Pipeline] ArtifactoryMavenBuild
    Jenkins Artifactory Plugin version: 2.13.0
    Artifactory integration is enabled

[JF] $ java -classpath /var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven/boot/* -Dmaven.home=/var/lib/jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven -DbuildInfoConfig.propertiesFile=/var/lib/jenkins/workspace/JF@tmp/buildInfo7470386380438368064.properties -Dm3plugin.lib=/var/lib/jenkins/workspace/JF@tmp/cache/artifactory-plugin/2.13.0 -Dclassworlds.conf=/var/lib/jenkins/workspace/JF@tmp/classworlds7388179377818037761conf -Dmaven.multiModuleProjectDirectory=/var/lib/jenkins/workspace/JF org.codehaus.plexus.classworlds.launcher.Launcher -f pom.xml clean install -Dmaven.test.skip=true
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - Scanning for projects...
    [main] INFO org.jfrog.build.extractor.maven.BuildInfoRecorder - Initializing Artifactory Build-Info Recording
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - ------------------------------------------------------------------------
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - Building SampleProjectForCICD 0.0.1-SNAPSHOT
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - ------------------------------------------------------------------------
    [main] WARNING org.codehaus.plexus.PlexusContainer - The POM for com.oracle.jdbc:ojdbc8:jar:12.2.0.1 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-clean-plugin:2.6.1:clean (default-clean) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.clean.CleanMojo - Deleting /var/lib/jenkins/workspace/JF/target
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-resources-plugin:2.6:resources (default-resources) @ sampleproject ---
    [main] INFO org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering - Using 'UTF-8' encoding to copy filtered resources.
    [main] INFO org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering - Copying 1 resource
    [main] INFO org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering - Copying 3 resources
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-compiler-plugin:3.1:compile (default-compile) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.compiler.CompilerMojo - Changes detected - recompiling the module!
    [main] INFO org.codehaus.plexus.compiler.javac.JavacCompiler - Compiling 11 source files to /var/lib/jenkins/workspace/JF/target/classes
    [main] WARNING org.apache.maven.plugin.compiler.CompilerMojo - /var/lib/jenkins/workspace/JF/src/main/java/guru/springframework/controllers/ProductAPI.java: /var/lib/jenkins/workspace/JF/src/main/java/guru/springframework/controllers/ProductAPI.java uses unchecked or unsafe operations.
    [main] WARNING org.apache.maven.plugin.compiler.CompilerMojo - /var/lib/jenkins/workspace/JF/src/main/java/guru/springframework/controllers/ProductAPI.java: Recompile with -Xlint:unchecked for details.
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-resources-plugin:2.6:testResources (default-testResources) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.resources.TestResourcesMojo - Not copying test resources
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.compiler.TestCompilerMojo - Not compiling test sources
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-surefire-plugin:2.18.1:test (default-test) @ sampleproject ---
    [main] INFO org.apache.maven.plugin.surefire.SurefirePlugin - Tests are skipped.
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-jar-plugin:2.6:jar (default-jar) @ sampleproject ---
    [main] INFO org.codehaus.plexus.archiver.jar.JarArchiver - Building jar: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- spring-boot-maven-plugin:1.5.1.RELEASE:repackage (default) @ sampleproject ---
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger -
    [main] INFO org.apache.maven.cli.event.ExecutionEventLogger - --- maven-install-plugin:2.5.2:install (default-install) @ sampleproject ---
    [main] INFO org.codehaus.plexus.PlexusContainer - Installing /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar to /var/lib/jenkins/.m2/repository/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar
    [main] INFO org.codehaus.plexus.PlexusContainer - Installing /var/lib/jenkins/workspace/JF/pom.xml to /var/lib/jenkins/.m2/repository/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.pom
    [main] INFO org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Deploying artifact: http://***:8081/artifactory/webapp/#/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Attempting retry #1
    [main] INFO org.apache.http.impl.execchain.RetryExec - I/O exception (java.net.SocketException) caught when processing request to {}->http://***:8081: Connection reset
    [main] INFO org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://***:8081
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Attempting retry #2
    [main] INFO org.apache.http.impl.execchain.RetryExec - I/O exception (java.net.SocketException) caught when processing request to {}->http://***:8081: Connection reset
    [main] INFO org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://***:8081
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Attempting retry #3
    [main] INFO org.apache.http.impl.execchain.RetryExec - I/O exception (java.net.SocketException) caught when processing request to {}->http://***:8081: Connection reset
    [main] INFO org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://***:8081
    [main] WARNING org.jfrog.build.extractor.maven.BuildInfoClientBuilder - Error occurred for request PUT /artifactory/webapp/%23/home/develop-snapshot/com/fortna/cicd/sampleproject/0.0.1-SNAPSHOT/sampleproject-0.0.1-SNAPSHOT.jar;vcs.revision=a704ec6ba9b9af8a1a02aeb3d1041a15135ac3d4;build.timestamp=1512480424292;build.name=JF;build.number=19 HTTP/1.1: Connection reset.
    [main] ERROR org.jfrog.build.extractor.maven.BuildInfoRecorder - org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed:
    java.lang.RuntimeException: Error occurred while publishing artifact to Artifactory: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar.
     Skipping deployment of remaining artifacts (if any) and build info.
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:296)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.net.SocketException: Connection reset
        at java.net.SocketOutputStream.socketWrite (SocketOutputStream.java:115)
        at java.net.SocketOutputStream.write (SocketOutputStream.java:155)
        at org.apache.http.impl.io.SessionOutputBufferImpl.streamWrite (SessionOutputBufferImpl.java:124)
        at org.apache.http.impl.io.SessionOutputBufferImpl.flushBuffer (SessionOutputBufferImpl.java:136)
        at org.apache.http.impl.io.SessionOutputBufferImpl.write (SessionOutputBufferImpl.java:167)
        at org.apache.http.impl.io.ContentLengthOutputStream.write (ContentLengthOutputStream.java:113)
        at org.apache.http.entity.FileEntity.writeTo (FileEntity.java:99)
        at org.apache.http.impl.DefaultBHttpClientConnection.sendRequestEntity (DefaultBHttpClientConnection.java:156)
        at org.apache.http.impl.conn.CPoolProxy.sendRequestEntity (CPoolProxy.java:162)
        at org.apache.http.protocol.HttpRequestExecutor.doSendRequest (HttpRequestExecutor.java:238)
        at org.apache.http.protocol.HttpRequestExecutor.execute (HttpRequestExecutor.java:123)
        at org.apache.http.impl.execchain.MainClientExec.execute (MainClientExec.java:271)
        at org.apache.http.impl.execchain.ProtocolExec.execute (ProtocolExec.java:184)
        at org.apache.http.impl.execchain.RetryExec.execute (RetryExec.java:88)
        at org.apache.http.impl.execchain.RedirectExec.execute (RedirectExec.java:110)
        at org.apache.http.impl.execchain.ServiceUnavailableRetryExec.execute (ServiceUnavailableRetryExec.java:84)
        at org.apache.http.impl.client.InternalHttpClient.doExecute (InternalHttpClient.java:184)
        at org.apache.http.impl.client.CloseableHttpClient.execute (CloseableHttpClient.java:82)
        at org.jfrog.build.client.PreemptiveHttpClient.execute (PreemptiveHttpClient.java:103)
        at org.jfrog.build.client.ArtifactoryHttpClient.execute (ArtifactoryHttpClient.java:216)
        at org.jfrog.build.client.ArtifactoryHttpClient.upload (ArtifactoryHttpClient.java:212)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.uploadFile (ArtifactoryBuildInfoClient.java:654)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.deployArtifact (ArtifactoryBuildInfoClient.java:344)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:294)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    [main] ERROR org.apache.maven.cli.MavenCli - Internal error: java.lang.RuntimeException: org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed: Error occurred while publishing artifact to Artifactory: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar.
    [main] ERROR org.apache.maven.cli.MavenCli -  Skipping deployment of remaining artifacts (if any) and build info. Connection reset
    [main] ERROR org.apache.maven.cli.MavenCli - -> [Help 1]
    org.apache.maven.InternalErrorException: Internal error: java.lang.RuntimeException: org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed:
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:122)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.lang.RuntimeException: org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded() listener has failed:
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:182)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.lang.RuntimeException: Error occurred while publishing artifact to Artifactory: /var/lib/jenkins/workspace/JF/target/sampleproject-0.0.1-SNAPSHOT.jar.
     Skipping deployment of remaining artifacts (if any) and build info.
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:296)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    Caused by: java.net.SocketException: Connection reset
        at java.net.SocketOutputStream.socketWrite (SocketOutputStream.java:115)
        at java.net.SocketOutputStream.write (SocketOutputStream.java:155)
        at org.apache.http.impl.io.SessionOutputBufferImpl.streamWrite (SessionOutputBufferImpl.java:124)
        at org.apache.http.impl.io.SessionOutputBufferImpl.flushBuffer (SessionOutputBufferImpl.java:136)
        at org.apache.http.impl.io.SessionOutputBufferImpl.write (SessionOutputBufferImpl.java:167)
        at org.apache.http.impl.io.ContentLengthOutputStream.write (ContentLengthOutputStream.java:113)
        at org.apache.http.entity.FileEntity.writeTo (FileEntity.java:99)
        at org.apache.http.impl.DefaultBHttpClientConnection.sendRequestEntity (DefaultBHttpClientConnection.java:156)
        at org.apache.http.impl.conn.CPoolProxy.sendRequestEntity (CPoolProxy.java:162)
        at org.apache.http.protocol.HttpRequestExecutor.doSendRequest (HttpRequestExecutor.java:238)
        at org.apache.http.protocol.HttpRequestExecutor.execute (HttpRequestExecutor.java:123)
        at org.apache.http.impl.execchain.MainClientExec.execute (MainClientExec.java:271)
        at org.apache.http.impl.execchain.ProtocolExec.execute (ProtocolExec.java:184)
        at org.apache.http.impl.execchain.RetryExec.execute (RetryExec.java:88)
        at org.apache.http.impl.execchain.RedirectExec.execute (RedirectExec.java:110)
        at org.apache.http.impl.execchain.ServiceUnavailableRetryExec.execute (ServiceUnavailableRetryExec.java:84)
        at org.apache.http.impl.client.InternalHttpClient.doExecute (InternalHttpClient.java:184)
        at org.apache.http.impl.client.CloseableHttpClient.execute (CloseableHttpClient.java:82)
        at org.jfrog.build.client.PreemptiveHttpClient.execute (PreemptiveHttpClient.java:103)
        at org.jfrog.build.client.ArtifactoryHttpClient.execute (ArtifactoryHttpClient.java:216)
        at org.jfrog.build.client.ArtifactoryHttpClient.upload (ArtifactoryHttpClient.java:212)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.uploadFile (ArtifactoryBuildInfoClient.java:654)
        at org.jfrog.build.extractor.clientConfiguration.client.ArtifactoryBuildInfoClient.deployArtifact (ArtifactoryBuildInfoClient.java:344)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deployArtifacts (BuildDeploymentHelper.java:294)
        at org.jfrog.build.extractor.maven.BuildDeploymentHelper.deploy (BuildDeploymentHelper.java:117)
        at org.jfrog.build.extractor.maven.BuildInfoRecorder.sessionEnded (BuildInfoRecorder.java:173)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:64)
        at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire (DefaultExecutionEventCatapult.java:42)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:137)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:309)
        at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:194)
        at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:107)
        at org.apache.maven.cli.MavenCli.execute (MavenCli.java:955)
        at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:290)
        at org.apache.maven.cli.MavenCli.main (MavenCli.java:194)
        at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke (Method.java:498)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:356)
    [main] ERROR org.apache.maven.cli.MavenCli -
    [main] ERROR org.apache.maven.cli.MavenCli - To see the full stack trace of the errors, re-run Maven with the -e switch.
    [main] ERROR org.apache.maven.cli.MavenCli - Re-run Maven using the -X switch to enable full debug logging.
    [main] ERROR org.apache.maven.cli.MavenCli -
    [main] ERROR org.apache.maven.cli.MavenCli - For more information about the errors and possible solutions, please read the following articles:
    [main] ERROR org.apache.maven.cli.MavenCli - [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/InternalErrorException
    [Pipeline] }
    [Pipeline] // stage
    [Pipeline] }
    [Pipeline] // node
    [Pipeline] End of Pipeline
    java.lang.RuntimeException: Maven build failed
        at org.jfrog.hudson.pipeline.steps.ArtifactoryMavenBuild$Execution.run(ArtifactoryMavenBuild.java:108)
        at org.jfrog.hudson.pipeline.steps.ArtifactoryMavenBuild$Execution.run(ArtifactoryMavenBuild.java:61)
        at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
        at hudson.security.ACL.impersonate(ACL.java:260)
        at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)
    Finished: FAILURE

Body:
Deploying Artifacts

stage ('Deploy Artifacts') {

    //Artifactory server instance declaration
    def server = Artifactory.server 'server1' //server1 is the Server ID given to Artifactory server in Jenkins

    //Capturing the Build artifacts from Build server to upload
    def uploadSpec = """{
        "files": [
            {
                "pattern": "/var/lib/jenkins/workspace/JF/target/*.jar",
                "target": "fortna_sample/"
            }
        ]
    }"""
    server.upload(uploadSpec)

    //Capturing the artifacts from Artifactory server to download it into Jenkins machine at /var/lib/jenkins/workspace/JF/jarFile/
    def downloadSpec = """{
        "files": [
            {
                "pattern": "fortna_sample/sampleproject-0.0.1-SNAPSHOT.jar",
                "target": "jarFile/"
            }
        ]
    }"""
    server.download(downloadSpec)

    //Publishing build info to Artifactory - Method 2
    def buildInfo = Artifactory.newBuildInfo()
    server.upload spec: uploadSpec, buildInfo: buildInfo
    //server.download spec: downloadSpec, buildInfo: buildInfo
    server.publishBuildInfo buildInfo

    //Capturing Environment variables
    buildInfo.env.capture = true
    buildInfo.env.collect()
    buildInfo.retention maxBuilds: 10, maxDays: 7, deleteBuildArtifacts: true

    // Build Promotion Section
    def promotionConfig = [
        // Mandatory parameters
        'buildName'          : buildInfo.name,
        'buildNumber'        : buildInfo.number,
        'targetRepo'         : 'libs-release-local',

        // Optional parameters
        'comment'            : 'PROMOTION SUCCESSFULLY COMPLETED',
        'sourceRepo'         : 'fortna_sample',
        'status'             : 'Released',
        'includeDependencies': false,
        'copy'               : false,
        // 'failFast' is true by default.
        // Set it to false, if you don't want the promotion to abort upon receiving the first error.
        'failFast'           : true
    ]

    // Promote build
    //server.promote promotionConfig //this promotes the build automatically to the target specified in promotionConfig
    Artifactory.addInteractivePromotion server: server, promotionConfig: promotionConfig, displayName: "Promotions Time" //this need human interaction to promote
    echo "Build Completed Successfully and Promotions are manual"
}


来源: stackexchange

问:
React Dynamic Html Tags
Lets say i have this react component refering to a TextInput.
I want this component to be a

<input type="text"> and a <textarea> as well, but with no ifs on it, as being passed throw props, however my renderer got extra stuff on the element as follows:

```<code>   render() {
      return (
            <label>
            <strong>{this.props.name}</strong>
               <input type="text" ref={ component => { this.input = component; } } name={this.props.name} onChange={this.handleChange} value={this.state.value} />
            </label>
      )
   }
</code>```

My original idea was doing something like this

```<code>myInputProps = { type: (<input type="text"/>) }
</code>```

So in my element i woul render this simply as

```<code>  {this.props.type}
</code>```

However how could i pass all those extra stuff to the element such as the ref, name, onchange etc ? What would be a good aproach on this problem ? I could do some ifs and check what should i render depending on the component state etc, but i`m not sure that would be the best.

答:
What you need is:</p>

```<code>render() {
  var input = this.props.type;
  input.props = {
      ...input.props,
      ref: (component) => { this.input = component;},
      onChange: this.handleChange,
      value: this.state.value
  };

  return (
        <label>
           <strong>{this.props.name}</strong>
           {input}
        </label>
  )
}
</code>```

ContentLicense: CC BY-SA 3.0

Title: React Dynamic Html Tags

Body:
Lets say i have this react component refering to a TextInput.
I want this component to be a

<input type="text"> and a <textarea> as well, but with no ifs on it, as being passed throw props, however my renderer got extra stuff on the element as follows:

   render() {
      return (

            {this.props.name}
               <input type="text" ref={ component => { this.input = component; } } name={this.props.name} onChange={this.handleChange} value={this.state.value} />

      )
   }

My original idea was doing something like this

myInputProps = { type: (<input type="text"/>) }

So in my element i woul render this simply as

  {this.props.type}

However how could i pass all those extra stuff to the element such as the ref, name, onchange etc ? What would be a good aproach on this problem ? I could do some ifs and check what should i render depending on the component state etc, but i`m not sure that would be the best.

Body:
What you need is:

render() {
  var input = this.props.type;
  input.props = {
      ...input.props,
      ref: (component) => { this.input = component;},
      onChange: this.handleChange,
      value: this.state.value
  };

  return (
        <label>
           <strong>{this.props.name}</strong>
           {input}
        </label>
  )
}


问:
Efficiently return words that match, or whose synonym(s), match a keyword
I have a database of industry-specific terms, each of which may have zero or more synonyms.  Users of the system can search for terms by keyword and the results should include any term that contains the keyword or that has at least one synonym that contains the keyword.  The result should then include the term and ONLY ONE of the matching synonyms.

Here's the setup... I have a term table with 2 fields: id and term.  I also have a synonym table with 3 fields: id, termId, and synonym.  So there would data like:

```<code>term Table
id | term
-- | -----
1  | dog
2  | cat
3  | bird

synonym Table
id | termId | synonym
-- | ------ | --------
1  | 1      | canine
2  | 1      | man's best friend
3  | 2      | feline
</code>```

A keyword search for (the letter) "i" should return the following as a result:

```<code>id | term   | synonym
-- | ------ | --------
1  | dog    | canine     <- because of the "i" in "canine"
2  | cat    | feline     <- because of the "i" in "feline"
3  | bird   |            <- because of the "i" in "bird"
</code>```

Notice how, even though both "dog" synonyms contain the letter "i", only one was returned in the result (doesn't matter which one).

Because I need to return all matches from the term table regardless of whether or not there's a synonym and I need no more than 1 matching synonym, I'm using an OUTER APPLY as follows:

```<code><!-- language: sql -->

SELECT
    term.id,
    term.term,
    synonyms.synonym
FROM
    term
    OUTER APPLY (
            SELECT
                TOP 1
                term.id,
                synonym.synonym
            FROM
                synonym
            WHERE
                term.id = synonym.termId
                AND synonym.synonym LIKE @keyword
        ) AS synonyms
WHERE
    term.term LIKE @keyword
    OR synonyms.synonym LIKE @keyword
</code>```

There are indexes on term.term, synonym.termId and synonym.synonym.  @Keyword is always something like '%foo%'.  The problem is that, with close to 50,000 terms (not that much for databases, I know, but...), the performance is horrible.  Any thoughts on how this can be done more efficiently?

Just a note, one thing I had thought to try was flattening the synonyms into a comma-delimited list in the term table so that I could get around the OUTER APPLY.  Unfortunately though, that list can easily exceed 900 characters which would then prevent SQL Server from adding an index to that column.  So that's a no-go.

Thanks very much in advance.

答:
For "flattening the synonyms into a comma-delimited list in the term table: - Have you considered using Full Text Search feature? It would be much faster even when your data goes on becoming bulky.
You can put all synonyms (as comma delimited) in "synonym" column and put full text index on the same. </p>

Body:
I have a database of industry-specific terms, each of which may have zero or more synonyms.  Users of the system can search for terms by keyword and the results should include any term that contains the keyword or that has at least one synonym that contains the keyword.  The result should then include the term and ONLY ONE of the matching synonyms.

Here's the setup... I have a term table with 2 fields: id and term.  I also have a synonym table with 3 fields: id, termId, and synonym.  So there would data like:

term Table
id | term
-- | -----
1  | dog
2  | cat
3  | bird

synonym Table
id | termId | synonym
-- | ------ | --------
1  | 1      | canine
2  | 1      | man's best friend
3  | 2      | feline

A keyword search for (the letter) "i" should return the following as a result:

id | term   | synonym
-- | ------ | --------
1  | dog    | canine     <- because of the "i" in "canine"
2  | cat    | feline     <- because of the "i" in "feline"
3  | bird   |            <- because of the "i" in "bird"

Notice how, even though both "dog" synonyms contain the letter "i", only one was returned in the result (doesn't matter which one).

Because I need to return all matches from the term table regardless of whether or not there's a synonym and I need no more than 1 matching synonym, I'm using an OUTER APPLY as follows:

SELECT
    term.id,
    term.term,
    synonyms.synonym
FROM
    term
    OUTER APPLY (
            SELECT
                TOP 1
                term.id,
                synonym.synonym
            FROM
                synonym
            WHERE
                term.id = synonym.termId
                AND synonym.synonym LIKE @keyword
        ) AS synonyms
WHERE
    term.term LIKE @keyword
    OR synonyms.synonym LIKE @keyword

There are indexes on term.term, synonym.termId and synonym.synonym.  @Keyword is always something like '%foo%'.  The problem is that, with close to 50,000 terms (not that much for databases, I know, but...), the performance is horrible.  Any thoughts on how this can be done more efficiently?

Just a note, one thing I had thought to try was flattening the synonyms into a comma-delimited list in the term table so that I could get around the OUTER APPLY.  Unfortunately though, that list can easily exceed 900 characters which would then prevent SQL Server from adding an index to that column.  So that's a no-go.

Thanks very much in advance.


问:
Not able to install @angular/cli using npm
I am new to "@angular/cli", I have tried every thing but could not install.
I am tired now please some one can help me to install angular 4 "@angular/cli" in my system.

node and npm Version

and when I am installing "npm install -g @angular/cli" then getting

after installing node -v 6 I am getting below erorr

please suggest me where actually I am wrong.

答:
It is possible your npm cache has a corrupted file, perhaps it partially downloaded something and then got an error. Try npm cache clean --force and see if that helps.

If that doesn't help look in the log file given in the error message. Find the unexpected end of JSON input message in the log file and look before it to see if there are any other hints to the problem.

You updated your question with a new error message. That one is more specific about the corrupted file. Try removing the cli-1.5.5.tgz file from the path specified and try again. If you are using a web proxy on your network then it is also possible that your proxy has stored a corrupted cache: if you are able then turn off any proxies configured for your system and try a direct download.


问:
PSQL does not detect .pgpass file
I have tried

Setting the permission of .pgpass to 0600

Confirmed .pgpass is in my user's home directory (/home/brandon/.pgpass)

use -w in pg_dumpall command

Confirmed the data in .pgpass is correct

The script (https://wiki.postgresql.org/wiki/Automated_Backup_on_Linux)  for automated backup works if I type the password again and again which is why i added -w to all the commands. It for some reason does not read the .pgpass file .

There are multiple error messages but they are generally this.

```<code> pg_dumpall: could not connect to database "template1": FATAL:  password    authentication failed for user "postgres"
</code>```

FATAL:  password authentication failed for user "postgres"

pg_pass file :

```<code>localhost:5432:my_db:postgres:password
</code>```

command line :

```<code>username@droplet:~/ProjectDir$ bash cronjob/db_backup/pg_backup.sh
Making backup directory in /home/backups/database/postgresql/2017-12-06/

Performing globals backup
--------------------------------------------

Globals backup
cronjob/db_backup/pg_backup.sh: line 80: /home/backups/database/postgresql/2017-12-06/globals.sql.gz.in_progress: Permission denied
pg_dumpall: could not connect to database "template1": fe_sendauth: no      password supplied

[!!ERROR!!] Failed to produce globals backup

Performing schema-only backups
--------------------------------------------

psql: fe_sendauth: no password supplied
The following databases were matched for schema-only backup:

Performing full backups
--------------------------------------------

psql: fe_sendauth: no password supplied

All database backups complete!
</code>```

答:
You should supply the actual calls to pg_dump and pg_dumpall for a more detailed answer.

However, from your output I see that pg_dumpall (?) tries to connect to database template1, but in your .pgpass file the only database is my_db.

You'll have to add entries to .pgpass for all databases to which you are trying to connect.

```<code>localhost:5432:mydb1:postgres:password
localhost:5432:mydb2:postgres:password
localhost:5432:mydb3:postgres:password
</code>```

Alternatively, you are also able to put an * as a placeholder for different database names.

```<code>localhost:5432:*:postgres:password
</code>```

Make sure that all the fields in .pgpass are the right/matching ones. If any of them (host, port, etc.) don't match, the unclear, uninformative and arguably wrong fe_sendauth: no password supplied error message will be the same.

Title: PSQL does not detect .pgpass file

Body:
I have tried

Setting the permission of .pgpass to 0600

Confirmed .pgpass is in my user's home directory (/home/brandon/.pgpass)

use -w in pg_dumpall command

Confirmed the data in .pgpass is correct

The script (https://wiki.postgresql.org/wiki/Automated_Backup_on_Linux)  for automated backup works if I type the password again and again which is why i added -w to all the commands. It for some reason does not read the .pgpass file .

There are multiple error messages but they are generally this.

 pg_dumpall: could not connect to database "template1": FATAL:  password    authentication failed for user "postgres"

FATAL:  password authentication failed for user "postgres"

pg_pass file :

localhost:5432:my_db:postgres:password

command line :

username@droplet:~/ProjectDir$ bash cronjob/db_backup/pg_backup.sh
Making backup directory in /home/backups/database/postgresql/2017-12-06/

Performing globals backup
--------------------------------------------

Globals backup
cronjob/db_backup/pg_backup.sh: line 80: /home/backups/database/postgresql/2017-12-06/globals.sql.gz.in_progress: Permission denied
pg_dumpall: could not connect to database "template1": fe_sendauth: no      password supplied

[!!ERROR!!] Failed to produce globals backup

Performing schema-only backups
--------------------------------------------

psql: fe_sendauth: no password supplied
The following databases were matched for schema-only backup:

Performing full backups
--------------------------------------------

psql: fe_sendauth: no password supplied

All database backups complete!

Body:
You should supply the actual calls to pg_dump and pg_dumpall for a more detailed answer.

However, from your output I see that pg_dumpall (?) tries to connect to database template1, but in your .pgpass file the only database is my_db.

You'll have to add entries to .pgpass for all databases to which you are trying to connect.

localhost:5432:mydb1:postgres:password
localhost:5432:mydb2:postgres:password
localhost:5432:mydb3:postgres:password

Alternatively, you are also able to put an * as a placeholder for different database names.

localhost:5432:*:postgres:password

Make sure that all the fields in .pgpass are the right/matching ones. If any of them (host, port, etc.) don't match, the unclear, uninformative and arguably wrong fe_sendauth: no password supplied error message will be the same.

ContentLicense: CC BY-SA 4.0


问:
To add a Serial Number as the First Column in a GridView
I have a Grid View . It has two bound columns. I need to have a Serial Number column as the first column.

How can i do that ?
Thanks in Advance

答: use Row index a bound field or on row data bound you can add a template column on which you could use the index of the row.</p>

ContentLicense: CC BY-SA 2.5


问:
Django staticfiles not found on Heroku (with whitenoise)
This question seems to be asked several time but I can not fix it.

I deployed a django app on production with DEBUG = False. I set my allowed_host.
I used {% load static from staticfiles %} to load static files. I exactly write the settings sugested by Heroku doc :

```<code>BASE_DIR = os.path.dirname(os.path.dirname(__file__))
PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__))

STATIC_ROOT = os.path.join(PROJECT_ROOT, 'staticfiles')
STATIC_URL = '/static/'

STATICFILES_DIRS = (
    os.path.join(PROJECT_ROOT, 'static'),
)

STATICFILES_STORAGE = 'whitenoise.django.GzipManifestStaticFilesStorage'
</code>```

BUT I got an error 500. And got this traceback (by mail)

```<code>...
`cache_name = self.clean_name(self.hashed_name(name))
 File "/app/.heroku/python/lib/python3.5/site-    packages/django/contrib/staticfiles/storage.py", line 94, in hashed_name (clean_name, self))
...
ValueError: The file ‘app/css/font.css’ could not be found with <whitenoise.django.GzipManifestStaticFilesStorage object at 0x7febf600a7f0>.`
</code>```

When I run heroku run python manage.py collectstatic --noinput
All seems ok :

276 static files copied to '/app/annuaire/staticfiles', 276 post-processed.

Does anyone have an idea to help me, please ?

Thanks

EDIT :

```<code>annuaire
|-- /annuaire
|-- -- /settings.py
|-- /app
|-- -- /static/...`
</code>```

wsgi.py

```<code>from django.core.wsgi import get_wsgi_application
from whitenoise.django import DjangoWhiteNoise

application = get_wsgi_application()
application = DjangoWhiteNoise(application)
</code>```

答:
The problem is that the Python application in Heroku uses the built-in web server and does not serve static files.

You can use the app of the whitenoise, this working solution is 100%.

Suppose you have already generated static files, for example:

```<code>$ python manage.py collectstatic
</code>```

Next you need to do this:

1) $ pip install whitenoise

2) add string "whitenoise==3.3.0" in your requirements.txt

3) add code in settings.py

```<code>STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles')
</code>```

4) add this code in app/wsgi.py

```<code>from whitenoise.django import DjangoWhiteNoise
application = DjangoWhiteNoise(application)
</code>```

Body:
This question seems to be asked several time but I can not fix it.

I deployed a django app on production with DEBUG = False. I set my allowed_host.
I used {% load static from staticfiles %} to load static files. I exactly write the settings sugested by Heroku doc :

BASE_DIR = os.path.dirname(os.path.dirname(__file__))
PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__))

STATIC_ROOT = os.path.join(PROJECT_ROOT, 'staticfiles')
STATIC_URL = '/static/'

STATICFILES_DIRS = (
    os.path.join(PROJECT_ROOT, 'static'),
)

STATICFILES_STORAGE = 'whitenoise.django.GzipManifestStaticFilesStorage'

BUT I got an error 500. And got this traceback (by mail)

...
`cache_name = self.clean_name(self.hashed_name(name))
 File "/app/.heroku/python/lib/python3.5/site-    packages/django/contrib/staticfiles/storage.py", line 94, in hashed_name (clean_name, self))
...
ValueError: The file ‘app/css/font.css’ could not be found with <whitenoise.django.GzipManifestStaticFilesStorage object at 0x7febf600a7f0>.`

When I run heroku run python manage.py collectstatic --noinput
All seems ok :

276 static files copied to '/app/annuaire/staticfiles', 276 post-processed.

Does anyone have an idea to help me, please ?

Thanks

EDIT :

annuaire
|-- /annuaire
|-- -- /settings.py
|-- /app
|-- -- /static/...`

wsgi.py

from django.core.wsgi import get_wsgi_application
from whitenoise.django import DjangoWhiteNoise

application = get_wsgi_application()
application = DjangoWhiteNoise(application)

Body:
The problem is that the Python application in Heroku uses the built-in web server and does not serve static files.

You can use the app of the whitenoise, this working solution is 100%.

Suppose you have already generated static files, for example:

$ python manage.py collectstatic

Next you need to do this:

1) $ pip install whitenoise

2) add string "whitenoise==3.3.0" in your requirements.txt

3) add code in settings.py

STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles')

4) add this code in app/wsgi.py

from whitenoise.django import DjangoWhiteNoise
application = DjangoWhiteNoise(application)


问:
Checkpoint deep learning models in Keras
I need help in implementing the checkpoint function in Keras. I am going to train a large dataset so in order to do that, first I trained a model using the iris flower dataset : http://machinelearningmastery.com/multi-class-classification-tutorial-keras-deep-learning-library/

since my own dataset is a lot similar to it only the difference is that my dataset is more bigger.

For the checkpoint function : http://machinelearningmastery.com/check-point-deep-learning-models-keras/

I understand the example using pima-indians dataset.
Now I am trying to implement the same checkpoint function in the iris-flower script. Here is what I tried so far.

```<code>import numpy
from pandas import *
from keras.models import Sequential
from keras.layers import Dense
from keras.wrappers.scikit_learn import KerasClassifier
from keras.utils import np_utils
from sklearn.model_selection import cross_val_score, KFold
from sklearn.preprocessing import LabelEncoder
from sklearn.pipeline import Pipeline
from keras.callbacks import ModelCheckpoint

seed = 7
numpy.random.seed(seed)

dataframe = read_csv("iris.csv", header=None)
dataset = dataframe.values
X = dataset[:,0:4].astype(float)
Y = dataset[:,4]

# encode class value as integers
encoder = LabelEncoder()
encoder.fit(Y)
encoded_Y = encoder.transform(Y)
dummy_y = np_utils.to_categorical(encoded_Y)

def baseline_model():
    model = Sequential()
    model.add(Dense(4, input_dim=4, init='normal', activation='relu'))
    model.add(Dense(3, init='normal', activation='sigmoid'))
    model.compile(loss='categorical_crossentropy', optimizer='adam', metrics=['accuracy'])
    return model

filepath="weights-improvement-{epoch:02d}-{val_acc:.2f}.hdf5"
checkpoint = ModelCheckpoint(filepath, monitor='val_acc', verbose=1, save_best_only=True, mode='max')
callbacks_list = [checkpoint]

estimator = KerasClassifier(build_fn=baseline_model, validation_split=0.33, nb_epoch=200, batch_size=5, callbacks=callbacks_list, verbose=0)
kfold = KFold(n_splits=10, shuffle=True, random_state=seed)
results = cross_val_score(estimator, X, dummy_y, cv=kfold)
print("Baseline: %.2f%% (%.2f%%)" % (results.mean()*100, results.std()*100))
</code>```

This script produced the following error. I don't know how to troubleshoot it or maybe my arrangement in the script is wrong.

```<code>RuntimeError: Cannot clone object <keras.wrappers.scikit_learn.KerasClassifier object at 0x10e120fd0>, as the constructor does not seem to set parameter callbacks
</code>```

I hope somebody can help me with this. Thank you.

答:
Instead of KerasClassifier, use the model itself.</p>

```<code>model = baseline_model()
#declare your callback methods here
model.fit(x,y, batch_size=32, verbose=0, epochs=10, shuffle=True, validation_split = 0.1, callbacks = <your list of callbacks>)
</code>```

Body:
I need help in implementing the checkpoint function in Keras. I am going to train a large dataset so in order to do that, first I trained a model using the iris flower dataset : http://machinelearningmastery.com/multi-class-classification-tutorial-keras-deep-learning-library/

since my own dataset is a lot similar to it only the difference is that my dataset is more bigger.

For the checkpoint function : http://machinelearningmastery.com/check-point-deep-learning-models-keras/

I understand the example using pima-indians dataset.
Now I am trying to implement the same checkpoint function in the iris-flower script. Here is what I tried so far.

import numpy
from pandas import *
from keras.models import Sequential
from keras.layers import Dense
from keras.wrappers.scikit_learn import KerasClassifier
from keras.utils import np_utils
from sklearn.model_selection import cross_val_score, KFold
from sklearn.preprocessing import LabelEncoder
from sklearn.pipeline import Pipeline
from keras.callbacks import ModelCheckpoint

seed = 7
numpy.random.seed(seed)

dataframe = read_csv("iris.csv", header=None)
dataset = dataframe.values
X = dataset[:,0:4].astype(float)
Y = dataset[:,4]

# encode class value as integers
encoder = LabelEncoder()
encoder.fit(Y)
encoded_Y = encoder.transform(Y)
dummy_y = np_utils.to_categorical(encoded_Y)

def baseline_model():
    model = Sequential()
    model.add(Dense(4, input_dim=4, init='normal', activation='relu'))
    model.add(Dense(3, init='normal', activation='sigmoid'))
    model.compile(loss='categorical_crossentropy', optimizer='adam', metrics=['accuracy'])
    return model

filepath="weights-improvement-{epoch:02d}-{val_acc:.2f}.hdf5"
checkpoint = ModelCheckpoint(filepath, monitor='val_acc', verbose=1, save_best_only=True, mode='max')
callbacks_list = [checkpoint]

estimator = KerasClassifier(build_fn=baseline_model, validation_split=0.33, nb_epoch=200, batch_size=5, callbacks=callbacks_list, verbose=0)
kfold = KFold(n_splits=10, shuffle=True, random_state=seed)
results = cross_val_score(estimator, X, dummy_y, cv=kfold)
print("Baseline: %.2f%% (%.2f%%)" % (results.mean()*100, results.std()*100))

This script produced the following error. I don't know how to troubleshoot it or maybe my arrangement in the script is wrong.

RuntimeError: Cannot clone object <keras.wrappers.scikit_learn.KerasClassifier object at 0x10e120fd0>, as the constructor does not seem to set parameter callbacks

I hope somebody can help me with this. Thank you.

Body:
Instead of KerasClassifier, use the model itself.

model = baseline_model()
#declare your callback methods here
model.fit(x,y, batch_size=32, verbose=0, epochs=10, shuffle=True, validation_split = 0.1, callbacks = <your list of callbacks>)


问:
Is it possible to set standard output in Java both to a file and to the standard output?
There is a Java command to redirect standard output to a file or back to the
 standart output:

```<code>PrintStream stdout = System.out;
System.setOut(new PrintStream(logFile));
// ...
System.setOut(stdout);
</code>```

But I need to have both of them. Is it possible to set standard output in Java both to the file and to the standard output?

答:
Use a Logger. If needed with a Layout just giving the input.
Then you can, even in code add both a ConsoleAppender and a FileAppender.

Also better code style. And that "logFile" is telling.

Body:
There is a Java command to redirect standard output to a file or back to the
 standart output:

PrintStream stdout = System.out;
System.setOut(new PrintStream(logFile));
// ...
System.setOut(stdout);

But I need to have both of them. Is it possible to set standard output in Java both to the file and to the standard output?


问:
Load testing Bot builder bot

Update

Using emulator as channelId and updating to SDK 3.13.1 works for me.

App ID: 8c082f92-fb38-4841-a29f-339eb315f7aa

SDK Platform: Node.js

SDK Version: 3.13.1

Active Channels: Facebook

Deployment Environment: ngrok

Issue Description

I tried following steps mentioned in this link. This has two parts. One is creating the token and second is to send a message to the bot. POSTMAN request leads to 500 Internal Server Error and ERROR: ChatConnector: receive - invalid signing key or OpenId metadata document in the code.

Code Example

Create token

```<code> curl -X POST  https://login.microsoftonline.com/botframework.com/oauth2/v2.0/token   -H 'cache-control: no-cache' -H 'content-type: application/x-www-form-urlencoded'  -H 'postman-token: 792660ab-b1aa-0cbd-edab-9b3847c170d5'  -d 'grant_type=client_credentials&client_id=8c082f92-fb38-4841-a29f-339eb315f7aa&client_secret=vxcihBT2679%7C(%23puEXBPT1!&scope=8c082f92-fb38-4841-a29f-339eb315f7aa%2F.default'
</code>```

Send a message

```<code> curl -X POST https://1c36f336.ngrok.io/api/messages -H 'authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6Ing0Nzh4eU9wbHNNMUg3TlhrN1N4MTd4MXVwYyJ9.eyJhdWQiOiI4YzA4MmY5Mi1mYjM4LTQ4NDEtYTI5Zi0zMzllYjMxNWY3YWEiLCJpc3MiOiJodHRwczovL2xvZ2luLm1pY3Jvc29mdG9ubGluZS5jb20vZDZkNDk0MjAtZjM5Yi00ZGY3LWExZGMtZDU5YTkzNTg3MWRiL3YyLjAiLCJpYXQiOjE1MTIxOTg2NjcsIm5iZiI6MTUxMjE5ODY2NywiZXhwIjoxNTEyMjAyNTY3LCJhaW8iOiJZMk5nWUZEOHRySzgvZk9XcDF2L1BMM2JibnRGRGdBPSIsImF6cCI6IjhjMDgyZjkyLWZiMzgtNDg0MS1hMjlmLTMzOWViMzE1ZjdhYSIsImF6cGFjciI6IjEiLCJ0aWQiOiJkNmQ0OTQyMC1mMzliLTRkZjctYTFkYy1kNTlhOTM1ODcxZGIiLCJ1dGkiOiJXLWdYbXpPSkxVYWdzSFZUbXBJd0FBIiwidmVyIjoiMi4wIn0.G705tzQIU5Mh6IROtXkIwm8Q9AKZ_q-VOtJuuozqP-ekhWoKc0HpcdhgBlnaMsMHKoM0RWhUlXn27xCfK46vEE9IZlkjcAh7huhvlWNtW8IP5w7QiL3JCSTYKCtBXZq-VKeWctNWR9M8Y9Ry4dyiEdcDMcHWrbOUqR6nXvlwG76GSR4YilqzMWdSW6t5Pep3hwOw07DSargYP0pDAnWAg3pWHnhcJ185533I1VVXEIuc_CK-RmP9qhUAScEbYkpp_7l75bVWzxKv-3E1UOG4SBj6UzfH47X5kwz_njn1kAJcrqBvP3s_CjS4qUdDSNARtxGZ3UQWj49UBKosqar0dg' -H 'cache-control: no-cache' -H 'content-type: application/json' -H 'postman-token: 3a74ce00-2da7-d674-5e4c-083f54ed30ff' -d '{ "type": "message", "id": "mid.$cAAGEkG8MNm1mOEBe-lgBvsWZbQUc", "channelId" : "test",  "conversation": { "id": "100023023852067-526013297749070"}, "from": { "id": "100023023852067" }, "recipient": { "id": "526013297749070" },  "serviceUrl": "https://1c36f336.ngrok.io", "text": "Hi message from postman !!!" }'
</code>```

Reproduction Steps

Using the two curl requests mentioned above. This should lead to the mentioned issue.

Expected Behavior

POSTMAN request should lead to 202 Accepted and bot receiving the message. Am I missing something or is there something wrong in the process? I saw some  issues  on load testing but none of them helped.

Actual Results

POSTMAN request leads to 500 Internal Server Error and ERROR: ChatConnector: receive - invalid signing key or OpenId metadata document in the code.

答:
Not sure if this will help, but if you're using the same "fromId" in every request for your load test, it might be relevant.

Previously I've had a similar issue that required me to use a unique "fromId" in each request, else a series of requests in rapid succession start to fail.

I raised this issue on github, and although it says "followed up offline" and "problem was with the bot code", it was actually due to using the same "fromId" in every request.

The issue is here: https://github.com/Microsoft/BotBuilder/issues/1176

Title: Load testing Bot builder bot

Body:
Update

Using emulator as channelId and updating to SDK 3.13.1 works for me.

App ID: 8c082f92-fb38-4841-a29f-339eb315f7aa

SDK Platform: Node.js

SDK Version: 3.13.1

Active Channels: Facebook

Deployment Environment: ngrok

Issue Description

I tried following steps mentioned in this link. This has two parts. One is creating the token and second is to send a message to the bot. POSTMAN request leads to 500 Internal Server Error and ERROR: ChatConnector: receive - invalid signing key or OpenId metadata document in the code.

Code Example

Create token

 curl -X POST  https://login.microsoftonline.com/botframework.com/oauth2/v2.0/token   -H 'cache-control: no-cache' -H 'content-type: application/x-www-form-urlencoded'  -H 'postman-token: 792660ab-b1aa-0cbd-edab-9b3847c170d5'  -d 'grant_type=client_credentials&client_id=8c082f92-fb38-4841-a29f-339eb315f7aa&client_secret=vxcihBT2679%7C(%23puEXBPT1!&scope=8c082f92-fb38-4841-a29f-339eb315f7aa%2F.default'

Send a message

 curl -X POST https://1c36f336.ngrok.io/api/messages -H 'authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6Ing0Nzh4eU9wbHNNMUg3TlhrN1N4MTd4MXVwYyJ9.eyJhdWQiOiI4YzA4MmY5Mi1mYjM4LTQ4NDEtYTI5Zi0zMzllYjMxNWY3YWEiLCJpc3MiOiJodHRwczovL2xvZ2luLm1pY3Jvc29mdG9ubGluZS5jb20vZDZkNDk0MjAtZjM5Yi00ZGY3LWExZGMtZDU5YTkzNTg3MWRiL3YyLjAiLCJpYXQiOjE1MTIxOTg2NjcsIm5iZiI6MTUxMjE5ODY2NywiZXhwIjoxNTEyMjAyNTY3LCJhaW8iOiJZMk5nWUZEOHRySzgvZk9XcDF2L1BMM2JibnRGRGdBPSIsImF6cCI6IjhjMDgyZjkyLWZiMzgtNDg0MS1hMjlmLTMzOWViMzE1ZjdhYSIsImF6cGFjciI6IjEiLCJ0aWQiOiJkNmQ0OTQyMC1mMzliLTRkZjctYTFkYy1kNTlhOTM1ODcxZGIiLCJ1dGkiOiJXLWdYbXpPSkxVYWdzSFZUbXBJd0FBIiwidmVyIjoiMi4wIn0.G705tzQIU5Mh6IROtXkIwm8Q9AKZ_q-VOtJuuozqP-ekhWoKc0HpcdhgBlnaMsMHKoM0RWhUlXn27xCfK46vEE9IZlkjcAh7huhvlWNtW8IP5w7QiL3JCSTYKCtBXZq-VKeWctNWR9M8Y9Ry4dyiEdcDMcHWrbOUqR6nXvlwG76GSR4YilqzMWdSW6t5Pep3hwOw07DSargYP0pDAnWAg3pWHnhcJ185533I1VVXEIuc_CK-RmP9qhUAScEbYkpp_7l75bVWzxKv-3E1UOG4SBj6UzfH47X5kwz_njn1kAJcrqBvP3s_CjS4qUdDSNARtxGZ3UQWj49UBKosqar0dg' -H 'cache-control: no-cache' -H 'content-type: application/json' -H 'postman-token: 3a74ce00-2da7-d674-5e4c-083f54ed30ff' -d '{ "type": "message", "id": "mid.$cAAGEkG8MNm1mOEBe-lgBvsWZbQUc", "channelId" : "test",  "conversation": { "id": "100023023852067-526013297749070"}, "from": { "id": "100023023852067" }, "recipient": { "id": "526013297749070" },  "serviceUrl": "https://1c36f336.ngrok.io", "text": "Hi message from postman !!!" }'

Reproduction Steps

Using the two curl requests mentioned above. This should lead to the mentioned issue.

Expected Behavior

POSTMAN request should lead to 202 Accepted and bot receiving the message. Am I missing something or is there something wrong in the process? I saw some  issues  on load testing but none of them helped.

Actual Results

POSTMAN request leads to 500 Internal Server Error and ERROR: ChatConnector: receive - invalid signing key or OpenId metadata document in the code.