Git Product home page Git Product logo

fix-orchestra-protobuf's Introduction

fix-orchestra-protobuf

Translators from FIX Orchestra to the protobuf family of serializations.


Supported Serializations

  • Protocol Buffers ver 2
  • Protocol Buffers ver 3
  • Cap'n Proto

Generation of schema files is based on Encoding FIX using GPB Release Candidate 3 specifications. Note that generation of .capnp files is also based on this spec and is done so without much consideration of the differences between the two encodings. I.e. there may be other ways to generate .capnp files to better leverage Cap'n Proto's efficiencies.


Prerequisites

Build

The project is built with Maven version 3.0 or later.


Usage

java -jar orchestra2proto-jar-with-dependencies.jar [options] orchestra_file

Options:
-altfs         Use alternate output file packaging
-help          Print this message
-lang <arg>    Schema language (valid args: proto2 proto3 capnp)
-nosort        Maintain repo field ordering
-opath <arg>   Output directory
-version       Print version

License

© 2019 FIX Protocol Limited

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

fix-orchestra-protobuf's People

Contributors

dependabot[bot] avatar donmendelson avatar gmala avatar ksiamis-connamara avatar mgatny avatar micheartin avatar tkrash avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fix-orchestra-protobuf's Issues

Unexpected element exception from file geneated from playlist

I generated a orchestra file using the playlist app, and it contains a namespace that causes the generator to crash.

Exception in thread "main" java.lang.RuntimeException: XML Validation Exception: unexpected element (uri:"http://fixprotocol.io/2022/orchestra/appinfo/fixml", local:"FIXMLencodingType"). Expected elements are <{}text> at row: 19353 column: 51

The namespace is used in these structures for example:

<fixr:field id="8" abbrName="BeginString" updated="FIX.Latest" type="BeginStringCodeSet" name="BeginString" updatedEP="270" added="FIX.2.7"> <fixr:annotation> <fixr:documentation purpose="SYNOPSIS"> Identifies beginning of new message and session protocol version by means of a session profile identifier (see FIX Session Layer for details). ALWAYS FIRST FIELD IN MESSAGE. (Always unencrypted).</fixr:documentation> <fixr:appinfo purpose="FIXML"> <fixml:FIXMLencodingType notReqXML="1"/> </fixr:appinfo> </fixr:annotation> </fixr:field>

<fixr:componentRef updatedEP="192" id="1021" updated="FIX.5.0SP2" added="FIX.4.4"> <fixr:annotation> <fixr:appinfo purpose="FIXML"> <fixml:FIXMLencodingType inlined="1"/> </fixr:appinfo> <fixr:documentation> Required if NoUnderlyings(711) &gt; 0.</fixr:documentation> </fixr:annotation> </fixr:componentRef>

Errors using this repository alongside the FIXTradingCommunity/orchestrations repository

Hi, I'm experimenting with using this repository alongside the FIX standard orchestration files in the orchestrations repository to generate proto3 files. When I try to run for instance

java -jar target/orchestra2proto-jar-with-dependencies.jar  -lang proto3 ~/orchestrations/FIX\ Standard/OrchestraFIXLatest.xml

I get the following error:

Exception in thread "main" java.lang.RuntimeException: XML Validation Exception: unexpected element (uri:"http://fixprotocol.io/2022/orchestra/appinfo/fixml", local:"FIXMLencodingType"). Expected elements are <{}text> at row: 20 column: 62
        at io.fixprotocol.orchestra2proto.JAXBValidator.handleEvent(JAXBValidator.java:30)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext.handleEvent(UnmarshallingContext.java:704)
        at com.sun.xml.bind.v2.runtime.unmarshaller.Loader.reportError(Loader.java:232)
        at com.sun.xml.bind.v2.runtime.unmarshaller.Loader.reportError(Loader.java:227)
        at com.sun.xml.bind.v2.runtime.unmarshaller.Loader.reportUnexpectedChildElement(Loader.java:94)
        at com.sun.xml.bind.v2.runtime.unmarshaller.Loader.childElement(Loader.java:75)
        at com.sun.xml.bind.v2.runtime.unmarshaller.StructureLoader.childElement(StructureLoader.java:238)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext._startElement(UnmarshallingContext.java:544)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext.startElement(UnmarshallingContext.java:526)
        at com.sun.xml.bind.v2.runtime.unmarshaller.SAXConnector.startElement(SAXConnector.java:138)
        at java.xml/com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:510)
        at java.xml/com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:183)
        at java.xml/com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:351)
        at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2710)
        at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:605)
        at java.xml/com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:112)
        at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:534)
        at java.xml/com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:888)
        at java.xml/com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:824)
        at java.xml/com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
        at java.xml/com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1216)
        at java.xml/com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:635)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:228)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:199)
        at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:170)
        at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:209)
        at io.fixprotocol.orchestra2proto.ProtoGen.generateProtos(ProtoGen.java:55)
        at io.fixprotocol.orchestra2proto.ProtoGen.main(ProtoGen.java:165)

Are there some other steps I need to follow for this to work?

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.