QuickFix rejecting messages with error "Out of order repeating group members" - quickfix

We are using QuickFix to extract trades and orders from ICE exchange. The current .NET application which is fetching the security definition requests is running quite fine. Our task is to migrate the application to Scala. While submitting the security definition request QuickFIx is rejecting the messages with "Out of order repeating group members" error .
Request : 8=FIX.4.2_9=51_35=c_48=0_167=FUT_320=XXX_Security_Request 0_321=3_10=175
QuickFix is rejecting with message : 8=FIX.4.2_9=132_35=3_34=12_49=xxxx_50=xxxxxx_52=20200805-10:49:01.193_56=ICE_45=12_58=Out of order repeating group members, field=305_371=305_372=d_10=097_
Session config settings:
[DEFAULT]
ConnectionType=initiator
StartTime=00:00:00
EndTime=23:59:59
FileLogPath=log
FileStorePath=store
SocketConnectPort=*****
SocketConnectHost=*****
ResetOnLogon=Y
ResetOnDisconnect=Y
AllowUnknownMsgFields=Y
ReconnectInterval=8
ValidateIncomingMessages=N
FileLogPath=.\Log\FixLog
FileLogBackupPath=.\Log\Backup
[SESSION]
BeginString=FIX.4.2
SenderCompID=****
TargetCompID=ICE
HeartBtInt=30
SenderSubID=******
UseDataDictionary=Y
DataDictionary=.\Config\FIX42.xml
ReconnectInterval=8
ValidateUserDefinedFields=N
AllowUnknownMsgFields=Y
ValidateFieldsOutOfOrder=N
We are using same FIX dictionary(FIX42.xml) as the currently running .NET application so not sure how the this is happening. Could someone please help us in resolving this ?

Related

wso2 API Endpoint creation failed: 404 ressource not found

I am trying to create a REST API with wso2 API_Manager to gather data from a Postgres database (learning purpose). I struggle doing so and I would like to know whether:
I did not understand wso2 components' roles properly (new techno and subject for me)
or there is an error in the way I configured the manager.
System setup
I used this official docker image, added postgres jdbc jar in /repository/components/lib/ and added the following in /repository/conf/datasources/master-datasources.xml:
<datasource>
<name>s0m3dAtabas3</name>
<description>The db used for testing purposes</description>
<definition type="RDBMS">
<configuration>
<url>jdbc:postgresql://sandor_postgres:5432/s0m3dAtabas3</url>
<driverClassName>org.postgresql.Driver</driverClassName>
<username>s0m3us3rfr0mdAtAMaj0r</username>
<password>N0t5uchAs1mple1</password>
<maxActive>80</maxActive>
<minIdle>5</minIdle>
<maxWait>60000</maxWait>
<defaultAutoCommit>false</defaultAutoCommit>
<testOnBorrow>true</testOnBorrow>
<validationInterval>30000</validationInterval>
</configuration>
</definition>
</datasource>
I made sure than the postgres' container named sandor_postgres is accessible from wso2's with these credentials. In this database, I have a table called something. The image comes with the following UIs:
admin
publisher
store
Graphical API creation
I first followed the WorldBank tutorial which seemed crystal clear (though I am not quite sure where the data came from). I then tried to adapt it.
Step 1: Design
I used the database name as context (s0m3dAtabas3) v.1.0.0. Since the table is called something, the url pattern I end up with is /s0m3dAtabas3/1.0.0/something
Step 2: Implement
This is where things start to be confusing. No matter the resource path I use in the Endpoint (end point type REST), I get a 404 and the logs are not very helpful
http://192.168.8.111:8280 -> 404
http://192.168.8.111:8280/something -> 404
http://192.168.8.111:9443/tried_several -> Invalid - Error connecting to backend
http://192.168.8.111:8243/tried_several -> Invalid - Error connecting to backend
INFO - InboundDBSyncRequestEvent Running DB sync task.
INFO - LogMediator STATUS = Message dispatched to the main sequence. Invalid URL., RESOURCE = /s0m3dAtabas3/1.0.0
INFO - CarbonAuthenticationUtil 'admin#carbon.super [-1234]' logged in at [2019-10-29 11:42:31,030+0000]
INFO - CarbonAuthenticationUtil 'admin#carbon.super [-1234]' logged in at [2019-10-29 11:42:31,197+0000]
INFO - LogMediator STATUS = Message dispatched to the main sequence. Invalid URL., RESOURCE = /s0m3dAtabas3/bullshit
INFO - CarbonAuthenticationUtil 'admin#carbon.super [-1234]' logged in at [2019-10-29 11:48:30,649+0000]
INFO - CarbonAuthenticationUtil 'admin#carbon.super [-1234]' logged in at [2019-10-29 11:48:30,790+0000]
INFO - LogMediator STATUS = Message dispatched to the main sequence. Invalid URL., RESOURCE = /
INFO - InboundDBSyncRequestEvent Running DB sync task.
INFO - LogMediator STATUS = Message dispatched to the main sequence. Invalid URL., RESOURCE = /
Did I miss some important configuration step or wso2 API Manager is not the standalone component I thought it was and requires another component to achieve what I am looking for?
It seems there is a misunderstanding in the concept-wise.
Here is the basic idea of a typical API Management solution.
You have a web service (REST, SOAP, etc...) which you need to expose as a managed API. Now, you can front your service with API Manager and expose it as a managed API with security, rate limiting, managed life cycle etc.
In your case, it seems you don't have such a service, but only have a database table. So, before using API Manager to front your service, you first need to expose your table as a service. For that purpose, I'd suggest you use the data service component of WSO2 EI 7.0.0. See [1] for how to do that. Once you have your service ready, you can use API Manager to expose it as a managed API.
[1] https://ei.docs.wso2.com/en/latest/micro-integrator/use-cases/tutorials/sending-a-simple-message-to-a-datasource/

