Git Product home page Git Product logo

Comments (3)

gbirchmeier avatar gbirchmeier commented on July 21, 2024

You don't have to implement all OnMessage methods.

You only implement OnMessage for each message type you want to handle. If crack doesn't find the appropriate handler, it rejects the message. This is by design.

The engine is supposed to reject all message types that you don't handle. The implication is that you don't support that type, therefore they shouldn't be sending it to you in the first place. This is pretty standard FIX behavior.

I've never connected to a counterparty that supports all message types. I don't think there are any.

from quickfixn.

NetTecture avatar NetTecture commented on July 21, 2024

Well, the main problem is: Already in the initial connection there are messages I dont really want to handle, but I want to use cracker. Heartbeat for example is something I see but that is handled fully by the framework. Logon/Logoff is something I have at the moment no interest to manually handle. RIght now I need t ogo through everything. With a Try method I could implement those that I want, but then basically decide myself what to do with the others.

from quickfixn.

gbirchmeier avatar gbirchmeier commented on July 21, 2024

You don't have to handle any of that.

See the "EXAMPLE MESSAGE CRACKER" code on this page: http://quickfixn.org/tutorial/receiving-messages

Your code should look similar to that. See all those empty function callbacks? Those are perfectly okay.

Don't overthink the Cracker. You call crack() in FromApp, and it will dispatch to the OnMessage() handlers. If the OnMessage handler is not present, then the message is rejected. That's all there is to it.

FromApp (thus Cracker) is only for application-level messages. Logon, Logoff, Heartbeat, ResendRequest... etc are all admin messages, and thus don't apply; usually you don't want to mess with those anyway.

Have you looked at the example programs in the Examples directory?

(Our help docs are clearly not adequate. We will have to do better.)

from quickfixn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.