ActiveWeb is a Java web framework inspired by Ruby on Rails. It is optimized to be sustainable, productive, and familiar for Java developers.
Questions tagged [activeweb]
49 questions
0
votes
1 answer
activeweb ContentFor tag render nothing?
I have read content for and yield tag section of activeweb doc. and activeweb version
16:59 $ mvn dependency:tree | grep activeweb
[INFO] +- org.javalite:activeweb:jar:2.2:compile
[INFO] +- org.javalite:activeweb-testing:jar:2.2:test
The layout.ftl…

Jack Tang
- 59
- 5
0
votes
2 answers
Javalite framwork in production env
I am going to ship out the first version of webapp base on Javalite framework. Thanks the framework, it makes the developing rapidly :). Here are some goals in my production env.
I would like to use maven-assembly-plugin to assemble all…

Jack Tang
- 59
- 5
0
votes
1 answer
URL mapping is not available in activeweb 2.0
In activeweb 2.0, if there is a space in the tomcat installation directory, then there will be no packages, so can not found the correct Controller and action.
Because the space will be replaced with '%20' when we use the classLoader get current…

靳刘杰
- 25
- 4
0
votes
1 answer
How to support netsted resources in ActiveWeb
Two models named "Post" and "Comment", and I want to build RESTful route like /post/123/comment/8 and CommentsController handles all RESTful actions.
I have tried…

Jack Tang
- 59
- 5
0
votes
1 answer
Any example of uploading files using activeweb?
I try to upload some csv files to server side and process them and save to database, any example about uploading file in activeweb?

Jack Tang
- 59
- 5
0
votes
1 answer
ActiveWeb: mocking injected service
When mocking a service injected into a controller, a service method should return a mocked object, something like that:
public class EmptyInterventionServiceMock implements InterventionService {
@Override
public Intervention…

belgoros
- 3,590
- 7
- 38
- 76
0
votes
1 answer
ActiveWeb: testing JSON response attributes and values
What is the preferred way to test JSON response, especially the attributes and values to be present in ? What is the right type of a controller to extend from: IntegrationSpec, ControllerSpec, AppIntegrationSpec? I didn't find the proper response in…

belgoros
- 3,590
- 7
- 38
- 76
0
votes
0 answers
ActiveWeb controller : testing headers values presence
I tried to test the presence of Authorization value in the request header and my AuthorizationFilter has never been hit:
@Test
public void shouldContainAuthorizationHeader() {
…

belgoros
- 3,590
- 7
- 38
- 76
0
votes
2 answers
ActiveWeb: model setter/getter does not work when calling in the template
When working with a legacy database, there are cases when I can't set up the relations properly using belongs_to annotation. In this case, I tried to define an attribute pointing to another Model class with its accessors methods as…

belgoros
- 3,590
- 7
- 38
- 76
0
votes
1 answer
How to configure a custom date format for ActiveWeb templates
The views docs have an example of number format configuration:
public class FreeMarkerConfig extends AbstractFreeMarkerConfig {
@Override
public void init() {
//this is to override a strange FreeMarker default processing of numbers
…

belgoros
- 3,590
- 7
- 38
- 76
0
votes
1 answer
ActiveWeb view - <@compress single_line=true>
I wonder what is the following declaration/macro used for (I'm rendering a custom JSON response):
<@compress single_line=true>
{
attribute_1: ${my_model.attribute_1},
attribute_2: ${my_model.attribute_2},
attribute_3:…

belgoros
- 3,590
- 7
- 38
- 76
0
votes
1 answer
Checking header for token presence
Is it possible to check header for available token and other OAuth values with ActiveWeb ? Are there any examples repos ? Thank you.

belgoros
- 3,590
- 7
- 38
- 76
0
votes
1 answer
ControllerRunner's Execution order
this is the activeweb2.0 source code
protected void run(Route route) throws Exception {
Configuration.injectFilters(); //no worries, will execute once, as filters have a life span of the app
try {
try { //nested try , a bit ugly, but…

靳刘杰
- 25
- 4
0
votes
1 answer
Can't get tests to pass on Gitlab CI
I've been trying to get our tests to pass on our Gitlab CI, but can't. I'm using the stock pipelines config that comes with Gitlab. All I've had to do is provide the gitlab yaml file to config the CI.
This is what we're using
image:…

Nibarulabs
- 7
- 2
0
votes
1 answer
Which version of tomcat should I be running on production
I have Jetty 9 deployed on production right now. I was working, but then recently I pushed some change and now my production database jndi connection doesn't work anymore. ActiveWeb complains
There are no connection specs in 'production'…

Nibarulabs
- 7
- 2