Project

General

Profile

« Previous | Next » 

Revision 10e96c9d

Added by Cherian Mathew about 10 years ago

DatabaseServiceHibernateImpl : added important fixme
CdmPersistentDataSource : clean up
CdmPersistentXMLSource : added context path enum for remoting
CdmApplicationUtils : variable change

View differences:

cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/api/application/CdmApplicationUtils.java
75 75
     */
76 76
    static private boolean copyResource(File directory, String resourceFileName){
77 77
        try {
78
            InputStream isDataSource = CdmUtils.class.getResourceAsStream(CdmPersistentDataSource.DATASOURCE_PATH + resourceFileName);
78
            InputStream isDataSource = CdmUtils.class.getResourceAsStream(CdmPersistentXMLSource.CDMSOURCE_PATH + resourceFileName);
79 79
            if (isDataSource != null){
80 80
                File fileToCopy = new File(directory + File.separator + resourceFileName);
81 81
                if (fileToCopy.createNewFile()){
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/config/CdmPersistentXMLSource.java
64 64
		SERVER, 		
65 65
		PORT,		
66 66
		FILEPATH,
67
		CONTEXTPATH,
67 68
		USERNAME,
68 69
		PASSWORD, 
69 70
		NOMENCLATURAL_CODE,
......
82 83
					return "port";
83 84
				case FILEPATH:
84 85
					return "filePath";
86
				case CONTEXTPATH:
87
					return "contextPath";
85 88
				case USERNAME:
86 89
					return "username";
87 90
				case PASSWORD:
cdmlib-persistence/src/main/java/eu/etaxonomy/cdm/database/CdmPersistentDataSource.java
52 52
	private static final Logger logger = Logger.getLogger(CdmPersistentDataSource.class);
53 53
	
54 54
	public static final String DATASOURCE_BEAN_POSTFIX = "DataSource";
55
	public final static String DATASOURCE_PATH = "/eu/etaxonomy/cdm/";
55

  
56 56
		
57 57
	private String beanName;
58 58
	private String dbUrl;
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/DatabaseServiceHibernateImpl.java
179 179
	
180 180
    /**
181 181
     * Execute a SQL query which returns a single value
182
     * FIXME:Remoting maybe not a smart idea to have this method here 
183
     * since private methods can also be accessed via reflection, which
184
     * could be problematic specially for the case of remoting.
182 185
     * 
183 186
     * @param query , which returns a single value
184 187
     * @return
......
205 208
    
206 209
    /**
207 210
     * Executes a query and returns the ResultSet.
208
     * 
211
     * FIXME:Remoting maybe not a smart idea to have this method here 
212
     * since private methods can also be accessed via reflection, which
213
     * could be problematic specially for the case of remoting.
214
     *      
209 215
     * @return ResultSet for the query.
210 216
     * @throws SQLException
211 217
     */

Also available in: Unified diff