eReviewBoard can't raise review request - eclipse

I have my reviewboard 1.7 configured and I am using eReviewBoard and Subclipse plugins in Eclipse IDE.
The issue is when I try to raise the review request it fails giving "timed out" as "Failed creating new review request : Exception executing PutMethod on http://10.203.3.244/api/review-requests/380/draft/ : Read timed out"
When I checked the info at "http://10.203.3.244/api/review-requests/380" I can't find the PUT method for "http://10.203.3.244/api/review-requests/380/draft" instead it is only for "http://10.203.3.244/api/review-requests/380"
Below is the xml:
<?xml version="1.0" encoding="utf-8"?>
<rsp>
<stat>ok</stat>
<review_request>
<status>pending</status>
<last_updated>2014-01-22T07:38:34Z</last_updated>
<description>Testing... </description>
<links>
<diffs>
<href>http://10.203.3.244/api/review-requests/380/diffs/</href>
<method>GET</method>
</diffs>
<repository>
<href>http://10.203.3.244/api/repositories/3/</href>
<method>GET</method>
<title>M2M Repository</title>
</repository>
<screenshots>
<href>http://10.203.3.244/api/review-requests/380/screenshots/</href>
<method>GET</method>
</screenshots>
<self>
<href>http://10.203.3.244/api/review-requests/380/</href>
<method>GET</method>
</self>
<update>
<href>http://10.203.3.244/api/review-requests/380/</href>
<method>PUT</method>
</update>
<last_update>
<href>http://10.203.3.244/api/review-requests/380/last-update/</href>
<method>GET</method>
</last_update>
<reviews>
<href>http://10.203.3.244/api/review-requests/380/reviews/</href>
<method>GET</method>
</reviews>
<draft>
<href>http://10.203.3.244/api/review-requests/380/draft/</href>
<method>GET</method>
</draft>
<file_attachments>
<href>http://10.203.3.244/api/review-requests/380/file-attachments/</href>
<method>GET</method>
</file_attachments>
<submitter>
<href>http://10.203.3.244/api/users/amritpal/</href>
<method>GET</method>
<title>amritpal</title>
</submitter>
<changes>
<href>http://10.203.3.244/api/review-requests/380/changes/</href>
<method>GET</method>
</changes>
<delete>
<href>http://10.203.3.244/api/review-requests/380/</href>
<method>DELETE</method>
</delete>
</links>
I don't know what to do next. I understand this info is generated and read by the plugin itself??!!
Has anyone faced this issue?

It looks like you raised this issue with the project, which is what I was going to recommend you do:
https://github.com/rombert/ereviewboard/issues/129

Related

How to delete a file with the Pentaho REST API

My Pentaho REST API is working expected for one feature : delete folder or file, I tried this syntax and some others but it didn't work :
PUT method : http://my-server/pentaho/api/repo/files/delete/public:basic.xml
I tried to change the method (DELETE) and other syntax but nothing worked
According to the documentation you PUT to:
/repo/files/delete
or
/repo/files/deletepermanent
with the body:
A comma-separated list of the files to be moved to the trash folder
or
A comma-separated list of the files to be deleted
Your PUT request should be :
http://servername.domain.com:8080/pentaho/api/repo/files/delete
and in the request body you need to put ID of deleted file.
This ID you can get making request like :
http://servername.domain.com:8080/pentaho/api/repo/files/home/karp/ARCH/children?locale=en
Answer will be similar to :
<?xml version="1.0" encoding="UTF-8" standalone="true"?>
<repositoryFileDtoes>
<repositoryFileDto>
<aclNode>false</aclNode>
<createdDate>1579701212208</createdDate>
<fileSize>8923</fileSize>
<folder>false</folder>
<hidden>false</hidden>
<id>6f43abcc-0e05-4dbe-8bf9-fc383a9e7983</id>
<lastModifiedDate>1579701212208</lastModifiedDate>
<locale>pl</locale>
<localePropertiesMapEntries>
<locale>default</locale>
<properties>
<key>file.title</key>
<value>Ankieta_po</value>
</properties>
<properties>
<key>jcr:primaryType</key>
<value>nt:unstructured</value>
</properties>
<properties>
<key>title</key>
<value>Ankieta_po</value>
</properties>
</localePropertiesMapEntries>
<locked>false</locked>
<name>Ankieta_po.prpt</name>
<notSchedulable>false</notSchedulable>
<ownerType>-1</ownerType>
<path>/home/karp/ARCH/Ankieta_po.prpt</path>
<title>Ankieta_po</title>
<versionCommentEnabled>false</versionCommentEnabled>
<versionId>1.1</versionId>
<versioned>true</versioned>
<versioningEnabled>false</versioningEnabled>
</repositoryFileDto>
</repositoryFileDtoes>
So , your request should looks like this (below from Postman) :
enter image description here

