Are you a candidate looking to sharpen your skills? Try our practice tests or view sample interview questions & Get hired by the best. Click Here×

Spring Batch Online Skill Assessment Test

Topics Covered

  • Spring Batch Fragments
  • Spring Hibernate Integration
  • Spring Batch
  • Annotations
  • Spring Batch with MySQL
  • Spring Batch Code
  • Spring Batch Configuration

Useful for hiring

  • Spring Batch Developer
  • Senior Java Developer
  • JavaScript Developer

Start hiring job-fit candidates using this assessment

GET A DEMO

"Finding quality talent is a challenge more so when you consider the sheer number of resumes we get each year. To top this, the time we spent on our recruitment process was humongous. Interview Mocha helped us to cut down on our candidate filtration time by 40%, making it our preferred assessment tool."

Pedro Furtado, Altran,
Capacity Manager
Question

Complete the following spring code to make it work correctly.

StaxEventItemWriter staxItemWriter = new StaxEventItemWriter()
…………………………………………………………………………

Map aliases = new HashMap();
aliases.put("customer","org.springframework.batch.sample.domain.CustomerCredit");
aliases.put("credit","java.math.BigDecimal");
aliases.put("name","java.lang.String");
Marshaller marshaller = new XStreamMarshaller();
marshaller.setAliases(aliases);

Answer
    • ExecutionContext executionContext = new ExecutionContext();

    • FileSystemResource resource = new FileSystemResource("data/outputFile.xml")

    • Set<Long> getRunningExecutions(String staxItemWriter) throws NoSuchJobException;

    • private Resource directory;
      public void setDirectoryResource(Resource directory) {
          this.directory = directory;
      }

Question

The BATCH_JOB_INSTANCE table holds all information relevant to a JobInstance and serves as the top of the overall hierarchy. How can you use DDL to create it?

Answer
    • CREATE TABLE BATCH_JOB_INSTANCE  (
        JOB_INSTANCE_ID BIGINT  PRIMARY KEY ,
        VERSION BIGINT,    
        JOB_NAME VARCHAR(100) NOT NULL ,
        JOB_KEY VARCHAR(2500)
       constraint JOB_ INSTANCE_PARAMS_FK foreign key (JOB_ INSTANCE_ID)
       references BATCH_JOB_ INSTANCE (JOB_ INSTANCE _ID)
      );

    • CREATE TABLE BATCH_JOB_INSTANCE  (
        JOB_INSTANCE_ID BIGINT  PRIMARY KEY ,
        VERSION BIGINT,    
        JOB_NAME VARCHAR(100) NOT NULL ,
        JOB_KEY VARCHAR(2500)
      );

    • CREATE TABLE BATCH_JOB_INSTANCE  (
        JOB_INSTANCE_ID BIGINT  PRIMARY KEY ,
        VERSION BIGINT,    
        JOB_NAME VARCHAR(100) NULL,
        JOB_KEY VARCHAR(2500)
       constraint JOB_ INSTANCE_PARAMS_FK foreign key (JOB_ INSTANCE_ID)
       references BATCH_JOB_ INSTANCE (JOB_ INSTANCE _ID)
      );

    • CREATE TABLE BATCH_JOB_INSTANCE  (
        JOB_INSTANCE_ID BIGINT  PRIMARY KEY ,
        VERSION BIGINT,    
        JOB_NAME VARCHAR(100) NULL ,
        JOB_KEY VARCHAR(2500)
      );

Question

Complete the attribute of the following transaction:

 
   
   
 


Note: There can be multiple correct answers to this question.

Answer
    • propagation="REQUIRED"

    • timeout="30"

    • propagation="REQUESTED" 

    • timeout="0"

Good News! You can customize this test as per your requirement

  • Choose and add questions from Interview Mocha question libraries

  • Add your own set of questions

  • Customize test settings like duration, number of questions, passing score, web proctoring and much more

  • Mail us at support@interviewmocha.com to create a custom test

Looking for a tailor-made test, to suit your assessment needs?

Get in touch

Global companies using Mocha assessments

  • altran
  • credit suisse
  • sephora
  • nielsen
  • capgemini
  • akamai

How Mocha assessments are brewed

Speed up your IT recruitment with Interview Mocha

  • 500+ IT skill tests
  • 20+ coding languages
  • 50+ domain knowledge tests
  • 100+ digital 2.0 skill tests
  • Customer focus aptitude tests
  • Enterprise ready features & more...
GET A DEMO

Why hiring managers and recruiters across the globe love Interview Mocha

Take your first step to hire job fit candidates

GET A DEMO