Skip to content

Commit b30e6f4

Browse files
authored
Merge pull request #810 from clowder-framework/release/beta-1
beta.1 release
2 parents a555862 + f4c9408 commit b30e6f4

File tree

10 files changed

+79
-7
lines changed

10 files changed

+79
-7
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Clowder V2 (In Development - Alpha Release)
1+
# Clowder V2 (In Active Development)
22

33
*For the previous version of Clowder, please see [Clowder V1](https://github.com/clowder-framework/clowder).*
44

backend/app/config.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ class Settings(BaseSettings):
99
API_V2_STR: str = "/api/v2"
1010
admin_email: str = "[email protected]"
1111
frontend_url: str = "http://localhost:3000"
12+
version: str = "2.0.0-beta.1"
1213

1314
# Unique secret for hashing API keys. Generate with `openssl rand -hex 32`
1415
local_auth_secret = "clowder_secret_key"

backend/app/main.py

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
from app.models.users import UserDB, UserAPIKeyDB, ListenerAPIKeyDB
3131
from app.models.visualization_config import VisualizationConfigDB
3232
from app.models.visualization_data import VisualizationDataDB
33-
from app.routers import folders, groups
33+
from app.routers import folders, groups, status
3434
from app.routers import (
3535
users,
3636
authorization,
@@ -57,7 +57,17 @@
5757
logger = logging.getLogger(__name__)
5858

5959
app = FastAPI(
60-
title=settings.APP_NAME, openapi_url=f"{settings.API_V2_STR}/openapi.json"
60+
title=settings.APP_NAME,
61+
openapi_url=f"{settings.API_V2_STR}/openapi.json",
62+
description="A cloud native data management framework to support any research domain. Clowder was "
63+
"developed to help researchers and scientists in data intensive domains manage raw data, complex "
64+
"metadata, and automatic data pipelines. ",
65+
version="2.0.0-beta.1",
66+
contact={"name": "Clowder", "url": "https://clowderframework.org/"},
67+
license_info={
68+
"name": "Apache 2.0",
69+
"url": "https://www.apache.org/licenses/LICENSE-2.0.html",
70+
},
6171
)
6272
BaseConfig.arbitrary_types_allowed = True
6373

@@ -178,6 +188,7 @@
178188
tags=["thumbnails"],
179189
dependencies=[Depends(get_current_username)],
180190
)
191+
api_router.include_router(status.router, prefix="/status", tags=["status"])
181192
api_router.include_router(keycloak.router, prefix="/auth", tags=["auth"])
182193
app.include_router(api_router, prefix=settings.API_V2_STR)
183194

backend/app/models/status.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
from pydantic import BaseModel
2+
3+
from app.config import settings
4+
5+
6+
class Status(BaseModel):
7+
version: str = settings.version

backend/app/routers/status.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
from fastapi import APIRouter
2+
from fastapi.security import HTTPBearer
3+
4+
from app.models.status import Status
5+
6+
router = APIRouter()
7+
security = HTTPBearer()
8+
9+
10+
@router.get("", response_model=Status)
11+
async def get_status():
12+
return Status()

frontend/src/components/Layout.tsx

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { useEffect } from "react";
33
import { styled, useTheme } from "@mui/material/styles";
44
import Box from "@mui/material/Box";
55
import Drawer from "@mui/material/Drawer";
6-
import CssBaseline from "@mui/material/CssBaseline";
76
import MuiAppBar, { AppBarProps as MuiAppBarProps } from "@mui/material/AppBar";
87
import Toolbar from "@mui/material/Toolbar";
98
import List from "@mui/material/List";
@@ -17,7 +16,7 @@ import ListItem from "@mui/material/ListItem";
1716
import ListItemButton from "@mui/material/ListItemButton";
1817
import ListItemIcon from "@mui/material/ListItemIcon";
1918
import ListItemText from "@mui/material/ListItemText";
20-
import { Link, Menu, MenuItem, MenuList } from "@mui/material";
19+
import { Link, Menu, MenuItem, MenuList, Typography } from "@mui/material";
2120
import { Link as RouterLink, useLocation } from "react-router-dom";
2221
import { useSelector } from "react-redux";
2322
import { RootState } from "../types/data";
@@ -136,7 +135,6 @@ export default function PersistentDrawerLeft(props) {
136135
// @ts-ignore
137136
return (
138137
<Box sx={{ display: "flex" }}>
139-
<CssBaseline />
140138
<AppBar position="fixed" open={open}>
141139
<Toolbar>
142140
<IconButton
@@ -327,6 +325,18 @@ export default function PersistentDrawerLeft(props) {
327325
<Main open={open}>
328326
<DrawerHeader />
329327
{children}
328+
<Box
329+
sx={{
330+
position: "fixed",
331+
bottom: "0px",
332+
minHeight: "30px",
333+
width: "100%",
334+
}}
335+
>
336+
<Typography variant="body2" color="primary.light">
337+
v2.0.0-beta.1
338+
</Typography>
339+
</Box>
330340
</Main>
331341
</Box>
332342
);

frontend/src/openapi/v2/core/OpenAPI.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ type Config = {
2020

2121
export const OpenAPI: Config = {
2222
BASE: '',
23-
VERSION: '0.1.0',
23+
VERSION: '2.0.0-beta.1',
2424
WITH_CREDENTIALS: false,
2525
CREDENTIALS: 'include',
2626
TOKEN: undefined,

frontend/src/openapi/v2/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ export type { Repository } from './models/Repository';
5757
export { RoleType } from './models/RoleType';
5858
export type { SearchCriteria } from './models/SearchCriteria';
5959
export type { SearchObject } from './models/SearchObject';
60+
export type { Status } from './models/Status';
6061
export type { ThumbnailOut } from './models/ThumbnailOut';
6162
export type { UserAndRole } from './models/UserAndRole';
6263
export type { UserAPIKeyOut } from './models/UserAPIKeyOut';
@@ -82,6 +83,7 @@ export { ListenersService } from './services/ListenersService';
8283
export { LoginService } from './services/LoginService';
8384
export { MetadataService } from './services/MetadataService';
8485
export { ServiceService } from './services/ServiceService';
86+
export { StatusService } from './services/StatusService';
8587
export { ThumbnailsService } from './services/ThumbnailsService';
8688
export { UsersService } from './services/UsersService';
8789
export { VisualizationsService } from './services/VisualizationsService';
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
/* istanbul ignore file */
2+
/* tslint:disable */
3+
/* eslint-disable */
4+
5+
export type Status = {
6+
version?: string;
7+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/* istanbul ignore file */
2+
/* tslint:disable */
3+
/* eslint-disable */
4+
import type { Status } from '../models/Status';
5+
import type { CancelablePromise } from '../core/CancelablePromise';
6+
import { request as __request } from '../core/request';
7+
8+
export class StatusService {
9+
10+
/**
11+
* Get Status
12+
* @returns Status Successful Response
13+
* @throws ApiError
14+
*/
15+
public static getStatusApiV2StatusGet(): CancelablePromise<Status> {
16+
return __request({
17+
method: 'GET',
18+
path: `/api/v2/status`,
19+
});
20+
}
21+
22+
}

0 commit comments

Comments
 (0)