SlideShare ist ein Scribd-Unternehmen logo
1 von 77
Downloaden Sie, um offline zu lesen
Introduction
    RPG Calls Java
   AppServer4RPG
Benchmark Example




       Inside ArdGate
   fast, stable and scalable
      RPG to Java calls


          Dieter Bender




     Dieter Bender   Inside ArdGate
Introduction
                                        Who is Dieter Bender
                       RPG Calls Java
                                        Architecture of ArdGate
                      AppServer4RPG
                                        The Gleiberg Project
                   Benchmark Example


Who is Dieter Bender

     WWW.BENDER-DV.DE
     Dieter Bender, 35435 Wettenberg, Germany
     AS/400 consultant
         Java, SQL, ILE RPG, COBOL
         Application integration, Database
     Training: Java, SQL, ILE RPG
     Open source components
         ArdGate: access any database from i with SQL
         AppServer4RPG: stable, scalable and fast RPG to Java
         integration
         some RPG components
     Dieter@Bender-DV.de


                        Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                           Who is Dieter Bender
                          RPG Calls Java
                                           Architecture of ArdGate
                         AppServer4RPG
                                           The Gleiberg Project
                      Benchmark Example


Architecture

 *ARDPGM must
 be native
 JDBC must be
 Java
 very few RPG
 (blue)
 lots of Java (red)
 lots of calls from
 RPG to Java
 multiple users
 no controll of
 environment
                           Dieter Bender   Inside ArdGate
Introduction
                                          Who is Dieter Bender
                         RPG Calls Java
                                          Architecture of ArdGate
                        AppServer4RPG
                                          The Gleiberg Project
                     Benchmark Example


Why Gleiberg Project?



 AppServer4RPG
 I’m living nearby
 open source to
 protect copyright
 of a Freelancer
 result of > 10
 years teaching
 and project
 experience



                          Dieter Bender   Inside ArdGate
Introduction
                                          Who is Dieter Bender
                         RPG Calls Java
                                          Architecture of ArdGate
                        AppServer4RPG
                                          The Gleiberg Project
                     Benchmark Example


Why Gleiberg Project?



 AppServer4RPG
 I’m living nearby
 open source to
 protect copyright
 of a Freelancer
 result of > 10
 years teaching
 and project
 experience



                          Dieter Bender   Inside ArdGate
Introduction
                                          Who is Dieter Bender
                         RPG Calls Java
                                          Architecture of ArdGate
                        AppServer4RPG
                                          The Gleiberg Project
                     Benchmark Example


Why Gleiberg Project?



 AppServer4RPG
 I’m living nearby
 open source to
 protect copyright
 of a Freelancer
 result of > 10
 years teaching
 and project
 experience



                          Dieter Bender   Inside ArdGate
Introduction
                                          Who is Dieter Bender
                         RPG Calls Java
                                          Architecture of ArdGate
                        AppServer4RPG
                                          The Gleiberg Project
                     Benchmark Example


Why Gleiberg Project?



 AppServer4RPG
 I’m living nearby
 open source to
 protect copyright
 of a Freelancer
 result of > 10
 years teaching
 and project
 experience



                          Dieter Bender   Inside ArdGate
Introduction
                                         Why is this Important?
                        RPG Calls Java
                                         Ways to Call Java from RPG
                       AppServer4RPG
                                         RPGs JNI Support
                    Benchmark Example


RPG is only a Subset of Java


      Java is designed for multithreading
      Java has lots of high quality open source components
      Java has lots of high quality open source tools RPG doesn’t
      have for money
      programmer productivity with OO languages is by far higher
      (by same level of experience)
      some examples:
          WebServices and XML
          generating PDF, HTML and EXCEL
          JDBC access to databases



                         Dieter Bender   Inside ArdGate
Introduction
                                         Why is this Important?
                        RPG Calls Java
                                         Ways to Call Java from RPG
                       AppServer4RPG
                                         RPGs JNI Support
                    Benchmark Example


RPG is only a Subset of Java


      Java is designed for multithreading
      Java has lots of high quality open source components
      Java has lots of high quality open source tools RPG doesn’t
      have for money
      programmer productivity with OO languages is by far higher
      (by same level of experience)
      some examples:
          WebServices and XML
          generating PDF, HTML and EXCEL
          JDBC access to databases



                         Dieter Bender   Inside ArdGate
Introduction
                                         Why is this Important?
                        RPG Calls Java
                                         Ways to Call Java from RPG
                       AppServer4RPG
                                         RPGs JNI Support
                    Benchmark Example


RPG is only a Subset of Java


      Java is designed for multithreading
      Java has lots of high quality open source components
      Java has lots of high quality open source tools RPG doesn’t
      have for money
      programmer productivity with OO languages is by far higher
      (by same level of experience)
      some examples:
          WebServices and XML
          generating PDF, HTML and EXCEL
          JDBC access to databases



                         Dieter Bender   Inside ArdGate
Introduction
                                         Why is this Important?
                        RPG Calls Java
                                         Ways to Call Java from RPG
                       AppServer4RPG
                                         RPGs JNI Support
                    Benchmark Example


RPG is only a Subset of Java


      Java is designed for multithreading
      Java has lots of high quality open source components
      Java has lots of high quality open source tools RPG doesn’t
      have for money
      programmer productivity with OO languages is by far higher
      (by same level of experience)
      some examples:
          WebServices and XML
          generating PDF, HTML and EXCEL
          JDBC access to databases



                         Dieter Bender   Inside ArdGate
Introduction
                                         Why is this Important?
                        RPG Calls Java
                                         Ways to Call Java from RPG
                       AppServer4RPG
                                         RPGs JNI Support
                    Benchmark Example


RPG is only a Subset of Java


      Java is designed for multithreading
      Java has lots of high quality open source components
      Java has lots of high quality open source tools RPG doesn’t
      have for money
      programmer productivity with OO languages is by far higher
      (by same level of experience)
      some examples:
          WebServices and XML
          generating PDF, HTML and EXCEL
          JDBC access to databases



                         Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


RPG Calls Java

     RUNJVA and QSH CMD(java ...)
         only Java applications could be called
         only error level is coming back
         horrible Overhead
     Java stored procedures
         only static methods could be called
         in SQL client mode not scaling
         in SQL server mode no controll over JVM properties
     JNI Java native interface
         was designed for C implementation of JVM and
         implementation of the Java tools
         cryptic programming and bad maintainability of code
         error recovery and analysis is complicated


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


RPG Calls Java

     RUNJVA and QSH CMD(java ...)
         only Java applications could be called
         only error level is coming back
         horrible Overhead
     Java stored procedures
         only static methods could be called
         in SQL client mode not scaling
         in SQL server mode no controll over JVM properties
     JNI Java native interface
         was designed for C implementation of JVM and
         implementation of the Java tools
         cryptic programming and bad maintainability of code
         error recovery and analysis is complicated


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


RPG Calls Java

     RUNJVA and QSH CMD(java ...)
         only Java applications could be called
         only error level is coming back
         horrible Overhead
     Java stored procedures
         only static methods could be called
         in SQL client mode not scaling
         in SQL server mode no controll over JVM properties
     JNI Java native interface
         was designed for C implementation of JVM and
         implementation of the Java tools
         cryptic programming and bad maintainability of code
         error recovery and analysis is complicated


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


Why I Don’t Like Embedded Java in RPG

     controll of the Java environment is near to impossible, because
     the JVM is started automatically
     using normal Java components produces embedded Java in
     RPG
     these programms are hard to develop, debug and maintain
     first call is very slow and starting hundreds or thousands JVM
     makes IBM happy, but doesn’t scale well
     the implementation of the JNI support in the RPG compiler is
     buggy and crashing JVMs are not recovereable! (BTW: never
     saw a crashing JVM outside the JNI support of RPG!!!)
     too much programming effort for suboptimal results


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


Why I Don’t Like Embedded Java in RPG

     controll of the Java environment is near to impossible, because
     the JVM is started automatically
     using normal Java components produces embedded Java in
     RPG
     these programms are hard to develop, debug and maintain
     first call is very slow and starting hundreds or thousands JVM
     makes IBM happy, but doesn’t scale well
     the implementation of the JNI support in the RPG compiler is
     buggy and crashing JVMs are not recovereable! (BTW: never
     saw a crashing JVM outside the JNI support of RPG!!!)
     too much programming effort for suboptimal results


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


