Merge pull request #1609 from molecula/more-merge-lattice-stuff

CLOUD-65 Finalize UI merge
This commit is contained in:
Alan Bernstein 2021-05-26 10:43:52 -05:00 committed by GitHub
commit 90e2d15cf0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 16 additions and 23 deletions

View file

@ -37,11 +37,23 @@ commands:
skip-if-root-unchanged:
description: "skips the parent job if the PR includes no changes to pilosa"
steps:
- run: '[ -n "$(git diff --name-only HEAD $(git merge-base master HEAD) | grep -v \"^lattice/\")" ] || circleci step halt || true'
- run: |
ROOT_CHANGED_FILES="$(git diff --name-only HEAD $(git merge-base master HEAD) | grep -v '^lattice/')"
echo "ROOT_CHANGED_FILES = $ROOT_CHANGED_FILES"
if [ -z $ROOT_CHANGED_FILES ] ; then
echo "halting step"
circleci step halt
fi
skip-if-lattice-unchanged:
description: "skips the parent job if the PR includes no changes to lattice"
steps:
- run: '[ -n "$(git diff --name-only HEAD $(git merge-base master HEAD) | grep ^lattice/\")" ] || circleci step halt || true'
- run: |
LATTICE_CHANGED_FILES="$(git diff --name-only HEAD $(git merge-base master HEAD) | grep '^lattice/')"
echo "LATTICE_CHANGED_FILES = $LATTICE_CHANGED_FILES"
if [ -z $LATTICE_CHANGED_FILES ] ; then
echo "halting step"
circleci step halt
fi
jobs:
setup:

View file

@ -58,15 +58,6 @@ Check out how the Pilosa [Data Model](https://www.pilosa.com/docs/data-model/) w
You can interact with Pilosa directly in the console using the [Pilosa Query Language](https://www.pilosa.com/docs/query-language/) (PQL).
## Upgrading UI
Lattice is now a submodule of Pilosa, for the purpose of keeping the frontend and backend components of the UI system synchronized. When making a change to the UI that requires changing both the backend and frontend, follow steps in this order:
1. merge frontend (Lattice) PR
2. run `make upgrade-lattice`
3. run `git add lattice`, `git commit -m"Upgrade Lattice"`, `git push`
4. merge backend (Pilosa) PR
## Client Libraries
There are supported libraries for the following languages:

5
api.go
View file

@ -1841,11 +1841,6 @@ func (api *API) Version() string {
return strings.TrimPrefix(Version, "v")
}
// Version returns the Lattice version.
func (api *API) LatticeVersion() string {
return LatticeVersionInfo()
}
// Info returns information about this server instance.
func (api *API) Info() serverInfo {
si := api.server.systemInfo

View file

@ -363,7 +363,7 @@ func (h *Handler) collectStats(next http.Handler) http.Handler {
// latticeRoutes lists the frontend routes that do not directly correspond to
// backend routes, and require special handling.
var latticeRoutes = []string{"/tables", "/query"}
var latticeRoutes = []string{"/tables", "/query", "/querybuilder"} // TODO somehow pull this from some metadata in the lattice directory
// newRouter creates a new mux http router.
func newRouter(handler *Handler) http.Handler {
@ -507,7 +507,7 @@ type statikHandler struct {
func newStatikHandler(h *Handler) statikHandler {
fs, err := h.fileSystem.New()
if err == nil {
h.logger.Printf("enabled Web UI (%s) at %s", h.api.LatticeVersion(), h.url)
h.logger.Printf("enabled Web UI at %s", h.url)
}
return statikHandler{

View file

@ -23,7 +23,6 @@ var Version string
var Commit string
var Variant string
var BuildTime string
var LatticeCommit string
var GoVersion string = runtime.Version()
var TrialDeadline string
@ -59,7 +58,3 @@ func VersionInfo() string {
}
return prefix + "Pilosa" + suffix
}
func LatticeVersionInfo() string {
return "g" + LatticeCommit
}