Openfire3.9.3 into eclipse

Recommended for you: Get network issues from WhatsUp Gold. Not end users.

Most recently in the development of IOS communication with the openfire function, the need to develop a push plug-in, openfire3.9.3 into the source code has been wrong very depressed, the following is the solution source code into eclipse error reporting

To the point, see this article friends should be JDK, eclipse is already installed, I will not install these development tools to repeat, carrying out openfire download address: .

1, Download the source code of openfire_src_3_9_3.zip, at present the latest version is 3.9.3

2, To download a good openfire_src_3_9_3.zip decompression to the work space, structure and contents are as follows:


 3, The openfire_src\build\eclipse directory settings, classpath, project are copied to the openfire_src\ directory, Then openfire_src\classpth, openfire_src\project, openfire_src\settings modified Eclipse project configuration file format, Renamed to add the last point in each original name., .classpth, .project, .settings. Note: in the windows cannot be renamed, need to operate in the DOS below, enter the corresponding directory implementation, rename classpth.Classpth can be executed    , like other two files:



 

4, Then open the Eclipse, select File > Import... – > Existing Projects into; Workspace F:\workspace\openfire_src   selection can be imported:



 

The following directory structure   after import:



  everyone there will be an exclamation mark found himself on this project, enter the path of building, will find:



 

This shows that the jar package is missing, the bouncycastle.jar will join the project.,

The three error occurs after removal, never mind, we step by step to fix the error, \openfire_src\src\java error, because the jar package, not to introduce, we introduce them to:



 

Note: a reference only one, so need to operate four times, it. Click on the OK, we found that the \openfire_src\src\java error has no. \Openfire_src\src\plugins\clustering\src\java error, Because of the lack of coherence.jar, coherence-work.jar, This three tangosol.jar jar package, We will be copied to the \openfire_src\src\plugins\clustering\lib directory, Then the three jar package, Join the build path:



  then we found \openfire_src\src\plugins\clustering\src\java error has disappeared, takes the package I will upload to the attachment

Finally, a \openfire_src\src\plugins\sip\src\java error because the SipCommRouter.java and SipManager.java of the two class does not implement the abstract methods and exception handling, The simplest approach is automatic repair function can be repaired by Eclipse. Now we find our program has no errors.

Then the following can compile and run the openfire setup files, of course can also download the corresponding system installation

5, The ANT compiler project

Eclipse has integrated the Ant, So we only need to right click on the /openfire_src/build/build.xml file, Select the Run As – > Ant Build can be compiled;, After successful program, It generates two new folders in /openfire_src/ with the directory: target and work .

6, Run the Openfire project

①, The   /openfire_src/src/i18n, /openfire_src/src/resources/jar, /openfire_src/build/lib/dist folder to the Source in the Build Path configuration, as shown in Fig.:



  configuration parameters.

Select Run - > Run Configurations... Java Application left, right click, select New:



  the default name:New_configuration revise: ServerStarter.

Select the Main tab, click the Browse button to select the openfire_src project; click the Search button input: ServerStarter automatic filter selection: ServerStarter – org.jivesoftware.openfire.starter:



Select the Arguments tab  , fill in the VM arguments:

-DopenfireHome="${workspace_loc:openfire_src}/target/openfire"

Note: the project path ${workspace_loc:openfire_src}

Select the Common tab, Debug and Run tick (after convenient fast start), and then click apply, then click Run:



 

 

Enter the address of the browser: Enter:

 



To solve the error can plug in development.  

Reprinted from: http://blog.csdn.net/lovexieyuan520/article/details/37743433

 

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download

Posted by Andra at July 29, 2014 - 11:30 AM