Unable to register Kie Server with Kie Workbench

"I'm setting up Kie Workbench 7.5 and Kie Server 7.5 both into tomcat 8.
But "Remote Servers" is showing blank list.
For installation reference I used http://blog.athico.com/2015/10/installing-kie-server-and-workbench-on.html this blog.
Once I hit http://localhost:8080/kie-server/services/rest/server this URL I am getting expected output as below:
<response type="SUCCESS" msg="Kie Server info">
<kie-server-info>
<capabilities>KieServer</capabilities>
<capabilities>BRM</capabilities>
<capabilities>BPM</capabilities>
<capabilities>CaseMgmt</capabilities>
<capabilities>BPM-UI</capabilities>
<capabilities>BRP</capabilities>
<capabilities>DMN</capabilities>
<capabilities>Swagger</capabilities>
<location>
http://localhost:8080/kie-server/services/rest/server
</location>
<name>tomcat-kieserver</name>
<id>tomcat-kieserver</id>
<version>7.5.0.Final</version>
</kie-server-info>
</response>
Configuration which I proviced
1. setenv.bat
set CATALINA_OPTS=-Xmx512M -Djbpm.tsr.jndi.lookup=java:comp/env/TransactionSynchronizationRegistry -Dorg.kie.server.persistence.ds=java:comp/env/jdbc/jbpm -Djbpm.tm.jndi.lookup=java:comp/env/TransactionManager -Dorg.kie.server.persistence.tm=JBossTS -Dhibernate.connection.release_mode=after_transaction -Dorg.kie.server.id=tomcat-kieserver -Djava.security.auth.login.config=C:/softwares/apache-tomcat-8.5.43/webapps/kie-drools-wb/WEB-INF/classes/login.config -Dorg.kie.server.location=http://localhost:8080/kie-server/services/rest/server -Dorg.kie.server.controller=http://localhost:8080/kie-drools-wb/rest/controller -Dcom.arjuna.ats.jta.recovery.XAResourceRecovery1=com.arjuna.ats.internal.jdbc.recovery.BasicXARecovery;abs://C:/softwares/apache-tomcat-8.5.43/conf/xa-recovery-properties.xml
2. server.xml
<Valve className="org.kie.integration.tomcat.JACCValve" />
3. context.xml
<Resource name="sharedDataSource"
auth="Container"
type="org.h2.jdbcx.JdbcDataSource"
user="sa"
password="sa"
url="jdbc:h2:mem:testdb;DB_CLOSE_DELAY=-1;MVCC=TRUE"
description="H2 Data Source"
loginTimeout="0"
testOnBorrow="false"
factory="org.h2.jdbcx.JdbcDataSourceFactory"/>
4. xa-recovery-properties.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
<properties>
<entry key="DB_1_DatabaseUser">sa</entry>
<entry key="DB_1_DatabasePassword">sa</entry>
<entry key="DB_1_DatabaseDynamicClass"></entry>
<entry key="DB_1_DatabaseURL">java:comp/env/h2DataSource</entry>
</properties>
On Tomcat console I am getting below warning:
WARNING [KieServer-ControllerConnect] org.kie.server.services.impl.controller.DefaultRestControllerImpl.connectToSingleController Exception encountered while syncing with controller at http://localhost:8080/kie-drools-wb/rest/controller/server/tomcat-kieserver error Error while sending PUT request to http://localhost:8080/kie-drools-wb/rest/controller/server/tomcat-kieserver response code 401
Workbench 7.0+ is not support Tomcat any more. If you want to use Workbench (it is already renamed to Business Central and has latest version 7.24) it should run on Wildfly 14.
You can try this quick start (just unzip file and it is ready to try or copy configurations): https://www.jbpm.org/learn/gettingStarted.html
If you need to start Workbench on Tomcat, you should use 6.x (which is not supported any more).

