After several information’s requests concerning the Spring certification, I have decided to write these some words about the SFC certification (Spring Framework Core) in order to share my resources and mock exams.

First, I have received during october 2008, the first training “Spring Framework Core” (4 days) at Luxembourg by the company Spring Source (Creators of the Spring framework). At the end of training, a voucher had been offered to allow the examination. Then, I took the exam SFC 2.5 during june 2011. This exam was about the version 2.5 of Spring, it had 50 multiple choice questions (one only possible answer per question), 88 minutes allotted for this exam. It is success when more than 75% of correct answers, and a provisional certificate of achievement is printed and delivered. The final certificate is received by email and/or post a few weeks later.

Concerning the registration and scheduling of exams, the candidates must register and schedule by:

  • Visiting the Pearsonvue website or Calling the Pearson VUE Call Center.
  • Spring exam should be scheduled at least one full business day in advance.
  • Candidates who need to cancel or reschedule their appointment must do so within 24 hours of their exam appointment.

For my preparation, I have studied Spring with:

For the mock exams, you could use the following resources which some are free and others by paying some euros:

To conclude this post, I propose you a ZIP bonus: a ZIP file containing the several mock exams with the corrections.

Best regards,


Today, I propose a very simple fake SMTP server designed for unit and system testing applications that send email messages. The class is a ServerSocket (Runnable) which responds to the standard SMTP commands but does not deliver messages to the user. The messages are printed in the full SMTP server log containing all the information exchanged between the SMTP server & the clients.

This ServerSocket could be executed in standalone in a Runnable or in a WEB project via a ContextServletListener configured in the web.xml:

	public static void main(String[] args) {
		try {
			FakeSMTPServer srv = new FakeSMTPServer();
			while (true) {
			} // end-while
		} catch (Exception e) {
		} // end-try

The classes in attachment need the junit-4.1.jar, mail-1.3.2.jar and spring-2.5.5.jar to be used.

Note: There is other products like SMTP4DEV usable directly without installation.

For the needs of a project, I have had the opportunity to use the Apache Commons Compress libary in order to archive and compress files in ZIP, TAR, GZIP.

Here, a brief presentation of this library from Apache:
Apache Commons Compress software defines an API for working with compression and archive formats. These include: bzip2, gzip, pack200 and ar, cpio, jar, tar, zip, dump. This is a Java API for working with tar, zip, gz, jar, cpio and bzip2 files. The code has origins in other Apache projects like Excalibur, Ant, Commons-IO and jRPM.
The compress component is split into compressors and archivers. While compressors (un)compress streams that usually store a single entry, archivers deal with archives that contain structured content represented by ArchiveEntry instances which in turn usually correspond to single files or directories. Currently the bzip2 and gzip formats are supported as compressors where gzip support is provided by the package of the Java class library. The ar, cpio, tar and zip formats are supported as archivers where the zip implementation provides capabilities that go beyond the features found in The compress component provides abstract base classes for compressors and archivers together with factories that can be used to choose implementations by algorithm name.
In the case of input streams the factories can also be used to guess the format and provide the matching implementation.

A note concerning the differences between GZIP and ZIP:
+ GZIP files (the Gnu format) are not archives and compress only one file. GZIP is essentially a one file subset of the Zip format.
+ GZIP compresses only one file and does not have a header. ZIP contains header information about what files are contained in the file.
+ ZIP is an archive file format, popularized on PCs, that contains multiple compressed files.

In the attachments files, you could find a project using commons-compress-1.0.jar with the classes:
CompressArchiveUtil: tool allowing the manipulations of tar or tar.gz documents;
ZipUtil: Utility to Zip and Unzip nested directories recursively

The outputs/files are created in test_compress1\bin\jUnitResources folder.

Source: Apache Commons Compress

During my self-training on GWT (Google Web Toolkit) and GAE (Google App Engine) which will be the topic of several next posts (presentation GWT and GEA, creation of new application with 2 interfaces JSP and GWT, securised by Spring security and the persistence with JPA/App Engine datastore, deployment on GEA..), I have encountered a deficiency or missing method in the FlexTable component of GWT.
This component has not a method to show/hide columns in Flextables at 1 line.

There is a method to hide a row:

    compFlextable.getRowFormatter().setVisible(arg0, arg1); 

But there is not method to hide a specific column:

    compFlextable.getColumnFormatter().setVisible(arg0, arg1); 

Here, a simple method which allows the hiding and showing of a column in a Flextable by the hiding of the column’s cell on each row:

	private void setColumnVisible(FlexTable table, int Col, boolean b) {
		for (int i = 0; i < table.getRowCount(); i++) {
			table.getCellFormatter().setVisible(i, Col, b);
Page 52 of 53:« First« 49 50 51 52 53 »
Copyright ® 2012 Huseyin Ozveren. No reproduction, even partial, can be used from this site and all its contents including text, documents, images, etc.. without the express permission of the author.