Why I Don’t Like Embedded Java in RPG

     controll of the Java environment is near to impossible, because
     the JVM is started automatically
     using normal Java components produces embedded Java in
     RPG
     these programms are hard to develop, debug and maintain
     first call is very slow and starting hundreds or thousands JVM
     makes IBM happy, but doesn’t scale well
     the implementation of the JNI support in the RPG compiler is
     buggy and crashing JVMs are not recovereable! (BTW: never
     saw a crashing JVM outside the JNI support of RPG!!!)
     too much programming effort for suboptimal results


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


Why I Don’t Like Embedded Java in RPG

     controll of the Java environment is near to impossible, because
     the JVM is started automatically
     using normal Java components produces embedded Java in
     RPG
     these programms are hard to develop, debug and maintain
     first call is very slow and starting hundreds or thousands JVM
     makes IBM happy, but doesn’t scale well
     the implementation of the JNI support in the RPG compiler is
     buggy and crashing JVMs are not recovereable! (BTW: never
     saw a crashing JVM outside the JNI support of RPG!!!)
     too much programming effort for suboptimal results


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


Why I Don’t Like Embedded Java in RPG

     controll of the Java environment is near to impossible, because
     the JVM is started automatically
     using normal Java components produces embedded Java in
     RPG
     these programms are hard to develop, debug and maintain
     first call is very slow and starting hundreds or thousands JVM
     makes IBM happy, but doesn’t scale well
     the implementation of the JNI support in the RPG compiler is
     buggy and crashing JVMs are not recovereable! (BTW: never
     saw a crashing JVM outside the JNI support of RPG!!!)
     too much programming effort for suboptimal results


                        Dieter Bender   Inside ArdGate
Introduction
                                        Why is this Important?
                       RPG Calls Java
                                        Ways to Call Java from RPG
                      AppServer4RPG
                                        RPGs JNI Support
                   Benchmark Example


Why I Don’t Like Embedded Java in RPG

     controll of the Java environment is near to impossible, because
     the JVM is started automatically
     using normal Java components produces embedded Java in
     RPG
     these programms are hard to develop, debug and maintain
     first call is very slow and starting hundreds or thousands JVM
     makes IBM happy, but doesn’t scale well
     the implementation of the JNI support in the RPG compiler is
     buggy and crashing JVMs are not recovereable! (BTW: never
     saw a crashing JVM outside the JNI support of RPG!!!)
     too much programming effort for suboptimal results


                        Dieter Bender   Inside ArdGate
Introduction
                                       Architecture of AppServer4RPG
                      RPG Calls Java
                                       The EventHandler Interface
                     AppServer4RPG
                                       The PORDS2POJO Pattern
                  Benchmark Example


Architecture Overview
 one resident
 JVM serves
 multiple RPG
 clients
 asynchronous
 communication
 extendable
 EventHandler
 concept
 RPG sends and
 receives
 DataStructure
 (translated by
 Java)
                       Dieter Bender   Inside ArdGate
Introduction
                                       Architecture of AppServer4RPG
                      RPG Calls Java
                                       The EventHandler Interface
                     AppServer4RPG
                                       The PORDS2POJO Pattern
                  Benchmark Example


Architecture Overview
 one resident
 JVM serves
 multiple RPG
 clients
 asynchronous
 communication
 extendable
 EventHandler
 concept
 RPG sends and
 receives
 DataStructure
 (translated by
 Java)
                       Dieter Bender   Inside ArdGate
Introduction
                                       Architecture of AppServer4RPG
                      RPG Calls Java
                                       The EventHandler Interface
                     AppServer4RPG
                                       The PORDS2POJO Pattern
                  Benchmark Example


Architecture Overview
 one resident
 JVM serves
 multiple RPG
 clients
 asynchronous
 communication
 extendable
 EventHandler
 concept
 RPG sends and
 receives
 DataStructure
 (translated by
 Java)
                       Dieter Bender   Inside ArdGate
Introduction
                                       Architecture of AppServer4RPG
                      RPG Calls Java
                                       The EventHandler Interface
                     AppServer4RPG
                                       The PORDS2POJO Pattern
                  Benchmark Example


Architecture Overview
 one resident
 JVM serves
 multiple RPG
 clients
 asynchronous
 communication
 extendable
 EventHandler
 concept
 RPG sends and
 receives
 DataStructure
 (translated by
 Java)
                       Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


The RPG Perspective




   RPG calls Java
   method
   read as:
   outDS =
   ARDPGM(inDS)




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


The RPG Perspective




   RPG calls Java
   method
   read as:
   outDS =
   ARDPGM(inDS)




                         Dieter Bender   Inside ArdGate
Introduction
                                            Architecture of AppServer4RPG
                           RPG Calls Java
                                            The EventHandler Interface
                          AppServer4RPG
                                            The PORDS2POJO Pattern
                       Benchmark Example


The Java Perspective




   Action: what
   should be called?
   how has the
   handler to look
   like?




                            Dieter Bender   Inside ArdGate
Introduction
                                            Architecture of AppServer4RPG
                           RPG Calls Java
                                            The EventHandler Interface
                          AppServer4RPG
                                            The PORDS2POJO Pattern
                       Benchmark Example


The Java Perspective




   Action: what
   should be called?
   how has the
   handler to look
   like?




                            Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Hybrid Objects




   Plain Old RPG
   DataStructure
   Plain Old Java
   Object




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Hybrid Objects




   Plain Old RPG
   DataStructure
   Plain Old Java
   Object




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Translation Objects


      PORDS2POJO:= a Java object, encapsulating the
      translation between the binary representation of a PORDS and
      a POJO
          POJO with all components of the PORDS as Java types
          object variable to hold the PORDS ( private byte[] huddle )
          setter and getter for the binary huddle
          this Hybrid objects always reflect the Java and the RPG
          perspective of the same data
          sometimes only on direction is needed and implemented




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Translation Objects


      PORDS2POJO:= a Java object, encapsulating the
      translation between the binary representation of a PORDS and
      a POJO
          POJO with all components of the PORDS as Java types
          object variable to hold the PORDS ( private byte[] huddle )
          setter and getter for the binary huddle
          this Hybrid objects always reflect the Java and the RPG
          perspective of the same data
          sometimes only on direction is needed and implemented




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Translation Objects


      PORDS2POJO:= a Java object, encapsulating the
      translation between the binary representation of a PORDS and
      a POJO
          POJO with all components of the PORDS as Java types
          object variable to hold the PORDS ( private byte[] huddle )
          setter and getter for the binary huddle
          this Hybrid objects always reflect the Java and the RPG
          perspective of the same data
          sometimes only on direction is needed and implemented




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Translation Objects


      PORDS2POJO:= a Java object, encapsulating the
      translation between the binary representation of a PORDS and
      a POJO
          POJO with all components of the PORDS as Java types
          object variable to hold the PORDS ( private byte[] huddle )
          setter and getter for the binary huddle
          this Hybrid objects always reflect the Java and the RPG
          perspective of the same data
          sometimes only on direction is needed and implemented




                         Dieter Bender   Inside ArdGate
Introduction
                                         Architecture of AppServer4RPG
                        RPG Calls Java
                                         The EventHandler Interface
                       AppServer4RPG
                                         The PORDS2POJO Pattern
                    Benchmark Example


Translation Objects


      PORDS2POJO:= a Java object, encapsulating the
      translation between the binary representation of a PORDS and
      a POJO
          POJO with all components of the PORDS as Java types
          object variable to hold the PORDS ( private byte[] huddle )
          setter and getter for the binary huddle
          this Hybrid objects always reflect the Java and the RPG
          perspective of the same data
          sometimes only on direction is needed and implemented




                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


A Real Life Example



      The idea: RPG application generates a HTML invoice
      Java generates from the HTML and a CSS a PDF invoice
      the Java Part is done by iText and Flying Saucer
      Requirement: 10.000 invoices in 6 h
      first customer evaluation: 30 sec. up to minutes for 1!
      my first evaluation on Wintel: subsecond!




                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


