Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0029275
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminoralways2015-03-13 15:282022-02-01 08:05
ReporteregoitzView Statuspublic 
Assigned ToTriage Platform Base 
PrioritynormalResolutionopenFixed in Version
StatusacknowledgedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0029275: Executing an smartbuild uses a Openbravo.properties located on a config folder on the same level than the installation folder

DescriptionWhen executing an smartbuild the Openbravo.properties file is use to get the data to connect the database.
By default the file is located on the config folder on the Openbravo installation folder.
If for any case you have a config folder on the parent folder of the OPenbravo installation folder with a Openbravo.properties file, that file is used.

If it is not correct you will get a error.
Steps To ReproduceHaving a Openbravo installation working on the following folder:
/opt/OpenbravoERP
copy the config folder to have also the config folder on the following location:
/opt/config
Change the
/opt/config/Openbravo.properties to point to a not existint database
Go to /opt/OpenbravoERP
execute ant smartubuild
You get a error

generate.entities.quick:
     [java] 0 [main] INFO org.openbravo.base.gen.GenerateEntitiesTask - Model has not changed since last run, not re-generating entities
     [java] 59 [main] ERROR org.openbravo.database.ConnectionProviderImpl - Error getting connection
     [java] org.postgresql.util.PSQLException: Connection refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
     [java] at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:136)
     [java] at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:66)
     [java] at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:125)
     [java] at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:30)
     [java] at org.postgresql.jdbc3g.AbstractJdbc3gConnection.<init>(AbstractJdbc3gConnection.java:22)
     [java] at org.postgresql.jdbc4.AbstractJdbc4Connection.<init>(AbstractJdbc4Connection.java:30)
     [java] at org.postgresql.jdbc4.Jdbc4Connection.<init>(Jdbc4Connection.java:24)
Proposed SolutionThe issue is in OBRebuildAppender:
if (new File("../../config/Openbravo.properties").exists())
fProp = new File("../../config/Openbravo.properties");
else if (new File("../config/Openbravo.properties").exists())
fProp = new File("../config/Openbravo.properties");
else if (new File("config/Openbravo.properties").exists())
fProp = new File("config/Openbravo.properties");
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2015-03-13 15:28 egoitz New Issue
2015-03-13 15:28 egoitz Assigned To => AugustoMauch
2015-03-13 15:28 egoitz Modules => Core
2015-03-13 15:28 egoitz Triggers an Emergency Pack => No
2015-03-16 08:00 alostale Status new => acknowledged
2015-03-17 14:37 alostale Assigned To AugustoMauch => platform
2022-02-01 08:05 alostale Assigned To platform => Triage Platform Base


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker