B4J Question Request for help due to scalability problem

Joan Paz

Member
Hello!

Im part of a company and we are currently carrying out several web application projects using B4j and Abmaterial, and the use of these tools has allowed us to greatly streamline our processes and has also allowed us to advance in our objectives in a very agile way. However, one of our projects, which is the most important and extensive in this moment, has generated some inconveniences associated with the number of modules that have been developed and we are sure that the problems that are happening to us are due to the fact that we have more than 130 modules (between classes and code), since these same problems do not happen to us in small projects of less than 20 modules. The problems that are happening to us due to the aforementioned are:

- Slowness at the moment of compiling in debug, happening in many cases errors that conclude the complilacion or freeze the b4j.

- The system.memory.exception error is frequent while we are working.

- Freezing of the b4j while we are writing source code.

- The hot code swap on the compiled version (Ctrl + S) stops working.

We are using a development enviroment with this specs:

- Intel i5 or i7, 7th generation.
- RAM 8 or 16 gb.
- Windows 10.
- java jdk1.8.0_202.
- B4j V7
- ABmaterial v 4.51

Due to the aforementioned, we thanks support if there is a possibility. If there is any corporate or x64 version that allows us to improve the performance of this great tool or any improvement that we could apply to solve our problem, we thank you in advance for your help with this.

Thanks a lot.
 
Last edited:

Tayfur

Well-Known Member
Licensed User
Longtime User


