Skip to content

Commit

Permalink
fix packt plugin (#110)
Browse files Browse the repository at this point in the history
  • Loading branch information
spolti authored Dec 28, 2022
1 parent 4b828eb commit 75d3af3
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ public void populate() {
}

BufferedReader reader = new BufferedReader(new StringReader(response.body().string()));
// navigate directly to the end of the html to get the product ID and get the 'const metaProductId' value
// navigate directly more or lest to where the product ID is and get the 'const metaProductId' value
// it is at the end of the html page.
Optional<String> metaProductId = reader.lines().skip(1616)
Optional<String> metaProductId = reader.lines().skip(1000)
.filter(s -> s.contains("const metaProductId"))
.map(s -> s.split("=")[1].replace("\'", "").replace(";", "").trim())
.findFirst();
Expand Down Expand Up @@ -141,7 +141,6 @@ public void populate() {
);
}
} catch (final Exception e) {
e.printStackTrace();
log.warnv("Failed to obtain the ebook information: {0}", e.getMessage());
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ quarkus.datasource.jdbc.min-size=8
quarkus.hibernate-orm.database.generation=update
# set to true to troubleshooting purposes
quarkus.hibernate-orm.log.sql=false
quarkus.log.category."org.hibernate.cache".level=DEBUG
quarkus.log.category."org.hibernate.cache".level=INFO

# not needed if create-drop database generation is used.
# It is required if a old version of ReBot was running
Expand All @@ -21,8 +21,8 @@ quarkus.log.category."org.hibernate.cache".level=DEBUG
# dev
%dev.quarkus.datasource.db-kind=h2
%dev.quarkus.datasource.jdbc.url=jdbc:h2:mem:testdb
%dev.quarkus.hibernate-orm.log.sql=true
%dev.quarkus.log.category."org.hibernate".level=DEBUG
%dev.quarkus.hibernate-orm.log.sql=false
%dev.quarkus.log.category."org.hibernate".level=INFO
%dev.quarkus.log.category."org.hibernate.cache".level=DEBUG
%dev.xyz.rebasing.rebot.telegram.userId=userid
%dev.xyz.rebasing.rebot.telegram.token=token
Expand Down
5 changes: 4 additions & 1 deletion rebot-telegram/src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,14 @@ quarkus.log.file.path=/tmp/quarkus.log
quarkus.log.file.level=TRACE
quarkus.log.file.format=%d{HH:mm:ss} %-5p [%c{2.}]] (%t) %s%e%n

# log definitions
quarkus.log.category."org.hibernate".level=INFO

# dev
%dev.quarkus.log.min-level=TRACE
%dev.quarkus.log.console.level=TRACE
%dev.quarkus.log.category."xyz.rebasing".level=TRACE
%dev.quarkus.log.category."org.hibernate.cache".level=DEBUG
%dev.quarkus.log.category."org.hibernate.cache".level=INFO
%dev.quarkus.log.category."org.jbpm.process".level=TRACE
%dev.quarkus.log.category."xyz.rebasing.rebot.plugin.postalcode.utils.BrazilPostalCodeUtils".level=INFO
%dev.quarkus.devservices.enabled=false
Expand Down

0 comments on commit 75d3af3

Please sign in to comment.