Commit fca9c00e authored by Meet Narendra's avatar Meet Narendra 💬

Meet final p2

parent 6ae69dc2
import { NgModule } from '@angular/core'; import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { HttpClientModule } from '@angular/common/http';
import { AppRoutingModule } from './app-routing.module'; import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component'; import { AppComponent } from './app.component';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
...@@ -47,6 +47,7 @@ import { CreateTicketDialog } from './jira/jira.component'; ...@@ -47,6 +47,7 @@ import { CreateTicketDialog } from './jira/jira.component';
imports: [ imports: [
BrowserModule, BrowserModule,
AppRoutingModule, AppRoutingModule,
HttpClientModule,
BrowserAnimationsModule, BrowserAnimationsModule,
MatButtonModule, MatButtonModule,
MatFormFieldModule, MatFormFieldModule,
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
</mat-expansion-panel-header> </mat-expansion-panel-header>
<div> <div>
<mat-form-field class="form-field-css"> <mat-form-field class="form-field-css">
<textarea matInput id="file-text" type="text" readonly="True" [rows]="file.url.split('\n').length" [(ngModel)]="file.url"></textarea> <textarea matInput class="file-text" type="text" readonly="True" [rows]="file.url.split('\n').length" [(ngModel)]="file.url"></textarea>
</mat-form-field> </mat-form-field>
<button mat-raised-button color="primary" style="margin-right: 10px;" (click)="allowEditFile()">Edit</button> <button mat-raised-button color="primary" style="margin-right: 10px;" (click)="allowEditFile()">Edit</button>
<button mat-raised-button color="primary" (click)="submitFile(file.id,file.url)">Save</button> <button mat-raised-button color="primary" (click)="submitFile(file.id,file.url)">Save</button>
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import {Observable, Observer} from 'rxjs'; import {Observable, Observer} from 'rxjs';
import { FetcherService } from '../fetcher.service'; import { FetcherService } from '../fetcher.service';
import { GET_GIT_FILES_API, POST_FILE_CHANGE_API } from '../urls';
import { getGitFilesResponse, postFileChangesResponse } from '../responses';
import { HttpClient } from '@angular/common/http';
import { Router } from '@angular/router';
import { CookieService } from 'ngx-cookie-service';
export interface entry{ export interface entry{
...@@ -25,10 +30,13 @@ export interface Section { ...@@ -25,10 +30,13 @@ export interface Section {
styleUrls: ['./github.component.css'] styleUrls: ['./github.component.css']
}) })
export class GithubComponent implements OnInit { export class GithubComponent implements OnInit {
projectId = NaN; projectId = '';
constructor(private fetcherService: FetcherService) { getGitFiles_stat$ = new Observable<getGitFilesResponse>;
postFileChange_stat$ = new Observable<postFileChangesResponse>;
constructor(private fetcherService: FetcherService, private http: HttpClient, private router: Router, private cookieService: CookieService) {
} }
fetchData(id: number) { fetchData(id: string) {
//return dummy data of type entry //return dummy data of type entry
var files:entry[] = [ var files:entry[] = [
{id: 1, name: "test", commitMessage: "test", commitDate: new Date('1/27/2022'), type: "folder", url: "test\n".repeat(10)}, {id: 1, name: "test", commitMessage: "test", commitDate: new Date('1/27/2022'), type: "folder", url: "test\n".repeat(10)},
...@@ -49,16 +57,32 @@ export class GithubComponent implements OnInit { ...@@ -49,16 +57,32 @@ export class GithubComponent implements OnInit {
console.log("submitting file"); console.log("submitting file");
console.log(data); console.log(data);
console.log(data.split("\n").length); console.log(data.split("\n").length);
document.getElementById("file-text")?.setAttribute("readonly", "true"); for (let i = 0; i < document.getElementsByClassName("file-text").length; i++) {
document.getElementsByClassName("file-text")[i].setAttribute("readonly", "true");
}
} }
allowEditFile(){ allowEditFile(){
document.getElementById("file-text")?.removeAttribute("readonly"); for (let i = 0; i < document.getElementsByClassName("file-text").length; i++) {
document.getElementsByClassName("file-text")[i].removeAttribute("readonly");
}
} }
files: entry[] = this.fetchData(this.projectId); files: entry[] = this.fetchData(this.projectId);
ngOnInit(): void { ngOnInit(): void {
this.projectId = this.fetcherService.getCurrentProjectId(); //this.projectId = this.fetcherService.getCurrentProjectId();
this.projectId = this.cookieService.get("pid");
console.log(this.projectId); console.log(this.projectId);
this.getGitFiles_stat$ = this.http.get<getGitFilesResponse>(GET_GIT_FILES_API+'?pid=' +this.projectId);
this.getGitFiles_stat$.subscribe((data) => {
console.log(data);
if (data.status == true) {
console.log("success");
console.log(data.files);
}
else {
console.log("failure");
}
});
} }
} }
\ No newline at end of file
...@@ -49,13 +49,13 @@ ...@@ -49,13 +49,13 @@
[colspan]=1 [colspan]=1
[rowspan]=1> [rowspan]=1>
<mat-card class="mat-card-css"> <mat-card class="mat-card-css">
<mat-card-title>{{tile.name}}</mat-card-title> <mat-card-title>{{tile.pname}}</mat-card-title>
<mat-card-content> <mat-card-content>
<p>{{tile.description}}</p> <p>{{tile.description}}</p>
<p>{{tile.content}}</p> <p>{{tile.content}}</p>
</mat-card-content> </mat-card-content>
<mat-card-actions> <mat-card-actions>
<button mat-button [routerLink]="['/project']" [state]="{id:tile.id, name: tile.name}">Open</button> <button mat-button [routerLink]="['/project']" [state]="{id:tile.pid, name: tile.pname}">Open</button>
</mat-card-actions> </mat-card-actions>
</mat-card> </mat-card>
</mat-grid-tile> </mat-grid-tile>
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { CookieService } from 'ngx-cookie-service'; import { CookieService } from 'ngx-cookie-service';
import { PROJECTS } from './projects'; //import { PROJECTS } from './projects';
import { GET_REPOS_API } from '../urls';
import { getProjectDetailsResponse } from '../responses';
import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';
import { Router } from '@angular/router';
export interface Tile { export interface Tile {
color: string; color: string;
cols: number; cols: number;
rows: number; rows: number;
text: string; text: string;
} }
@Component({ @Component({
selector: 'app-home', selector: 'app-home',
templateUrl: './home.component.html', templateUrl: './home.component.html',
styleUrls: ['./home.component.css'] styleUrls: ['./home.component.css']
}) })
export class HomeComponent implements OnInit { export class HomeComponent implements OnInit {
constructor(private cookieService: CookieService) { } project_stat$ = new Observable<getProjectDetailsResponse>;
setCookie(name: string,value: string){ projects = new Array<{pid:string;pname:string;created_date:string;powner:string;confluence_id:string;git_id:string;jira_id:string;content:string;description:string}>();
this.cookieService.set(name,value); constructor(private cookieService: CookieService, private router: Router, private http: HttpClient ) { }
setCookie(kname: string,value: string){
this.cookieService.set(kname,value);
} }
getCookie(name: string){ getCookie(kname: string){
return this.cookieService.get(name); return this.cookieService.get(kname);
} }
deleteCookie(name: string){ deleteCookie(kname: string){
this.cookieService.delete(name); this.cookieService.delete(kname);
} }
calColCount(){ calColCount(){
console.log(window.innerWidth); //console.log(window.innerWidth);
if(window.innerWidth > 1000){ if(window.innerWidth > 1000){
return 3; return 3;
}else if(window.innerWidth > 600){ }else if(window.innerWidth > 600){
...@@ -34,9 +42,24 @@ export class HomeComponent implements OnInit { ...@@ -34,9 +42,24 @@ export class HomeComponent implements OnInit {
} }
} }
ngOnInit(): void { ngOnInit(): void {
console.log(this.getCookie('uid'));
this.project_stat$ = this.http.get<getProjectDetailsResponse>(GET_REPOS_API+'?uid='+ this.getCookie('uid'));
this.project_stat$.subscribe(
(response) => {
console.log(response);
if (response.status == true) {
for (let i = 0; i < response.repos.length; i++) {
this.projects.push(response.repos[i]);
}
console.log(this.projects);
}
else{
alert('Invalid Credentials');
}
}
);
} }
tiles: Tile[] = [ tiles: Tile[] = [
{text: 'One', cols: 1, rows: 1, color: 'white'}, {text: 'One', cols: 1, rows: 1, color: 'white'},
]; ];
projects = PROJECTS;
} }
...@@ -6,13 +6,13 @@ ...@@ -6,13 +6,13 @@
</mat-form-field> </mat-form-field>
<mat-form-field class="flex-item"> <mat-form-field class="flex-item">
<mat-label>Password</mat-label> <mat-label>Password</mat-label>
<input matInput placeholder="Password" [formControl]="password"> <input matInput placeholder="Password" type="password" [formControl]="password">
<mat-error *ngIf="password.invalid">Password is required {{getErrorMessage()}}</mat-error> <mat-error *ngIf="password.invalid">Password is required {{getErrorMessage()}}</mat-error>
</mat-form-field> </mat-form-field>
<button class="flex-item" mat-raised-button color="primary" [routerLink]="['/home']" (click)="login()"> <button class="flex-item" mat-raised-button color="primary" (click)="login()">
Login Login
</button> </button>
<button class="flex-item" mat-raised-button color="primary" [routerLink]="['/home']" (click)="register()"> <button class="flex-item" mat-raised-button color="primary" (click)="register()">
Register here Register here
</button> </button>
</div> </div>
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { FormControl, Validators } from '@angular/forms'; import { FormControl, Validators } from '@angular/forms';
import { CookieService } from 'ngx-cookie-service'; import { CookieService } from 'ngx-cookie-service';
import { LOGIN_API, REGISTER_API } from '../urls';
import { LoginResponse, RegisterResponse } from '../responses';
import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';
import { Router } from '@angular/router';
@Component({ @Component({
selector: 'app-login', selector: 'app-login',
templateUrl: './login.component.html', templateUrl: './login.component.html',
...@@ -9,18 +16,35 @@ import { CookieService } from 'ngx-cookie-service'; ...@@ -9,18 +16,35 @@ import { CookieService } from 'ngx-cookie-service';
export class LoginComponent implements OnInit { export class LoginComponent implements OnInit {
email = new FormControl('', [Validators.required, Validators.email]); email = new FormControl('', [Validators.required, Validators.email]);
password = new FormControl('', [Validators.required]); password = new FormControl('', [Validators.required]);
login_stat$ = new Observable<LoginResponse>;
register_stat$ = new Observable<RegisterResponse>;
getErrorMessage() { getErrorMessage() {
if (this.email.hasError('required')) { if (this.email.hasError('required')) {
return 'You must enter a value'; return 'You must enter a value';
} }
return this.email.hasError('email') ? 'Not a valid email' : ''; return this.email.hasError('email') ? 'Not a valid email' : '';
} }
constructor(private cookieService: CookieService) { constructor(private cookieService: CookieService, private http:HttpClient, private router: Router) {}
}
login() { login() {
console.log(this.email.value); console.log(this.email.value);
console.log(this.password.value); console.log(this.password.value);
this.login_stat$ = this.http.post<LoginResponse>(LOGIN_API, {
email: this.email.value,
password: this.password.value
});
this.login_stat$.subscribe(
(response) => {
console.log(response);
if (response.status == true) {
this.cookieService.set('email', response.email);
//window.location.href = '/home';
this.router.navigate(['/home']);
}
else{
alert('Invalid Credentials');
}
}
);
this.setCookie('email',String(this.email.value)); this.setCookie('email',String(this.email.value));
this.setCookie('password',String(this.password.value)); this.setCookie('password',String(this.password.value));
this.setCookie('login','true'); this.setCookie('login','true');
...@@ -32,6 +56,26 @@ export class LoginComponent implements OnInit { ...@@ -32,6 +56,26 @@ export class LoginComponent implements OnInit {
register(){ register(){
console.log(this.email.value); console.log(this.email.value);
console.log(this.password.value); console.log(this.password.value);
this.register_stat$ = this.http.post<RegisterResponse>(REGISTER_API, {
email: this.email.value,
password: this.password.value,
role: 'employee',
first_name: 'Jon',
last_name: 'Snow',
});
this.register_stat$.subscribe(
(response) => {
console.log(response);
if (response.status == true) {
this.cookieService.set('uid', response.uid);
//window.location.href = '/home';
this.router.navigate(['/home']);
}
else{
alert('Registration Failed Try Later');
}
}
);
this.setCookie('email',String(this.email.value)); this.setCookie('email',String(this.email.value));
this.setCookie('password',String(this.password.value)); this.setCookie('password',String(this.password.value));
this.setCookie('login','true'); this.setCookie('login','true');
...@@ -47,6 +91,7 @@ export class LoginComponent implements OnInit { ...@@ -47,6 +91,7 @@ export class LoginComponent implements OnInit {
} }
ngOnInit(): void { ngOnInit(): void {
} }
} }
...@@ -43,22 +43,19 @@ ...@@ -43,22 +43,19 @@
</div> </div>
</mat-toolbar> </mat-toolbar>
</p> </p>
<div id="profile-comp" class="flex-container row"> <div id="profile-comp" class="flex-container row" style="justify-content: space-around; margin: 5%;">
<mat-card class="example-card flex-item"> <mat-card class="example-card flex-item">
<mat-card-header> <mat-card-header>
<div mat-card-avatar class="example-header-image"></div> <div mat-card-avatar class="example-header-image"></div>
<mat-card-title>First Name Last Name</mat-card-title> <mat-card-title> {{first_name}} {{last_name}} </mat-card-title>
<mat-card-subtitle>Employee Designation</mat-card-subtitle> <mat-card-subtitle>{{role}}</mat-card-subtitle>
</mat-card-header> </mat-card-header>
<img mat-card-image src="https://material.angular.io/assets/img/examples/shiba2.jpg" alt="Photo of a Shiba Inu"> <img mat-card-image [src]="'assets/'+profile_img" style="max-width:max-content;" alt="Profile Picture failed to Load...">
<mat-card-content> <mat-card-content>
<p> <p>
Some catchy bio. {{bio}}
</p> </p>
</mat-card-content> </mat-card-content>
<mat-card-actions>
<button mat-button>Edit Profile</button>
</mat-card-actions>
</mat-card> </mat-card>
<mat-vertical-stepper [linear]="false" #stepper > <mat-vertical-stepper [linear]="false" #stepper >
...@@ -87,7 +84,7 @@ ...@@ -87,7 +84,7 @@
<form [formGroup]="thirdFormGroup"> <form [formGroup]="thirdFormGroup">
<ng-template matStepLabel>Bio</ng-template> <ng-template matStepLabel>Bio</ng-template>
<mat-form-field> <mat-form-field>
<input matInput placeholder="Address" formControlName="thirdCtrl" required> <input matInput placeholder="Bio" formControlName="thirdCtrl" required>
</mat-form-field> </mat-form-field>
<div> <div>
<button mat-button matStepperPrevious>Back</button> <button mat-button matStepperPrevious>Back</button>
...@@ -100,7 +97,7 @@ ...@@ -100,7 +97,7 @@
You are now done. You are now done.
<div> <div>
<button mat-button matStepperPrevious>Back</button> <button mat-button matStepperPrevious>Back</button>
<button mat-button (click)="stepper.reset()">Reset</button> <button mat-button (click)="updateProfile()">Submit</button>
</div> </div>
</mat-step> </mat-step>
</mat-vertical-stepper> </mat-vertical-stepper>
......
import { Component, OnInit } from '@angular/core'; import { Component, OnInit } from '@angular/core';
import { CookieService } from 'ngx-cookie-service'; import { CookieService } from 'ngx-cookie-service';
import {FormBuilder, FormGroup} from '@angular/forms'; import {FormBuilder, FormGroup} from '@angular/forms';
import { FormControl, Validators } from '@angular/forms';
import { GET_USER_DETAILS_API, POST_USER_DETAILS_API } from '../urls';
import { getUserDetailsResponse, postUserDetailsResponse } from '../responses';
import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';
import { Router } from '@angular/router';
@Component({ @Component({
selector: 'app-profile', selector: 'app-profile',
...@@ -11,13 +17,82 @@ export class ProfileComponent implements OnInit { ...@@ -11,13 +17,82 @@ export class ProfileComponent implements OnInit {
firstFormGroup: FormGroup; firstFormGroup: FormGroup;
secondFormGroup: FormGroup; secondFormGroup: FormGroup;
thirdFormGroup: FormGroup; thirdFormGroup: FormGroup;
constructor(private cookieService: CookieService,private _formBuilder: FormBuilder) { getUser$ = new Observable<getUserDetailsResponse>;
postUser$ = new Observable<postUserDetailsResponse>;
uid = this.getCookie('uid');
email = "";
password = "";
role = "";
created_date = "";
active_stat = false;
profile_img = "";
bio = "";
first_name = "";
last_name = "";
full_name = "";
//edit_first_name = new FormControl('', [Validators.required]);
//edit_last_name = new FormControl('', [Validators.required]);
//edit_bio = new FormControl('', [Validators.required]);
constructor(private cookieService: CookieService,private _formBuilder: FormBuilder, private http:HttpClient, private router: Router) {
this.firstFormGroup = this._formBuilder.group({firstCtrl: ['']}); this.firstFormGroup = this._formBuilder.group({firstCtrl: ['']});
this.secondFormGroup = this._formBuilder.group({secondCtrl: ['']}); this.secondFormGroup = this._formBuilder.group({secondCtrl: ['']});
this.thirdFormGroup = this._formBuilder.group({thirdCtrl: ['']}); this.thirdFormGroup = this._formBuilder.group({thirdCtrl: ['']});
} }
updateProfile(){
console.log(this.firstFormGroup.value.firstCtrl);
console.log(this.secondFormGroup.value.secondCtrl);
console.log(this.thirdFormGroup.value.thirdCtrl);
this.full_name = this.firstFormGroup.value.firstCtrl.toString();
this.first_name = this.full_name.split(",")[0];
this.last_name = this.full_name.split(",")[1];
this.bio = this.thirdFormGroup.value.thirdCtrl.toString();
this.profile_img = this.secondFormGroup.value.secondCtrl.toString();
//console.log(this.profile_img.split("\\"));
this.profile_img = this.profile_img.split("\\").slice(-1)[0];
//console.log(this.profile_img);
this.postUser$ = this.http.post<postUserDetailsResponse>(POST_USER_DETAILS_API, {
uid: this.uid,
first_name: this.first_name,
last_name: this.last_name,
profile_img: this.profile_img,
bio: this.bio
});
this.postUser$.subscribe(
(response) => {
console.log(response);
if (response.status == true) {
alert('Profile Updated');
//this.router.navigate(['/home']);
}
else{
alert('Invalid Entries');
}
}
);
}
ngOnInit(): void { ngOnInit(): void {
this.getUser$ = this.http.get<getUserDetailsResponse>(GET_USER_DETAILS_API + "?uid=" + this.uid);
this.getUser$.subscribe(
(response) => {
console.log(response);
if (response.status == true) {
this.email = response.user[0].email;
this.password = response.user[0].password;
this.role = response.user[0].role;
this.created_date = response.user[0].created_date;
this.active_stat = response.user[0].active;
this.profile_img = response.user[0].profile_img;
this.bio = response.user[0].bio;
this.first_name = response.user[0].first_name;
this.last_name = response.user[0].last_name;
}
else{
alert('Invalid Credentials');
}
}
);
} }
setCookie(name: string,value: string){ setCookie(name: string,value: string){
this.cookieService.set(name,value); this.cookieService.set(name,value);
......
...@@ -6,6 +6,7 @@ import { JiraComponent } from '../jira/jira.component'; ...@@ -6,6 +6,7 @@ import { JiraComponent } from '../jira/jira.component';
import { SlackComponent } from '../slack/slack.component'; import { SlackComponent } from '../slack/slack.component';
import { ConfluenceComponent } from '../confluence/confluence.component'; import { ConfluenceComponent } from '../confluence/confluence.component';
import { FetcherService } from '../fetcher.service'; import { FetcherService } from '../fetcher.service';
import { CookieService } from 'ngx-cookie-service';
export interface ExampleTab { export interface ExampleTab {
label: string; label: string;
content: string; content: string;
...@@ -21,7 +22,8 @@ export class ProjectComponent implements OnInit { ...@@ -21,7 +22,8 @@ export class ProjectComponent implements OnInit {
name: string; name: string;
tabInd = 1; tabInd = 1;
asyncTabs: Observable<ExampleTab[]>; asyncTabs: Observable<ExampleTab[]>;
constructor(private fetcherService: FetcherService) { pid = '';
constructor(private fetcherService: FetcherService, private cookieService: CookieService) {
console.log(window.history.state); console.log(window.history.state);
this.id = window.history.state.id; this.id = window.history.state.id;
this.name = window.history.state.name; this.name = window.history.state.name;
...@@ -40,7 +42,12 @@ export class ProjectComponent implements OnInit { ...@@ -40,7 +42,12 @@ export class ProjectComponent implements OnInit {
this.tabInd = event.index+1; this.tabInd = event.index+1;
} }
ngOnInit(): void { ngOnInit(): void {
this.pid = this.cookieService.get('pid');
if (this.id != undefined && this.pid != this.id.toString()) {
this.cookieService.set('pid', this.id.toString());
}
this.fetcherService.setCurrentProjectId(this.id); this.fetcherService.setCurrentProjectId(this.id);
console.log(this.id);
} }
} }
export interface LoginResponse {
email: string;
status: boolean;
}
export interface RegisterResponse {
uid: string;
status: boolean;
}
export interface getUserDetailsResponse {
user: [
{
email: string;
password: string;
role: string;
uid: string;
created_date: string;
active: boolean;
profile_img: string;
bio: string;
first_name: string;
last_name: string;
}
];
status: boolean;
}
export interface postUserDetailsResponse {
status: boolean;
}
export interface getProjectDetailsResponse {
repos: [
{
pid: string;
pname: string;
created_date: string;
powner: string;
confluence_id: string;
git_id: string;
jira_id: string;
content: string;
description: string;
}
];
status: boolean;
}
export interface getGitFilesResponse {
files: [
{
git_id: string;
}
];
status: boolean;
}
export interface postFileChangesResponse {
status: boolean;
}
/*
path('isAuthenticated/',checkAuthViewSet.as_view()),
path('authenticate/',authenticateViewSet.as_view()),
path('register/',registerViewSet.as_view()),
path('getRepos/',getReposViewSet.as_view()),
path('getGitFiles/',getGitFilesViewSet.as_view()),
path('getJiraTickets/',getJiraTicketsViewSet.as_view()),
path('getJiraBoards/',getJiraBoardViewSet.as_view()),
path('createJiraTicket/',createJiraTicketViewSet.as_view()),
path('updateJiraTicket/',updateJiraTicketViewSet.as_view()),
path('postFileChange/',postFileChangeViewSet.as_view()),
path('postFileCreate/',postFileCreateViewSet.as_view()),
path('getConfluencePages/',getConfluencePagesViewSet.as_view()),
path('getUserDetails/',getUserDetailsViewSet.as_view()),
path('postUserDetails/',postUserDetailsViewSet.as_view()),
path('getProjectDetails/',getProjectDetailsViewSet.as_view()),
*/
export const LOGIN_AUTH = 'http://localhost:8000/api/isAuthenticated/';
export const LOGIN_API = 'http://localhost:8000/api/authenticate/';
export const REGISTER_API = 'http://localhost:8000/api/register/';
export const GET_REPOS_API = 'http://localhost:8000/api/getRepos/';
export const GET_GIT_FILES_API = 'http://localhost:8000/api/getGitFiles/';
export const GET_JIRA_TICKETS_API = 'http://localhost:8000/api/getJiraTickets/';
export const GET_JIRA_BOARDS_API = 'http://localhost:8000/api/getJiraBoards/';
export const CREATE_JIRA_TICKET_API = 'http://localhost:8000/api/createJiraTicket/';
export const UPDATE_JIRA_TICKET_API = 'http://localhost:8000/api/updateJiraTicket/';
export const POST_FILE_CHANGE_API = 'http://localhost:8000/api/postFileChange/';
export const POST_FILE_CREATE_API = 'http://localhost:8000/api/postFileCreate/';
export const GET_CONFLUENCE_PAGES_API = 'http://localhost:8000/api/getConfluencePages/';
export const GET_USER_DETAILS_API = 'http://localhost:8000/api/getUserDetails/';
export const POST_USER_DETAILS_API = 'http://localhost:8000/api/postUserDetails/';
export const GET_PROJECT_DETAILS_API = 'http://localhost:8000/api/getProjectDetails/';
id,name,commitMessage,commitDate,type,content
1,File1,updatedFiles,10-05-22,file,"But I must explain to you how all this mistaken idea of denouncing pleasure and praising pain was born and I will give you a complete account of the system, and expound the actual teachings of the great explorer of the truth, the master-builder of human happiness. No one rejects, dislikes, or avoids pleasure itself, because it is pleasure, but because those who do not know how to pursue pleasure rationally encounter consequences that are extremely painful. Nor again is there anyone who loves or pursues or desires to obtain pain of itself, because it is pain, but because occasionally circumstances occur in which toil and pain can procure him some great pleasure. To take a trivial example, which of us ever undertakes laborious physical exercise, except to obtain some advantage from it? But who has any right to find fault with a man who chooses to enjoy a pleasure that has no annoying consequences, or one who avoids a pain that produces no resultant pleasure?"
2,File2,Merged files,11-10-22,file,"""At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et molestiae non recusandae. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat."""
3,File3,updatedFiles,10-05-22,file,"But I must explain to you how all this mistaken idea of denouncing pleasure and praising pain was born and I will give you a complete account of the system, and expound the actual teachings of the great explorer of the truth, the master-builder of human happiness. No one rejects, dislikes, or avoids pleasure itself, because it is pleasure, but because those who do not know how to pursue pleasure rationally encounter consequences that are extremely painful. Nor again is there anyone who loves or pursues or desires to obtain pain of itself, because it is pain, but because occasionally circumstances occur in which toil and pain can procure him some great pleasure. To take a trivial example, which of us ever undertakes laborious physical exercise, except to obtain some advantage from it? But who has any right to find fault with a man who chooses to enjoy a pleasure that has no annoying consequences, or one who avoids a pain that produces no resultant pleasure?"
4,File4,Merged files,11-10-22,file,"""At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et molestiae non recusandae. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat."""
5,File5,updatedFiles,10-05-22,file,"But I must explain to you how all this mistaken idea of denouncing pleasure and praising pain was born and I will give you a complete account of the system, and expound the actual teachings of the great explorer of the truth, the master-builder of human happiness. No one rejects, dislikes, or avoids pleasure itself, because it is pleasure, but because those who do not know how to pursue pleasure rationally encounter consequences that are extremely painful. Nor again is there anyone who loves or pursues or desires to obtain pain of itself, because it is pain, but because occasionally circumstances occur in which toil and pain can procure him some great pleasure. To take a trivial example, which of us ever undertakes laborious physical exercise, except to obtain some advantage from it? But who has any right to find fault with a man who chooses to enjoy a pleasure that has no annoying consequences, or one who avoids a pain that produces no resultant pleasure?"
id,name,commitMessage,commitDate,type,content,
<!-- saved from url=(0054)https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/ -->
<html><head><meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title> CS 631 </title>
</head>
<body>
<center>
<h3>CS631 : Implementation techniques in DBMS</h3>
<h3 class="normal">Autumn 2022 </h3>
</center>
<br>
<b>Previous years</b>:
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/2021">Autumn 2021</a>,
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/2020">Autumn 2020</a>,
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/2019-Autumn">Autumn 2019</a>,
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/2019-Spring">Spring 2019</a> and many earlier years;
older offerings are linked from earlier years.
<br>
Sample exam papers will be provided in moodle.
<br>
<b>Instructor</b>:
<a class="menu" href="https://www.cse.iitb.ac.in/~sudarsha">S. Sudarshan</a>
<br>
<b>Teaching Assistants</b>: Sayanti Bhattacharya, Jaynik Gaglani <br>
<b> TA Office Hours:</b> TBD <br>
<!--
<em>Mon 10.30 AM-12.30 PM, Wed 10.30 AM-12.30 PM, </em>
Ravi: <em> Mon 2.00-4.00 PM, Tue 2.00-4.00 PM </em> <b>Venue</b> <em> SIC 212 (Info Lab)</em>
<br>
-->
<b> Faculty Office hours</b>: Sudarshan: <em> To be fixed</em>
<!-- <em>Mon 5.00-6.00 PM, Wed 12.00 - 1.00 PM</em>-->
<!-- Room SIA 206. -->
<!-- Mon: TBD<br>
Tue: TBD <br>
Wed: TBD<br>
Thu: TBD<br>
Fri: TBD -->
<br>
<br>
<b>Lecture schedule</b> Slot 5:
Wed and Friday, 9.30-11.00
<br>
<br>
<b>Course Websites</b>: In addition to this static Web page, we will also be using Moodle for assignment submissions, and Piazza for discussions.
More information on Piazza sign up to be provided.
<hr>
<b> Textbook</b>
Database System Concepts, Silberschatz, Korth and Sudarshan,
7th edition (2019), McGraw Hill.
The Indian print of 7th ed is available as of 21/7/2021.
<br>
You can order it from <a href="https://www.flipkart.com/search?q=9789390727506&amp;affid=mcgrawhill001">Flipkart</a> or <a href="https://www.amazon.in/Database-System-Concepts-Abraham-Silberschatz/dp/9390727502"> Amazon</a> now, and presumably from other sources soon.
<br>
<br> Other reading material will be made available periodically
<br>
<b> Book Slides</b>, <b>Errata</b>, <i> solutions to selected exercises</i>
and other resources
are available at: <a href="https://db-book.com/"> https://db-book.com</a> <br><br>
<b>Course contents</b>
We will be covering Implementation techniques including
Storage and indexing, query processing, and transaction processing
(Chapters 12-19),
Database System Architectures (Chapter 20) and
Parallel and Distributed Storage, Query Processing and Transaction Processing (Chapters 21-23).
<p>
We may also cover several research papers during the course.
</p><p>
As in the other recent offerings, we will have an increased focus on Big Data,
starting with using Big Data systems, and then diving into their internals.
You will also set up PostgreSQL, and learn how to
make small changes to it as part of the course assignments.
</p><p>
The infrastructure for your course project will be your choice of
PostgreSQL or any of the open source big data systems.
If you wish to do it on any other infrastructure, you can discuss it with me.
<br><br>
<b>Evaluation scheme</b>
Details are linked from Moodle.
<!-- Midsem: 20, Endsem: 35, Quizzes: 7+8, Assignments: 4+2+4, Project: 20.-->
<br>
<br>
<b>Audit Requirements</b>: Must attend all classes and take all exams.
No need to do homeworks/assignments/projects.
<br><br>
</p><hr>
<br>
<font color="red"><b> Project Information </b></font>
<ol>
<li> <a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/PostgreSQL-Resources/ProjectTopics.html">PostgreSQL project topic suggestions</a>
(under construction, will add more ideas)
<!-- <li> <a href="Hyracks-Projects.html">Hyracks project topic suggestions</a>-->
<!-- <li> <a href="projectgroups.html"> <font> <b> Project Groups TBA </b></font> </a> -->
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/project.html">Information about Projects TBA</a>
</li></ol>
<br>
<font color="red"><b> PostgreSQL Resources </b></font>
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/PostgreSQL-Resources">Click Here</a>
(Instruction on <a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/patchfile-creation.html"> creating patch files</a>
for submitting your project)
<br>
<!--
<font color="red"><b> Hyracks Resources </b></font>
<a href="https://www.cse.iitb.ac.in/dbms/Data/Courses/CS632/Talks/Hyracks.ppt">
Hyracks Overview Talk</a>,
<a href="steps_to_setup_Hyracks.html">Steps to set up Hyracks</a>,
<a href="Hyracks-Demo.html">Hyracks Demo steps</a>
-->
<br>
<hr>
<h4>Schedule of Lectures (tentative)</h4>
<table border="3">
<tbody><tr>
<td bgcolor="eeffee">Topic No.</td>
<td bgcolor="eeffee">Date</td>
<td bgcolor="eeffee">Topic</td><td bgcolor="eeffee">Notes</td></tr>
<tr> <td> 1 </td> <td>July 27</td> <td>Introduction/Overview </td></tr>
<tr> <td> 2 </td> <td> Aug 3,5 </td>
<td>Chapter 12 and 13: Physical Storage Systems and Data Storage Structures </td>
<td> Assignment: Download and compile PostgreSQL, and open in Eclipse, using <a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/PostgreSQL-Resources/Postgres%20Setup%20Instructions.html">instructions provided here</a><br>
<a href="https://www.postgresql.org/docs/current/static/storage.html">Physical Storage in PostgreSQL</a>,
Look inside above link for information on
<a href="https://www.postgresql.org/docs/current/static/storage-file-layout.html">file layout</a>,
<a href="https://www.postgresql.org/docs/current/static/storage-page-layout.html"> database page layout</a>, and
<a href="https://www.postgresql.org/docs/current/static/storage-fsm.html">free space map</a>
(and lots more details <a href="https://www.cse.iitb.ac.in/dbms/Data/Courses/CS631/PostgreSQL-Resources/postgresql-11.1/src/backend/storage/freespace/README">src/backend/storage/freespace/README</a>).
And how PostgreSQL stores
<a href="https://www.postgresql.org/docs/current/static/storage-toast.html">oversized attributes using
the TOAST technique</a>
</td></tr>
<tr> <td> 3 </td> <td> Aug 10, 12 </td> <td>Chapter 14: Indexing</td>
<!--
<td> BigTable: <a href="https://www.cse.iitb.ac.in/dbms/Data/Courses/CS632/Talks/bigtable-uw-presentation.ppt">
CS632 Talk slides</a>,
(Extra reading:
<a href="https://www.cse.iitb.ac.in/dbms/Data/Courses/CS632/Papers/bigtable-osdi06.pdf"> BigTable paper</a>,
<a href="https://www.cse.iitb.ac.in/dbms/Data/Courses/CS632/Talks/bigtable-video.mp4"> Jeff Dean Video</a>)
</td></tr>
<tr> <td> 4 </td> <td>Aug 4</td> <td>Chapter 11: Indexing (Cont.)</td>
-->
<td><a href="https://www.postgresql.org/docs/current/static/indexam.html">Index access method interface in PostgreSQL</a> (read only if you want to create new index types)</td></tr>
<tr> <td> 4 </td> <td>Aug 17, 19 </td> <td>Chapter 15: Query Processing</td> <td>.</td></tr>
<tr> <td> </td> <td>TBD</td> <td>Extra class: Overview of PostgreSQL internals -1 </td> <td>
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/PostgreSQL-Resources">PostgreSQL resources</a>, in particular see
<a href="https://www.cse.iitb.ac.in/infolab/Data/Courses/CS631/PostgreSQL-Resources/pg_tour.pdf">Tom Lane's talk</a></td></tr>
<tr> <td> 5 </td> <td>Aug 24, 26 </td> <td>Chapter 16: Query Optimization</td>
<td>
<a href="https://www.postgresql.org/docs/current/static/view-pg-stats.html"> Statistics in PostgreSQL</a>,
and <a href="https://www.postgresql.org/docs/current/static/row-estimation-examples.html">examples of row estimation in PostgreSQL</a> in particular see how PostgreSQL special cases most common values (MCVs).
<br>Assignments on query plans in PostgreSQL
</td>
</tr>
<tr> <td> </td> <td>TBD</td> <td>Extra class: Overview of PostgreSQL internals -2, Debugging in Eclipse</td> <td>..</td></tr>
<tr> <td> 6 </td> <td>Aug 31</td> <td>Chapter 17 Transactions</td> <td>.</td></tr>
<tr> <td> 7 </td> <td>Sep 2, 7, 9</td> <td>Chapter 18: Concurrency Control </td> <td>.</td></tr>
<tr> <td> </td> <td>Sep 14 - 20</td> <td>No Class (Midsem Exam) </td> <td>.</td></tr>
<tr> <td> 8 </td> <td>Sep 21, 23 </td> <td>Chapter 19: Recovery </td> <td>.</td></tr>
<tr> <td> 9 </td> <td> Sep 28, 30 </td> <td>Chapter 10: Big Data</td>
<td> </td> </tr>
<tr> <td> 10 </td> <td>Oct 5,7 </td> <td>Chapter 20: Database Architecture </td> <td>
<!-- (Case study not covered in 2015:
<a href="https://www.intel.com/en_US/Assets/PDF/whitepaper/mc_sap_wp.pdf"> Intel white paper on the
SAP HANA system architecture</aa)>
-->
</td></tr>
<tr> <td> 11 </td> <td>Oct 12, 14 </td> <td> Parallel and Distributed Storage </td> <td>.</td></tr>
<tr> <td> 12 </td> <td>Oct 19, 21 </td> <td>Parallel and Distributed Query Processing </td> <td></td></tr>
<tr> <td> 13 </td> <td>Oct 26, 28, Nov 2 </td> <td>Parallel and Distributed Transaction Processing </td> <td>.</td></tr>
<tr> <td> 14 </td> <td>Nov 4, 9</td> <td> RAFT: In search of an Understandable Consensus Algorithm, Diego Ongarro and John Ousterhout, USENIX ATC 2014 </td> <td>.</td></tr>
<!--
<tr> <td> 25 </td> <td>TBD</td> <td>Distributed Data Storage Systems </td> <td>
<a href="NoSQLDatabases.ppt">Talk on NoSQL Databases (ppt)</a> and
optionally,
<a href="https://www.cse.iitb.ac.in/~sudarsha/Talks/MassivelyParallelDataStorageSystems-2015.pptx">
talk on distributed data storage (updated Nov 2015)</a> <br>
</td><td/></tr>
-->
<!--
<tr> <td> 26 </td> <td>TBD</td> <td>Big Table </td> <td>
<a href="https://www.cse.iitb.ac.in/dbms/Data/Courses/CS632/Papers/bigtable-osdi06.pdf"> BigTable paper </a> and
<a href=" https://www.cse.iitb.ac.in/infolab/Data/Courses/CS632/Talks/bigtable-uw-presentation.ppt">Talk</a>
<br>
You can also view <a href="https://video.google.com/videoplay?docid=7278544055668715642">the BigTable talk at video.google.com</a>
</td></tr>
-->
<!--
<tr> <td> 14 </td> <td>Nov 4, 5</td> <td>Chapter 25: Advanced Application Development</td> <td>.</td></tr>
<tr> <td> 15 </td> <td>Nov 7</td> <td>Current Research Areas + CS 632</td> <td>.</td></tr>
-->
<!--
<tr> <td> 28 </td> <td>TBD</td> <td>Chapter 25: Spatial and Temporal Data and Mobility </td>
<td> (Optionally read the <a href="rTreeGuttman.pdf"> R-Tree paper by Guttman before class</a>, talk on <a href="SpatialIndex.ppt">Spatial Index</a>)</td></tr>
<tr> <td> 29 </td> <td>TBD</td> <td><strike>Chapter 5: Sections on OLAP and Warehousing </strike> </td> <td>..</td></tr>
-->
</tbody></table>
</body></html>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment