-
Notifications
You must be signed in to change notification settings - Fork 3
Story/vspc 204 #308
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
pkharge
wants to merge
143
commits into
develop
Choose a base branch
from
story/VSPC-204
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Story/vspc 204 #308
Changes from all commits
Commits
Show all changes
143 commits
Select commit
Hold shift + click to select a range
0783f6d
[story/VSPC-204] added download section in staff page
d1b15cc
[story/VSPC-204] download api
e1cda05
[story/VSPC-204] added jsoup dependency
d68de99
[story/VSPC-204] modified download api response
9e509e2
[story/VSPC-204] copy images to new folder structure
70907bb
[story/VSPC-204] store images under eaach space
0d2e771
[story/VSPC-204] downlaod template modified to pick up images
78c5003
[story-VSPC-204] copied resources for css
1a6da12
[story/VSPC-204] converted to zip folder. added template for slides
7a71f63
[story/VSPC-204] added code to consider branching points
737dad5
[story/VSPC-204] zip folder download working as expected
0a24c03
[story/VSPC-204] list of downlods
ef2ee5a
[story/VSPC-204] refactored downloads manager
0c3e206
[story/VSPC-204] refactor
3caf863
[story/VSPC-204] test cases
b7d9442
[story/VSPC-204] test cases
34496eb
[story/VSPC-204] removed controller call to download html template
e74fe71
[story/VSPC-204] refactor
e280828
[story/VSPC-204]
dff8c3d
[story/VSPC-204] removed unwanted methods
e1bf075
[story/VSPC-204] code factor
3adad85
[story/VSPC-204] code factor
3a86887
[story/VSPC-204]
d2a9a14
Merge branch 'develop' into story/VSPC-204
3926ce1
[story/VSPC-204] review comments
pkharge 7d8fb37
[story/VSPC-204] added async
pkharge 9f521c3
[story/VSPC-204] async - polling
pkharge 88c9b87
[story/VSPC-204] modifed backend
pkharge c7c6df4
[story/VSPC-204]
pkharge 0847669
[story/VSPC-204] future task
pkharge 4896d85
[story/VSPC-204] sequencehistory
pkharge 1f2c46d
[story/VSPC-204] polling in javascript
pkharge 4702909
[story/VSPC-204] thymeleaf context npe pending
pkharge 3cc5781
[story/VSPC-204] async config
pkharge 60bc618
[story/VSPC-204] testing branching point
pkharge 1f4b4fd
[story/VSPC-204] review comment
pkharge da355c1
[story/VSPC-204] added new context to process template in async method
pkharge 2a6ce84
[story/VSPC-204] modified space download template for async method
pkharge 1c52717
[story/VSPC-204] async exhibition folder
pkharge 0bdf246
[story/VSPC-204]
pkharge 9fe3a25
[story/VSPC-204] 2 rest apis for polling
pkharge 342f195
[story/VSPC-204] fixed ajax calls
pkharge 0b8538e
[story/VSPC-204]progress spinner
pkharge f8cce1c
[story/VSPC-204] added different api for polling
pkharge b6f9027
[story/VSPC-204] read polling response in ui
pkharge fbfca18
[VSPC-204] async flow working fine
pkharge 510692d
[story/VSPC-204] pagination added
pkharge 9f390e4
[story/VSPC-204]test cases
pkharge 8152349
[story/VSPC-204] added snapshot task entity
pkharge 7ae7346
[story/VSPC-204 ]ui changes
pkharge d84796c
[story/VSPC-204] one to oen bidirectional
pkharge 40a83b6
[story/VSPC-204] snapshot task fixed
pkharge 4e716bf
[story/VSPC-204] ui alert, test cases
pkharge ccb6a35
[story/vspc-204] REFACTOR
pkharge cec7445
[story/vspc-204] refactor
pkharge effb3a5
[story/VSPC-204] refactor, test case
pkharge b7ab2e7
[story/VSPC-204] pom xml
pkharge 8c64978
[story/VSPC-204 ] refactor
pkharge 24fbc07
[story/VSPC-204] code factor
pkharge 72abc69
[story/VSPC-204] code factor
pkharge 1f05362
Merge branch 'develop' into story/VSPC-204
pkharge eeacaea
[story/VSPC-204] refactor
pkharge bcde954
[story/VSPC-204]
pkharge d00e77b
[story/VSPC-204] added folder type
pkharge bd85667
[story/VSPC-204] added relative paths
pkharge 38ee8a9
[story/VSPC-204] testing
pkharge 3d23f6d
[story/VSPC-204] relative path working zip folder downlaoding
pkharge e391b62
[story/VSPC-204] test case
pkharge c3e29aa
[story/VSPC-204]
pkharge 0a1add5
[story/VSPC-204] storage engine added
pkharge 9c1b8ed
[story/VSPC-204] bean storage engine
pkharge 4c2fa90
[story/VSPC-204] code factor
pkharge eb029f3
[story/VSPC-204] code factor
pkharge 7c9b5ba
[story/VSPC-204] code factor
pkharge aad9e14
[story/VSPC-204] merge conflict
pkharge ab92dad
[story/VSPC-204] review comments
pkharge 80d3796
[story/VSPC-204] review comments
pkharge b19a2b6
[story/VSPC-204] Review comments
swetalina-prusty25 8ba400d
[story/VSPC-214] Resolved errors
swetalina-prusty25 52a24b3
[story/VSPC-204] create snapshot method
swetalina-prusty25 92b0062
[story/VSPC-204] Async Configuration
swetalina-prusty25 b0a44ad
[story/VSPC-204]Number format Exception
swetalina-prusty25 f777e53
[story/VSPC-204]Getting string value
swetalina-prusty25 d61e650
Code cleanup - removed spaces, fixed few errors
pooja-thalur 7f3ce57
fixed the config issue and removed unused imports
pooja-thalur b35db5b
Addressed review comments
pooja-thalur 7b232cc
removed debug statement
pooja-thalur 35a495c
fixed the issue with creating a snapshot
pooja-thalur d9b3deb
fixed exceptions occured during testing
pooja-thalur 44bbd99
Removing servlet context dependency as per review comments
pooja-thalur 298e3d9
Changes to download resources folder
pooja-thalur 6dc1fc0
Merge branch 'develop' into story/VSPC-204
pooja-thalur 2357602
Code cleanup and addressing pr comments
pooja-thalur 0134549
Codefactor issue
pooja-thalur 4cf5d37
Code cleanup - removed unused imports
pooja-thalur 70d45f3
removed sysout and console logs (VSPC-204)
pooja-thalur 966c169
VSPC-204 removed spaces
pooja-thalur 38794fa
logging the error
pooja-thalur d3b7e10
[VSPC-204] addressed pr comments
pooja-thalur 1091f71
[VSPC-204] addressed pr comments
pooja-thalur d270fc0
[VSPC-204] addressed pr comments - renamed download to snapshots
pooja-thalur 57bac32
[VSPC-204] addressed pr comments - added java doc
pooja-thalur be69f61
[VSPC-204] code cleanup
pooja-thalur b5ce14d
[VSPC-204] code cleanup
pooja-thalur 502cbb9
[VSPC-204] delete folder after creating a zip
pooja-thalur e12f6f0
[VSPC-204] Fixed code factor issue
pooja-thalur e7857e9
[VSPC-204] Code cleanup
pooja-thalur 7d6b9f0
[VSPC-204] addressed pr comments
pooja-thalur 246caf4
[VSPC-204] addressed pr comments
pooja-thalur 2635356
[VSPC-204] Addressed pr comments
pooja-thalur 9da2084
[VSPC-204] code cleanup
pooja-thalur 26e30c8
[VSPC-204] codefactor issue fixed
pooja-thalur fa22d8c
[VSPC-204] addressed pr comments
pooja-thalur a3afc68
[VSPC-204] addressed pr comments - to store branching point slide
pooja-thalur 6b93127
[VSPC-204] addressed pr comments
pooja-thalur 2d28775
[VSPC-204] addressed pr comments
pooja-thalur 2a4149b
[VSPC-204] Addressed pr comments
pooja-thalur de3303d
[VSPC-204] Branching point rendering changes
pooja-thalur fd94f74
[VSPC-204] code cleanup
pooja-thalur 74b3372
[VSPC-204] code cleanup
pooja-thalur 9ebe4ce
[VSPC-204] addressed review comments
pooja-thalur e42f6fe
[VSPC-204]changed unit tests
pooja-thalur 229ba5f
[VSPC-204] code cleanup and fixed testcases
pooja-thalur 8ba9281
[VSPC-204] code refactored
pooja-thalur e42eac9
[VSPC-204] addressed pr comment
pooja-thalur e269bb1
[VSPC-204] addressing review comments
pooja-thalur 504ff0b
[VSPC-204] addressed pr comments
pooja-thalur 27c94a7
[VSPC-204] removed console logs
pooja-thalur 334ff22
[VSPC-204] fixing issue on creating snapshot
pooja-thalur 27bcf6b
Merge branch 'develop' into story/VSPC-204
pooja-thalur 3d19a1e
[VSPC-204] Async changes
pooja-thalur 79210a4
[VSPC-204] failing testcase fixed
pooja-thalur 93b1aa9
[VSPC-204] review comments addressed
pooja-thalur d665d9e
[VSPC-204] async changes
pooja-thalur a205132
[VSPC-204] fixed unit tests
pooja-thalur 5f1b1cc
[VSPC-204] code cleanup
pooja-thalur 41d73db
Merge branch 'develop' into story/VSPC-204
pooja-thalur 4256d9e
[VSPC-204] upload storage engine change
pooja-thalur 2fa6b8c
[VSPC-204] Fixed ui issues, proper nav for exhibitions exports, worki…
Girik1105 937227c
[VSPC-204] Added AsyncSnapshotCreator interface
Girik1105 d7c3f76
[VSPC-204] Pom update
Girik1105 f1407a2
Merge branch 'develop' into story/VSPC-204
Girik1105 c66eac7
[VSPC-204] Fixed var cannot be resolved to type issue
Girik1105 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
vspace/src/main/java/edu/asu/diging/vspace/config/AsyncConfiguration.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
package edu.asu.diging.vspace.config; | ||
|
||
import java.util.concurrent.Executor; | ||
|
||
import org.springframework.beans.factory.annotation.Value; | ||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.scheduling.annotation.EnableAsync; | ||
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; | ||
import org.springframework.security.core.context.SecurityContextHolder; | ||
|
||
@Configuration | ||
@EnableAsync | ||
public class AsyncConfiguration { | ||
|
||
@Value("${async_core_pool_size}") | ||
private int corePoolSize; | ||
|
||
@Value("${async_max_pool_size}") | ||
private int maxPoolSize; | ||
|
||
@Value("${async_queue_capacity}") | ||
private int queueCapacity; | ||
|
||
@Bean(name="asyncExecutor") | ||
public Executor getAsyncExecutor() { | ||
// Set the strategy so that threads can inherit the authenticated user | ||
SecurityContextHolder.setStrategyName(SecurityContextHolder.MODE_INHERITABLETHREADLOCAL); | ||
ThreadPoolTaskExecutor asyncExecutor = new ThreadPoolTaskExecutor(); | ||
|
||
asyncExecutor.setCorePoolSize(corePoolSize); | ||
asyncExecutor.setMaxPoolSize(maxPoolSize); | ||
asyncExecutor.setQueueCapacity(queueCapacity); | ||
|
||
asyncExecutor.setThreadNamePrefix("threadAsync"); | ||
asyncExecutor.setWaitForTasksToCompleteOnShutdown(true); | ||
asyncExecutor.initialize(); | ||
|
||
return asyncExecutor; | ||
} | ||
|
||
} |
30 changes: 30 additions & 0 deletions
30
vspace/src/main/java/edu/asu/diging/vspace/config/StorageEngineConfig.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package edu.asu.diging.vspace.config; | ||
|
||
import org.springframework.beans.factory.annotation.Value; | ||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.stereotype.Component; | ||
|
||
import edu.asu.diging.vspace.core.file.IStorageEngine; | ||
import edu.asu.diging.vspace.core.file.impl.StorageEngine; | ||
|
||
@Component | ||
@Configuration | ||
public class StorageEngineConfig { | ||
|
||
@Value("${downloads_path}") | ||
private String downloadsPath; | ||
|
||
@Value("${uploads_path}") | ||
private String uploadsPath; | ||
|
||
@Bean(name = "storageEngineDownloads") | ||
public IStorageEngine storageEngineDownloads(){ | ||
jdamerow marked this conversation as resolved.
Show resolved
Hide resolved
|
||
return new StorageEngine(downloadsPath); | ||
} | ||
|
||
@Bean(name = "storageEngineUploads") | ||
public IStorageEngine storageEngineUploads(){ | ||
return new StorageEngine(uploadsPath); | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
vspace/src/main/java/edu/asu/diging/vspace/core/data/ExhibitionSnapshotRepository.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package edu.asu.diging.vspace.core.data; | ||
|
||
import org.springframework.data.domain.Page; | ||
import org.springframework.data.domain.Pageable; | ||
import org.springframework.data.repository.PagingAndSortingRepository; | ||
|
||
import edu.asu.diging.vspace.core.model.impl.ExhibitionSnapshot; | ||
|
||
public interface ExhibitionSnapshotRepository extends PagingAndSortingRepository<ExhibitionSnapshot, String> { | ||
|
||
Page<ExhibitionSnapshot> findAllByOrderByCreationDateDesc(Pageable requestedPage); | ||
|
||
ExhibitionSnapshot findByFolderName(String exhibitionFolderName); | ||
|
||
} |
21 changes: 21 additions & 0 deletions
21
vspace/src/main/java/edu/asu/diging/vspace/core/data/SnapshotTaskRepository.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package edu.asu.diging.vspace.core.data; | ||
|
||
import java.util.Optional; | ||
|
||
import org.javers.spring.annotation.JaversSpringDataAuditable; | ||
import org.springframework.data.repository.PagingAndSortingRepository; | ||
import org.springframework.stereotype.Repository; | ||
|
||
import edu.asu.diging.vspace.core.model.impl.SnapshotTask; | ||
|
||
@Repository | ||
@JaversSpringDataAuditable | ||
public interface SnapshotTaskRepository extends PagingAndSortingRepository<SnapshotTask, String>{ | ||
|
||
SnapshotTask findFirstByOrderByCreationDateDesc(); | ||
|
||
Optional<SnapshotTask> findById(String id); | ||
|
||
Optional<SnapshotTask> findByExhibitionSnapshotId(String exhibitionSnapshotId); | ||
|
||
} |
30 changes: 30 additions & 0 deletions
30
...c/main/java/edu/asu/diging/vspace/core/exception/ExhibitionSnapshotNotFoundException.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package edu.asu.diging.vspace.core.exception; | ||
|
||
import org.springframework.http.HttpStatus; | ||
import org.springframework.web.bind.annotation.ResponseStatus; | ||
|
||
@ResponseStatus(value = HttpStatus.NOT_FOUND, reason = "Exhibition snapshot folder not found") | ||
public class ExhibitionSnapshotNotFoundException extends Exception{ | ||
private static final long serialVersionUID = 1L; | ||
|
||
public ExhibitionSnapshotNotFoundException() { | ||
super(); | ||
} | ||
|
||
public ExhibitionSnapshotNotFoundException(String message, Throwable cause, boolean enableSuppression, | ||
boolean writableStackTrace) { | ||
super(message, cause, enableSuppression, writableStackTrace); | ||
} | ||
|
||
public ExhibitionSnapshotNotFoundException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
public ExhibitionSnapshotNotFoundException(Throwable cause) { | ||
super(cause); | ||
} | ||
|
||
public ExhibitionSnapshotNotFoundException(String id) { | ||
jdamerow marked this conversation as resolved.
Show resolved
Hide resolved
|
||
super("Exhibition snapshot folder with id " + id + " not found"); | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
...rc/main/java/edu/asu/diging/vspace/core/exception/SnapshotCouldNotBeCreatedException.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package edu.asu.diging.vspace.core.exception; | ||
import org.springframework.http.HttpStatus; | ||
import org.springframework.web.bind.annotation.ResponseStatus; | ||
|
||
@ResponseStatus(value = HttpStatus.NOT_FOUND, reason = "Snapshot could not be created") | ||
public class SnapshotCouldNotBeCreatedException extends Exception{ | ||
private static final long serialVersionUID = 1L; | ||
|
||
public SnapshotCouldNotBeCreatedException(String id) { | ||
super("Snapshot could not be created for snapshot task id " + id + " not found"); | ||
} | ||
|
||
public SnapshotCouldNotBeCreatedException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
vspace/src/main/java/edu/asu/diging/vspace/core/file/IStorageManager.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package edu.asu.diging.vspace.core.file; | ||
|
||
import edu.asu.diging.vspace.core.exception.FileStorageException; | ||
import edu.asu.diging.vspace.core.model.IVSImage; | ||
|
||
public interface IStorageManager { | ||
|
||
/** | ||
* Copies given image from uploads to exhibition snapshot folder | ||
* | ||
* @param image | ||
* @param imagesFolderPath | ||
* @throws FileStorageException | ||
*/ | ||
void copyImage(IVSImage image, String imagesFolderPath) throws FileStorageException; | ||
|
||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.