Angular5 PDF Generation from HTML or JSON - spring

I am working with angular5 app with backend in spring java , I need to create PDF (exam form preview pdf) , can you please suggest me on which side is preferable (client or server) ? if on client then suggest me any ng5 package .

On server side. There are a lot of examples how to create pdf in java. Simply google it. Here are few of them.
Spring MVC - Generate PDF Example
Generate PDF Using Spring Framework
Creating PDF Files in Java

Related

How to generate an OpenAPI from a Spring app without running the app?

I can run a Spring Boot application and then use the springdoc-openapi-maven-plugin artifact to generate an OpenAPI spec.
However, is there also a way to generate the spec without running the application first?
I currently want to generate the spec in a GitHub Action and a direct way would simplify this a lot.
you can use swagger editor: https://editor.swagger.io/
It allows you to write a json/yaml with your specifications and at the same time you can view the result.
Also, in the upper part there are 2 features, which allow you to generate the code based on the json/yaml made.
For example you can create a spring application with all the endpoints you go to specify in your json/yaml ( server).
But you can also generate HTML. (Client)

Replace JSP with Thymeleaf in Legacy Application

My company wants to level up by deploying our web-application as spring boot executable jar:
Specifications (Legacy Webpap):
classic web app (25 years old) but now with Spring
Over 100 jsp files
And more jsp files generated by our custom jsp generator
Custom jsp tag lib with more than 30 java classes
All jsp files are html 4 files with Active X components.
Problem
One of the main problems is that jsp rendition is not supported in executable jars. Therefore I consider using Thymeleaf. My best guess is to replace the rendition process in our custom jsp generator. In the future (don't know when that is) we plan to migrate to a single page web app but for now I need to run the web app as jar and with our existing templates and tag library.
Draft
My Question
Is it possible to use Thymeleaf along with our custom tag library?

BIRT spring Integration

New to BIRT, started 3 days back.
Requirement
Will have REPORTING menu in the existing web application, which will give option to choose the type of report(pdf and chart(drilled down also))
and generate the selected chart with the mentioned date.
What I had done so far
Tried stand-alone report application using sample database.
created a birt rest service, but not sure how to feed data to that.
Calrification required
Do I need to create a template using report design eclipse plugin and an application which is a spring boot where I can connect to
database using hibernate and feed the template with data or is there any better approach in this?
My application consists of REST API and the client will consume it. So what will be the return type of the birt web service? Is it a byte stream?
To run BIRT on existing tomcat server, Do I need any other libraries.
Has been referred a lot of articles regarding BIRT, really stuck at integrating with an existing application. Thanks in advance

Spring MVC template engin vs plane html

I'm a little confused about template engines like thymeleaf or velocity.
My question is are there any profits from using template engine instead plain html + angular?
I'm asking because I'm developing application using
Spring boot 1.3.2
Angular 1.4.8
Thymeleaf
and I'm wondering if is a chance in Spring MVC application that I'll nead template engine instead make it all in plain hmtl + angular?
AngularJS is as client-side Javascript framework.
Thymeleaf is a server-side template engine capable of create HTML, CSS, Javascript and text.
You can use both to create your web app.
For instance you can send to your customers already processed pages by Thymeleaf with the client specific data. As the customer interacts with your page you can use AngularJS to bring data from your server via Ajax or to process his requests locally, so your server will not need to send the entire page to your customer as he interacts with your page, this will make your page faster.

Spring XD facebook data extraction

Is there anyway to extract Facebook data using Spring XD?
I am now able to extract Facebook data using Graph api, Json, Java Program, but the question is if could I integrate this this to be executed automatically through Spring XD.
You can create a custom source module.
If it is general enough, consider contributing it to spring-xd-modules. The README has information about contributing.

Resources