Hello there ;
I'm developing a program for my company.
More modules are added every week. and will add...
I had an error last week when run on debug mode.
And I opened a bug report (https://www.b4x.com/android/forum/threads/error-debug-mode-on-starting.101845/)
Now B4J app works goood. I explaned my solitions under below.
I LOVE to use B4J. I am sure @Erel fix it . Please share results ...

Not: My solitions for my problems; Its maybe halp you.
I didit change my project code.
  • Delete Object folder
  • I had more than one JAva version. I deleted all. I re -insatall last versiyon JAVA 1.8.202
  • Delete b4j and re install (this was my first choice and it didn't work.)
 
Last edited:
Upvote 0

Joan Paz

Member
1. Can you post the compilation window text?

2. Can you post a screenshot with the memory error?

Hello!

Thanks a lot for answer Mr. Erel.

1. Compilation windows text:

B4X:
Waiting for debugger to connect...
Program started.
Start B4J Analyse!
When an error occurs, check the B4JAnalyse.log file in the Objects folder to see the last B4J line it was working on.
Collecting data from B4J source files... (1/2)
EventosNomina.bas
UtilsAtenticacion.bas
utilitarios_main.bas
EstilosTemas.bas
UtilsSQLCore.bas
visualizeutils.bas
selectizejs.bas
pushjs.bas
DBM.bas
UtilsEventos.bas
catalogos_g_main.bas
horarios_main.bas
estilos_core.bas
UserHandler.bas
configuraciones_main.bas
Utils.bas
construccionmenu.bas
utilsHorarios.bas
UtilsConfiguraciones.bas
utilsPersonas.bas
UtilsV2.bas
nomina_main.bas
utilsConceptos.bas
utilsNomina.bas
autenticacion_main.bas
ChatShared.bas
altaempleado_main.bas
catalogos_e_main.bas
EventosComunicaciones.bas
procesos_main.bas
ABMShared.bas
EventosHorarios.bas
UtilsAprobaciones.bas
aprobaciones_main.bas
comunicaciones_main.bas
ABMCustomComponentTemplate.bas
TabsNew.bas
captchacus.bas
PeriodPickerCus.bas
B4JSValidaciones.bas
ABMTableGrid.bas
DatePickercus.bas
DateTimePickerCus.bas
Periodpicker.bas
TimePickerCus.bas
visualizedashboard.bas
visualizereport.bas
ABMCacheScavenger.bas
ABMUploadHandler.bas
ABMCacheControl.bas
ABMErrorHandler.bas
LikeComponent.bas
AjaxHandler.bas
ABMRootFilter.bas
Post.bas
alta_postulacion.bas
auth_ini.bas
badlogin.bas
carga.bas
setupWizard.bas
abc_cadenasAprobaciones.bas
ABMPageTemplateAlternative.bas
recovery.bas
seleccion_locacion.bas
abc_importarData.bas
sandbox.bas
SelectizeCus.bas
abc_recuperacion.bas
abc_empleados.bas
abc_familia.bas
abc_padecimiento.bas
abc_personaeducacion.bas
abc_personaexperiencia.bas
abc_personas.bas
datos_pagoEmpleado.bas
abc_areas.bas
abc_categoria.bas
abc_ciudad.bas
TimeLinePage.bas
abc_deptos.bas
abc_empresas.bas
abc_empresasPagadoras.bas
abc_estado.bas
abc_estadoCivil.bas
abc_Idioma.bas
abc_importarAreas.bas
abc_instituto_educativo.bas
abc_moneda.bas
abc_municipio.bas
ains.bas
abc_origenEmpleado.bas
abc_pais.bas
abc_personasCategoria.bas
abc_puestosDescripciones.bas
abc_registroPatronal.bas
abc_tipoGenero.bas
abc_tipoParentesco.bas
abc_AsignarHorario_v2.bas
abc_curso_empleado.bas
abc_eventos.bas
abc_cursos.bas
abc_dia_asueto.bas
abc_dia_asueto_v2.bas
abc_incidencia_rh.bas
abc_Listado_sesion.bas
abc_listado_tipohorario.bas
abc_personaConstante.bas
abc_sesiones.bas
abc_mov_hor_per.bas
customselect2.bas
usuario_locacion.bas
abc_locaciones.bas
abc_banco.bas
abc_categoriaTalla.bas
abc_registroHora.bas
abc_personaNomina.bas
ChatPage.bas
abc_puestos.bas
abc_areas_estudio.bas
abc_incidenciaPersona.bas
abc_vacantes.bas
inicio.bas
login.bas
abc_usuarios.bas
descripcion_puestos.bas
abc_acumulados.bas
abc_calculoNomina.bas
abc_cierrePeriodo.bas
abc_conceptos.bas
abc_configurarRecibo.bas
abc_constantes.bas
abc_creditos.bas
abc_pagoCreditos.bas
abc_personaAcumulados.bas
abc_tipoNomina.bas
abc_variablesSistema.bas
creacionmenu.bas
alta_empleado.bas
abc_categoriaItem.bas
abc_ccosto.bas
abc_contratoTypes.bas
abc_modalidad.bas
abc_norma.bas
abc_objetivo_dc.bas
abc_sesion_lugar.bas
abc_tematica_cursos.bas
abc_tipo_curso.bas
abc_tipoDeuda.bas
abc_tipoDocumento.bas
abc_tipoEducacion.bas
abc_tipoEnfermedad.bas
abc_tipoEquipo.bas
abc_tipoSolicitud.bas
inicializador.bas
redireccionador.bas
abc_incidencia.bas
abc_postulaciones.bas
oferta_vacantes.bas
postular_vacante.bas
abc_aprobaciones.bas
userdashboard.bas
abc_perfiles.bas
ABMApplication.bas
abc_comunicado.bas
abc_clases.bas
abc_politicas.bas
ABMPageTemplate.bas
core-base.b4j
Analysing data from B4J source files... (2/2)
Number of icons needed: 808
loading C:\B4J_FAST\PROYEC~1\CORE-B~1.51\Objects: copymewithjar.needs...
Using cache system: 3.0
Current App version: 1551032506471
Needs material/awesome icons
success
Building C:\B4J_FAST\PROYEC~1\CORE-B~1.51\Objects\copymewithjar.js.needs
Cloning to C:\B4J_FAST\PROYEC~1\CORE-B~1.51\Objects\www\core-base\b4js.1551032506471.js
Building core.min.1551032506471.css...
2019-02-24 14:22:30.075:INFO::main: Logging initialized @45612ms to org.eclipse.jetty.util.log.StdErrLog
2019-02-24 14:22:30.248:INFO:oejs.Server:main: jetty-9.4.z-SNAPSHOT; built: 2018-05-03T15:56:21.710Z; git: daa59876e6f384329b122929e70a80934569428c; jvm 1.8.0_202-b08
2019-02-24 14:22:30.303:INFO:oejs.session:main: DefaultSessionIdManager workerName=node0
2019-02-24 14:22:30.303:INFO:oejs.session:main: No SessionScavenger set, using defaults
2019-02-24 14:22:30.306:INFO:oejs.session:main: node0 Scavenging every 600000ms
2019-02-24 14:22:30.367:INFO:oejsh.ContextHandler:main: Started o.e.j.s.ServletContextHandler@7a419da4{/,file:///C:/B4J_FAST/PROYECTO_CORE/core-base%20ver%204.51/Objects/www/,AVAILABLE}
2019-02-24 14:22:30.371:INFO:oejs.AbstractNCSARequestLog:main: Opened C:\B4J_FAST\PROYECTO_CORE\core-base ver 4.51\Objects\logs\b4j-2019_02_24.request.log
2019-02-24 14:22:30.385:INFO:oejs.AbstractConnector:main: Started ServerConnector@53fdffa1{HTTP/1.1,[http/1.1]}{0.0.0.0:8585}
2019-02-24 14:22:30.385:INFO:oejs.Server:main: Started @45923ms
Emulated network latency: 100ms
2019-02-24 14:22:30.392:INFO:oejs.AbstractConnector:main: Stopped ServerConnector@53fdffa1{HTTP/1.1,[http/1.1]}{0.0.0.0:8585}
2019-02-24 14:22:30.393:INFO:oejs.session:main: node0 Stopped scavenging
2019-02-24 14:22:30.396:INFO:oejsh.ContextHandler:main: Stopped o.e.j.s.ServletContextHandler@7a419da4{/,file:///C:/B4J_FAST/PROYECTO_CORE/core-base%20ver%204.51/Objects/www/,UNAVAILABLE}
2019-02-24 14:22:30.399:INFO:oejs.Server:main: jetty-9.4.z-SNAPSHOT; built: 2018-05-03T15:56:21.710Z; git: daa59876e6f384329b122929e70a80934569428c; jvm 1.8.0_202-b08
2019-02-24 14:22:30.430:INFO:oejsh.ContextHandler:main: Started o.e.j.s.ServletContextHandler@7a419da4{/,file:///C:/B4J_FAST/PROYECTO_CORE/core-base%20ver%204.51/Objects/www/,AVAILABLE}
2019-02-24 14:22:30.431:INFO:oejs.AbstractNCSARequestLog:main: Opened C:\B4J_FAST\PROYECTO_CORE\core-base ver 4.51\Objects\logs\b4j-2019_02_24.request.log
2019-02-24 14:22:30.431:INFO:oejs.session:main: DefaultSessionIdManager workerName=node0
2019-02-24 14:22:30.431:INFO:oejs.session:main: No SessionScavenger set, using defaults
2019-02-24 14:22:30.431:INFO:oejs.session:main: node0 Scavenging every 600000ms
2019-02-24 14:22:30.435:INFO:oejs.AbstractConnector:main: Started ServerConnector@53fdffa1{HTTP/1.1,[http/1.1]}{0.0.0.0:8585}
2019-02-24 14:22:30.435:INFO:oejs.Server:main: Started @45974ms
2019-02-24 14:22:30.436:INFO:oejs.session:main: node0 Scavenging every 990000ms

2. Memory error:










Thanks again.
 

Attachments

  • upload_2019-2-24_14-35-2.png
    318.3 KB · Views: 337
Upvote 0

Joan Paz

Member
Are you using a shared network drive for your work? If yes, try to edit/debug your project on a local drive.

PS: Never had similar issues, even if I work for hours

Hi!

Actually im runnig the project in a solid state disk, because im trying to improve the compilation speed.

Thanks a lot.
 
Upvote 0

Joan Paz

Member

Hello!

Im in the same situation, i really love B4j but im little worry because our project is growing quickly and we have this problems that generate a delay in the development.
In relation to the attempts to solve the problems, I did the same as you, i updated my version of b4j from 6 to 7, updated my java from 111 to 202 and even the Abmaterial took it to the latest version 4.51, but still continued with the problems i mentioned. I hope we can find the best way to solve this problems to keep growing with this wonderful development tool.

Thanks a lot!
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
Upvote 0

Joan Paz

Member
Why are you setting the VM heap size to 3gb? You are probably running out of available space. Set it to a lower value during development.
Hello! the truth is that I did it as part of my tests, I tested it in 1024, 2048, and even 6144 but the problems remain.

Thanks!
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…