A Real Life Example



      The idea: RPG application generates a HTML invoice
      Java generates from the HTML and a CSS a PDF invoice
      the Java Part is done by iText and Flying Saucer
      Requirement: 10.000 invoices in 6 h
      first customer evaluation: 30 sec. up to minutes for 1!
      my first evaluation on Wintel: subsecond!




                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


A Real Life Example



      The idea: RPG application generates a HTML invoice
      Java generates from the HTML and a CSS a PDF invoice
      the Java Part is done by iText and Flying Saucer
      Requirement: 10.000 invoices in 6 h
      first customer evaluation: 30 sec. up to minutes for 1!
      my first evaluation on Wintel: subsecond!




                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


A Real Life Example



      The idea: RPG application generates a HTML invoice
      Java generates from the HTML and a CSS a PDF invoice
      the Java Part is done by iText and Flying Saucer
      Requirement: 10.000 invoices in 6 h
      first customer evaluation: 30 sec. up to minutes for 1!
      my first evaluation on Wintel: subsecond!




                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


A Real Life Example



      The idea: RPG application generates a HTML invoice
      Java generates from the HTML and a CSS a PDF invoice
      the Java Part is done by iText and Flying Saucer
      Requirement: 10.000 invoices in 6 h
      first customer evaluation: 30 sec. up to minutes for 1!
      my first evaluation on Wintel: subsecond!




                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                      RPG Calls Java   The RUNJVA Way
                     AppServer4RPG     The Embedded Java in RPG Way
                  Benchmark Example    The Gleiberg Version


HTML2PDF4I by Aaron Bartell


     Article in IBM Systems Magazine
     Open Source at http://mowyourlawn.com
     Java Application as a wrapper for iText and Flying Saucer
     called by RPG programm via RUNJVA with assembled
     classpath setting
     my evaluation 10 sec.
         opening a Job for each call of RUNJVA and starting a JVM
         slow, but scaling linear - JVM is closed after call.




                       Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                      RPG Calls Java   The RUNJVA Way
                     AppServer4RPG     The Embedded Java in RPG Way
                  Benchmark Example    The Gleiberg Version


HTML2PDF4I by Aaron Bartell


     Article in IBM Systems Magazine
     Open Source at http://mowyourlawn.com
     Java Application as a wrapper for iText and Flying Saucer
     called by RPG programm via RUNJVA with assembled
     classpath setting
     my evaluation 10 sec.
         opening a Job for each call of RUNJVA and starting a JVM
         slow, but scaling linear - JVM is closed after call.




                       Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                      RPG Calls Java   The RUNJVA Way
                     AppServer4RPG     The Embedded Java in RPG Way
                  Benchmark Example    The Gleiberg Version


HTML2PDF4I by Aaron Bartell


     Article in IBM Systems Magazine
     Open Source at http://mowyourlawn.com
     Java Application as a wrapper for iText and Flying Saucer
     called by RPG programm via RUNJVA with assembled
     classpath setting
     my evaluation 10 sec.
         opening a Job for each call of RUNJVA and starting a JVM
         slow, but scaling linear - JVM is closed after call.




                       Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


The Classpath Problem


     first problem: you will need 3 jar files in your classpath
         starting the JVM at Job begin => a JVM is started, but
         maybe not used
         starting the JVM before usage => might fail, because started
         before
         submitting a job for usage => same problem as RUNJVA with
         more effort!
         setting global classpath => might interfere with other
         applications
         using extdir => even worse, has higher priority than classpath
         setting




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


The Classpath Problem


     first problem: you will need 3 jar files in your classpath
         starting the JVM at Job begin => a JVM is started, but
         maybe not used
         starting the JVM before usage => might fail, because started
         before
         submitting a job for usage => same problem as RUNJVA with
         more effort!
         setting global classpath => might interfere with other
         applications
         using extdir => even worse, has higher priority than classpath
         setting




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


The Classpath Problem


     first problem: you will need 3 jar files in your classpath
         starting the JVM at Job begin => a JVM is started, but
         maybe not used
         starting the JVM before usage => might fail, because started
         before
         submitting a job for usage => same problem as RUNJVA with
         more effort!
         setting global classpath => might interfere with other
         applications
         using extdir => even worse, has higher priority than classpath
         setting




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


The Classpath Problem


     first problem: you will need 3 jar files in your classpath
         starting the JVM at Job begin => a JVM is started, but
         maybe not used
         starting the JVM before usage => might fail, because started
         before
         submitting a job for usage => same problem as RUNJVA with
         more effort!
         setting global classpath => might interfere with other
         applications
         using extdir => even worse, has higher priority than classpath
         setting




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


The Classpath Problem


     first problem: you will need 3 jar files in your classpath
         starting the JVM at Job begin => a JVM is started, but
         maybe not used
         starting the JVM before usage => might fail, because started
         before
         submitting a job for usage => same problem as RUNJVA with
         more effort!
         setting global classpath => might interfere with other
         applications
         using extdir => even worse, has higher priority than classpath
         setting




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


Why I Gave Up

     second problem: for one java statement you need multiple
     RPG declarations and statements.
         10 minutes programming java <=> one day programming
         embedded Java in RPG
     third problem: hard to read debug and even worse in
     production!
         impossible to use log4j
     maybe faster for subsequent calls in the same job than
     RUNJVA
     scalability even worse (the programm could be called in every
     Job!)



                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


Why I Gave Up

     second problem: for one java statement you need multiple
     RPG declarations and statements.
         10 minutes programming java <=> one day programming
         embedded Java in RPG
     third problem: hard to read debug and even worse in
     production!
         impossible to use log4j
     maybe faster for subsequent calls in the same job than
     RUNJVA
     scalability even worse (the programm could be called in every
     Job!)



                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


Why I Gave Up

     second problem: for one java statement you need multiple
     RPG declarations and statements.
         10 minutes programming java <=> one day programming
         embedded Java in RPG
     third problem: hard to read debug and even worse in
     production!
         impossible to use log4j
     maybe faster for subsequent calls in the same job than
     RUNJVA
     scalability even worse (the programm could be called in every
     Job!)



                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                           RPG Calls Java   The RUNJVA Way
                          AppServer4RPG     The Embedded Java in RPG Way
                       Benchmark Example    The Gleiberg Version


The RPG Perspective




  what we want
  install
  AppServer4RPG
  implement the call




                            Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                           RPG Calls Java   The RUNJVA Way
                          AppServer4RPG     The Embedded Java in RPG Way
                       Benchmark Example    The Gleiberg Version


The RPG Perspective




  what we want
  install
  AppServer4RPG
  implement the call




                            Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                           RPG Calls Java   The RUNJVA Way
                          AppServer4RPG     The Embedded Java in RPG Way
                       Benchmark Example    The Gleiberg Version


The RPG Perspective




  what we want
  install
  AppServer4RPG
  implement the call




                            Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


Closing the Chain to Java




  now we need an
  EventHandler to be
  called
  configure
  AppServer4RPG




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


Closing the Chain to Java




  now we need an
  EventHandler to be
  called
  configure
  AppServer4RPG




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                      RPG Calls Java   The RUNJVA Way
                     AppServer4RPG     The Embedded Java in RPG Way
                  Benchmark Example    The Gleiberg Version


What Happens Now Calling the RPG Programm?
     the RPG part puts its input parameters to the request DS and
     calls fireEventP
     the RPG part of JVAGATE creates a response DTAQ
     sends the data (and an identifier for the caller Job) in
     packages to the JAVAQ
     listens on the responseQ for the answer
     Now the Java part of AppServer4RPG does its work (hopefully
     it was started)
         starts a new worker Thread to be ready for the next request
         creates a Handler for the requested Event,
         creates Request and Response Objects and calls the
         performWork of the Handler
         sends the response Data back in packages to the ResponseQ.
         known by the identifier passed with the request

                       Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                      RPG Calls Java   The RUNJVA Way
                     AppServer4RPG     The Embedded Java in RPG Way
                  Benchmark Example    The Gleiberg Version


