Merge "Issue #2044 Fix topo retrieval in ifpnetCDF" into development

Former-commit-id: d03977c8be [formerly f0b278ad16] [formerly f3138d7bd9] [formerly d03977c8be [formerly f0b278ad16] [formerly f3138d7bd9] [formerly 668cbd0c87 [formerly f3138d7bd9 [formerly 50129c57d6cc798da0dcf6b5f9b84811af5f6fa1]]]]
Former-commit-id: 668cbd0c87
Former-commit-id: 7216cc451e [formerly 3221f96696] [formerly a34f34558a475b7d104e70954a47c3c1c7f1904b [formerly 28863afe77]]
Former-commit-id: e2baa80fd6e5878a963ef4fe8b342329c98723f8 [formerly 26a029cb5f]
Former-commit-id: 9a2bcc145c
This commit is contained in:
Ron Anderson 2013-07-25 18:17:08 -05:00 committed by Gerrit Code Review
commit 88956eedbf

View file

@ -40,7 +40,7 @@ from com.raytheon.edex.plugin.gfe.config import IFPServerConfigManager
from com.raytheon.uf.common.dataplugin.gfe.config import ProjectionData_ProjectionType as ProjectionType
from com.raytheon.edex.plugin.gfe.smartinit import IFPDB
from com.raytheon.edex.plugin.gfe.util import CartDomain2D
from com.raytheon.edex.plugin.gfe.server.database import TopoDatabaseManager
from com.raytheon.edex.plugin.gfe.server import IFPServer
from com.raytheon.uf.common.dataplugin.gfe.db.objects import DatabaseID
from com.raytheon.uf.common.dataplugin.gfe.reference import ReferenceID
from com.raytheon.uf.common.dataplugin.gfe.reference import ReferenceData
@ -465,11 +465,13 @@ def storeTopoGrid(client, file, databaseID, maskGrid, clipArea):
"Stores the topo grid in the database"
# Get the grid location and projection information
gridLoc = IFPServerConfigManager.getServerConfig(DatabaseID(databaseID).getSiteId()).dbDomain()
ifpServer = IFPServer.getActiveServer(DatabaseID(databaseID).getSiteId())
gridLoc = ifpServer.getConfig().dbDomain()
pDict = gridLoc.getProjection()
# Get the topo grid
topoGrid = TopoDatabaseManager.getTopoData(gridLoc).getPayload().get(0).__numpy__[0]
topoGrid = ifpServer.getTopoMgr().getTopoData(gridLoc).getPayload().__numpy__[0]
topoGrid = clipToExtrema(topoGrid, clipArea)
topoGrid = numpy.flipud(topoGrid)