Git Product home page Git Product logo

file-management-system's People

Contributors

sdrahnea avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

file-management-system's Issues

[FMS-14] Delete data older by age

Implement functionality which allow application to remove the file by age.

Add new property: age in days / months / years
Example:
file.cleanup.age=100
file.cleanup.age.type=DAY or MONTH. or YEAR

File cleanup is not enable:

  • by default, no property was declared
  • properties are declared, but empty

Should be like a scheduler which run at least once per day and execute file clean up.

Note: if the application uses the database then the records should be disabled from the all possible business flows.

[FMS-8] Implement storage strategy - FILE_PER_YEAR_DATE

Storage strategy - FILE_PER_YEAR_DATE (no storage into database)

File storage based on the following rule: ${file.db.location} / ${tenant} / ${year}/ ${date} /${file_id}

To storage the file, the request will contains: tenant. To return the file_id and date (when file was created).
To receive the file, the request will contains: tenant / year / date / file_id.

[FMS-10] Implement storage strategy - FILE_PER_YEAR_MONTH_DAY

Storage strategy - FILE_PER_YEAR_MONTH_DAY (no storage into database)

File storage based on the following rule: ${file.db.location} / ${tenant} / ${year}/ ${month}/ ${day} /${file_id}

To storage the file, the request will contains: tenant. To return the file_id and date (when file was created).
To receive the file, the request will contains: tenant / year / month / day / file_id.

[FMS-6] Implement storage strategy: FILE

Storage strategy - FILE (no storage into database)

File storage based on the following rule: ${file.db.location} / ${tenant} / ${file_id}

To storage the file, the request will contains: tenant. To return the file_id.
To receive the file, the request will contains: tenant and file_id.

[FMS-9] Implement storage strategy - FILE_PER_YEAR_MONTH_DATE

Storage strategy - FILE_PER_YEAR_MONTH_DATE (no storage into database)

File storage based on the following rule: ${file.db.location} / ${tenant} / ${year}/ ${month}/ ${date} /${file_id}

To storage the file, the request will contains: tenant. To return the file_id and date (when file was created).
To receive the file, the request will contains: tenant / year / month / date / file_id.

[FMS-1] Unable to process parts as no multi-part configuration has been provided

java 9 / 11

2021-05-04T15:57:30,661 ERROR [http-nio-8081-exec-10] o.a.j.l.DirectJDKLog: Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.springframework.web.multipart.MultipartException: Failed to parse multipart servlet request; nested exception is java.lang.IllegalStateException: Unable to process parts as no multi-part configuration has been provided] with root cause
java.lang.IllegalStateException: Unable to process parts as no multi-part configuration has been provided
at org.apache.catalina.connector.Request.parseParts(Request.java:2856)
at org.apache.catalina.connector.Request.getParts(Request.java:2824)
at org.apache.catalina.connector.RequestFacade.getParts(RequestFacade.java:1098)
at org.springframework.web.multipart.support.StandardMultipartHttpServletRequest.parseRequest(StandardMultipartHttpServletRequest.java:95)
at org.springframework.web.multipart.support.StandardMultipartHttpServletRequest.(StandardMultipartHttpServletRequest.java:88)
at org.springframework.web.multipart.support.StandardMultipartHttpServletRequest.(StandardMultipartHttpServletRequest.java:72)
at org.springframework.web.multipart.support.MultipartResolutionDelegate.resolveMultipartArgument(MultipartResolutionDelegate.java:106)
at org.springframework.web.servlet.mvc.method.annotation.RequestPartMethodArgumentResolver.resolveArgument(RequestPartMethodArgumentResolver.java:128)
at org.springframework.web.method.support.HandlerMethodArgumentResolverComposite.resolveArgument(HandlerMethodArgumentResolverComposite.java:121)
at org.springframework.web.method.support.InvocableHandlerMethod.getMethodArgumentValues(InvocableHandlerMethod.java:170)
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:137)
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:106)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:894)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:808)
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1060)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:962)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006)
at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:909)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:652)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:733)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:227)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:542)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:143)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:357)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:374)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:893)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1707)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.base/java.lang.Thread.run(Thread.java:836)

Process finished with exit code -1

[FMS-13] Add java client for fms

Add java client for fms as a project, so anybody should be able to see an example about show to exchange the dates between a supposed client application and file management system.

Should an sample for each end-point.

[FMS-7] Implement storage strategy: FILE_PER_DATE

Storage strategy - FILE_PER_DATE (no storage into database)

File storage based on the following rule: ${file.db.location} / ${tenant} / ${date}/ ${file_id}

To storage the file, the request will contains: tenant. To return the file_id and date (when file was created).
To receive the file, the request will contains: tenant / date / file_id.

[FMS-3] add multi-tenant possibility

the application should be storage files based on tenant.
The default file structure should be:
{$file.db.location} / {$tenant} / {$DEFAULT_STRATEGY_DIRECTORY: current_date} / {$FILE_ID}

where properties (except the last one) are folders and if not present then create :

  1. file.db.location - base root where will be saved all files content
  2. tenant - folder for related tenant
  3. DEFAULT_STRATEGY_DIRECTORY - in future to be able to create folders based on different strategies. Currently it should be create a folder based on current date
  4. FILE_ID - the id which is received from the client

[FMS-11] FILE_PER_YEAR_MONTH

Storage strategy - FILE_PER_YEAR_MONTH_DAY (no storage into database)

File storage based on the following rule: ${file.db.location} / ${tenant} / ${year}/ ${month} /${file_id}

To storage the file, the request will contains: tenant. To return the file_id and date (when file was created).
To receive the file, the request will contains: tenant / year / month / file_id.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.