What Happens Now Calling the RPG Programm?
     the RPG part puts its input parameters to the request DS and
     calls fireEventP
     the RPG part of JVAGATE creates a response DTAQ
     sends the data (and an identifier for the caller Job) in
     packages to the JAVAQ
     listens on the responseQ for the answer
     Now the Java part of AppServer4RPG does its work (hopefully
     it was started)
         starts a new worker Thread to be ready for the next request
         creates a Handler for the requested Event,
         creates Request and Response Objects and calls the
         performWork of the Handler
         sends the response Data back in packages to the ResponseQ.
         known by the identifier passed with the request

                       Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                      RPG Calls Java   The RUNJVA Way
                     AppServer4RPG     The Embedded Java in RPG Way
                  Benchmark Example    The Gleiberg Version


What Happens Now Calling the RPG Programm?
     the RPG part puts its input parameters to the request DS and
     calls fireEventP
     the RPG part of JVAGATE creates a response DTAQ
     sends the data (and an identifier for the caller Job) in
     packages to the JAVAQ
     listens on the responseQ for the answer
     Now the Java part of AppServer4RPG does its work (hopefully
     it was started)
         starts a new worker Thread to be ready for the next request
         creates a Handler for the requested Event,
         creates Request and Response Objects and calls the
         performWork of the Handler
         sends the response Data back in packages to the ResponseQ.
         known by the identifier passed with the request

                       Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                         RPG Calls Java   The RUNJVA Way
                        AppServer4RPG     The Embedded Java in RPG Way
                     Benchmark Example    The Gleiberg Version


The EventHandler



  gets a Request
  a simple
  PORDS2POJO
  binary is set with
  Constructor
  getter for properties
  the EventHandler




                          Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                         RPG Calls Java   The RUNJVA Way
                        AppServer4RPG     The Embedded Java in RPG Way
                     Benchmark Example    The Gleiberg Version


The EventHandler




  gets a Request
  a simple
  PORDS2POJO
  binary is set with
  Constructor
  getter for properties
  the EventHandler




                          Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                         RPG Calls Java   The RUNJVA Way
                        AppServer4RPG     The Embedded Java in RPG Way
                     Benchmark Example    The Gleiberg Version


The EventHandler




  gets a Request
  a simple
  PORDS2POJO
  binary is set with
  Constructor
  getter for properties
  the EventHandler




                          Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


The Results

      Transaction Times of subseconds
      first call in a Job as fast as following (JVM is prestarted)
      very scalable (one JVM serves multiple RPG Jobs)
      no Classpath issues, simply throw the needed jar files to the lib
      directory of AppServer4RPG
      multiple instances of AppServer4RPG could run on the same
      box with diffrent JVM settings
      AppServer4RPG could be installed on a dedicated server
      less programming effort than embedded Java in RPG
      flexible logging with log4j simplifies trouble shooting


                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


The Results

      Transaction Times of subseconds
      first call in a Job as fast as following (JVM is prestarted)
      very scalable (one JVM serves multiple RPG Jobs)
      no Classpath issues, simply throw the needed jar files to the lib
      directory of AppServer4RPG
      multiple instances of AppServer4RPG could run on the same
      box with diffrent JVM settings
      AppServer4RPG could be installed on a dedicated server
      less programming effort than embedded Java in RPG
      flexible logging with log4j simplifies trouble shooting


                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


The Results

      Transaction Times of subseconds
      first call in a Job as fast as following (JVM is prestarted)
      very scalable (one JVM serves multiple RPG Jobs)
      no Classpath issues, simply throw the needed jar files to the lib
      directory of AppServer4RPG
      multiple instances of AppServer4RPG could run on the same
      box with diffrent JVM settings
      AppServer4RPG could be installed on a dedicated server
      less programming effort than embedded Java in RPG
      flexible logging with log4j simplifies trouble shooting


                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


The Results

      Transaction Times of subseconds
      first call in a Job as fast as following (JVM is prestarted)
      very scalable (one JVM serves multiple RPG Jobs)
      no Classpath issues, simply throw the needed jar files to the lib
      directory of AppServer4RPG
      multiple instances of AppServer4RPG could run on the same
      box with diffrent JVM settings
      AppServer4RPG could be installed on a dedicated server
      less programming effort than embedded Java in RPG
      flexible logging with log4j simplifies trouble shooting


                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


The Results

      Transaction Times of subseconds
      first call in a Job as fast as following (JVM is prestarted)
      very scalable (one JVM serves multiple RPG Jobs)
      no Classpath issues, simply throw the needed jar files to the lib
      directory of AppServer4RPG
      multiple instances of AppServer4RPG could run on the same
      box with diffrent JVM settings
      AppServer4RPG could be installed on a dedicated server
      less programming effort than embedded Java in RPG
      flexible logging with log4j simplifies trouble shooting


                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                        RPG Calls Java   The RUNJVA Way
                       AppServer4RPG     The Embedded Java in RPG Way
                    Benchmark Example    The Gleiberg Version


The Results

      Transaction Times of subseconds
      first call in a Job as fast as following (JVM is prestarted)
      very scalable (one JVM serves multiple RPG Jobs)
      no Classpath issues, simply throw the needed jar files to the lib
      directory of AppServer4RPG
      multiple instances of AppServer4RPG could run on the same
      box with diffrent JVM settings
      AppServer4RPG could be installed on a dedicated server
      less programming effort than embedded Java in RPG
      flexible logging with log4j simplifies trouble shooting


                         Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                       RPG Calls Java   The RUNJVA Way
                      AppServer4RPG     The Embedded Java in RPG Way
                   Benchmark Example    The Gleiberg Version


Summary


    Don’t try to write Java code in RPG, provide Java methods
    with Datastructure parameter interfaces for RPG usage!
    Let your Java Code run in a prestarted resident JVM,
    communicating asynchronous with your native programms.


    Outlook (Nice to have!)
          Dynamic PORDS2POJO Beans.
          True Tomcat Version of AppServer4RPG.




                        Dieter Bender   Inside ArdGate
Introduction   Generating PDF from HTML
                 RPG Calls Java   The RUNJVA Way
                AppServer4RPG     The Embedded Java in RPG Way
             Benchmark Example    The Gleiberg Version


Questions?




                  Dieter Bender   Inside ArdGate

Weitere ähnliche Inhalte

Was ist angesagt?

Agile - Iteration 0 CodeMash 2010
Agile - Iteration 0 CodeMash 2010Agile - Iteration 0 CodeMash 2010
Agile - Iteration 0 CodeMash 2010
kensipe
 
Tech Days 2015: Multi-language Programming with GPRbuild
Tech Days 2015: Multi-language Programming with GPRbuildTech Days 2015: Multi-language Programming with GPRbuild
Tech Days 2015: Multi-language Programming with GPRbuild
AdaCore
 
Marrying Jenkins and Gerrit-Berlin Expert Days 2013
Marrying Jenkins and Gerrit-Berlin Expert Days 2013Marrying Jenkins and Gerrit-Berlin Expert Days 2013
Marrying Jenkins and Gerrit-Berlin Expert Days 2013
Dharmesh Sheta
 

Was ist angesagt? (8)

Agile - Iteration 0 CodeMash 2010
Agile - Iteration 0 CodeMash 2010Agile - Iteration 0 CodeMash 2010
Agile - Iteration 0 CodeMash 2010
 
Tech Days 2015: Multi-language Programming with GPRbuild
Tech Days 2015: Multi-language Programming with GPRbuildTech Days 2015: Multi-language Programming with GPRbuild
Tech Days 2015: Multi-language Programming with GPRbuild
 
Continuous Delivery NYC: From GitOps to an adaptable CI/CD Pattern for Kubern...
Continuous Delivery NYC: From GitOps to an adaptable CI/CD Pattern for Kubern...Continuous Delivery NYC: From GitOps to an adaptable CI/CD Pattern for Kubern...
Continuous Delivery NYC: From GitOps to an adaptable CI/CD Pattern for Kubern...
 
Scripting In Java
Scripting In JavaScripting In Java
Scripting In Java
 