nested loops TXMLMap Talend

I have a problem when I'm trying to read XML from tRestclient > tXMLMap
tRestclient GET message :
<content type="application/xml">
<mSmiley Tongueroperties>
<d:FileSystemObjectType >0</d:FileSystemObjectType>
<d:Id>13</d:Id>
<d:Title>health</d:Title>
<d:c3vxId m:type="Collection(Edm.Int32)">
<d:element>198</d:element>
<d:element>101</d:element>
</d:c3vxId>
</properties>
<properties>
<d:FileSystemObjectType >1</d:FileSystemObjectType>
<d:Id>13</d:Id>
<d:Title>human</d:Title>
<d:c3vxId m:type="Collection(Edm.Int32)">
<d:element>200</d:element>
<d:element>101</d:element>
</d:c3vxId>
</properties>
<properties>
<d:FileSystemObjectType >2</d:FileSystemObjectType>
<d:Id>13</d:Id>
<d:Title>technology</d:Title>
<d:c3vxId m:type="Collection(Edm.Int32)">
<d:element>108</d:element>
<d:element>101</d:element>
</d:c3vxId>
</pperties>
</content
the problem is that I can't loop on because it's a child node.
Do you have any solutions for this please ?
thank's
Data Integration

Spring Integration graph editor tab in Spring Tool Suite loses "manual-mode" edits when edit raw XML source

