gVote is a voter information platform that walks users through steps in the U.S. voting procedure by helping users register to vote, listing relevant upcoming elections, and providing ballot information and nearby polling sites, so that users are prepared to vote on election day.
To avoid having to delete all non-election entities from datastore with every request for ballot information from the datastore the following have been done:
Contests and Referendums now have a new field called division which specify which division a certain contest/referendum corresponds to.
Elections now have a new field called divisions which is a set of all the electoral divisions queried with respect to the election.
A query to Google Civic Information API's representativeInfoByAddress query is made in InfoCardServlet for each ballot information request to determine which electoral divisions the provided address belongs to.
In InfoCardServlet, voterInfoQuery is only called when the address provided belongs to one or more districts that are not in the divisions field of the current election.
Using cookies, the information returned by representativeInfoByAddress is used in ContestsServlet to return only the Contests and Referendums relevant to the user.
Polling Station Information will no longer be stored on the datastore and instead PollingStationServlet now makes a call to voterInfoQuery to get the polling station information for every request.
To avoid having to delete all non-election entities from datastore with every request for ballot information from the datastore the following have been done:
division
which specify which division a certain contest/referendum corresponds to.divisions
which is a set of all the electoral divisions queried with respect to the election.representativeInfoByAddress
query is made inInfoCardServlet
for each ballot information request to determine which electoral divisions the provided address belongs to.InfoCardServlet
,voterInfoQuery
is only called when the address provided belongs to one or more districts that are not in thedivisions
field of the current election.representativeInfoByAddress
is used inContestsServlet
to return only the Contests and Referendums relevant to the user.PollingStationServlet
now makes a call tovoterInfoQuery
to get the polling station information for every request.