[jboss-jira] [JBoss JIRA] (WFLY-3724) Batch jobs don't receive partition-specific parameters

Cheng Fang (JIRA) issues at jboss.org
Fri Sep 5 14:19:00 EDT 2014


    [ https://issues.jboss.org/browse/WFLY-3724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12999529#comment-12999529 ] 

Cheng Fang commented on WFLY-3724:
----------------------------------

Just a note on how to run Java EE 7 Tutorial phonebilling app on WildFly:

1,  modify persistence.xml to use hibernate persistence properties, instead of eclipselink ones.  If using h2 datasource as the persistence jta-data-source, use H2Dialet.

{noformat}
<properties>
      <!--<property name="eclipselink.ddl-generation" value="drop-and-create-tables"/>-->
        <property name="hibernate.hbm2ddl.auto" value="create"/>
        <property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/>
    </properties>
{noformat}

2, optionally, you can use a custom datasource (not the default one in WildFly) so you can check batch application data or batch runtime data with another tool (db browser or IDE).  For example, to use file-based H2 database:

{noformat}
<datasources>
                <datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS" enabled="true" use-java-context="true">
                    <connection-url>jdbc:h2:~/jberet-repo;MVCC=true</connection-url>
                    <driver>h2</driver>
                </datasource>
{noformat}

3, optionally use jberet jdbc job repository, instead of the default in-memory job repository, so you can check batch runtime data even after server shutdown.

{noformat}
<subsystem xmlns="urn:jboss:domain:batch:1.0">
            <job-repository>
                <jdbc jndi-name="java:jboss/datasources/ExampleDS"/>
            </job-repository>
{noformat}

These changes can be made with WildFly CLI, and the above xml reflects the configuration after the change.

> Batch jobs don't receive partition-specific parameters
> ------------------------------------------------------
>
>                 Key: WFLY-3724
>                 URL: https://issues.jboss.org/browse/WFLY-3724
>             Project: WildFly
>          Issue Type: Bug
>          Components: Batch
>    Affects Versions: 8.1.0.Final
>         Environment: Windows 7 Home Premium Service Pack 1 64-bit + JDK8u11 + WildFly 8.1.0 Final
>            Reporter: Ari Silvan
>            Assignee: Enrique González Martínez
>
> When defining a batch job chunk step to run as partitions, ItemReader doesn't receive the partition-specific parameters specified by an implementation of the PartitionPlan interface. Parameters are null. See steps to reproduce for further details.



--
This message was sent by Atlassian JIRA
(v6.3.1#6329)



More information about the jboss-jira mailing list