I'm currently using Spring Tool Suite (STS) (Version: 3.6.4.201412021321-CI-B775, Build Id: 201411281415, Platform: Eclipse Luna SR1 (4.4.1)) with Spring Integration 4.1.0.
I have a Spring configuration XML file that includes the Spring Integration namespace. I have a large workflow that is difficult to get to layout nicely on the integration-graph with "automatic layout" mode. As such I did the following:
Went into the integration-graph tab and used "manual layout" mode to
organize my graph then I saved that layout.
Went back to the "source" tab and added some components to the XML
file and saved the file.
Upon returning to the integration-graph tab the "manual layout" is
still selected (as it was when I last left that screen) but my
original "manual layout" mode changes are no longer saved.
Returning to "automatic layout" mode then switching back to "manual
layout" mode doesn't seem to help. The issue also happens even if
you just change a space or delete/re-add a character to the raw XML
file (basically if the XML file is modified at all).
To reproduce use this XML context.
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context" xmlns:int="http://www.springframework.org/schema/integration" xmlns:task="http://www.springframework.org/schema/task" xsi:schemaLocation="http://www.springframework.org/schema/integration http://www.springframework.org/schema/integration/spring-integration.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task.xsd">
<int:inbound-channel-adapter id="fileAdapter" ref="fileReadingMessageSource" method="receive" auto-startup="true" channel="files">
<int:poller fixed-delay="#{T(java.lang.Integer).MAX_VALUE}" />
</int:inbound-channel-adapter>
<bean id="fileReadingMessageSource" class="org.springframework.integration.file.FileReadingMessageSource">
<property name="directory" value="C:/Users/af25830/Desktop/tmg-exchange-gateway-nam/t2" />
</bean>
<int:channel id="files" />
<int:logging-channel-adapter id="logger" level="INFO" logger-name="fileLogger" channel="files" auto-startup="false" />
</beans>
Initially graph looks like this:
.settings/com.springsource.sts.config.flow.prefs contains:
//com.springsource.sts.config.flow.coordinates\:http\://www.springframework.org/schema/integration\:/spring-integration-test/src/main/resources/META-INF/spring/integration/spring-integration-test-context.xml=<?xml version\="1.0" encoding\="UTF-8"?>\r\n<graph>\r\n<element clazz\="InboundChannelAdapterModelElement" type\="inbound-channel-adapter">\r\n<structure end\="1038" endstart\="1008" start\="809" startend\="939"/>\r\n<bounds height\="118" width\="120" x\="19" y\="17"/>\r\n</element>\r\n<element clazz\="ChannelModelElement" type\="channel">\r\n<structure end\="1280" endstart\="1280" start\="1254" startend\="1280"/>\r\n<bounds height\="118" width\="120" x\="159" y\="17"/>\r\n</element>\r\n<element clazz\="LoggingChannelAdapterModelElement" type\="logging-channel-adapter">\r\n<structure end\="1401" endstart\="1401" start\="1283" startend\="1401"/>\r\n<bounds height\="118" width\="120" x\="299" y\="17"/>\r\n</element>\r\n</graph>
Enter "manual layout" and move something to get it to look similar to this:
.settings/com.springsource.sts.config.flow.prefs contains:
//com.springsource.sts.config.flow.coordinates\:http\://www.springframework.org/schema/integration\:/spring-integration-test/src/main/resources/META-INF/spring/integration/spring-integration-test-context.xml=<?xml version\="1.0" encoding\="UTF-8"?>\r\n<graph>\r\n<element clazz\="InboundChannelAdapterModelElement" type\="inbound-channel-adapter">\r\n<structure end\="1038" endstart\="1008" start\="809" startend\="939"/>\r\n<bounds height\="118" width\="120" x\="19" y\="17"/>\r\n</element>\r\n<element clazz\="ChannelModelElement" type\="channel">\r\n<structure end\="1280" endstart\="1280" start\="1254" startend\="1280"/>\r\n<bounds height\="118" width\="120" x\="159" y\="17"/>\r\n</element>\r\n<element clazz\="LoggingChannelAdapterModelElement" type\="logging-channel-adapter">\r\n<structure end\="1401" endstart\="1401" start\="1283" startend\="1401"/>\r\n<bounds height\="118" width\="120" x\="337" y\="148"/>\r\n</element>\r\n</graph>
Go to the "source" tab and make any change (delete a char and re-add it). Save file.
.settings/com.springsource.sts.config.flow.prefs contains:
//com.springsource.sts.config.flow.coordinates\:http\://www.springframework.org/schema/integration\:/spring-integration-test/src/main/resources/META-INF/spring/integration/spring-integration-test-context.xml=<?xml version\="1.0" encoding\="UTF-8"?>\r\n<graph>\r\n<element clazz\="InboundChannelAdapterModelElement" type\="inbound-channel-adapter">\r\n<structure end\="1038" endstart\="1008" start\="809" startend\="939"/>\r\n<bounds height\="118" width\="120" x\="19" y\="17"/>\r\n</element>\r\n<element clazz\="ChannelModelElement" type\="channel">\r\n<structure end\="1280" endstart\="1280" start\="1254" startend\="1280"/>\r\n<bounds height\="118" width\="120" x\="159" y\="17"/>\r\n</element>\r\n<element clazz\="LoggingChannelAdapterModelElement" type\="logging-channel-adapter">\r\n<structure end\="1401" endstart\="1401" start\="1283" startend\="1401"/>\r\n<bounds height\="118" width\="120" x\="299" y\="17"/>\r\n</element>\r\n</graph>
Return to integration-graph tab and go to "manual layout" mode, you'll see your changes are now reverted.
This is very commonly done and as-such it would be nice if "manual layout" edits didn't get reverted whenever the raw XML file gets edited.
Am I missing a step that would prevent that from happening?