Open Source Jumpstart Tooling Up Intro
Open Source Jumpstart Tooling Up IntroOpen Source Jumpstart Tooling Up Intro
Open Source Jumpstart Tooling Up Intro
 
Marrying Jenkins and Gerrit-Berlin Expert Days 2013
Marrying Jenkins and Gerrit-Berlin Expert Days 2013Marrying Jenkins and Gerrit-Berlin Expert Days 2013
Marrying Jenkins and Gerrit-Berlin Expert Days 2013
 
Android on Windows 11 - A Developer's Perspective (Windows Subsystem For Andr...
Android on Windows 11 - A Developer's Perspective (Windows Subsystem For Andr...Android on Windows 11 - A Developer's Perspective (Windows Subsystem For Andr...
Android on Windows 11 - A Developer's Perspective (Windows Subsystem For Andr...
 
Code, ci, infrastructure - the gophers way
Code, ci, infrastructure - the gophers wayCode, ci, infrastructure - the gophers way
Code, ci, infrastructure - the gophers way
 

Ähnlich wie App server4rpg - English

Neo4 + Grails
Neo4 + GrailsNeo4 + Grails
Neo4 + Grails
stasimus
 
Evdokimov python arsenal for re
Evdokimov   python arsenal for reEvdokimov   python arsenal for re
Evdokimov python arsenal for re
DefconRussia
 

Ähnlich wie App server4rpg - English (20)

Ruby with cucmber
Ruby with cucmberRuby with cucmber
Ruby with cucmber
 
Neo4J and Grails
Neo4J and GrailsNeo4J and Grails
Neo4J and Grails
 
Neo4 + Grails
Neo4 + GrailsNeo4 + Grails
Neo4 + Grails
 
Dell PowerEdge R750 server featuring a modern 100Gb Broadcom 57508 NIC achiev...
Dell PowerEdge R750 server featuring a modern 100Gb Broadcom 57508 NIC achiev...Dell PowerEdge R750 server featuring a modern 100Gb Broadcom 57508 NIC achiev...
Dell PowerEdge R750 server featuring a modern 100Gb Broadcom 57508 NIC achiev...
 
GraalVM - OpenSlava 2019-10-18
GraalVM - OpenSlava 2019-10-18GraalVM - OpenSlava 2019-10-18
GraalVM - OpenSlava 2019-10-18
 
AWS Meetup Paris - Short URL project by Pernod Ricard
AWS Meetup Paris - Short URL project by Pernod RicardAWS Meetup Paris - Short URL project by Pernod Ricard
AWS Meetup Paris - Short URL project by Pernod Ricard
 
GraalVM - MadridJUG 2019-10-22
GraalVM - MadridJUG 2019-10-22GraalVM - MadridJUG 2019-10-22
GraalVM - MadridJUG 2019-10-22
 
AISLER @ FOSDEM 2017
AISLER @ FOSDEM 2017AISLER @ FOSDEM 2017
AISLER @ FOSDEM 2017
 
Common Java problems when developing with Android
Common Java problems when developing with AndroidCommon Java problems when developing with Android
Common Java problems when developing with Android
 
Meetup React Sanca - 29/11/18 - React Testing
Meetup React Sanca - 29/11/18 - React TestingMeetup React Sanca - 29/11/18 - React Testing
Meetup React Sanca - 29/11/18 - React Testing
 
Debugging seL4 apps with the GNU Debugger
Debugging seL4 apps with the GNU DebuggerDebugging seL4 apps with the GNU Debugger
Debugging seL4 apps with the GNU Debugger
 
REST in Peace. Long live gRPC! @ Codineers
REST in Peace. Long live gRPC! @ CodineersREST in Peace. Long live gRPC! @ Codineers
REST in Peace. Long live gRPC! @ Codineers
 
Adapter 2pp
Adapter 2ppAdapter 2pp
Adapter 2pp
 
GradleのREPLプラグイン紹介 #jggug
GradleのREPLプラグイン紹介 #jggugGradleのREPLプラグイン紹介 #jggug
GradleのREPLプラグイン紹介 #jggug
 
Evdokimov python arsenal for re
Evdokimov   python arsenal for reEvdokimov   python arsenal for re
Evdokimov python arsenal for re
 
Introducing the R2DBC async Java connector
Introducing the R2DBC async Java connectorIntroducing the R2DBC async Java connector
Introducing the R2DBC async Java connector
 
Gearman Introduction
Gearman IntroductionGearman Introduction
Gearman Introduction
 
apidays Australia 2022 - Lessons from doing EdgeDevOps (GitOps) in the bush, ...
apidays Australia 2022 - Lessons from doing EdgeDevOps (GitOps) in the bush, ...apidays Australia 2022 - Lessons from doing EdgeDevOps (GitOps) in the bush, ...
apidays Australia 2022 - Lessons from doing EdgeDevOps (GitOps) in the bush, ...
 
Go lambda-presentation
Go lambda-presentationGo lambda-presentation
Go lambda-presentation
 
GraphQL-ify your APIs
GraphQL-ify your APIsGraphQL-ify your APIs
GraphQL-ify your APIs
 

Mehr von COMMON Europe

Compiling the Compiler
Compiling the CompilerCompiling the Compiler
Compiling the Compiler
COMMON Europe
 

Mehr von COMMON Europe (20)

What's New in WebSphere Application Server
What's New in WebSphere Application ServerWhat's New in WebSphere Application Server
What's New in WebSphere Application Server
 
Compiling the Compiler
Compiling the CompilerCompiling the Compiler
Compiling the Compiler
 
Workload Groups overview updates
Workload Groups overview updatesWorkload Groups overview updates
Workload Groups overview updates
 
Why i - Common Europe 2012
Why i - Common Europe 2012Why i - Common Europe 2012
Why i - Common Europe 2012
 
The Ruby OpenSSL extension
The Ruby OpenSSL extensionThe Ruby OpenSSL extension
The Ruby OpenSSL extension
 
Using Ruby on IBM i (i5/OS)
Using Ruby on IBM i (i5/OS)Using Ruby on IBM i (i5/OS)
Using Ruby on IBM i (i5/OS)
 
IBM Systems Director Navigator for i
IBM Systems Director Navigator for iIBM Systems Director Navigator for i
IBM Systems Director Navigator for i
 
IBM i Trends & Directions Common Europe 2012
IBM i Trends & Directions Common Europe 2012IBM i Trends & Directions Common Europe 2012
IBM i Trends & Directions Common Europe 2012
 
IBM i Technology Refreshes Overview 2012 06-04
IBM i Technology Refreshes Overview 2012 06-04IBM i Technology Refreshes Overview 2012 06-04
IBM i Technology Refreshes Overview 2012 06-04
 
IBM i 7.1 & TRs CEC 2012
IBM i 7.1 & TRs CEC 2012IBM i 7.1 & TRs CEC 2012
IBM i 7.1 & TRs CEC 2012
 
DB2 Web Query whats new
DB2 Web Query whats newDB2 Web Query whats new
DB2 Web Query whats new
 
Access client solutions overview
Access client solutions overviewAccess client solutions overview
Access client solutions overview
 
What's new with Zend server
What's new with Zend serverWhat's new with Zend server
What's new with Zend server
 
RPG investment
RPG investmentRPG investment
RPG investment
 
Php arrays for RPG programmers
Php arrays for RPG programmersPhp arrays for RPG programmers
Php arrays for RPG programmers
 
Open source report writing tools for IBM i Vienna 2012
Open source report writing tools for IBM i  Vienna 2012Open source report writing tools for IBM i  Vienna 2012
Open source report writing tools for IBM i Vienna 2012
 
Moving 5.4 to 7.1 AB
Moving 5.4 to 7.1 ABMoving 5.4 to 7.1 AB
Moving 5.4 to 7.1 AB
 
Introduction to My SQL
Introduction to My SQLIntroduction to My SQL
Introduction to My SQL
 
IBM CEC 2012 Storage june 11, 2012
IBM CEC 2012 Storage june 11, 2012IBM CEC 2012 Storage june 11, 2012
IBM CEC 2012 Storage june 11, 2012
 
Getting started with PHP on IBM i
Getting started with PHP on IBM iGetting started with PHP on IBM i
Getting started with PHP on IBM i
 

Kürzlich hochgeladen

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Kürzlich hochgeladen (20)

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 

App server4rpg - English

  • 1. Introduction RPG Calls Java AppServer4RPG Benchmark Example Inside ArdGate fast, stable and scalable RPG to Java calls Dieter Bender Dieter Bender Inside ArdGate
  • 2. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Who is Dieter Bender WWW.BENDER-DV.DE Dieter Bender, 35435 Wettenberg, Germany AS/400 consultant Java, SQL, ILE RPG, COBOL Application integration, Database Training: Java, SQL, ILE RPG Open source components ArdGate: access any database from i with SQL AppServer4RPG: stable, scalable and fast RPG to Java integration some RPG components Dieter@Bender-DV.de Dieter Bender Inside ArdGate
  • 3. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 4. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 5. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 6. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 7. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 8. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 9. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Architecture *ARDPGM must be native JDBC must be Java very few RPG (blue) lots of Java (red) lots of calls from RPG to Java multiple users no controll of environment Dieter Bender Inside ArdGate
  • 10. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Why Gleiberg Project? AppServer4RPG I’m living nearby open source to protect copyright of a Freelancer result of > 10 years teaching and project experience Dieter Bender Inside ArdGate
  • 11. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Why Gleiberg Project? AppServer4RPG I’m living nearby open source to protect copyright of a Freelancer result of > 10 years teaching and project experience Dieter Bender Inside ArdGate
  • 12. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Why Gleiberg Project? AppServer4RPG I’m living nearby open source to protect copyright of a Freelancer result of > 10 years teaching and project experience Dieter Bender Inside ArdGate
  • 13. Introduction Who is Dieter Bender RPG Calls Java Architecture of ArdGate AppServer4RPG The Gleiberg Project Benchmark Example Why Gleiberg Project? AppServer4RPG I’m living nearby open source to protect copyright of a Freelancer result of > 10 years teaching and project experience Dieter Bender Inside ArdGate
  • 14. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG is only a Subset of Java Java is designed for multithreading Java has lots of high quality open source components Java has lots of high quality open source tools RPG doesn’t have for money programmer productivity with OO languages is by far higher (by same level of experience) some examples: WebServices and XML generating PDF, HTML and EXCEL JDBC access to databases Dieter Bender Inside ArdGate
  • 15. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG is only a Subset of Java Java is designed for multithreading Java has lots of high quality open source components Java has lots of high quality open source tools RPG doesn’t have for money programmer productivity with OO languages is by far higher (by same level of experience) some examples: WebServices and XML generating PDF, HTML and EXCEL JDBC access to databases Dieter Bender Inside ArdGate
  • 16. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG is only a Subset of Java Java is designed for multithreading Java has lots of high quality open source components Java has lots of high quality open source tools RPG doesn’t have for money programmer productivity with OO languages is by far higher (by same level of experience) some examples: WebServices and XML generating PDF, HTML and EXCEL JDBC access to databases Dieter Bender Inside ArdGate
  • 17. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG is only a Subset of Java Java is designed for multithreading Java has lots of high quality open source components Java has lots of high quality open source tools RPG doesn’t have for money programmer productivity with OO languages is by far higher (by same level of experience) some examples: WebServices and XML generating PDF, HTML and EXCEL JDBC access to databases Dieter Bender Inside ArdGate
  • 18. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG is only a Subset of Java Java is designed for multithreading Java has lots of high quality open source components Java has lots of high quality open source tools RPG doesn’t have for money programmer productivity with OO languages is by far higher (by same level of experience) some examples: WebServices and XML generating PDF, HTML and EXCEL JDBC access to databases Dieter Bender Inside ArdGate
  • 19. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG Calls Java RUNJVA and QSH CMD(java ...) only Java applications could be called only error level is coming back horrible Overhead Java stored procedures only static methods could be called in SQL client mode not scaling in SQL server mode no controll over JVM properties JNI Java native interface was designed for C implementation of JVM and implementation of the Java tools cryptic programming and bad maintainability of code error recovery and analysis is complicated Dieter Bender Inside ArdGate
  • 20. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG Calls Java RUNJVA and QSH CMD(java ...) only Java applications could be called only error level is coming back horrible Overhead Java stored procedures only static methods could be called in SQL client mode not scaling in SQL server mode no controll over JVM properties JNI Java native interface was designed for C implementation of JVM and implementation of the Java tools cryptic programming and bad maintainability of code error recovery and analysis is complicated Dieter Bender Inside ArdGate
  • 21. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example RPG Calls Java RUNJVA and QSH CMD(java ...) only Java applications could be called only error level is coming back horrible Overhead Java stored procedures only static methods could be called in SQL client mode not scaling in SQL server mode no controll over JVM properties JNI Java native interface was designed for C implementation of JVM and implementation of the Java tools cryptic programming and bad maintainability of code error recovery and analysis is complicated Dieter Bender Inside ArdGate
  • 22. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example Why I Don’t Like Embedded Java in RPG controll of the Java environment is near to impossible, because the JVM is started automatically using normal Java components produces embedded Java in RPG these programms are hard to develop, debug and maintain first call is very slow and starting hundreds or thousands JVM makes IBM happy, but doesn’t scale well the implementation of the JNI support in the RPG compiler is buggy and crashing JVMs are not recovereable! (BTW: never saw a crashing JVM outside the JNI support of RPG!!!) too much programming effort for suboptimal results Dieter Bender Inside ArdGate
  • 23. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example Why I Don’t Like Embedded Java in RPG controll of the Java environment is near to impossible, because the JVM is started automatically using normal Java components produces embedded Java in RPG these programms are hard to develop, debug and maintain first call is very slow and starting hundreds or thousands JVM makes IBM happy, but doesn’t scale well the implementation of the JNI support in the RPG compiler is buggy and crashing JVMs are not recovereable! (BTW: never saw a crashing JVM outside the JNI support of RPG!!!) too much programming effort for suboptimal results Dieter Bender Inside ArdGate
  • 24. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example Why I Don’t Like Embedded Java in RPG controll of the Java environment is near to impossible, because the JVM is started automatically using normal Java components produces embedded Java in RPG these programms are hard to develop, debug and maintain first call is very slow and starting hundreds or thousands JVM makes IBM happy, but doesn’t scale well the implementation of the JNI support in the RPG compiler is buggy and crashing JVMs are not recovereable! (BTW: never saw a crashing JVM outside the JNI support of RPG!!!) too much programming effort for suboptimal results Dieter Bender Inside ArdGate
  • 25. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example Why I Don’t Like Embedded Java in RPG controll of the Java environment is near to impossible, because the JVM is started automatically using normal Java components produces embedded Java in RPG these programms are hard to develop, debug and maintain first call is very slow and starting hundreds or thousands JVM makes IBM happy, but doesn’t scale well the implementation of the JNI support in the RPG compiler is buggy and crashing JVMs are not recovereable! (BTW: never saw a crashing JVM outside the JNI support of RPG!!!) too much programming effort for suboptimal results Dieter Bender Inside ArdGate
  • 26. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example Why I Don’t Like Embedded Java in RPG controll of the Java environment is near to impossible, because the JVM is started automatically using normal Java components produces embedded Java in RPG these programms are hard to develop, debug and maintain first call is very slow and starting hundreds or thousands JVM makes IBM happy, but doesn’t scale well the implementation of the JNI support in the RPG compiler is buggy and crashing JVMs are not recovereable! (BTW: never saw a crashing JVM outside the JNI support of RPG!!!) too much programming effort for suboptimal results Dieter Bender Inside ArdGate
  • 27. Introduction Why is this Important? RPG Calls Java Ways to Call Java from RPG AppServer4RPG RPGs JNI Support Benchmark Example Why I Don’t Like Embedded Java in RPG controll of the Java environment is near to impossible, because the JVM is started automatically using normal Java components produces embedded Java in RPG these programms are hard to develop, debug and maintain first call is very slow and starting hundreds or thousands JVM makes IBM happy, but doesn’t scale well the implementation of the JNI support in the RPG compiler is buggy and crashing JVMs are not recovereable! (BTW: never saw a crashing JVM outside the JNI support of RPG!!!) too much programming effort for suboptimal results Dieter Bender Inside ArdGate
  • 28. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Architecture Overview one resident JVM serves multiple RPG clients asynchronous communication extendable EventHandler concept RPG sends and receives DataStructure (translated by Java) Dieter Bender Inside ArdGate
  • 29. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Architecture Overview one resident JVM serves multiple RPG clients asynchronous communication extendable EventHandler concept RPG sends and receives DataStructure (translated by Java) Dieter Bender Inside ArdGate
  • 30. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Architecture Overview one resident JVM serves multiple RPG clients asynchronous communication extendable EventHandler concept RPG sends and receives DataStructure (translated by Java) Dieter Bender Inside ArdGate
  • 31. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Architecture Overview one resident JVM serves multiple RPG clients asynchronous communication extendable EventHandler concept RPG sends and receives DataStructure (translated by Java) Dieter Bender Inside ArdGate
  • 32. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example The RPG Perspective RPG calls Java method read as: outDS = ARDPGM(inDS) Dieter Bender Inside ArdGate
  • 33. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example The RPG Perspective RPG calls Java method read as: outDS = ARDPGM(inDS) Dieter Bender Inside ArdGate
  • 34. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example The Java Perspective Action: what should be called? how has the handler to look like? Dieter Bender Inside ArdGate
  • 35. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example The Java Perspective Action: what should be called? how has the handler to look like? Dieter Bender Inside ArdGate
  • 36. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Hybrid Objects Plain Old RPG DataStructure Plain Old Java Object Dieter Bender Inside ArdGate
  • 37. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Hybrid Objects Plain Old RPG DataStructure Plain Old Java Object Dieter Bender Inside ArdGate
  • 38. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Translation Objects PORDS2POJO:= a Java object, encapsulating the translation between the binary representation of a PORDS and a POJO POJO with all components of the PORDS as Java types object variable to hold the PORDS ( private byte[] huddle ) setter and getter for the binary huddle this Hybrid objects always reflect the Java and the RPG perspective of the same data sometimes only on direction is needed and implemented Dieter Bender Inside ArdGate
  • 39. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Translation Objects PORDS2POJO:= a Java object, encapsulating the translation between the binary representation of a PORDS and a POJO POJO with all components of the PORDS as Java types object variable to hold the PORDS ( private byte[] huddle ) setter and getter for the binary huddle this Hybrid objects always reflect the Java and the RPG perspective of the same data sometimes only on direction is needed and implemented Dieter Bender Inside ArdGate
  • 40. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Translation Objects PORDS2POJO:= a Java object, encapsulating the translation between the binary representation of a PORDS and a POJO POJO with all components of the PORDS as Java types object variable to hold the PORDS ( private byte[] huddle ) setter and getter for the binary huddle this Hybrid objects always reflect the Java and the RPG perspective of the same data sometimes only on direction is needed and implemented Dieter Bender Inside ArdGate
  • 41. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Translation Objects PORDS2POJO:= a Java object, encapsulating the translation between the binary representation of a PORDS and a POJO POJO with all components of the PORDS as Java types object variable to hold the PORDS ( private byte[] huddle ) setter and getter for the binary huddle this Hybrid objects always reflect the Java and the RPG perspective of the same data sometimes only on direction is needed and implemented Dieter Bender Inside ArdGate
  • 42. Introduction Architecture of AppServer4RPG RPG Calls Java The EventHandler Interface AppServer4RPG The PORDS2POJO Pattern Benchmark Example Translation Objects PORDS2POJO:= a Java object, encapsulating the translation between the binary representation of a PORDS and a POJO POJO with all components of the PORDS as Java types object variable to hold the PORDS ( private byte[] huddle ) setter and getter for the binary huddle this Hybrid objects always reflect the Java and the RPG perspective of the same data sometimes only on direction is needed and implemented Dieter Bender Inside ArdGate
  • 43. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version A Real Life Example The idea: RPG application generates a HTML invoice Java generates from the HTML and a CSS a PDF invoice the Java Part is done by iText and Flying Saucer Requirement: 10.000 invoices in 6 h first customer evaluation: 30 sec. up to minutes for 1! my first evaluation on Wintel: subsecond! Dieter Bender Inside ArdGate
  • 44. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version A Real Life Example The idea: RPG application generates a HTML invoice Java generates from the HTML and a CSS a PDF invoice the Java Part is done by iText and Flying Saucer Requirement: 10.000 invoices in 6 h first customer evaluation: 30 sec. up to minutes for 1! my first evaluation on Wintel: subsecond! Dieter Bender Inside ArdGate
  • 45. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version A Real Life Example The idea: RPG application generates a HTML invoice Java generates from the HTML and a CSS a PDF invoice the Java Part is done by iText and Flying Saucer Requirement: 10.000 invoices in 6 h first customer evaluation: 30 sec. up to minutes for 1! my first evaluation on Wintel: subsecond! Dieter Bender Inside ArdGate
  • 46. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version A Real Life Example The idea: RPG application generates a HTML invoice Java generates from the HTML and a CSS a PDF invoice the Java Part is done by iText and Flying Saucer Requirement: 10.000 invoices in 6 h first customer evaluation: 30 sec. up to minutes for 1! my first evaluation on Wintel: subsecond! Dieter Bender Inside ArdGate
  • 47. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version A Real Life Example The idea: RPG application generates a HTML invoice Java generates from the HTML and a CSS a PDF invoice the Java Part is done by iText and Flying Saucer Requirement: 10.000 invoices in 6 h first customer evaluation: 30 sec. up to minutes for 1! my first evaluation on Wintel: subsecond! Dieter Bender Inside ArdGate
  • 48. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version HTML2PDF4I by Aaron Bartell Article in IBM Systems Magazine Open Source at http://mowyourlawn.com Java Application as a wrapper for iText and Flying Saucer called by RPG programm via RUNJVA with assembled classpath setting my evaluation 10 sec. opening a Job for each call of RUNJVA and starting a JVM slow, but scaling linear - JVM is closed after call. Dieter Bender Inside ArdGate
  • 49. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version HTML2PDF4I by Aaron Bartell Article in IBM Systems Magazine Open Source at http://mowyourlawn.com Java Application as a wrapper for iText and Flying Saucer called by RPG programm via RUNJVA with assembled classpath setting my evaluation 10 sec. opening a Job for each call of RUNJVA and starting a JVM slow, but scaling linear - JVM is closed after call. Dieter Bender Inside ArdGate
  • 50. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version HTML2PDF4I by Aaron Bartell Article in IBM Systems Magazine Open Source at http://mowyourlawn.com Java Application as a wrapper for iText and Flying Saucer called by RPG programm via RUNJVA with assembled classpath setting my evaluation 10 sec. opening a Job for each call of RUNJVA and starting a JVM slow, but scaling linear - JVM is closed after call. Dieter Bender Inside ArdGate
  • 51. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Classpath Problem first problem: you will need 3 jar files in your classpath starting the JVM at Job begin => a JVM is started, but maybe not used starting the JVM before usage => might fail, because started before submitting a job for usage => same problem as RUNJVA with more effort! setting global classpath => might interfere with other applications using extdir => even worse, has higher priority than classpath setting Dieter Bender Inside ArdGate
  • 52. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Classpath Problem first problem: you will need 3 jar files in your classpath starting the JVM at Job begin => a JVM is started, but maybe not used starting the JVM before usage => might fail, because started before submitting a job for usage => same problem as RUNJVA with more effort! setting global classpath => might interfere with other applications using extdir => even worse, has higher priority than classpath setting Dieter Bender Inside ArdGate
  • 53. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Classpath Problem first problem: you will need 3 jar files in your classpath starting the JVM at Job begin => a JVM is started, but maybe not used starting the JVM before usage => might fail, because started before submitting a job for usage => same problem as RUNJVA with more effort! setting global classpath => might interfere with other applications using extdir => even worse, has higher priority than classpath setting Dieter Bender Inside ArdGate
  • 54. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Classpath Problem first problem: you will need 3 jar files in your classpath starting the JVM at Job begin => a JVM is started, but maybe not used starting the JVM before usage => might fail, because started before submitting a job for usage => same problem as RUNJVA with more effort! setting global classpath => might interfere with other applications using extdir => even worse, has higher priority than classpath setting Dieter Bender Inside ArdGate
  • 55. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Classpath Problem first problem: you will need 3 jar files in your classpath starting the JVM at Job begin => a JVM is started, but maybe not used starting the JVM before usage => might fail, because started before submitting a job for usage => same problem as RUNJVA with more effort! setting global classpath => might interfere with other applications using extdir => even worse, has higher priority than classpath setting Dieter Bender Inside ArdGate
  • 56. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Why I Gave Up second problem: for one java statement you need multiple RPG declarations and statements. 10 minutes programming java <=> one day programming embedded Java in RPG third problem: hard to read debug and even worse in production! impossible to use log4j maybe faster for subsequent calls in the same job than RUNJVA scalability even worse (the programm could be called in every Job!) Dieter Bender Inside ArdGate
  • 57. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Why I Gave Up second problem: for one java statement you need multiple RPG declarations and statements. 10 minutes programming java <=> one day programming embedded Java in RPG third problem: hard to read debug and even worse in production! impossible to use log4j maybe faster for subsequent calls in the same job than RUNJVA scalability even worse (the programm could be called in every Job!) Dieter Bender Inside ArdGate
  • 58. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Why I Gave Up second problem: for one java statement you need multiple RPG declarations and statements. 10 minutes programming java <=> one day programming embedded Java in RPG third problem: hard to read debug and even worse in production! impossible to use log4j maybe faster for subsequent calls in the same job than RUNJVA scalability even worse (the programm could be called in every Job!) Dieter Bender Inside ArdGate
  • 59. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The RPG Perspective what we want install AppServer4RPG implement the call Dieter Bender Inside ArdGate
  • 60. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The RPG Perspective what we want install AppServer4RPG implement the call Dieter Bender Inside ArdGate
  • 61. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The RPG Perspective what we want install AppServer4RPG implement the call Dieter Bender Inside ArdGate
  • 62. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Closing the Chain to Java now we need an EventHandler to be called configure AppServer4RPG Dieter Bender Inside ArdGate
  • 63. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Closing the Chain to Java now we need an EventHandler to be called configure AppServer4RPG Dieter Bender Inside ArdGate
  • 64. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version What Happens Now Calling the RPG Programm? the RPG part puts its input parameters to the request DS and calls fireEventP the RPG part of JVAGATE creates a response DTAQ sends the data (and an identifier for the caller Job) in packages to the JAVAQ listens on the responseQ for the answer Now the Java part of AppServer4RPG does its work (hopefully it was started) starts a new worker Thread to be ready for the next request creates a Handler for the requested Event, creates Request and Response Objects and calls the performWork of the Handler sends the response Data back in packages to the ResponseQ. known by the identifier passed with the request Dieter Bender Inside ArdGate
  • 65. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version What Happens Now Calling the RPG Programm? the RPG part puts its input parameters to the request DS and calls fireEventP the RPG part of JVAGATE creates a response DTAQ sends the data (and an identifier for the caller Job) in packages to the JAVAQ listens on the responseQ for the answer Now the Java part of AppServer4RPG does its work (hopefully it was started) starts a new worker Thread to be ready for the next request creates a Handler for the requested Event, creates Request and Response Objects and calls the performWork of the Handler sends the response Data back in packages to the ResponseQ. known by the identifier passed with the request Dieter Bender Inside ArdGate
  • 66. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version What Happens Now Calling the RPG Programm? the RPG part puts its input parameters to the request DS and calls fireEventP the RPG part of JVAGATE creates a response DTAQ sends the data (and an identifier for the caller Job) in packages to the JAVAQ listens on the responseQ for the answer Now the Java part of AppServer4RPG does its work (hopefully it was started) starts a new worker Thread to be ready for the next request creates a Handler for the requested Event, creates Request and Response Objects and calls the performWork of the Handler sends the response Data back in packages to the ResponseQ. known by the identifier passed with the request Dieter Bender Inside ArdGate
  • 67. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The EventHandler gets a Request a simple PORDS2POJO binary is set with Constructor getter for properties the EventHandler Dieter Bender Inside ArdGate
  • 68. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The EventHandler gets a Request a simple PORDS2POJO binary is set with Constructor getter for properties the EventHandler Dieter Bender Inside ArdGate
  • 69. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The EventHandler gets a Request a simple PORDS2POJO binary is set with Constructor getter for properties the EventHandler Dieter Bender Inside ArdGate
  • 70. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Results Transaction Times of subseconds first call in a Job as fast as following (JVM is prestarted) very scalable (one JVM serves multiple RPG Jobs) no Classpath issues, simply throw the needed jar files to the lib directory of AppServer4RPG multiple instances of AppServer4RPG could run on the same box with diffrent JVM settings AppServer4RPG could be installed on a dedicated server less programming effort than embedded Java in RPG flexible logging with log4j simplifies trouble shooting Dieter Bender Inside ArdGate
  • 71. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Results Transaction Times of subseconds first call in a Job as fast as following (JVM is prestarted) very scalable (one JVM serves multiple RPG Jobs) no Classpath issues, simply throw the needed jar files to the lib directory of AppServer4RPG multiple instances of AppServer4RPG could run on the same box with diffrent JVM settings AppServer4RPG could be installed on a dedicated server less programming effort than embedded Java in RPG flexible logging with log4j simplifies trouble shooting Dieter Bender Inside ArdGate
  • 72. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Results Transaction Times of subseconds first call in a Job as fast as following (JVM is prestarted) very scalable (one JVM serves multiple RPG Jobs) no Classpath issues, simply throw the needed jar files to the lib directory of AppServer4RPG multiple instances of AppServer4RPG could run on the same box with diffrent JVM settings AppServer4RPG could be installed on a dedicated server less programming effort than embedded Java in RPG flexible logging with log4j simplifies trouble shooting Dieter Bender Inside ArdGate
  • 73. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Results Transaction Times of subseconds first call in a Job as fast as following (JVM is prestarted) very scalable (one JVM serves multiple RPG Jobs) no Classpath issues, simply throw the needed jar files to the lib directory of AppServer4RPG multiple instances of AppServer4RPG could run on the same box with diffrent JVM settings AppServer4RPG could be installed on a dedicated server less programming effort than embedded Java in RPG flexible logging with log4j simplifies trouble shooting Dieter Bender Inside ArdGate
  • 74. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Results Transaction Times of subseconds first call in a Job as fast as following (JVM is prestarted) very scalable (one JVM serves multiple RPG Jobs) no Classpath issues, simply throw the needed jar files to the lib directory of AppServer4RPG multiple instances of AppServer4RPG could run on the same box with diffrent JVM settings AppServer4RPG could be installed on a dedicated server less programming effort than embedded Java in RPG flexible logging with log4j simplifies trouble shooting Dieter Bender Inside ArdGate
  • 75. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version The Results Transaction Times of subseconds first call in a Job as fast as following (JVM is prestarted) very scalable (one JVM serves multiple RPG Jobs) no Classpath issues, simply throw the needed jar files to the lib directory of AppServer4RPG multiple instances of AppServer4RPG could run on the same box with diffrent JVM settings AppServer4RPG could be installed on a dedicated server less programming effort than embedded Java in RPG flexible logging with log4j simplifies trouble shooting Dieter Bender Inside ArdGate
  • 76. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Summary Don’t try to write Java code in RPG, provide Java methods with Datastructure parameter interfaces for RPG usage! Let your Java Code run in a prestarted resident JVM, communicating asynchronous with your native programms. Outlook (Nice to have!) Dynamic PORDS2POJO Beans. True Tomcat Version of AppServer4RPG. Dieter Bender Inside ArdGate
  • 77. Introduction Generating PDF from HTML RPG Calls Java The RUNJVA Way AppServer4RPG The Embedded Java in RPG Way Benchmark Example The Gleiberg Version Questions? Dieter Bender Inside ArdGate