AEM - Users not synched with User Synchronization using Sling Distribution

I do not see new user info (or updates to user profiles) being synched to/from Publish-Author.
When I create a new user on Publish, I can see that there is a “SimpleDistributionAgent” on Author.. but I cannot find the user in Author(searched entire crx).
I did all the osgi configs as detailed here:
https://docs.adobe.com/docs/en/aem/6-2/administer/security/security/sync.html
I do not see any error in the log…
Publish error.log
09.03.2017 14:27:41.711 *INFO* [127.0.0.1 [1489091261702] POST /libs/sling/distribution/services/exporters/socialpubsync-reverse HTTP/1.1] org.apache.sling.distribution.servlet.DistributionPackageExporterServlet Processed distribution export request in 8 ms: : fetched 1
09.03.2017 14:27:41.841 *INFO* [127.0.0.1 [1489091261793] POST /libs/sling/distribution/services/exporters/socialpubsync-reverse HTTP/1.1]
org.apache.sling.distribution.agent.impl.SimpleDistributionAgent [agent][socialpubsync-reverse] exported package distrpackage_1489091245609_7459cd18-91d9-404c-bb08-a296dd5d4aa4 with info DistributionPackageInfo{ request.type=ADD,
request.paths=[/home/users/C/C3Pz6GaEbUDD5-rdYr7Z/profile]} from queue default by exporter socialpubsync-reverse
Author error.log
09.03.2017 14:27:41.740 *INFO* [sling-default-19-scheduledEventTriggerorg.apache.sling.distribution.agent.impl.SimpleDistributionAgent$AgentBasedRequestHandler#7971f913]
org.apache.jackrabbit.vault.packaging.impl.JcrPackageDefinitionImpl unwrapping package sling/distribution:socialpubsync-vlt_1489091245573_674d4c01-853e-4c53-8828-31f63dda85d2:0.0.1
09.03.2017 14:27:41.801 *INFO* [sling-threadpool-70fe0a04-9496-4992-803d-ea75f39514ae-(apache-sling-job-thread-pool)-3-org_apache_sling_distribution_queue_socialpubsync_endpoint0(org/apache/sling/distribution/queue/socialpubsync/endpoint0)]
org.apache.sling.distribution.agent.impl.SimpleDistributionAgent [agent][socialpubsync] [endpoint0] PACKAGE-DELIVERED DSTRQ45:
ADD paths=[/home/users/C/C3Pz6GaEbUDD5-rdYr7Z/profile], importTime=6ms, execTime=879ms, size=5058B
No errors in Author and Publish Sync diagnostics
What am I missing?
User synchronization will not create users on Author. The sync is only between Publishers.
As of AEM 6.1, when user synchronization is enabled, user data is automatically synchronized across the publish instances in the farm and are not created on author.
https://docs.adobe.com/docs/en/aem/6-2/administer/security/security/sync.html
With the above setup, i started up 2 publish instances (4503, 4504) and when i create or update any user (or profile), the data is synched between both Publish instances.

ATG:Error while baseline indexing- Unable to process any CSF calls as the Credential Store server is not enabled

I am getting the following error while doing baseline index of my Endeca application in ATG
15:26:47,891 ERROR [nucleusNamespace.atg.dynamo.security.opss.csf.CredentialStoreManager] (Thread-201) Unable to process any CSF calls as the Credential Store server i
s not enabled. Please check log for more details
15:26:47,913 INFO [nucleusNamespace.atg.commerce.search.StoreLocationOutputConfig] (Thread-201) Starting bulk load
15:26:47,915 INFO [nucleusNamespace.atg.commerce.endeca.index.CategoryToDimensionOutputConfig] (index-/atg/commerce/endeca/index/ProductCatalogSimpleIndexingAdmin) Fa
iled to cancel incremental load of /atg/commerce/endeca/index/CategoryToDimensionOutputConfig, probably because no bulk load was running.
15:26:47,916 INFO [nucleusNamespace.atg.endeca.index.ConfigImportDocumentSubmitter] (Thread-203) Opening configuration repository connection for application logistore
15:26:47,917 ERROR [nucleusNamespace.atg.dynamo.security.opss.csf.CredentialStoreManager] (Thread-203) Unable to process any CSF calls as the Credential Store server i
s not enabled. Please check log for more details
15:26:47,916 INFO [nucleusNamespace.atg.commerce.search.ProductCatalogOutputConfig] (index-/atg/commerce/endeca/index/ProductCatalogSimpleIndexingAdmin) Failed to can
cel incremental load of /atg/commerce/search/ProductCatalogOutputConfig, probably because no bulk load was running.
15:26:47,917 INFO [nucleusNamespace.atg.commerce.search.StoreLocationOutputConfig] (index-/atg/commerce/endeca/index/ProductCatalogSimpleIndexingAdmin) Failed to canc
el incremental load of /atg/commerce/search/StoreLocationOutputConfig, probably because no bulk load was running.
15:26:47,919 INFO [nucleusNamespace.atg.endeca.index.ConfigImportDocumentSubmitter] (Thread-199) Opening configuration repository connection for application logistore
15:26:47,919 ERROR [nucleusNamespace.atg.dynamo.security.opss.csf.CredentialStoreManager] (Thread-199) Unable to process any CSF calls as the Credential Store server i
s not enabled. Please check log for more details
15:26:47,919 INFO [nucleusNamespace.atg.commerce.endeca.index.ProductCatalogSimpleIndexingAdmin] (Thread-203) Indexing process cancelled, Endeca says: Could not retri
eve workbench credential properties from credential store.
15:26:47,919 INFO [nucleusNamespace.atg.endeca.index.ConfigImportDocumentSubmitter] (Thread-207) Opening configuration repository connection for application logistore
15:26:47,920 ERROR [nucleusNamespace.atg.dynamo.security.opss.csf.CredentialStoreManager] (Thread-207) Unable to process any CSF calls as the Credential Store server i
s not enabled. Please check log for more details
15:26:47,921 INFO [nucleusNamespace.atg.commerce.endeca.index.ProductCatalogSimpleIndexingAdmin] (Thread-207) Indexing process cancelled, Endeca says: Could not retri
eve workbench credential properties from credential store.
After doing extensive research I found that C:\ATG\ATG11.2\home\servers\atg_production_lockserver\localconfig\atg\dynamo\server\OPSSInitializer.properties has path for jps-config.xml ie
JPSConfigurationLocation=C:/ATG/ATG11.2/home/../home/security/jps-config.xml
This jps-config.xml has some CSF related configuration.
How can I get rid of this error for successful baseline indexing.
I am stuck on this part.
This happens if you change the default workbench password. Simple solution would be, change Endeca experience manager password back to admin and try.
Otherwise, password needs to be changed in multiple places.
Thanks,
Ajay Agrawal
Go to the OPSSInitializer component in dyn admin and check whether the path for jps-config.xml specified is correct there. If not, correct the path.

Moqui - Connecting to an IMAP server over an SSL connection?

I am trying to poll an email server in Moqui 1.5.4. I am using org.moqui.impl.EmailServices.poll#EmailServer from the 'tools' application.
The email server is set up as follows:
<moqui.basic.email.EmailServer emailServerId="testEmail" mailUsername="test.account#xxxxxxx.ie" mailPassword="xxxxxxxx" smtpHost="" smtpPort="" smtpSsl="" storeHost="Webmail8.xxxxxxxxxxx.ie" storePort="993" storeProtocol="imap" storeDelete="N" />
All entries, passwords have been tested on Outlook and connect no problem to the server.
I get a javax.mail.AuthenticationFailedException.
Additional Information:
In initial tests I received the following error message, so I removed the 'static' modifier from the indicated line in the code. (I was not sure yet if it was an issue or if I may be doing something wrong.)
--- 98330 [ndlerThread[15]] WARN moqui.impl.context.TransactionFacadeImpl
Transaction rollback. The rollback was originally caused by: startup failed:
classpath_//org/moqui/impl/pollEmailServer_groovy: 28: Modifier 'static' not allowed here.
# line 28, column 1.
final static Logger logger = LoggerFactory.getLogger("org.moqui.impl.pollEmailServer")
Some things I tried to see if I could resolve the problem include:
setting storeProtocol="imaps"
including the smtp details in the EmailServer entry (note I only need to poll, not send mail).
adding the following line to pollEmailServer.groovy (having looked at the com.sun.mail.imap package).
sessionProperties.put("mail.imap.ssl.enable", true)
Full Authentication failed error message is:
Error running service [org.moqui.impl.EmailServices.poll#EmailServer] (Throwable)
javax.mail.AuthenticationFailedException
at javax.mail.Service.connect(Service.java:306)
at javax.mail.Service.connect(Service.java:156)
at javax.mail.Service.connect(Service.java:105)
at pollEmailServer_groovy.run(pollEmailServer_groovy:47)
at org.moqui.impl.context.runner.GroovyScriptRunner.run(GroovyScriptRunner.groovy:50)
at org.moqui.impl.context.ResourceFacadeImpl.script(ResourceFacadeImpl.groovy:337)
at org.moqui.impl.service.runner.ScriptServiceRunner.runService(ScriptServiceRunner.groovy:49)
at org.moqui.impl.service.ServiceCallSyncImpl.callSingle(ServiceCallSyncImpl.groovy:260)
at org.moqui.impl.service.ServiceCallSyncImpl.call(ServiceCallSyncImpl.groovy:137)
at ServiceRun_xml_transition_run_actions.run(ServiceRun_xml_transition_run_actions:10)
at org.moqui.impl.actions.XmlAction.run(XmlAction.groovy:99)
at org.moqui.impl.screen.ScreenDefinition$TransitionItem.run(ScreenDefinition.groovy:659)
at org.moqui.impl.screen.ScreenRenderImpl.recursiveRunTransition(ScreenRenderImpl.groovy:223)
at org.moqui.impl.screen.ScreenRenderImpl.recursiveRunTransition(ScreenRenderImpl.groovy:217)
at org.moqui.impl.screen.ScreenRenderImpl.recursiveRunTransition(ScreenRenderImpl.groovy:217)
at org.moqui.impl.screen.ScreenRenderImpl.recursiveRunTransition(ScreenRenderImpl.groovy:217)
at org.moqui.impl.screen.ScreenRenderImpl.recursiveRunTransition(ScreenRenderImpl.groovy:217)
at org.moqui.impl.screen.ScreenRenderImpl.internalRender(ScreenRenderImpl.groovy:301)
at org.moqui.impl.screen.ScreenRenderImpl.render(ScreenRenderImpl.groovy:164)
at org.moqui.impl.webapp.MoquiServlet.doScreenRequest(MoquiServlet.groovy:71)
at org.moqui.impl.webapp.MoquiServlet.doPost(MoquiServlet.groovy:37)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:713)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
at net.winstone.core.ServletCotion.execute(ServletConfiguration.java:270)
at net.winstone.core.SimpleRequestDispatcher.forward(SimpleRequestDispatcher.java:290)
at net.winstone.core.listener.RequestHandlerThread.processRequest(RequestHandlerThread.java:212)
at net.winstone.core.listener.RequestHandlerThread.run(RequestHandlerThread.java:143)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at net.winstone.util.BoundedExecutorService$1.run(BoundedExecutorService.java:81)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Addendum: Processing the messages once polled with Email ECA Rules.
I can see when I turn on logger info in EmailEcaRule.groovy that the condition in my Email ECA keeps evaluating to 'false'. But it shouldn't be?
======== EMECA Process Received Email conditionPassed? false My condition: TestEmail fields:
(Note that I inserted "My condition: ${fields.subject}" into the logger info to double check my condition expression was as it should be.)
My emeca is:
<emecas xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://moqui.org/xsd/email-eca-1.5.xsd">
<emeca rule-name="Process Received Email">
<condition><expression>fields.subject == 'TestEmail'</expression></condition>
<actions>
<service-call name="org.moqui.impl.EmailServices.save#EcaEmailMessage" />
</actions>
</emeca>
</emecas>
I have tested and re-tested this. I don't know why it is evaluating to false. Please let me know if any additional information is required.
Still no luck in solving this. I must be doing something stupid. I commented out if (conditionPassed) {} in the EmailEcaRule.groovy to bypass my condition in the Email ECA rule and just run the action, but now it gets hung up with a "Cannot invoke method get() on null object" error in org.moqui.impl.EmailServices.save#EcaEmailMessage, presumably on headers.get('message-id'). But I can see in the log information that the message Id is in the headers information, and successfully converted to lower case.
There were a few issues with this. First is that Moqui was using an old version of JavaMail (now updated to 1.5.4). Another was how the password was passed through, and more generally there was lots of room for improvement in how the script for poll#EmailServer service was using the JavaMail API.
There are various changes in place as of commit #bf0f872. I was able to connect successfully using storeProtocol=imaps, storePort=993, etc.
To answer your question: without these code changes I don't think connection via SSL would be possible. In other words, this ended up being more of a bug report than a question.

Log not being recorded for quickfix c++ Session

I am currently running a FIX initiator and succesfully connecting to an acceptor. The problem is, no log is being recorded. The .cfg for the application is written below.
[DEFAULT]
ConnectionType=initiator
ReconnectInterval=2
ResetOnLogon=Y
FileStorePath=store
FileLogPath=logging
StartTime=00:00:00
EndTime=00:00:00
UseDataDictionary=Y
# standard config elements
[SESSION]
# inherit ConnectionType, ReconnectInterval and SenderCompID from default
BeginString=FIX.4.4
SenderCompID=INIT
TargetCompID=ACCEPT
SocketConnectHost=xxx
SocketConnectPort=xxx
HeartBtInt=30
DataDictionary=FIX44MD.xml
[SESSION]
BeginString=FIX.4.4
SenderCompID=INIT
TargetCompID=ACCEPT1
SocketConnectHost=xxx
SocketConnectPort=xxx
HeartBtInt=30
DataDictionary=FIX44OMS.xml
The excerpt from the code which initiates the connection is written below:
std::string file = argv[ 1 ];
FIX::SessionSettings settings( file );
Application application;
FIX::FileStoreFactory storeFactory( settings );
FIX::ScreenLogFactory logFactory( settings );
FIX::SocketInitiator initiator( application, storeFactory, settings, logFactory);
initiator.start();
application.run();
initiator.stop();
I'm pretty sure the problem isn't related to writing permissions, as i am running the app as an administrator.
That's because you're using a ScreenLogFactory, which, as its name implies, only logs to the screen (e.g. your terminal).
Change it to a FileLogFactory and you should be in business.