Transaction commit delay when routing message from one jms queue to another

We are trying to build simple transacted jms-to-jms router using Mule ESB and JBoss Messaging. When we run Mule ESB with application configured as below, we observe strange behaviour.
Approximately 10 messages are routed from queue test1 to test2
Nothing happens for ~40 seconds.
goto 1
Queue test1 is filled with around 500 messages when we start test. We use Mule 3.2 and JBoss 5.1.
If I remove transactions from code below everything works fine, all messages are sent to queue test2 instantly. Also, everything is fine if I change transactions from xa to jms -- by replacing xa-transaction tags with jms:transaction.
I don't know what causes this pause in message processing on ESB, probably transaction commit is delayed.
My question is: what should I do to have xa transactions working correctly?
I'll provide more details if needed. I asked this question on Mule ESB forum before with no answer http://forum.mulesoft.org/mulesoft/topics/transaction_commit_delay_when_routing_message_from_one_jms_queue_to_another
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:jms="http://www.mulesoft.org/schema/mule/jms" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" xmlns:core="http://www.mulesoft.org/schema/mule/core" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jbossts="http://www.mulesoft.org/schema/mule/jbossts" version="CE-3.2.1" xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/jms http://www.mulesoft.org/schema/mule/jms/current/mule-jms.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/jbossts http://www.mulesoft.org/schema/mule/jbossts/current/mule-jbossts.xsd ">
<jbossts:transaction-manager> </jbossts:transaction-manager>
<configuration>
<default-threading-profile maxThreadsActive="30" maxThreadsIdle="5"/>
<default-receiver-threading-profile maxThreadsActive="10" maxThreadsIdle="5"/>
</configuration>
<spring:beans>
<spring:bean id="jmsJndiTemplate" class="org.springframework.jndi.JndiTemplate" doc:name="Bean">
<spring:property name="environment">
<spring:props>
<spring:prop key="java.naming.factory.url.pkgs">org.jboss.naming:org.jnp.interfaces</spring:prop>
<spring:prop key="jnp.disableDiscovery">true</spring:prop>
<spring:prop key="java.naming.factory.initial">org.jnp.interfaces.NamingContextFactory</spring:prop>
<spring:prop key="java.naming.provider.url">localhost:1099</spring:prop>
</spring:props>
</spring:property>
</spring:bean>
<spring:bean id="jmsConnectionFactory" class="org.springframework.jndi.JndiObjectFactoryBean" doc:name="Bean">
<spring:property name="jndiTemplate">
<spring:ref bean="jmsJndiTemplate"/>
</spring:property>
<spring:property name="jndiName">
<spring:value>XAConnectionFactory</spring:value>
</spring:property>
</spring:bean>
</spring:beans>
<jms:connector name="JMS" specification="1.1" numberOfConsumers="10" connectionFactory-ref="jmsConnectionFactory" doc:name="JMS"/>
<flow name="flow" doc:name="flow">
<jms:inbound-endpoint queue="test1" connector-ref="JMS" doc:name="qt1">
<xa-transaction action="ALWAYS_BEGIN"/>
</jms:inbound-endpoint>
<echo-component doc:name="Echo"/>
<jms:outbound-endpoint queue="test2" connector-ref="JMS" doc:name="qt2">
<xa-transaction action="ALWAYS_JOIN"/>
</jms:outbound-endpoint>
<echo-component doc:name="Echo"/>
</flow>
</mule>
Here you can find log fragment for 1 message interaction. Please note that in this case there was no delay.
And here is log fragment for 11 messages. All of them were in queue test1 when app started, as you can see 10 messages are routed instantly and one is delayed by 1 minute.
I've found root of my problem: my queues were defined with following attribute:
<attribute name="RedeliveryDelay">60000</attribute>
Removing it or setting low value solves my problem with delays. Problem is, I don't know why :)
I always thought that redelivery delay is used when delivery fails, which was not the case in my app.